	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function stm32_fmc2_exec_op
_stm32_fmc2_exec_op:                    ## @stm32_fmc2_exec_op
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r13d
	movq	%rsi, %r15
	movq	%rdi, %r12
	movl	(%rdi), %edi
	callq	_to_stm32_nfc
	movq	%rax, %r14
	movl	16(%r15), %esi
	movq	%r12, %rdi
	callq	_stm32_fmc2_select_chip
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	testl	%eax, %eax
	jne	LBB0_15
## %bb.1:
	testl	%r13d, %r13d
	je	LBB0_3
## %bb.2:
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
LBB0_15:
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	cmpl	$0, (%r15)
	je	LBB0_15
## %bb.4:
	xorl	%ebx, %ebx
	leaq	LJTI0_0(%rip), %r13
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_5
LBB0_13:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	8(%rax,%rdx), %esi
	movq	%r12, %rdi
	callq	_nand_soft_waitrdy
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_5 Depth=1
	incq	%rbx
	movl	(%r15), %eax
	cmpq	%rax, %rbx
	jae	LBB0_15
LBB0_5:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_9 Depth 2
	movq	8(%r15), %rax
	imulq	$56, %rbx, %rdx
	movl	(%rax,%rdx), %ecx
	addl	$-128, %ecx
	cmpl	$4, %ecx
	ja	LBB0_14
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movslq	(%r13,%rcx,4), %rcx
	addq	%r13, %rcx
	jmpq	*%rcx
LBB0_12:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	20(%rax,%rdx), %esi
	movl	12(%rax,%rdx), %ecx
	movl	16(%rax,%rdx), %edx
	movq	%r12, %rdi
	callq	_stm32_fmc2_write_data
	jmp	LBB0_14
LBB0_11:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	24(%rax,%rdx), %esi
	movl	12(%rax,%rdx), %ecx
	movl	16(%rax,%rdx), %edx
	movq	%r12, %rdi
	callq	_stm32_fmc2_read_data
	jmp	LBB0_14
LBB0_16:                                ##   in Loop: Header=BB0_5 Depth=1
	movl	48(%rax,%rdx), %edi
	movq	(%r14), %rax
	movq	16(%r14), %rcx
	movl	(%rcx,%rax,4), %esi
	callq	_writeb_relaxed
	jmp	LBB0_14
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	cmpl	$0, 32(%rax,%rdx)
	je	LBB0_14
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	leaq	(%rax,%rdx), %r13
	addq	$32, %r13
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_9:                                 ##   Parent Loop BB0_5 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	8(%r13), %rax
	movl	(%rax,%r12,4), %edi
	movq	(%r14), %rax
	movq	8(%r14), %rcx
	movl	(%rcx,%rax,4), %esi
	callq	_writeb_relaxed
	incq	%r12
	movl	(%r13), %eax
	cmpq	%rax, %r12
	jb	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_5 Depth=1
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	leaq	LJTI0_0(%rip), %r13
	jmp	LBB0_14
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_13, LBB0_13-LJTI0_0
.set L0_0_set_12, LBB0_12-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_16, LBB0_16-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
LJTI0_0:
	.long	L0_0_set_13
	.long	L0_0_set_12
	.long	L0_0_set_11
	.long	L0_0_set_16
	.long	L0_0_set_7
	.end_data_region
                                        ## -- End function
	.no_dead_strip	_stm32_fmc2_exec_op
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function stm32_fmc2_exec_op
_stm32_fmc2_exec_op:                    ; @stm32_fmc2_exec_op
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	mov	x23, x2
	mov	x19, x1
	mov	x20, x0
	ldr	w0, [x0]
	bl	_to_stm32_nfc
	mov	x21, x0
	ldr	w1, [x19, #16]
	mov	x0, x20
	bl	_stm32_fmc2_select_chip
	mov	x22, x0
	cbnz	w0, LBB0_3
; %bb.1:
	cbz	w23, LBB0_4
LBB0_2:
	mov	w22, #0
LBB0_3:
	mov	x0, x22
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_4:
	ldr	w8, [x19]
	cbz	w8, LBB0_2
; %bb.5:
	mov	x23, #0
	mov	w22, #0
	mov	w24, #56
Lloh0:
	adrp	x25, lJTI0_0@PAGE
Lloh1:
	add	x25, x25, lJTI0_0@PAGEOFF
	b	LBB0_8
LBB0_6:                                 ;   in Loop: Header=BB0_8 Depth=1
	madd	x8, x23, x24, x8
	ldr	w1, [x8, #8]
	mov	x0, x20
	bl	_nand_soft_waitrdy
	mov	x22, x0
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	add	x23, x23, #1
	ldr	w8, [x19]
	cmp	x23, x8
	b.hs	LBB0_3
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_15 Depth 2
	ldr	x8, [x19, #8]
	mul	x9, x23, x24
	ldr	w9, [x8, x9]
	sub	w9, w9, #128
	cmp	w9, #4
	b.hi	LBB0_7
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	adr	x10, LBB0_6
	ldrb	w11, [x25, x9]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_10:                                ;   in Loop: Header=BB0_8 Depth=1
	madd	x8, x23, x24, x8
	ldp	w2, w1, [x8, #16]
	ldr	w3, [x8, #12]
	mov	x0, x20
	bl	_stm32_fmc2_write_data
	b	LBB0_7
LBB0_11:                                ;   in Loop: Header=BB0_8 Depth=1
	madd	x8, x23, x24, x8
	ldr	w1, [x8, #24]
	ldp	w3, w2, [x8, #12]
	mov	x0, x20
	bl	_stm32_fmc2_read_data
	b	LBB0_7
LBB0_12:                                ;   in Loop: Header=BB0_8 Depth=1
	madd	x8, x23, x24, x8
	ldr	w0, [x8, #48]
	ldr	x8, [x21, #16]
	ldr	x9, [x21]
	ldr	w1, [x8, x9, lsl #2]
	bl	_writeb_relaxed
	b	LBB0_7
LBB0_13:                                ;   in Loop: Header=BB0_8 Depth=1
	madd	x26, x23, x24, x8
	ldr	w9, [x26, #32]!
	cbz	w9, LBB0_7
; %bb.14:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x27, #0
	madd	x8, x23, x24, x8
	add	x28, x8, #40
LBB0_15:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x28]
	ldr	w0, [x8, x27, lsl #2]
	ldp	x9, x8, [x21]
	ldr	w1, [x8, x9, lsl #2]
	bl	_writeb_relaxed
	add	x27, x27, #1
	ldr	w8, [x26]
	cmp	x27, x8
	b.lo	LBB0_15
	b	LBB0_7
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_6-LBB0_6)>>2
	.byte	(LBB0_10-LBB0_6)>>2
	.byte	(LBB0_11-LBB0_6)>>2
	.byte	(LBB0_12-LBB0_6)>>2
	.byte	(LBB0_13-LBB0_6)>>2
                                        ; -- End function
	.no_dead_strip	_stm32_fmc2_exec_op
.subsections_via_symbols
