	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_fha_assign                     ## -- Begin function fha_assign
	.p2align	4, 0x90
_fha_assign:                            ## @fha_assign
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	cmpq	$0, (%rdx)
	je	LBB0_4
## %bb.1:
	movq	(%rbx), %rax
	movq	_NFS_PROG@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
## %bb.2:
	movl	8(%rbx), %eax
	andl	$-2, %eax
	cmpl	$2, %eax
	jne	LBB0_4
## %bb.3:
	movq	%rdx, %r15
	addq	$8, %rdx
	leaq	-56(%rbp), %r13
	movq	%rbx, %rdi
	movq	%r13, %rsi
	callq	_fha_extract_info
	movl	-48(%rbp), %esi
	movq	%r15, %rdi
	callq	_fha_hash_entry_lookup
	movq	%rax, %r12
	movq	%rax, 16(%rbx)
	movl	-52(%rbp), %eax
	movl	%eax, 28(%rbx)
	movl	-56(%rbp), %eax
	movl	%eax, 24(%rbx)
	movq	%r15, %rdi
	movq	%r12, %rsi
	movq	%r13, %rdx
	movq	%r14, %rcx
	callq	_fha_hash_entry_choose_thread
	movq	%rax, %r14
	leaq	L_.str(%rip), %rsi
	movq	%rax, %rdi
	callq	_KASSERT
	movl	-52(%rbp), %esi
	movq	%r12, %rdi
	movl	$1, %edx
	callq	_fha_hash_entry_add_op
	incl	8(%r14)
	movl	-56(%rbp), %eax
	movl	%eax, 4(%r14)
	movq	%r14, %rdi
	callq	_mtx_lock
	movl	(%r12), %edi
	callq	_mtx_unlock
	jmp	LBB0_5
LBB0_4:
	movq	$0, 16(%rbx)
	movq	%r14, %rdi
	callq	_mtx_lock
LBB0_5:
	movq	%r14, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NFS_PROG,8,3                   ## @NFS_PROG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fha_assign: NULL thread!"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_fha_assign                     ; -- Begin function fha_assign
	.p2align	2
_fha_assign:                            ; @fha_assign
	.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	x20, x2
	mov	x21, x1
	mov	x19, x0
	ldr	x8, [x2], #8
	cbz	x8, LBB0_4
; %bb.1:
	ldr	x8, [x21]
Lloh0:
	adrp	x9, _NFS_PROG@GOTPAGE
Lloh1:
	ldr	x9, [x9, _NFS_PROG@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.2:
	ldr	w8, [x21, #8]
	and	w8, w8, #0xfffffffe
	cmp	w8, #2
	b.ne	LBB0_4
; %bb.3:
	mov	x1, sp
	mov	x0, x21
	bl	_fha_extract_info
	ldr	w1, [sp, #8]
	mov	x0, x20
	bl	_fha_hash_entry_lookup
	mov	x22, x0
	str	x0, [x21, #16]
	ldr	d0, [sp]
	str	d0, [x21, #24]
	mov	x2, sp
	mov	x0, x20
	mov	x1, x22
	mov	x3, x19
	bl	_fha_hash_entry_choose_thread
	mov	x19, x0
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_KASSERT
	ldr	w1, [sp, #4]
	mov	x0, x22
	mov	w2, #1
	bl	_fha_hash_entry_add_op
	ldr	w8, [x19, #8]
	add	w8, w8, #1
	ldr	w9, [sp]
	stp	w9, w8, [x19, #4]
	mov	x0, x19
	bl	_mtx_lock
	ldr	w0, [x22]
	bl	_mtx_unlock
	b	LBB0_5
LBB0_4:
	str	xzr, [x21, #16]
	mov	x0, x19
	bl	_mtx_lock
LBB0_5:
	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	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_NFS_PROG,8,3                   ; @NFS_PROG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fha_assign: NULL thread!"

.subsections_via_symbols
