	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function verify_eraseblock_in_one_go
_verify_eraseblock_in_one_go:           ## @verify_eraseblock_in_one_go
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_mtd@GOTPCREL(%rip), %r12
	movq	(%r12), %rax
	movslq	(%rax), %rcx
	movslq	%edi, %rbx
	imulq	%rcx, %rbx
	movslq	4(%rax), %r14
	movq	_pgcnt@GOTPCREL(%rip), %rax
	movslq	(%rax), %r15
	imulq	%r14, %r15
	movq	_writebuf@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	_rnd_state@GOTPCREL(%rip), %rdi
	movq	%r15, %rdx
	callq	_prandom_bytes_state
	movq	_MTD_OPS_AUTO_OOB@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	movl	$0, -48(%rbp)
	movq	$0, -56(%rbp)
	movq	%r15, -96(%rbp)
	movq	$0, -88(%rbp)
	xorps	%xmm0, %xmm0
	movups	%xmm0, -72(%rbp)
	movq	_readbuf@GOTPCREL(%rip), %r13
	movq	(%r13), %rax
	movq	%rax, -80(%rbp)
	movq	(%r12), %rdi
	leaq	-96(%rbp), %rdx
	movl	%ebx, %esi
	callq	_mtd_read_oob
	movl	%eax, %r12d
	movl	%eax, %edi
	callq	_mtd_is_bitflip
	testl	%r12d, %r12d
	je	LBB0_2
## %bb.1:
	testq	%rax, %rax
	je	LBB0_13
LBB0_2:
	movl	$-1, %r12d
	cmpq	%r15, -88(%rbp)
	jne	LBB0_13
## %bb.3:
	movq	_pgcnt@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jle	LBB0_11
## %bb.4:
	xorl	%r12d, %r12d
	xorl	%r15d, %r15d
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_5 Depth=1
	movslq	%ebx, %rsi
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_pr_err
	movq	_errcnt@GOTPCREL(%rip), %rdx
	movl	(%rdx), %eax
	leal	1(%rax), %ecx
	movl	%ecx, (%rdx)
	cmpl	$1000, %eax                     ## imm = 0x3E8
	jge	LBB0_7
LBB0_10:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	_mtd@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	addl	8(%rax), %ebx
	incq	%r15
	movq	_pgcnt@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	addq	%r14, %r12
	cmpq	%rax, %r15
	jge	LBB0_11
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rsi
	addq	%r12, %rsi
	movq	_writebuf@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	addq	%r12, %rdx
	movl	%ebx, %edi
	movq	%r14, %rcx
	callq	_memcmpshow
	movq	_bitflip_limit@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	ja	LBB0_6
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_5 Depth=1
	leaq	L_.str.3(%rip), %rdi
	callq	_pr_info
	jmp	LBB0_10
LBB0_13:
	leaq	L_.str(%rip), %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_pr_err
	movq	_errcnt@GOTPCREL(%rip), %rax
	incl	(%rax)
	jmp	LBB0_12
LBB0_11:
	xorl	%r12d, %r12d
	jmp	LBB0_12
LBB0_7:
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_pr_err
	movl	$-1, %r12d
LBB0_12:
	movl	%r12d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mtd,8,3                        ## @mtd
	.comm	_pgcnt,4,2                      ## @pgcnt
	.comm	_rnd_state,4,2                  ## @rnd_state
	.comm	_writebuf,8,3                   ## @writebuf
	.comm	_MTD_OPS_AUTO_OOB,4,2           ## @MTD_OPS_AUTO_OOB
	.comm	_readbuf,8,3                    ## @readbuf
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"error: readoob failed at %#llx\n"

	.comm	_errcnt,4,2                     ## @errcnt
	.comm	_bitflip_limit,8,3              ## @bitflip_limit
L_.str.1:                               ## @.str.1
	.asciz	"error: verify failed at %#llx\n"

L_.str.2:                               ## @.str.2
	.asciz	"error: too many errors\n"

L_.str.3:                               ## @.str.3
	.asciz	"ignoring error as within bitflip_limit\n"

	.no_dead_strip	_verify_eraseblock_in_one_go
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function verify_eraseblock_in_one_go
_verify_eraseblock_in_one_go:           ; @verify_eraseblock_in_one_go
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x28, x27, [sp, #64]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
                                        ; kill: def $w0 killed $w0 def $x0
Lloh0:
	adrp	x23, _mtd@GOTPAGE
Lloh1:
	ldr	x23, [x23, _mtd@GOTPAGEOFF]
	ldr	x8, [x23]
	sxtw	x9, w0
	ldpsw	x10, x19, [x8]
Lloh2:
	adrp	x24, _pgcnt@GOTPAGE
Lloh3:
	ldr	x24, [x24, _pgcnt@GOTPAGEOFF]
	mul	x20, x10, x9
	ldrsw	x8, [x24]
	mul	x21, x8, x19
Lloh4:
	adrp	x25, _writebuf@GOTPAGE
Lloh5:
	ldr	x25, [x25, _writebuf@GOTPAGEOFF]
	ldr	x1, [x25]
Lloh6:
	adrp	x0, _rnd_state@GOTPAGE
Lloh7:
	ldr	x0, [x0, _rnd_state@GOTPAGEOFF]
	mov	x2, x21
	bl	_prandom_bytes_state
Lloh8:
	adrp	x8, _MTD_OPS_AUTO_OOB@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MTD_OPS_AUTO_OOB@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	stp	wzr, w8, [sp, #56]
	stp	x21, xzr, [sp, #8]
	stp	xzr, xzr, [sp, #40]
Lloh11:
	adrp	x26, _readbuf@GOTPAGE
Lloh12:
	ldr	x26, [x26, _readbuf@GOTPAGEOFF]
	ldr	x8, [x26]
	stp	x8, xzr, [sp, #24]
	ldr	x0, [x23]
	add	x2, sp, #8
	mov	x1, x20
	bl	_mtd_read_oob
	mov	x22, x0
	bl	_mtd_is_bitflip
	cmp	w22, #0
	ccmp	x0, #0, #0, ne
	b.eq	LBB0_10
; %bb.1:
	ldr	x8, [sp, #16]
	cmp	x8, x21
	b.ne	LBB0_9
; %bb.2:
	ldr	w8, [x24]
	cmp	w8, #1
	b.lt	LBB0_11
; %bb.3:
	mov	x27, #0
	mov	x28, #0
Lloh13:
	adrp	x22, _bitflip_limit@GOTPAGE
Lloh14:
	ldr	x22, [x22, _bitflip_limit@GOTPAGEOFF]
Lloh15:
	adrp	x21, _errcnt@GOTPAGE
Lloh16:
	ldr	x21, [x21, _errcnt@GOTPAGEOFF]
                                        ; kill: def $w20 killed $w20 killed $x20 def $x20
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	sxtw	x8, w20
	str	x8, [sp]
Lloh17:
	adrp	x0, l_.str.1@PAGE
Lloh18:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_err
	ldr	w8, [x21]
	add	w9, w8, #1
	str	w9, [x21]
	cmp	w8, #1000
	b.ge	LBB0_12
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x28, x28, #1
	ldr	x8, [x23]
	ldr	w8, [x8, #8]
	add	w20, w8, w20
	ldrsw	x8, [x24]
	add	x27, x27, x19
	cmp	x28, x8
	b.ge	LBB0_11
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x26]
	add	x1, x27, x8
	ldr	x8, [x25]
	add	x2, x27, x8
	mov	x0, x20
	mov	x3, x19
	bl	_memcmpshow
	ldr	x8, [x22]
	cmp	x0, x8
	b.hi	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	cbz	x0, LBB0_5
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh19:
	adrp	x0, l_.str.3@PAGE
Lloh20:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_pr_info
	b	LBB0_5
LBB0_9:
	mov	w22, #-1
LBB0_10:
	str	x20, [sp]
Lloh21:
	adrp	x0, l_.str@PAGE
Lloh22:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_err
Lloh23:
	adrp	x8, _errcnt@GOTPAGE
Lloh24:
	ldr	x8, [x8, _errcnt@GOTPAGEOFF]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
	b	LBB0_13
LBB0_11:
	mov	w22, #0
	b	LBB0_13
LBB0_12:
Lloh25:
	adrp	x0, l_.str.2@PAGE
Lloh26:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_pr_err
	mov	w22, #-1
LBB0_13:
	mov	x0, x22
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_mtd,8,3                        ; @mtd
	.comm	_pgcnt,4,2                      ; @pgcnt
	.comm	_rnd_state,4,2                  ; @rnd_state
	.comm	_writebuf,8,3                   ; @writebuf
	.comm	_MTD_OPS_AUTO_OOB,4,2           ; @MTD_OPS_AUTO_OOB
	.comm	_readbuf,8,3                    ; @readbuf
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"error: readoob failed at %#llx\n"

	.comm	_errcnt,4,2                     ; @errcnt
	.comm	_bitflip_limit,8,3              ; @bitflip_limit
l_.str.1:                               ; @.str.1
	.asciz	"error: verify failed at %#llx\n"

l_.str.2:                               ; @.str.2
	.asciz	"error: too many errors\n"

l_.str.3:                               ; @.str.3
	.asciz	"ignoring error as within bitflip_limit\n"

	.no_dead_strip	_verify_eraseblock_in_one_go
.subsections_via_symbols
