	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_LockWaiterCount                ## -- Begin function LockWaiterCount
	.p2align	4, 0x90
_LockWaiterCount:                       ## @LockWaiterCount
	.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, %r15
	movq	(%rdi), %rbx
	testq	%rbx, %rbx
	jle	LBB0_2
## %bb.1:
	movq	_LockMethods@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_lengthof
	cmpq	%rax, %rbx
	jl	LBB0_3
LBB0_2:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdx
	callq	_elog
LBB0_3:
	movq	%r15, %rdi
	callq	_LockTagHashCode
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_LockHashPartitionLock
	movq	%rax, %r14
	movq	_LW_EXCLUSIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_LWLockAcquire
	movq	_LockMethodLockHash@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_HASH_FIND@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	-28(%rbp), %r8
	movq	%r15, %rsi
	movl	%ebx, %edx
	callq	_hash_search_with_hash_value
	cmpl	$0, -28(%rbp)
	je	LBB0_4
## %bb.5:
	movq	%rax, %rbx
	xorl	%edi, %edi
	testq	%rax, %rax
	setne	%dil
	callq	_Assert
	movl	(%rbx), %ebx
	jmp	LBB0_6
LBB0_4:
	xorl	%ebx, %ebx
LBB0_6:
	movq	%r14, %rdi
	callq	_LWLockRelease
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LockMethods,4,2                ## @LockMethods
	.comm	_ERROR,4,2                      ## @ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unrecognized lock method: %d"

	.comm	_LW_EXCLUSIVE,4,2               ## @LW_EXCLUSIVE
	.comm	_LockMethodLockHash,4,2         ## @LockMethodLockHash
	.comm	_HASH_FIND,4,2                  ## @HASH_FIND
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_LockWaiterCount                ; -- Begin function LockWaiterCount
	.p2align	2
_LockWaiterCount:                       ; @LockWaiterCount
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	ldr	x20, [x0]
	cmp	x20, #1
	b.lt	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _LockMethods@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LockMethods@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_lengthof
	cmp	x20, x0
	b.lt	LBB0_3
LBB0_2:
Lloh3:
	adrp	x8, _ERROR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ERROR@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_elog
LBB0_3:
	mov	x0, x19
	bl	_LockTagHashCode
	mov	x21, x0
	bl	_LockHashPartitionLock
	mov	x20, x0
Lloh8:
	adrp	x8, _LW_EXCLUSIVE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _LW_EXCLUSIVE@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	bl	_LWLockAcquire
Lloh11:
	adrp	x8, _LockMethodLockHash@GOTPAGE
Lloh12:
	ldr	x8, [x8, _LockMethodLockHash@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
Lloh14:
	adrp	x8, _HASH_FIND@GOTPAGE
Lloh15:
	ldr	x8, [x8, _HASH_FIND@GOTPAGEOFF]
Lloh16:
	ldr	w3, [x8]
	add	x4, sp, #12
	mov	x1, x19
	mov	x2, x21
	bl	_hash_search_with_hash_value
	ldr	w8, [sp, #12]
	cbz	w8, LBB0_5
; %bb.4:
	mov	x19, x0
	cmp	x0, #0
	cset	w0, ne
	bl	_Assert
	ldr	w19, [x19]
	b	LBB0_6
LBB0_5:
	mov	w19, #0
LBB0_6:
	mov	x0, x20
	bl	_LWLockRelease
	mov	x0, x19
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_LockMethods,4,2                ; @LockMethods
	.comm	_ERROR,4,2                      ; @ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unrecognized lock method: %d"

	.comm	_LW_EXCLUSIVE,4,2               ; @LW_EXCLUSIVE
	.comm	_LockMethodLockHash,4,2         ; @LockMethodLockHash
	.comm	_HASH_FIND,4,2                  ; @HASH_FIND
.subsections_via_symbols
