	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nand_default_bbt               ## -- Begin function nand_default_bbt
	.p2align	4, 0x90
_nand_default_bbt:                      ## @nand_default_bbt
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	8(%rdi), %rax
	movl	(%rax), %ecx
	movq	_NAND_IS_AND@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_4
## %bb.1:
	cmpq	$0, 24(%rax)
	jne	LBB0_3
## %bb.2:
	movq	_bbt_main_descr@GOTPCREL(%rip), %rdx
	movq	%rdx, 24(%rax)
	movq	_bbt_mirror_descr@GOTPCREL(%rip), %rdx
	movq	%rdx, 16(%rax)
LBB0_3:
	movq	_NAND_USE_FLASH_BBT@GOTPCREL(%rip), %rdx
	orl	(%rdx), %ecx
	movl	%ecx, (%rax)
	movq	_agand_flashbased@GOTPCREL(%rip), %rsi
	popq	%rbp
	jmp	_nand_scan_bbt                  ## TAILCALL
LBB0_4:
	movq	_NAND_USE_FLASH_BBT@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_11
## %bb.5:
	cmpq	$0, 24(%rax)
	jne	LBB0_7
## %bb.6:
	movq	_bbt_main_descr@GOTPCREL(%rip), %rcx
	movq	%rcx, 24(%rax)
	movq	_bbt_mirror_descr@GOTPCREL(%rip), %rcx
	movq	%rcx, 16(%rax)
LBB0_7:
	movq	8(%rax), %rsi
	testq	%rsi, %rsi
	je	LBB0_8
LBB0_16:
	popq	%rbp
	jmp	_nand_scan_bbt                  ## TAILCALL
LBB0_11:
	xorps	%xmm0, %xmm0
	movups	%xmm0, 16(%rax)
	movq	8(%rax), %rsi
	testq	%rsi, %rsi
	jne	LBB0_16
## %bb.12:
	cmpl	$513, (%rdi)                    ## imm = 0x201
	jl	LBB0_13
## %bb.14:
	movq	_largepage_memorybased@GOTPCREL(%rip), %rsi
	jmp	LBB0_15
LBB0_8:
	cmpl	$513, (%rdi)                    ## imm = 0x201
	jl	LBB0_9
## %bb.10:
	movq	_largepage_flashbased@GOTPCREL(%rip), %rsi
	jmp	LBB0_15
LBB0_9:
	movq	_smallpage_flashbased@GOTPCREL(%rip), %rsi
	jmp	LBB0_15
LBB0_13:
	movq	_smallpage_memorybased@GOTPCREL(%rip), %rsi
LBB0_15:
	movq	%rsi, 8(%rax)
	popq	%rbp
	jmp	_nand_scan_bbt                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_NAND_IS_AND,4,2                ## @NAND_IS_AND
	.comm	_bbt_main_descr,4,2             ## @bbt_main_descr
	.comm	_bbt_mirror_descr,4,2           ## @bbt_mirror_descr
	.comm	_NAND_USE_FLASH_BBT,4,2         ## @NAND_USE_FLASH_BBT
	.comm	_agand_flashbased,4,2           ## @agand_flashbased
	.comm	_largepage_flashbased,4,2       ## @largepage_flashbased
	.comm	_smallpage_flashbased,4,2       ## @smallpage_flashbased
	.comm	_largepage_memorybased,4,2      ## @largepage_memorybased
	.comm	_smallpage_memorybased,4,2      ## @smallpage_memorybased
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nand_default_bbt               ; -- Begin function nand_default_bbt
	.p2align	2
_nand_default_bbt:                      ; @nand_default_bbt
	.cfi_startproc
; %bb.0:
	ldr	x8, [x0, #8]
	ldr	w9, [x8]
Lloh0:
	adrp	x10, _NAND_IS_AND@GOTPAGE
Lloh1:
	ldr	x10, [x10, _NAND_IS_AND@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_4
; %bb.1:
	ldr	x10, [x8, #24]
	cbnz	x10, LBB0_3
; %bb.2:
Lloh3:
	adrp	x10, _bbt_main_descr@GOTPAGE
Lloh4:
	ldr	x10, [x10, _bbt_main_descr@GOTPAGEOFF]
Lloh5:
	adrp	x11, _bbt_mirror_descr@GOTPAGE
Lloh6:
	ldr	x11, [x11, _bbt_mirror_descr@GOTPAGEOFF]
	stp	x11, x10, [x8, #16]
LBB0_3:
Lloh7:
	adrp	x10, _NAND_USE_FLASH_BBT@GOTPAGE
Lloh8:
	ldr	x10, [x10, _NAND_USE_FLASH_BBT@GOTPAGEOFF]
Lloh9:
	ldr	w10, [x10]
	orr	w9, w10, w9
	str	w9, [x8]
Lloh10:
	adrp	x1, _agand_flashbased@GOTPAGE
Lloh11:
	ldr	x1, [x1, _agand_flashbased@GOTPAGEOFF]
	b	_nand_scan_bbt
LBB0_4:
Lloh12:
	adrp	x10, _NAND_USE_FLASH_BBT@GOTPAGE
Lloh13:
	ldr	x10, [x10, _NAND_USE_FLASH_BBT@GOTPAGEOFF]
Lloh14:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_9
; %bb.5:
	ldr	x9, [x8, #24]
	cbnz	x9, LBB0_7
; %bb.6:
Lloh15:
	adrp	x9, _bbt_main_descr@GOTPAGE
Lloh16:
	ldr	x9, [x9, _bbt_main_descr@GOTPAGEOFF]
Lloh17:
	adrp	x10, _bbt_mirror_descr@GOTPAGE
Lloh18:
	ldr	x10, [x10, _bbt_mirror_descr@GOTPAGEOFF]
	stp	x10, x9, [x8, #16]
LBB0_7:
	ldr	x1, [x8, #8]
	cbz	x1, LBB0_11
LBB0_8:
	b	_nand_scan_bbt
LBB0_9:
	stp	xzr, xzr, [x8, #16]
	ldr	x1, [x8, #8]
	cbnz	x1, LBB0_8
; %bb.10:
Lloh19:
	adrp	x9, _smallpage_memorybased@GOTPAGE
Lloh20:
	ldr	x9, [x9, _smallpage_memorybased@GOTPAGEOFF]
	ldr	w10, [x0]
Lloh21:
	adrp	x11, _largepage_memorybased@GOTPAGE
Lloh22:
	ldr	x11, [x11, _largepage_memorybased@GOTPAGEOFF]
	b	LBB0_12
LBB0_11:
Lloh23:
	adrp	x9, _smallpage_flashbased@GOTPAGE
Lloh24:
	ldr	x9, [x9, _smallpage_flashbased@GOTPAGEOFF]
	ldr	w10, [x0]
Lloh25:
	adrp	x11, _largepage_flashbased@GOTPAGE
Lloh26:
	ldr	x11, [x11, _largepage_flashbased@GOTPAGEOFF]
LBB0_12:
	cmp	w10, #512
	csel	x1, x11, x9, gt
	str	x1, [x8, #8]
	b	_nand_scan_bbt
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_NAND_IS_AND,4,2                ; @NAND_IS_AND
	.comm	_bbt_main_descr,4,2             ; @bbt_main_descr
	.comm	_bbt_mirror_descr,4,2           ; @bbt_mirror_descr
	.comm	_NAND_USE_FLASH_BBT,4,2         ; @NAND_USE_FLASH_BBT
	.comm	_agand_flashbased,4,2           ; @agand_flashbased
	.comm	_largepage_flashbased,4,2       ; @largepage_flashbased
	.comm	_smallpage_flashbased,4,2       ; @smallpage_flashbased
	.comm	_largepage_memorybased,4,2      ; @largepage_memorybased
	.comm	_smallpage_memorybased,4,2      ; @smallpage_memorybased
.subsections_via_symbols
