	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function read_fiforeg
_read_fiforeg:                          ## @read_fiforeg
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movslq	%edx, %r12
	shlq	$2, %r12
	addq	8(%rdi), %r12
	movl	%esi, %ebx
	leal	3(%rbx), %eax
	leal	6(%rbx), %r15d
	testl	%eax, %eax
	cmovnsl	%eax, %r15d
	sarl	$2, %r15d
	cmpl	$32, %esi
	jl	LBB0_3
## %bb.1:
	cmpq	$0, (%r14)
	je	LBB0_3
## %bb.2:
	movq	_DMA_FROM_DEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%ebx, %edx
	callq	_flctl_dma_fifo0_transfer
	testq	%rax, %rax
	jg	LBB0_7
	jmp	LBB0_4
LBB0_3:
	testl	%ebx, %ebx
	jle	LBB0_9
LBB0_4:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	cmpl	$2, %r15d
	movl	$1, %r13d
	movl	%r15d, %ebx
	cmovgel	%r15d, %r13d
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_wait_rfifo_ready
	movq	%r14, %rdi
	callq	_FLDTFIFO
	movl	%eax, %edi
	callq	_readl
	movq	%rax, (%r12,%r15,8)
	incq	%r15
	cmpq	%r15, %r13
	jne	LBB0_5
## %bb.6:
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	movl	%ebx, %r15d
	jle	LBB0_9
LBB0_7:
	cmpl	$2, %r15d
	movl	$1, %r14d
	cmovgel	%r15d, %r14d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r12,%rbx,8), %rdi
	callq	_be32_to_cpu
	movq	%rax, (%r12,%rbx,8)
	incq	%rbx
	cmpq	%rbx, %r14
	jne	LBB0_8
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DMA_FROM_DEVICE,4,2            ## @DMA_FROM_DEVICE
	.no_dead_strip	_read_fiforeg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function read_fiforeg
_read_fiforeg:                          ; @read_fiforeg
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x20, x1
	mov	x21, x0
	ldr	x8, [x0, #8]
	add	x19, x8, w2, sxtw #2
	add	w8, w1, #3
	add	w9, w1, #6
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w22, w8, #2
	cmp	w1, #32
	b.lt	LBB0_3
; %bb.1:
	ldr	x8, [x21]
	cbz	x8, LBB0_3
; %bb.2:
Lloh0:
	adrp	x8, _DMA_FROM_DEVICE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DMA_FROM_DEVICE@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	mov	x0, x21
	mov	x1, x19
	mov	x2, x20
	bl	_flctl_dma_fifo0_transfer
	cmp	x0, #1
	b.ge	LBB0_7
	b	LBB0_4
LBB0_3:
	cmp	w20, #1
	b.lt	LBB0_9
LBB0_4:
	cmp	w22, #1
	csinc	w23, w22, wzr, gt
	mov	x24, x19
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	bl	_wait_rfifo_ready
	mov	x0, x21
	bl	_FLDTFIFO
	bl	_readl
	str	x0, [x24], #8
	subs	x23, x23, #1
	b.ne	LBB0_5
; %bb.6:
	cmp	w20, #1
	b.lt	LBB0_9
LBB0_7:
	cmp	w22, #1
	csinc	w20, w22, wzr, gt
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x19]
	bl	_be32_to_cpu
	str	x0, [x19], #8
	subs	x20, x20, #1
	b.ne	LBB0_8
LBB0_9:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_DMA_FROM_DEVICE,4,2            ; @DMA_FROM_DEVICE
	.no_dead_strip	_read_fiforeg
.subsections_via_symbols
