	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function register_thread
_register_thread:                       ## @register_thread
	.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
	movq	%rdx, %r12
	movq	%rsi, %r14
	movq	%rdi, %r15
	xorl	%edi, %edi
	testq	%rdx, %rdx
	je	LBB0_2
## %bb.1:
	cmpq	$0, (%r12)
	sete	%dil
LBB0_2:
	callq	_REQUIRE
	movl	$16, %edi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %rbx
	movq	_FALSE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%edi, %edi
	movl	%edx, %esi
	xorl	%ecx, %ecx
	callq	_CreateEvent
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	8(%r14), %rcx
	movq	_LSIGNAL@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	(%rcx,%rdx,8), %rcx
	movq	8(%rbx), %rsi
	movq	%rcx, (%rsi,%rdx,8)
	movq	8(%rbx), %rcx
	movq	_LBROADCAST@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	%rax, (%rcx,%rdx,8)
	movq	%r15, (%rbx)
	movl	(%r14), %edi
	movq	_link@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rsi
	callq	_ISC_LIST_APPEND
	movq	%rbx, (%r12)
	movq	_ISC_R_SUCCESS@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_3:
	movq	_ISC_R_NOMEMORY@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_5:
	movq	%rbx, %rdi
	callq	_free
	movq	_ISC_R_UNEXPECTED@GOTPCREL(%rip), %rax
LBB0_7:
	movl	(%rax), %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ISC_R_NOMEMORY,4,2             ## @ISC_R_NOMEMORY
	.comm	_FALSE,4,2                      ## @FALSE
	.comm	_ISC_R_UNEXPECTED,4,2           ## @ISC_R_UNEXPECTED
	.comm	_LSIGNAL,8,3                    ## @LSIGNAL
	.comm	_LBROADCAST,8,3                 ## @LBROADCAST
	.comm	_link,4,2                       ## @link
	.comm	_ISC_R_SUCCESS,4,2              ## @ISC_R_SUCCESS
	.no_dead_strip	_register_thread
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function register_thread
_register_thread:                       ; @register_thread
	.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	x19, x2
	mov	x20, x1
	mov	x21, x0
	cbz	x2, LBB0_2
; %bb.1:
	ldr	x8, [x19]
	cmp	x8, #0
	cset	w0, eq
	b	LBB0_3
LBB0_2:
	mov	w0, #0
LBB0_3:
	bl	_REQUIRE
	mov	w0, #16
	bl	_malloc
	cbz	x0, LBB0_6
; %bb.4:
	mov	x22, x0
Lloh0:
	adrp	x8, _FALSE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, #0
	mov	x2, x1
	mov	x3, #0
	bl	_CreateEvent
	cbz	x0, LBB0_7
; %bb.5:
	ldr	x8, [x20, #8]
Lloh3:
	adrp	x9, _LSIGNAL@GOTPAGE
Lloh4:
	ldr	x9, [x9, _LSIGNAL@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	lsl	x9, x9, #3
	ldr	x8, [x8, x9]
	ldr	x10, [x22, #8]
	str	x8, [x10, x9]
	ldr	x8, [x22, #8]
Lloh6:
	adrp	x9, _LBROADCAST@GOTPAGE
Lloh7:
	ldr	x9, [x9, _LBROADCAST@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	str	x0, [x8, x9, lsl #3]
	str	x21, [x22]
	ldr	w0, [x20]
Lloh9:
	adrp	x8, _link@GOTPAGE
Lloh10:
	ldr	x8, [x8, _link@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	mov	x1, x22
	bl	_ISC_LIST_APPEND
	str	x22, [x19]
Lloh12:
	adrp	x8, _ISC_R_SUCCESS@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ISC_R_SUCCESS@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:
Lloh14:
	adrp	x8, _ISC_R_NOMEMORY@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ISC_R_NOMEMORY@GOTPAGEOFF]
	b	LBB0_8
LBB0_7:
	mov	x0, x22
	bl	_free
Lloh16:
	adrp	x8, _ISC_R_UNEXPECTED@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ISC_R_UNEXPECTED@GOTPAGEOFF]
LBB0_8:
	ldr	w0, [x8]
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ISC_R_NOMEMORY,4,2             ; @ISC_R_NOMEMORY
	.comm	_FALSE,4,2                      ; @FALSE
	.comm	_ISC_R_UNEXPECTED,4,2           ; @ISC_R_UNEXPECTED
	.comm	_LSIGNAL,8,3                    ; @LSIGNAL
	.comm	_LBROADCAST,8,3                 ; @LBROADCAST
	.comm	_link,4,2                       ; @link
	.comm	_ISC_R_SUCCESS,4,2              ; @ISC_R_SUCCESS
	.no_dead_strip	_register_thread
.subsections_via_symbols
