	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fpga_write
_fpga_write:                            ## @fpga_write
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	(%rdi), %r15
	movl	(%rsi), %eax
	cmpl	$4, %eax
	jl	LBB0_3
## %bb.1:
	leaq	-28(%rbp), %r14
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	$4, %esi
	movq	%rbx, %rdx
	callq	_uiomove
	movl	(%r15), %esi
	movl	4(%r15), %edi
	movl	-28(%rbp), %ecx
	xorl	%edx, %edx
	callq	_bus_space_write_4
	movl	(%rbx), %eax
	cmpl	$3, %eax
	jg	LBB0_2
LBB0_3:
	cmpl	$1, %eax
	je	LBB0_8
## %bb.4:
	cmpl	$2, %eax
	je	LBB0_7
## %bb.5:
	cmpl	$3, %eax
	jne	LBB0_10
## %bb.6:
	leaq	-28(%rbp), %rdi
	movl	$3, %esi
	movq	%rbx, %rdx
	callq	_uiomove
	movl	$16777215, %ecx                 ## imm = 0xFFFFFF
	andl	-28(%rbp), %ecx
	jmp	LBB0_9
LBB0_8:
	leaq	-28(%rbp), %rdi
	movl	$1, %esi
	movq	%rbx, %rdx
	callq	_uiomove
	movzbl	-28(%rbp), %ecx
	jmp	LBB0_9
LBB0_7:
	leaq	-28(%rbp), %rdi
	movl	$2, %esi
	movq	%rbx, %rdx
	callq	_uiomove
	movzwl	-28(%rbp), %ecx
LBB0_9:
	movl	%ecx, -28(%rbp)
	movl	(%r15), %esi
	movl	4(%r15), %edi
	xorl	%edx, %edx
	callq	_bus_space_write_4
LBB0_10:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_fpga_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fpga_write
_fpga_write:                            ; @fpga_write
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x1
	ldr	x20, [x0]
	ldr	w8, [x1]
	cmp	w8, #4
	b.lt	LBB0_2
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	add	x0, sp, #12
	mov	w1, #4
	mov	x2, x19
	bl	_uiomove
	ldp	w1, w0, [x20]
	ldr	w3, [sp, #12]
	mov	w2, #0
	bl	_bus_space_write_4
	ldr	w8, [x19]
	cmp	w8, #3
	b.gt	LBB0_1
LBB0_2:
	cmp	w8, #1
	b.eq	LBB0_6
; %bb.3:
	cmp	w8, #2
	b.eq	LBB0_7
; %bb.4:
	cmp	w8, #3
	b.ne	LBB0_9
; %bb.5:
	add	x0, sp, #12
	mov	w1, #3
	mov	x2, x19
	bl	_uiomove
	ldr	w8, [sp, #12]
	and	w3, w8, #0xffffff
	b	LBB0_8
LBB0_6:
	add	x0, sp, #12
	mov	w1, #1
	mov	x2, x19
	bl	_uiomove
	ldrb	w3, [sp, #12]
	b	LBB0_8
LBB0_7:
	add	x0, sp, #12
	mov	w1, #2
	mov	x2, x19
	bl	_uiomove
	ldrh	w3, [sp, #12]
LBB0_8:
	str	w3, [sp, #12]
	ldp	w1, w0, [x20]
	mov	w2, #0
	bl	_bus_space_write_4
LBB0_9:
	mov	w0, #0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_fpga_write
.subsections_via_symbols
