	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nicvf_sq_append_skb            ## -- Begin function nicvf_sq_append_skb
	.p2align	4, 0x90
_nicvf_sq_append_skb:                   ## @nicvf_sq_append_skb
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r14d
	movq	%rdx, %rbx
	movq	%rsi, %r12
	movq	%rdi, %r13
	movq	%rdx, %rsi
	callq	_nicvf_sq_subdesc_required
	movl	%eax, %r15d
	movq	%r12, %rdi
	callq	_atomic_read
	cmpl	%eax, %r15d
	jle	LBB0_2
## %bb.1:
	movq	8(%r13), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_netdev_dbg
	jmp	LBB0_10
LBB0_2:
	movq	%r12, %rdi
	movl	%r15d, %esi
	callq	_nicvf_get_sq_desc
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	%rbx, %rdi
	callq	_skb_shinfo
	cmpq	$0, 8(%rax)
	je	LBB0_4
## %bb.3:
	cmpl	$0, 32(%r13)
	je	LBB0_17
LBB0_4:
	movl	%r14d, -72(%rbp)                ## 4-byte Spill
	movl	%r15d, %ecx
	decl	%ecx
	movl	(%rbx), %r9d
	movq	%r13, %rdi
	movq	%r12, %rsi
	movl	-48(%rbp), %r14d                ## 4-byte Reload
	movl	%r14d, %edx
	movq	%rbx, %r8
	callq	_nicvf_sq_add_hdr_subdesc
	movq	%r12, %rdi
	movl	%r14d, %esi
	callq	_nicvf_get_nxt_sqentry
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	%rbx, %rdi
	callq	_skb_is_nonlinear
	testq	%rax, %rax
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	je	LBB0_6
## %bb.5:
	movq	%rbx, %rdi
	callq	_skb_headlen
	movl	%eax, %r14d
	jmp	LBB0_7
LBB0_6:
	movl	(%rbx), %r14d
LBB0_7:
	movq	24(%r13), %r12
	movl	4(%rbx), %edi
	callq	_virt_to_page
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	movl	%eax, %r13d
	movl	4(%rbx), %edi
	callq	_offset_in_page
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r8d
	movq	_DMA_ATTR_SKIP_CPU_SYNC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r9d
	movq	%r12, %rdi
	movl	%r13d, %esi
	movl	%eax, %edx
	movl	%r14d, %ecx
	callq	_dma_map_page_attrs
	movl	%eax, %r12d
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	24(%rax), %rdi
	movl	%r12d, %esi
	callq	_dma_mapping_error
	testq	%rax, %rax
	je	LBB0_12
## %bb.8:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movl	%r15d, %edx
LBB0_9:
	callq	_nicvf_rollback_sq_desc
LBB0_10:
	xorl	%eax, %eax
LBB0_11:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movl	%r14d, %edx
	movl	%r12d, %ecx
	callq	_nicvf_sq_add_gather_subdesc
	movq	%rbx, %rdi
	callq	_skb_is_nonlinear
	testq	%rax, %rax
	movq	%rbx, %r13
	movl	%r15d, -68(%rbp)                ## 4-byte Spill
	je	LBB0_18
## %bb.13:
	movq	%r13, %rdi
	callq	_skb_shinfo
	cmpl	$0, (%rax)
	jle	LBB0_18
## %bb.14:
	xorl	%r12d, %r12d
	xorl	%ebx, %ebx
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movl	-44(%rbp), %r14d                ## 4-byte Reload
	movq	%r13, -88(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_15:                                ## =>This Inner Loop Header: Depth=1
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	movq	%r13, %rdi
	callq	_skb_shinfo
	movq	16(%rax), %rbx
	movq	%r12, -96(%rbp)                 ## 8-byte Spill
	addq	%r12, %rbx
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_nicvf_get_nxt_sqentry
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	%rbx, %rdi
	callq	_skb_frag_size
	movl	%eax, %r12d
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	24(%r15), %rax
	movq	%rax, -104(%rbp)                ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_skb_frag_page
	movl	%eax, %r13d
	movq	%rbx, %rdi
	callq	_skb_frag_off
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r8d
	movq	_DMA_ATTR_SKIP_CPU_SYNC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r9d
	movq	-104(%rbp), %rdi                ## 8-byte Reload
	movl	%r13d, %esi
	movl	%eax, %edx
	movl	%r12d, %ecx
	callq	_dma_map_page_attrs
	movl	%eax, %r13d
	movq	24(%r15), %rdi
	movl	%eax, %esi
	callq	_dma_mapping_error
	testq	%rax, %rax
	jne	LBB0_23
## %bb.16:                              ##   in Loop: Header=BB0_15 Depth=1
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	-44(%rbp), %r14d                ## 4-byte Reload
	movl	%r14d, %esi
	movl	%r12d, %edx
	movl	%r13d, %ecx
	callq	_nicvf_sq_add_gather_subdesc
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	incq	%rbx
	movq	-88(%rbp), %r13                 ## 8-byte Reload
	movq	%r13, %rdi
	callq	_skb_shinfo
	movslq	(%rax), %rax
	movq	-96(%rbp), %r12                 ## 8-byte Reload
	addq	$4, %r12
	cmpq	%rax, %rbx
	jl	LBB0_15
	jmp	LBB0_19
LBB0_17:
	movq	%r13, %rdi
	movq	%r12, %rsi
	movl	%r14d, %edx
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	movq	%rbx, %r8
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_nicvf_sq_append_tso            ## TAILCALL
LBB0_18:
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movl	-44(%rbp), %r14d                ## 4-byte Reload
LBB0_19:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	cmpq	$0, 16(%rax)
	je	LBB0_22
## %bb.20:
	movq	%r13, %rdi
	callq	_skb_shinfo
	cmpq	$0, 8(%rax)
	je	LBB0_22
## %bb.21:
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_nicvf_get_nxt_sqentry
	movq	%r15, %rdi
	movl	%eax, %esi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movq	%r13, %rcx
	callq	_nicvf_sq_add_cqe_subdesc
LBB0_22:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rsi
	movl	-72(%rbp), %edx                 ## 4-byte Reload
	movl	-68(%rbp), %ecx                 ## 4-byte Reload
	callq	_nicvf_sq_doorbell
	movl	$1, %eax
	jmp	LBB0_11
LBB0_23:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rsi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
                                        ## kill: def $ecx killed $ecx killed $rcx
	callq	_nicvf_unmap_sndq_buffers
	movq	%rbx, %rdi
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	movl	-68(%rbp), %edx                 ## 4-byte Reload
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_DMA_TO_DEVICE,4,2              ## @DMA_TO_DEVICE
	.comm	_DMA_ATTR_SKIP_CPU_SYNC,4,2     ## @DMA_ATTR_SKIP_CPU_SYNC
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Not enough SQ descriptors to xmit pkt\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nicvf_sq_append_skb            ; -- Begin function nicvf_sq_append_skb
	.p2align	2
_nicvf_sq_append_skb:                   ; @nicvf_sq_append_skb
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x21, x3
	mov	x20, x2
	mov	x22, x1
	mov	x23, x0
	mov	x1, x2
	bl	_nicvf_sq_subdesc_required
	mov	x19, x0
	mov	x0, x22
	bl	_atomic_read
	cmp	w19, w0
	b.le	LBB0_2
; %bb.1:
	ldr	x8, [x23, #8]
	ldr	w0, [x8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_netdev_dbg
	b	LBB0_10
LBB0_2:
	mov	x0, x22
	mov	x1, x19
	bl	_nicvf_get_sq_desc
	mov	x24, x0
	mov	x0, x20
	bl	_skb_shinfo
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_4
; %bb.3:
	ldr	w8, [x23, #32]
	cbz	w8, LBB0_21
LBB0_4:
	sub	w3, w19, #1
	ldr	w5, [x20]
	mov	x0, x23
	mov	x1, x22
	mov	x2, x24
	mov	x4, x20
	bl	_nicvf_sq_add_hdr_subdesc
	mov	x0, x22
	mov	x1, x24
	bl	_nicvf_get_nxt_sqentry
	mov	x25, x0
	mov	x0, x20
	bl	_skb_is_nonlinear
	cbz	x0, LBB0_6
; %bb.5:
	mov	x0, x20
	bl	_skb_headlen
	mov	x26, x0
	b	LBB0_7
LBB0_6:
	ldr	w26, [x20]
LBB0_7:
	ldr	x27, [x23, #24]
	ldr	w0, [x20, #4]
	bl	_virt_to_page
	mov	x28, x0
	ldr	w0, [x20, #4]
	bl	_offset_in_page
	mov	x2, x0
Lloh2:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh4:
	ldr	w4, [x8]
Lloh5:
	adrp	x8, _DMA_ATTR_SKIP_CPU_SYNC@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DMA_ATTR_SKIP_CPU_SYNC@GOTPAGEOFF]
Lloh7:
	ldr	w5, [x8]
	mov	x0, x27
	mov	x1, x28
	mov	x3, x26
	bl	_dma_map_page_attrs
	mov	x27, x0
	ldr	x0, [x23, #24]
	mov	x1, x27
	bl	_dma_mapping_error
	cbz	x0, LBB0_12
; %bb.8:
	mov	x0, x22
	mov	x1, x25
	mov	x2, x19
LBB0_9:
	bl	_nicvf_rollback_sq_desc
LBB0_10:
	mov	w0, #0
LBB0_11:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_12:
	str	w21, [sp, #8]                   ; 4-byte Folded Spill
	mov	x0, x22
	mov	x1, x25
	mov	x2, x26
	mov	x3, x27
	bl	_nicvf_sq_add_gather_subdesc
	mov	x0, x20
	bl	_skb_is_nonlinear
	str	w19, [sp, #12]                  ; 4-byte Folded Spill
	str	w24, [sp, #4]                   ; 4-byte Folded Spill
	cbz	x0, LBB0_17
; %bb.13:
	mov	x0, x20
	bl	_skb_shinfo
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_17
; %bb.14:
	mov	x19, #0
	mov	x26, #0
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_skb_shinfo
	ldr	x8, [x0, #16]
	add	x28, x8, x19
	mov	x0, x22
	mov	x1, x25
	bl	_nicvf_get_nxt_sqentry
	mov	x25, x0
	mov	x0, x28
	bl	_skb_frag_size
	mov	x27, x0
	ldr	x21, [x23, #24]
	mov	x0, x28
	bl	_skb_frag_page
	mov	x24, x0
	mov	x0, x28
	bl	_skb_frag_off
	mov	x2, x0
Lloh8:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh10:
	ldr	w4, [x8]
Lloh11:
	adrp	x8, _DMA_ATTR_SKIP_CPU_SYNC@GOTPAGE
Lloh12:
	ldr	x8, [x8, _DMA_ATTR_SKIP_CPU_SYNC@GOTPAGEOFF]
Lloh13:
	ldr	w5, [x8]
	mov	x0, x21
	mov	x1, x24
	mov	x3, x27
	bl	_dma_map_page_attrs
	mov	x28, x0
	ldr	x0, [x23, #24]
	mov	x1, x28
	bl	_dma_mapping_error
	cbnz	x0, LBB0_22
; %bb.16:                               ;   in Loop: Header=BB0_15 Depth=1
	mov	x0, x22
	mov	x1, x25
	mov	x2, x27
	mov	x3, x28
	bl	_nicvf_sq_add_gather_subdesc
	add	x26, x26, #1
	mov	x0, x20
	bl	_skb_shinfo
	ldrsw	x8, [x0]
	add	x19, x19, #4
	cmp	x26, x8
	b.lt	LBB0_15
LBB0_17:
	ldr	x8, [x23, #16]
	cbz	x8, LBB0_20
; %bb.18:
	mov	x0, x20
	bl	_skb_shinfo
	ldr	x8, [x0, #8]
	cbz	x8, LBB0_20
; %bb.19:
	mov	x0, x22
	mov	x1, x25
	bl	_nicvf_get_nxt_sqentry
	mov	x1, x0
	mov	x0, x22
	ldr	w2, [sp, #4]                    ; 4-byte Folded Reload
	mov	x3, x20
	bl	_nicvf_sq_add_cqe_subdesc
LBB0_20:
	mov	x0, x23
	mov	x1, x20
	ldp	w2, w3, [sp, #8]                ; 8-byte Folded Reload
	bl	_nicvf_sq_doorbell
	mov	w0, #1
	b	LBB0_11
LBB0_21:
	mov	x0, x23
	mov	x1, x22
	mov	x2, x21
	mov	x3, x24
	mov	x4, x20
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_nicvf_sq_append_tso
LBB0_22:
	mov	x0, x23
	mov	x1, x22
	ldr	w2, [sp, #4]                    ; 4-byte Folded Reload
	mov	x3, x26
	bl	_nicvf_unmap_sndq_buffers
	mov	x0, x22
	mov	x1, x25
	ldr	w2, [sp, #12]                   ; 4-byte Folded Reload
	b	LBB0_9
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_DMA_TO_DEVICE,4,2              ; @DMA_TO_DEVICE
	.comm	_DMA_ATTR_SKIP_CPU_SYNC,4,2     ; @DMA_ATTR_SKIP_CPU_SYNC
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Not enough SQ descriptors to xmit pkt\n"

.subsections_via_symbols
