	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function create_worker
_create_worker:                         ## @create_worker
	.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	%rsi, %r14
	movq	%rdi, %r15
	movq	_thread_mode@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_1
## %bb.4:
	leaq	-28(%rbp), %rdi
	callq	_pthread_attr_init
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	leaq	L_.str.1(%rip), %rdi
	callq	_barf
LBB0_6:
	movq	_PTHREAD_STACK_MIN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-28(%rbp), %rdi
	callq	_pthread_attr_setstacksize
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	leaq	L_.str.2(%rip), %rdi
	callq	_barf
LBB0_8:
	leaq	-32(%rbp), %rdi
	leaq	-28(%rbp), %rsi
	movq	%r14, %rdx
	movq	%r15, %rcx
	callq	_pthread_create
	testl	%eax, %eax
	jne	LBB0_12
## %bb.9:
	movl	-32(%rbp), %ebx
	jmp	LBB0_10
LBB0_1:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_fork
	cmpl	$-1, %eax
	je	LBB0_11
## %bb.2:
	testl	%eax, %eax
	jne	LBB0_10
## %bb.3:
	movq	%r15, %rdi
	callq	*%r14
	xorl	%edi, %edi
	callq	_exit
LBB0_11:
	leaq	L_.str(%rip), %rdi
	callq	_barf
LBB0_10:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movl	%eax, %ebx
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	%ebx, %edi
	callq	_strerror
	leaq	L_.str.3(%rip), %rsi
	movl	%r14d, %edi
	movq	%rax, %rdx
	movl	%ebx, %ecx
	callq	_fprintf
	movl	$-1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.comm	_thread_mode,4,2                ## @thread_mode
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fork()"

L_.str.1:                               ## @.str.1
	.asciz	"pthread_attr_init:"

	.comm	_PTHREAD_STACK_MIN,4,2          ## @PTHREAD_STACK_MIN
L_.str.2:                               ## @.str.2
	.asciz	"pthread_attr_setstacksize"

	.comm	_stderr,4,2                     ## @stderr
L_.str.3:                               ## @.str.3
	.asciz	"pthread_create failed: %s (%d)\n"

	.no_dead_strip	_create_worker
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function create_worker
_create_worker:                         ; @create_worker
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, _thread_mode@GOTPAGE
Lloh1:
	ldr	x8, [x8, _thread_mode@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cbz	w8, LBB0_7
; %bb.1:
	add	x0, sp, #12
	bl	_pthread_attr_init
	cbz	x0, LBB0_3
; %bb.2:
Lloh3:
	adrp	x0, l_.str.1@PAGE
Lloh4:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_barf
LBB0_3:
Lloh5:
	adrp	x8, _PTHREAD_STACK_MIN@GOTPAGE
Lloh6:
	ldr	x8, [x8, _PTHREAD_STACK_MIN@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	add	x0, sp, #12
	bl	_pthread_attr_setstacksize
	cbz	x0, LBB0_5
; %bb.4:
Lloh8:
	adrp	x0, l_.str.2@PAGE
Lloh9:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_barf
LBB0_5:
	add	x0, sp, #8
	add	x1, sp, #12
	mov	x2, x19
	mov	x3, x20
	bl	_pthread_create
	cbnz	w0, LBB0_13
; %bb.6:
	ldr	w0, [sp, #8]
	b	LBB0_12
LBB0_7:
	bl	_fork
	cmn	w0, #1
	b.eq	LBB0_10
; %bb.8:
	cbnz	w0, LBB0_11
; %bb.9:
	mov	x0, x20
	blr	x19
	mov	w0, #0
	bl	_exit
LBB0_10:
Lloh10:
	adrp	x0, l_.str@PAGE
Lloh11:
	add	x0, x0, l_.str@PAGEOFF
	bl	_barf
LBB0_11:
	mov	w0, #0
LBB0_12:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_13:
	mov	x19, x0
Lloh12:
	adrp	x8, _stderr@GOTPAGE
Lloh13:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh14:
	ldr	w20, [x8]
	bl	_strerror
	mov	x2, x0
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	mov	x3, x19
	bl	_fprintf
	mov	w0, #-1
	bl	_exit
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_thread_mode,4,2                ; @thread_mode
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fork()"

l_.str.1:                               ; @.str.1
	.asciz	"pthread_attr_init:"

	.comm	_PTHREAD_STACK_MIN,4,2          ; @PTHREAD_STACK_MIN
l_.str.2:                               ; @.str.2
	.asciz	"pthread_attr_setstacksize"

	.comm	_stderr,4,2                     ; @stderr
l_.str.3:                               ; @.str.3
	.asciz	"pthread_create failed: %s (%d)\n"

	.no_dead_strip	_create_worker
.subsections_via_symbols
