	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nlm_cancel_async_lock
_nlm_cancel_async_lock:                 ## @nlm_cancel_async_lock
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	16(%rdi), %r14
	movq	_MA_OWNED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_mtx_assert
	movq	%r14, %rdi
	callq	_mtx_unlock
	movl	12(%rbx), %edi
	movq	_F_CANCEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	8(%rbx), %rcx
	movq	_F_REMOTE@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	leaq	4(%rbx), %rax
	movq	%rax, (%rsp)
	xorl	%esi, %esi
	xorl	%r9d, %r9d
	callq	_VOP_ADVLOCKASYNC
	movl	%eax, %r15d
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movq	_taskqueue_thread@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_taskqueue_drain
	jmp	LBB0_3
LBB0_2:
	movq	%r14, %rdi
	callq	_mtx_lock
	movl	8(%r14), %r8d
	movl	12(%r14), %ecx
	leaq	L_.str(%rip), %rsi
	movl	$2, %edi
	movq	%rbx, %rdx
	callq	_NLM_DEBUG
	leaq	4(%r14), %rdi
	movq	_af_link@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rsi
	callq	_TAILQ_REMOVE
	movq	%r14, %rdi
	callq	_mtx_unlock
	movq	%rbx, %rdi
	callq	_nlm_free_async_lock
LBB0_3:
	movq	%r14, %rdi
	callq	_mtx_lock
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MA_OWNED,4,2                   ## @MA_OWNED
	.comm	_F_CANCEL,4,2                   ## @F_CANCEL
	.comm	_F_REMOTE,4,2                   ## @F_REMOTE
	.comm	_taskqueue_thread,4,2           ## @taskqueue_thread
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"NLM: async lock %p for %s (sysid %d) cancelled\n"

	.comm	_af_link,4,2                    ## @af_link
	.no_dead_strip	_nlm_cancel_async_lock
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nlm_cancel_async_lock
_nlm_cancel_async_lock:                 ; @nlm_cancel_async_lock
	.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, x0
	ldr	x19, [x0, #16]
Lloh0:
	adrp	x8, _MA_OWNED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MA_OWNED@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_mtx_assert
	mov	x0, x19
	bl	_mtx_unlock
	ldr	w0, [x20, #12]
Lloh3:
	adrp	x8, _F_CANCEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _F_CANCEL@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	add	x3, x20, #8
Lloh6:
	adrp	x8, _F_REMOTE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _F_REMOTE@GOTPAGEOFF]
Lloh8:
	ldr	w4, [x8]
	add	x6, x20, #4
	mov	x1, #0
	mov	x5, #0
	bl	_VOP_ADVLOCKASYNC
	mov	x21, x0
	cbz	w0, LBB0_2
; %bb.1:
Lloh9:
	adrp	x8, _taskqueue_thread@GOTPAGE
Lloh10:
	ldr	x8, [x8, _taskqueue_thread@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	mov	x1, x20
	bl	_taskqueue_drain
	b	LBB0_3
LBB0_2:
	mov	x0, x19
	bl	_mtx_lock
	ldp	w4, w3, [x19, #8]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #2
	mov	x2, x20
	bl	_NLM_DEBUG
	add	x0, x19, #4
Lloh14:
	adrp	x8, _af_link@GOTPAGE
Lloh15:
	ldr	x8, [x8, _af_link@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
	mov	x1, x20
	bl	_TAILQ_REMOVE
	mov	x0, x19
	bl	_mtx_unlock
	mov	x0, x20
	bl	_nlm_free_async_lock
LBB0_3:
	mov	x0, x19
	bl	_mtx_lock
	mov	x0, x21
	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
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_MA_OWNED,4,2                   ; @MA_OWNED
	.comm	_F_CANCEL,4,2                   ; @F_CANCEL
	.comm	_F_REMOTE,4,2                   ; @F_REMOTE
	.comm	_taskqueue_thread,4,2           ; @taskqueue_thread
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"NLM: async lock %p for %s (sysid %d) cancelled\n"

	.comm	_af_link,4,2                    ; @af_link
	.no_dead_strip	_nlm_cancel_async_lock
.subsections_via_symbols
