	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function myri10ge_alloc_rx_pages
_myri10ge_alloc_rx_pages:               ## @myri10ge_alloc_rx_pages
	.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, %ebx
	movq	%rsi, %r14
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	cmpl	$0, (%rsi)
	setne	%al
	testl	%ecx, %ecx
	sete	%cl
	andb	%al, %cl
	movzbl	%cl, %edi
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_12
## %bb.1:
	movl	4(%r14), %r15d
	movl	8(%r14), %eax
	movl	12(%r14), %r13d
	addl	%r13d, %eax
	incl	%eax
	cmpl	%eax, %r15d
	jne	LBB0_2
LBB0_12:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_3 Depth=1
	movl	8(%r14), %eax
	movl	12(%r14), %r13d
	addl	%r13d, %eax
	incl	%eax
	cmpl	%eax, %r15d
	je	LBB0_12
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	16(%r14), %eax
	addl	%ebx, %eax
	movq	_MYRI10GE_ALLOC_SIZE@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jle	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	___GFP_COMP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
	movq	_MYRI10GE_ALLOC_ORDER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_alloc_pages
	movq	%rax, %r12
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_6
## %bb.8:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	%r12, 56(%r14)
	movl	$0, 16(%r14)
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	_MYRI10GE_ALLOC_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_PCI_DMA_FROMDEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	%r12, %rsi
	xorl	%edx, %edx
	callq	_pci_map_page
	movl	%eax, %edx
	movl	%eax, 40(%r14)
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	56(%r14), %rdi
	callq	_get_page
	movl	40(%r14), %edx
LBB0_9:                                 ##   in Loop: Header=BB0_3 Depth=1
	andl	%r15d, %r13d
	movq	48(%r14), %rax
	movq	56(%r14), %rcx
	movslq	%r13d, %r12
	movq	%r12, %rbx
	shlq	$4, %rbx
	leaq	(%rax,%rbx), %rdi
	movq	%rcx, 8(%rax,%rbx)
	movl	16(%r14), %ecx
	movl	%ecx, (%rax,%rbx)
	movq	_bus@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_pci_unmap_addr_set
	movl	40(%r14), %edi
	callq	_MYRI10GE_LOWPART_TO_U32
	movslq	16(%r14), %rdi
	addq	%rax, %rdi
	callq	_htonl
	movq	24(%r14), %rcx
	movq	%rax, 8(%rcx,%rbx)
	movl	40(%r14), %edi
	callq	_MYRI10GE_HIGHPART_TO_U32
	movq	%rax, %rdi
	callq	_htonl
	movq	24(%r14), %rcx
	movq	%rax, (%rcx,%rbx)
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	movl	%ebx, %edi
	callq	_SKB_DATA_ALIGN
	addl	%eax, 16(%r14)
	movl	4(%r14), %r15d
	incl	%r15d
	movl	%r15d, 4(%r14)
	movl	%r12d, %eax
	notl	%eax
	testb	$7, %al
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_3 Depth=1
	leaq	-28(,%r12,4), %rdi
	addq	32(%r14), %rdi
	addq	$-7, %r12
	shlq	$4, %r12
	addq	24(%r14), %r12
	movq	%r12, %rsi
	callq	_myri10ge_submit_8rx
	movl	4(%r14), %r15d
	jmp	LBB0_11
LBB0_6:
	movl	4(%r14), %eax
	subl	8(%r14), %eax
	cmpl	$15, %eax
	jg	LBB0_12
## %bb.7:
	movl	$1, (%r14)
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_MYRI10GE_ALLOC_SIZE,4,2        ## @MYRI10GE_ALLOC_SIZE
	.comm	_GFP_ATOMIC,4,2                 ## @GFP_ATOMIC
	.comm	___GFP_COMP,4,2                 ## @__GFP_COMP
	.comm	_MYRI10GE_ALLOC_ORDER,4,2       ## @MYRI10GE_ALLOC_ORDER
	.comm	_PCI_DMA_FROMDEVICE,4,2         ## @PCI_DMA_FROMDEVICE
	.comm	_bus,4,2                        ## @bus
	.no_dead_strip	_myri10ge_alloc_rx_pages
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function myri10ge_alloc_rx_pages
_myri10ge_alloc_rx_pages:               ; @myri10ge_alloc_rx_pages
	.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	x20, x2
	mov	x19, x1
	mov	x21, x0
	ldr	w8, [x1]
	cmp	w3, #0
	ccmp	w8, #0, #4, eq
	cset	w0, ne
	bl	_unlikely
	cbnz	x0, LBB0_2
; %bb.1:
	ldp	w27, w8, [x19, #4]
	ldr	w24, [x19, #12]
	add	w8, w8, w24
	add	w8, w8, #1
	cmp	w27, w8
	b.ne	LBB0_3
LBB0_2:
	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_3:
Lloh0:
	adrp	x23, _MYRI10GE_ALLOC_SIZE@GOTPAGE
Lloh1:
	ldr	x23, [x23, _MYRI10GE_ALLOC_SIZE@GOTPAGEOFF]
Lloh2:
	adrp	x25, ___GFP_COMP@GOTPAGE
Lloh3:
	ldr	x25, [x25, ___GFP_COMP@GOTPAGEOFF]
Lloh4:
	adrp	x26, _MYRI10GE_ALLOC_ORDER@GOTPAGE
Lloh5:
	ldr	x26, [x26, _MYRI10GE_ALLOC_ORDER@GOTPAGEOFF]
Lloh6:
	adrp	x28, _bus@GOTPAGE
Lloh7:
	ldr	x28, [x28, _bus@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldp	w8, w24, [x19, #8]
	add	w8, w8, w24
	add	w8, w8, #1
	cmp	w27, w8
	b.eq	LBB0_2
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x19, #16]
	ldr	w9, [x23]
	add	w8, w8, w20
	cmp	w8, w9
	b.le	LBB0_8
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
Lloh8:
	adrp	x8, _GFP_ATOMIC@GOTPAGE
Lloh9:
	ldr	x8, [x8, _GFP_ATOMIC@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	ldr	w9, [x25]
	orr	w0, w9, w8
	ldr	w1, [x26]
	bl	_alloc_pages
	mov	x22, x0
	cmp	x0, #0
	cset	w0, eq
	bl	_unlikely
	cbnz	x0, LBB0_11
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	str	x22, [x19, #56]
	str	wzr, [x19, #16]
	ldr	w0, [x21]
	ldr	w3, [x23]
Lloh11:
	adrp	x8, _PCI_DMA_FROMDEVICE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _PCI_DMA_FROMDEVICE@GOTPAGEOFF]
Lloh13:
	ldr	w4, [x8]
	mov	x1, x22
	mov	w2, #0
	bl	_pci_map_page
	mov	x2, x0
	str	w0, [x19, #40]
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x0, [x19, #56]
	bl	_get_page
	ldr	w2, [x19, #40]
LBB0_9:                                 ;   in Loop: Header=BB0_5 Depth=1
	and	w22, w24, w27
	ldp	x9, x8, [x19, #48]
	mvn	w24, w22
	sbfiz	x27, x22, #4, #32
	add	x0, x9, x27
	str	x8, [x0, #8]
	ldr	w8, [x19, #16]
	str	w8, [x0]
	ldr	w1, [x28]
	bl	_pci_unmap_addr_set
	ldr	w0, [x19, #40]
	bl	_MYRI10GE_LOWPART_TO_U32
	ldrsw	x8, [x19, #16]
	add	x0, x0, x8
	bl	_htonl
	ldr	x8, [x19, #24]
	add	x8, x8, x27
	str	x0, [x8, #8]
	ldr	w0, [x19, #40]
	bl	_MYRI10GE_HIGHPART_TO_U32
	bl	_htonl
	ldr	x8, [x19, #24]
	str	x0, [x8, x27]
	mov	x0, x20
	bl	_SKB_DATA_ALIGN
	ldr	w8, [x19, #16]
	add	w8, w8, w0
	str	w8, [x19, #16]
	ldr	w8, [x19, #4]
	add	w27, w8, #1
	str	w27, [x19, #4]
	tst	w24, #0x7
	b.ne	LBB0_4
; %bb.10:                               ;   in Loop: Header=BB0_5 Depth=1
	sxtw	x8, w22
	sub	x8, x8, #7
	ldp	x10, x9, [x19, #24]
	add	x0, x9, x8, lsl #2
	add	x1, x10, x8, lsl #4
	bl	_myri10ge_submit_8rx
	ldr	w27, [x19, #4]
	b	LBB0_4
LBB0_11:
	ldp	w8, w9, [x19, #4]
	sub	w8, w8, w9
	cmp	w8, #15
	b.gt	LBB0_2
; %bb.12:
	mov	w8, #1
	str	w8, [x19]
	b	LBB0_2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_MYRI10GE_ALLOC_SIZE,4,2        ; @MYRI10GE_ALLOC_SIZE
	.comm	_GFP_ATOMIC,4,2                 ; @GFP_ATOMIC
	.comm	___GFP_COMP,4,2                 ; @__GFP_COMP
	.comm	_MYRI10GE_ALLOC_ORDER,4,2       ; @MYRI10GE_ALLOC_ORDER
	.comm	_PCI_DMA_FROMDEVICE,4,2         ; @PCI_DMA_FROMDEVICE
	.comm	_bus,4,2                        ; @bus
	.no_dead_strip	_myri10ge_alloc_rx_pages
.subsections_via_symbols
