	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_uverbs_destroy_ufile_hw        ## -- Begin function uverbs_destroy_ufile_hw
	.p2align	4, 0x90
_uverbs_destroy_ufile_hw:               ## @uverbs_destroy_ufile_hw
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r12
	movq	_RDMA_REMOVE_CLOSE@GOTPCREL(%rip), %rax
	cmpl	%esi, (%rax)
	jne	LBB0_3
## %bb.1:
	movq	%r12, %rdi
	callq	_mutex_trylock
	testl	%eax, %eax
	jne	LBB0_4
## %bb.2:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%r12, %rdi
	callq	_mutex_lock
LBB0_4:
	leaq	4(%r12), %r15
	movq	%r15, %rdi
	callq	_down_write
	movq	16(%r12), %rax
	testq	%rax, %rax
	je	LBB0_11
## %bb.5:
	movabsq	$4294967297, %rcx               ## imm = 0x100000001
	movq	%rcx, (%rax)
	leaq	8(%r12), %rbx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_list_empty
	testl	%eax, %eax
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	%r12, %rdi
	movl	%r14d, %esi
	callq	___uverbs_cleanup_ufile
	testq	%rax, %rax
	je	LBB0_6
LBB0_8:
	movq	16(%r12), %rax
	movl	$0, 4(%rax)
	movq	%rbx, %rdi
	callq	_list_empty
	testl	%eax, %eax
	jne	LBB0_10
## %bb.9:
	movq	%r12, %rdi
	movl	%r14d, %esi
	callq	___uverbs_cleanup_ufile
LBB0_10:
	movq	%r12, %rdi
	movl	%r14d, %esi
	callq	_ufile_destroy_ucontext
LBB0_11:
	movq	%r15, %rdi
	callq	_up_write
	movq	%r12, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mutex_unlock                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_RDMA_REMOVE_CLOSE,4,2          ## @RDMA_REMOVE_CLOSE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_uverbs_destroy_ufile_hw        ; -- Begin function uverbs_destroy_ufile_hw
	.p2align	2
_uverbs_destroy_ufile_hw:               ; @uverbs_destroy_ufile_hw
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _RDMA_REMOVE_CLOSE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RDMA_REMOVE_CLOSE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w1
	b.ne	LBB0_3
; %bb.1:
	bl	_mutex_trylock
	cbnz	w0, LBB0_4
; %bb.2:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_3:
	bl	_mutex_lock
LBB0_4:
	add	x21, x19, #4
	mov	x0, x21
	bl	_down_write
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_11
; %bb.5:
	movi.2s	v0, #1
	str	d0, [x8]
	add	x22, x19, #8
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	bl	_list_empty
	cbnz	w0, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x19
	mov	x1, x20
	bl	___uverbs_cleanup_ufile
	cbz	x0, LBB0_6
LBB0_8:
	ldr	x8, [x19, #16]
	str	wzr, [x8, #4]
	mov	x0, x22
	bl	_list_empty
	cbnz	w0, LBB0_10
; %bb.9:
	mov	x0, x19
	mov	x1, x20
	bl	___uverbs_cleanup_ufile
LBB0_10:
	mov	x0, x19
	mov	x1, x20
	bl	_ufile_destroy_ucontext
LBB0_11:
	mov	x0, x21
	bl	_up_write
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_mutex_unlock
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_RDMA_REMOVE_CLOSE,4,2          ; @RDMA_REMOVE_CLOSE
.subsections_via_symbols
