	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lpc32xx_nand_read_page_syndrome
_lpc32xx_nand_read_page_syndrome:       ## @lpc32xx_nand_read_page_syndrome
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r13d
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_nand_to_mtd
	movq	%rax, %r15
	movq	%r14, %rdi
	callq	_nand_get_controller_data
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	%rsp, %r12
	movl	$0, -56(%rbp)
	movq	_LPC32XX_ECC_SAVE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shlq	$2, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rax
	movq	%r14, %rdi
	movl	%r13d, %esi
	movq	%rax, %r13
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_nand_read_page_op
	movl	(%r14), %edx
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	$1, %ecx
	callq	_lpc32xx_xfer
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movq	24(%r14), %rsi
	movl	8(%r15), %edx
	movq	%r14, %rdi
	callq	*32(%r14)
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rsi
	movl	(%r14), %edx
	movq	%r13, %rdi
	callq	_lpc32xx_slc_ecc_copy
	leaq	-56(%rbp), %rdx
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_mtd_ooblayout_ecc
	testl	%eax, %eax
	jne	LBB0_6
## %bb.1:
	cmpl	$0, (%r14)
	jle	LBB0_2
## %bb.3:
	movq	%r12, -80(%rbp)                 ## 8-byte Spill
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	movq	%r13, %r15
	movslq	-56(%rbp), %r13
	shlq	$2, %r13
	addq	24(%r14), %r13
	movl	16(%r14), %eax
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	imull	%r12d, %eax
	cltq
	leaq	(%r15,%rax,4), %rcx
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	callq	*8(%r14)
	movl	%eax, %ecx
	shrl	$31, %ecx
	testl	%eax, %eax
	movl	$1, %edx
	cmovsl	%edx, %eax
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	addl	%eax, (%rdx,%rcx,4)
	movslq	20(%r14), %rax
	leaq	(%rbx,%rax,4), %rbx
	movslq	16(%r14), %rax
	leaq	(%r13,%rax,4), %r13
	incl	%r12d
	cmpl	(%r14), %r12d
	jl	LBB0_4
## %bb.5:
	movl	-60(%rbp), %eax                 ## 4-byte Reload
	movq	-80(%rbp), %r12                 ## 8-byte Reload
	jmp	LBB0_6
LBB0_2:
	movl	-60(%rbp), %eax                 ## 4-byte Reload
LBB0_6:
	movq	%r12, %rsp
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_8
## %bb.7:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_LPC32XX_ECC_SAVE_SIZE,4,2      ## @LPC32XX_ECC_SAVE_SIZE
	.no_dead_strip	_lpc32xx_nand_read_page_syndrome
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lpc32xx_nand_read_page_syndrome
_lpc32xx_nand_read_page_syndrome:       ; @lpc32xx_nand_read_page_syndrome
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	sub	sp, sp, #16
	mov	x23, x3
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
	bl	_nand_to_mtd
	mov	x21, x0
	mov	x0, x20
	bl	_nand_get_controller_data
	mov	x24, x0
	mov	x25, sp
	stur	wzr, [x29, #-80]
Lloh3:
	adrp	x8, _LPC32XX_ECC_SAVE_SIZE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LPC32XX_ECC_SAVE_SIZE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	lsl	x8, x8, #2
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x7fffffff0
	sub	x22, x9, x8
	mov	sp, x22
	mov	x0, x20
	mov	x1, x23
	mov	w2, #0
	mov	x3, #0
	mov	w4, #0
	bl	_nand_read_page_op
	ldr	w2, [x20]
	mov	x0, x21
	mov	x1, x19
	mov	w3, #1
	bl	_lpc32xx_xfer
	mov	x23, x0
	ldp	x1, x8, [x20, #24]
	ldr	w2, [x21, #8]
	mov	x0, x20
	blr	x8
	ldr	x1, [x24]
	ldr	w2, [x20]
	mov	x0, x22
	bl	_lpc32xx_slc_ecc_copy
	sub	x2, x29, #80
	mov	x0, x21
	mov	w1, #0
	bl	_mtd_ooblayout_ecc
	cbnz	w0, LBB0_5
; %bb.1:
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_4
; %bb.2:
	mov	w26, #0
	ldr	x8, [x20, #24]
	ldursw	x9, [x29, #-80]
	add	x24, x8, x9, lsl #2
	ldr	w8, [x20, #16]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x20, #8]
	mul	w8, w8, w26
	add	x3, x22, w8, sxtw #2
	mov	x0, x20
	mov	x1, x19
	mov	x2, x24
	blr	x9
	lsr	w8, w0, #31
	lsl	x8, x8, #2
	cmp	w0, #0
	csinc	w9, w0, wzr, ge
	ldr	w10, [x21, x8]
	add	w9, w10, w9
	str	w9, [x21, x8]
	ldpsw	x8, x9, [x20, #16]
	add	x19, x19, x9, lsl #2
	add	x24, x24, x8, lsl #2
	add	w26, w26, #1
	ldr	w9, [x20]
	cmp	w26, w9
	b.lt	LBB0_3
LBB0_4:
	mov	x0, x23
LBB0_5:
	mov	sp, x25
	ldur	x8, [x29, #-72]
Lloh8:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh9:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_7
; %bb.6:
	sub	sp, x29, #64
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_7:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_LPC32XX_ECC_SAVE_SIZE,4,2      ; @LPC32XX_ECC_SAVE_SIZE
	.no_dead_strip	_lpc32xx_nand_read_page_syndrome
.subsections_via_symbols
