	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipath_reset_availshadow
_ipath_reset_availshadow:               ## @ipath_reset_availshadow
	.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
	movq	_ipath_pioavail_lock@GOTPCREL(%rip), %rdi
	callq	_spin_lock_irqsave
	cmpl	$0, (%r14)
	jle	LBB0_7
## %bb.1:
	xorl	%r12d, %r12d
	movq	_INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT@GOTPCREL(%rip), %r13
	leaq	L_.str(%rip), %r15
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%r12
	movslq	(%r14), %rax
	cmpq	%rax, %r12
	jge	LBB0_7
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r12, %rax
	cmpq	$4, %r12
	jb	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_IPATH_SWAP_PIOBUFS@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%eax, %eax
	testl	%ecx, 4(%r14)
	setne	%al
	xorq	%r12, %rax
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	24(%r14), %rcx
	cltq
	movl	(%rcx,%rax,4), %edi
	callq	_le64_to_cpu
	movq	8(%r14), %rsi
	movq	16(%r14), %rcx
	movslq	(%rsi,%r12,4), %rdx
	movl	(%rcx,%r12,4), %ebx
	notl	%ebx
	movzbl	(%r13), %ecx
	shll	%cl, %ebx
	andl	$-1431655766, %ebx              ## imm = 0xAAAAAAAA
	orl	%eax, %ebx
	movl	%ebx, (%rsi,%r12,4)
	cmpl	%ebx, %edx
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movl	%r12d, %esi
	movl	%ebx, %ecx
	callq	_ipath_dbg
	jmp	LBB0_6
LBB0_7:
	movq	_ipath_pioavail_lock@GOTPCREL(%rip), %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irqrestore         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.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
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"shadow[%d] was %Lx, now %lx\n"

	.no_dead_strip	_ipath_reset_availshadow
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipath_reset_availshadow
_ipath_reset_availshadow:               ; @ipath_reset_availshadow
	.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, x0
Lloh0:
	adrp	x0, _ipath_pioavail_lock@GOTPAGE
Lloh1:
	ldr	x0, [x0, _ipath_pioavail_lock@GOTPAGEOFF]
	bl	_spin_lock_irqsave
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.1:
	mov	x20, #0
Lloh2:
	adrp	x22, _IPATH_SWAP_PIOBUFS@GOTPAGE
Lloh3:
	ldr	x22, [x22, _IPATH_SWAP_PIOBUFS@GOTPAGEOFF]
Lloh4:
	adrp	x23, _INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT@GOTPAGE
Lloh5:
	ldr	x23, [x23, _INFINIPATH_SENDPIOAVAIL_BUSY_SHIFT@GOTPAGEOFF]
Lloh6:
	adrp	x21, l_.str@PAGE
Lloh7:
	add	x21, x21, l_.str@PAGEOFF
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x20, x20, #1
	ldrsw	x8, [x19]
	cmp	x20, x8
	b.ge	LBB0_7
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x8, x20
	cmp	x20, #4
	b.lo	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x19, #4]
	ldr	w9, [x22]
	tst	w9, w8
	cset	w8, ne
	eor	x8, x20, x8
LBB0_5:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	x9, [x19, #24]
	sbfiz	x8, x8, #2, #32
	ldr	w0, [x9, x8]
	bl	_le64_to_cpu
	lsl	x8, x20, #2
	ldp	x9, x10, [x19, #8]
	ldrsw	x2, [x9, x8]
	ldr	w10, [x10, x8]
	mvn	w10, w10
	ldr	w11, [x23]
	lsl	w10, w10, w11
	and	w10, w10, #0xaaaaaaaa
	orr	w3, w10, w0
	str	w3, [x9, x8]
	cmp	w2, w3
	b.eq	LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x21
	mov	x1, x20
	bl	_ipath_dbg
	b	LBB0_2
LBB0_7:
Lloh8:
	adrp	x0, _ipath_pioavail_lock@GOTPAGE
Lloh9:
	ldr	x0, [x0, _ipath_pioavail_lock@GOTPAGEOFF]
	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
	b	_spin_unlock_irqrestore
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.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
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"shadow[%d] was %Lx, now %lx\n"

	.no_dead_strip	_ipath_reset_availshadow
.subsections_via_symbols
