	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ql_get_next_chunk
_ql_get_next_chunk:                     ## @ql_get_next_chunk
	.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	%rdx, %r14
	movq	%rsi, %r13
	movq	%rdi, %r15
	cmpq	$0, 24(%rsi)
	je	LBB0_1
LBB0_6:
	leaq	8(%r13), %rax
	movups	(%rax), %xmm0
	movups	16(%rax), %xmm1
	movups	%xmm1, 16(%r14)
	movups	%xmm0, (%r14)
	movq	8(%r13), %rbx
	addq	(%r13), %rbx
	movq	%rbx, 8(%r13)
	movq	%r15, %rdi
	callq	_ql_lbq_block_size
	cmpq	%rax, %rbx
	jne	LBB0_8
## %bb.7:
	movq	$0, 24(%r13)
	movl	$1, 8(%r14)
	jmp	LBB0_9
LBB0_1:
	movq	___GFP_COLD@GOTPCREL(%rip), %rax
	movq	___GFP_COMP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	orl	(%rax), %edi
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
	movl	4(%r15), %esi
	callq	_alloc_pages
	movq	%rax, 24(%r13)
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_drv@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r15), %edx
	leaq	L_.str(%rip), %rcx
	movq	%r15, %rdi
	callq	_netif_err
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_10
LBB0_8:
	movl	(%r13), %eax
	addl	%eax, 32(%r13)
	movq	24(%r13), %rdi
	callq	_get_page
	movl	$0, 8(%r14)
LBB0_9:
	xorl	%r12d, %r12d
LBB0_10:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	$0, 8(%r13)
	movl	8(%r15), %ebx
	movq	24(%r13), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdi
	callq	_ql_lbq_block_size
	movq	_PCI_DMA_FROMDEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r8d
	xorl	%r12d, %r12d
	movl	%ebx, %edi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	xorl	%edx, %edx
	movq	%rax, %rcx
	callq	_pci_map_page
	movl	%eax, %ebx
	movl	8(%r15), %edi
	movl	%eax, %esi
	callq	_pci_dma_mapping_error
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	24(%r13), %rdi
	movl	4(%r15), %esi
	callq	___free_pages
	movq	_drv@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r15), %edx
	leaq	L_.str.1(%rip), %rcx
	movq	%r15, %rdi
	callq	_netif_err
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
	jmp	LBB0_10
LBB0_5:
	movl	%ebx, 36(%r13)
	movq	24(%r13), %rdi
	callq	_page_address
	movl	%eax, 32(%r13)
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	___GFP_COLD,4,2                 ## @__GFP_COLD
	.comm	___GFP_COMP,4,2                 ## @__GFP_COMP
	.comm	_GFP_ATOMIC,4,2                 ## @GFP_ATOMIC
	.comm	_drv,4,2                        ## @drv
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"page allocation failed.\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_PCI_DMA_FROMDEVICE,4,2         ## @PCI_DMA_FROMDEVICE
L_.str.1:                               ## @.str.1
	.asciz	"PCI mapping failed.\n"

	.no_dead_strip	_ql_get_next_chunk
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ql_get_next_chunk
_ql_get_next_chunk:                     ; @ql_get_next_chunk
	.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	x19, x2
	mov	x21, x1
	mov	x20, x0
	ldr	x8, [x1, #24]
	cbz	x8, LBB0_3
LBB0_1:
	add	x8, x21, #8
	ldp	q0, q1, [x8]
	stp	q0, q1, [x19]
	ldp	x8, x9, [x21]
	add	x22, x9, x8
	str	x22, [x21, #8]
	mov	x0, x20
	bl	_ql_lbq_block_size
	cmp	x22, x0
	b.ne	LBB0_5
; %bb.2:
	mov	w0, #0
	str	xzr, [x21, #24]
	mov	w8, #1
	str	w8, [x19, #8]
	b	LBB0_9
LBB0_3:
Lloh0:
	adrp	x8, ___GFP_COLD@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___GFP_COLD@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, ___GFP_COMP@GOTPAGE
Lloh4:
	ldr	x9, [x9, ___GFP_COMP@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh6:
	adrp	x9, _GFP_ATOMIC@GOTPAGE
Lloh7:
	ldr	x9, [x9, _GFP_ATOMIC@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w0, w8, w9
	ldr	w1, [x20, #4]
	bl	_alloc_pages
	str	x0, [x21, #24]
	cmp	x0, #0
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_6
; %bb.4:
Lloh9:
	adrp	x8, _drv@GOTPAGE
Lloh10:
	ldr	x8, [x8, _drv@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	ldr	w2, [x20]
Lloh12:
	adrp	x3, l_.str@PAGE
Lloh13:
	add	x3, x3, l_.str@PAGEOFF
	b	LBB0_8
LBB0_5:
	ldr	w8, [x21]
	ldr	w9, [x21, #32]
	add	w8, w9, w8
	str	w8, [x21, #32]
	ldr	x0, [x21, #24]
	bl	_get_page
	mov	w0, #0
	str	wzr, [x19, #8]
	b	LBB0_9
LBB0_6:
	str	xzr, [x21, #8]
	ldr	w22, [x20, #8]
	ldr	x23, [x21, #24]
	mov	x0, x20
	bl	_ql_lbq_block_size
	mov	x3, x0
Lloh14:
	adrp	x8, _PCI_DMA_FROMDEVICE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _PCI_DMA_FROMDEVICE@GOTPAGEOFF]
Lloh16:
	ldr	w4, [x8]
	mov	x0, x22
	mov	x1, x23
	mov	w2, #0
	bl	_pci_map_page
	mov	x22, x0
	ldr	w0, [x20, #8]
	mov	x1, x22
	bl	_pci_dma_mapping_error
	cbz	x0, LBB0_10
; %bb.7:
	ldr	x0, [x21, #24]
	ldr	w1, [x20, #4]
	bl	___free_pages
Lloh17:
	adrp	x8, _drv@GOTPAGE
Lloh18:
	ldr	x8, [x8, _drv@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	ldr	w2, [x20]
Lloh20:
	adrp	x3, l_.str.1@PAGE
Lloh21:
	add	x3, x3, l_.str.1@PAGEOFF
LBB0_8:
	mov	x0, x20
	bl	_netif_err
Lloh22:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	neg	w0, w8
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
LBB0_10:
	str	w22, [x21, #36]
	ldr	x0, [x21, #24]
	bl	_page_address
	str	w0, [x21, #32]
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	___GFP_COLD,4,2                 ; @__GFP_COLD
	.comm	___GFP_COMP,4,2                 ; @__GFP_COMP
	.comm	_GFP_ATOMIC,4,2                 ; @GFP_ATOMIC
	.comm	_drv,4,2                        ; @drv
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"page allocation failed.\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_PCI_DMA_FROMDEVICE,4,2         ; @PCI_DMA_FROMDEVICE
l_.str.1:                               ; @.str.1
	.asciz	"PCI mapping failed.\n"

	.no_dead_strip	_ql_get_next_chunk
.subsections_via_symbols
