	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipath_update_pio_bufs
_ipath_update_pio_bufs:                 ## @ipath_update_pio_bufs
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	24(%rdi), %r12
	testq	%r12, %r12
	je	LBB0_15
## %bb.1:
	movq	%rdi, %r13
	movl	32(%rdi), %r15d
	movq	_ipath_debug@GOTPCREL(%rip), %rax
	movq	___IPATH_VERBDBG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, (%rax)
	je	LBB0_4
## %bb.2:
	movq	(%r13), %r14
	movq	_PKT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	(%r12), %edi
	callq	_le64_to_cpu
	cltq
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movq	(%r14), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movl	4(%r12), %edi
	callq	_le64_to_cpu
	cltq
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	8(%r14), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movl	8(%r12), %edi
	callq	_le64_to_cpu
	cltq
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	16(%r14), %rbx
	movl	12(%r12), %edi
	callq	_le64_to_cpu
	cltq
	leaq	L_.str.1(%rip), %rsi
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	-72(%rbp), %r8                  ## 8-byte Reload
	movq	-64(%rbp), %r9                  ## 8-byte Reload
	pushq	24(%r14)
	pushq	%rax
	pushq	%rbx
	pushq	-56(%rbp)                       ## 8-byte Folded Reload
	callq	_ipath_cdbg
	addq	$32, %rsp
	cmpl	$5, %r15d
	jb	LBB0_4
## %bb.3:
	movq	_PKT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	16(%r12), %edi
	callq	_le64_to_cpu
	cltq
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movq	32(%r14), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movl	20(%r12), %edi
	callq	_le64_to_cpu
	cltq
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	40(%r14), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movl	24(%r12), %edi
	callq	_le64_to_cpu
	cltq
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	48(%r14), %rbx
	movl	28(%r12), %edi
	callq	_le64_to_cpu
	cltq
	leaq	L_.str.2(%rip), %rsi
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	-72(%rbp), %r8                  ## 8-byte Reload
	movq	-64(%rbp), %r9                  ## 8-byte Reload
	pushq	56(%r14)
	pushq	%rax
	pushq	%rbx
	pushq	-56(%rbp)                       ## 8-byte Folded Reload
	callq	_ipath_cdbg
	addq	$32, %rsp
	movq	_ipath_pioavail_lock@GOTPCREL(%rip), %rdi
	callq	_spin_lock_irqsave
	jmp	LBB0_5
LBB0_4:
	movq	_ipath_pioavail_lock@GOTPCREL(%rip), %rdi
	callq	_spin_lock_irqsave
	testq	%r15, %r15
	je	LBB0_14
LBB0_5:
	xorl	%ebx, %ebx
	movq	_IPATH_SWAP_PIOBUFS@GOTPCREL(%rip), %r14
	movq	_INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT@GOTPCREL(%rip), %r12
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_6 Depth=1
	incq	%rbx
	cmpq	%r15, %rbx
	je	LBB0_14
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$4, %rbx
	jb	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	(%r14), %eax
	testl	%eax, 8(%r13)
	je	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	%ebx, %eax
	xorq	$1, %rax
	shlq	$2, %rax
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_6 Depth=1
	leaq	(,%rbx,4), %rax
LBB0_10:                                ##   in Loop: Header=BB0_6 Depth=1
	addq	24(%r13), %rax
	movl	(%rax), %edi
	callq	_le64_to_cpu
	movq	(%r13), %r8
	movq	16(%r13), %rcx
	movq	(%r8,%rbx,8), %rsi
	xorl	%esi, %eax
	movl	%eax, %edi
	notl	%edi
	andl	(%rcx,%rbx,4), %edi
	movzbl	(%r12), %ecx
	movl	%edi, %edx
	shll	%cl, %edx
	testl	%edi, %edi
	je	LBB0_13
## %bb.11:                              ##   in Loop: Header=BB0_6 Depth=1
	movslq	%edx, %rcx
	testq	%rcx, %rsi
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_6 Depth=1
	andl	%edx, %eax
	xorl	%esi, %eax
	cltq
	movq	%rax, (%r8,%rbx,8)
	jmp	LBB0_13
LBB0_14:
	movq	_ipath_pioavail_lock@GOTPCREL(%rip), %rdi
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irqrestore         ## TAILCALL
LBB0_15:
	leaq	L_.str(%rip), %rdi
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ipath_dbg                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Update shadow pioavail, but regs_dma NULL!\n"

	.comm	_ipath_debug,4,2                ## @ipath_debug
	.comm	___IPATH_VERBDBG,4,2            ## @__IPATH_VERBDBG
	.comm	_PKT,4,2                        ## @PKT
L_.str.1:                               ## @.str.1
	.asciz	"Refill avail, dma0=%llx shad0=%lx, d1=%llx s1=%lx, d2=%llx s2=%lx, d3=%llx s3=%lx\n"

L_.str.2:                               ## @.str.2
	.asciz	"2nd group, dma4=%llx shad4=%lx, d5=%llx s5=%lx, d6=%llx s6=%lx, d7=%llx s7=%lx\n"

	.comm	_ipath_pioavail_lock,4,2        ## @ipath_pioavail_lock
	.comm	_IPATH_SWAP_PIOBUFS,4,2         ## @IPATH_SWAP_PIOBUFS
	.comm	_INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT,4,2 ## @INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT
	.no_dead_strip	_ipath_update_pio_bufs
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipath_update_pio_bufs
_ipath_update_pio_bufs:                 ; @ipath_update_pio_bufs
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	ldr	x28, [x0, #24]
	cbz	x28, LBB0_14
; %bb.1:
	mov	x19, x0
Lloh0:
	adrp	x8, _ipath_debug@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ipath_debug@GOTPAGEOFF]
	ldr	w27, [x0, #32]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, ___IPATH_VERBDBG@GOTPAGE
Lloh4:
	ldr	x9, [x9, ___IPATH_VERBDBG@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.2:
	ldr	x20, [x19]
Lloh6:
	adrp	x8, _PKT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PKT@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	str	w8, [sp, #28]                   ; 4-byte Folded Spill
	ldr	w0, [x28]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x21, w0
	ldr	x22, [x20]
	ldr	w0, [x28, #4]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x23, w0
	ldr	x24, [x20, #8]
	ldr	w0, [x28, #8]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x25, w0
	ldr	x26, [x20, #16]
	ldr	w0, [x28, #12]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x8, w0
	ldr	x9, [x20, #24]
	stp	x8, x9, [sp]
Lloh9:
	adrp	x1, l_.str.1@PAGE
Lloh10:
	add	x1, x1, l_.str.1@PAGEOFF
	ldr	w0, [sp, #28]                   ; 4-byte Folded Reload
	mov	x2, x21
	mov	x3, x22
	mov	x4, x23
	mov	x5, x24
	mov	x6, x25
	mov	x7, x26
	bl	_ipath_cdbg
	cmp	w27, #5
	b.lo	LBB0_4
; %bb.3:
Lloh11:
	adrp	x8, _PKT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _PKT@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	str	w8, [sp, #28]                   ; 4-byte Folded Spill
	ldr	w0, [x28, #16]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x21, w0
	ldr	x22, [x20, #32]
	ldr	w0, [x28, #20]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x23, w0
	ldr	x24, [x20, #40]
	ldr	w0, [x28, #24]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x25, w0
	ldr	x26, [x20, #48]
	ldr	w0, [x28, #28]
	bl	_le64_to_cpu
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x8, w0
	ldr	x9, [x20, #56]
	stp	x8, x9, [sp]
Lloh14:
	adrp	x1, l_.str.2@PAGE
Lloh15:
	add	x1, x1, l_.str.2@PAGEOFF
	ldr	w0, [sp, #28]                   ; 4-byte Folded Reload
	mov	x2, x21
	mov	x3, x22
	mov	x4, x23
	mov	x5, x24
	mov	x6, x25
	mov	x7, x26
	bl	_ipath_cdbg
Lloh16:
	adrp	x0, _ipath_pioavail_lock@GOTPAGE
Lloh17:
	ldr	x0, [x0, _ipath_pioavail_lock@GOTPAGEOFF]
	bl	_spin_lock_irqsave
	b	LBB0_5
LBB0_4:
Lloh18:
	adrp	x0, _ipath_pioavail_lock@GOTPAGE
Lloh19:
	ldr	x0, [x0, _ipath_pioavail_lock@GOTPAGEOFF]
	bl	_spin_lock_irqsave
	cbz	w27, LBB0_13
LBB0_5:
	mov	x20, #0
Lloh20:
	adrp	x21, _IPATH_SWAP_PIOBUFS@GOTPAGE
Lloh21:
	ldr	x21, [x21, _IPATH_SWAP_PIOBUFS@GOTPAGEOFF]
Lloh22:
	adrp	x22, _INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT@GOTPAGE
Lloh23:
	ldr	x22, [x22, _INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT@GOTPAGEOFF]
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	x20, x20, #1
	cmp	x20, x27
	b.eq	LBB0_13
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	cmp	x20, #4
	b.lo	LBB0_10
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w8, [x19, #8]
	ldr	w9, [x21]
	tst	w9, w8
	b.eq	LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [x19, #24]
	and	x9, x20, #0xffffffff
	eor	x9, x9, #0x1
	add	x8, x8, x9, lsl #2
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [x19, #24]
	add	x8, x8, x20, lsl #2
LBB0_11:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w0, [x8]
	bl	_le64_to_cpu
	ldr	x8, [x19, #16]
	ldr	w10, [x8, x20, lsl #2]
	ldr	x8, [x19]
	ldr	x9, [x8, x20, lsl #3]
	eor	w11, w0, w9
	bic	w11, w10, w11
	ldr	w10, [x22]
	lsl	w10, w11, w10
	cmp	w11, #0
	sxtw	x11, w10
	and	x11, x9, x11
	ccmp	x11, #0, #4, ne
	b.eq	LBB0_6
; %bb.12:                               ;   in Loop: Header=BB0_7 Depth=1
	bic	w9, w9, w10
	and	w10, w10, w0
	orr	w9, w9, w10
	sxtw	x9, w9
	str	x9, [x8, x20, lsl #3]
	b	LBB0_6
LBB0_13:
Lloh24:
	adrp	x0, _ipath_pioavail_lock@GOTPAGE
Lloh25:
	ldr	x0, [x0, _ipath_pioavail_lock@GOTPAGEOFF]
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	b	_spin_unlock_irqrestore
LBB0_14:
Lloh26:
	adrp	x0, l_.str@PAGE
Lloh27:
	add	x0, x0, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	b	_ipath_dbg
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Update shadow pioavail, but regs_dma NULL!\n"

	.comm	_ipath_debug,4,2                ; @ipath_debug
	.comm	___IPATH_VERBDBG,4,2            ; @__IPATH_VERBDBG
	.comm	_PKT,4,2                        ; @PKT
l_.str.1:                               ; @.str.1
	.asciz	"Refill avail, dma0=%llx shad0=%lx, d1=%llx s1=%lx, d2=%llx s2=%lx, d3=%llx s3=%lx\n"

l_.str.2:                               ; @.str.2
	.asciz	"2nd group, dma4=%llx shad4=%lx, d5=%llx s5=%lx, d6=%llx s6=%lx, d7=%llx s7=%lx\n"

	.comm	_ipath_pioavail_lock,4,2        ; @ipath_pioavail_lock
	.comm	_IPATH_SWAP_PIOBUFS,4,2         ; @IPATH_SWAP_PIOBUFS
	.comm	_INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT,4,2 ; @INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT
	.no_dead_strip	_ipath_update_pio_bufs
.subsections_via_symbols
