	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function daemon_main
_daemon_main:                           ## @daemon_main
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movl	%edi, %ebx
	movq	__SC_OPEN_MAX@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_sysconf
	movq	%rax, %r15
	cmpl	$4, %r15d
	jl	LBB0_6
## %bb.1:
	decl	%r15d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	leal	-1(%r15), %eax
	incl	%r15d
	cmpl	$4, %r15d
	movl	%eax, %r15d
	jbe	LBB0_6
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	%r15d, %ebx
	je	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	%r15d, %r14d
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r15d, %edi
	callq	_close
	jmp	LBB0_5
LBB0_6:
	leaq	-36(%rbp), %r15
	movq	%r15, %rdi
	callq	_pthread_attr_init
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_pthread_attr_setdetachstate
	movq	_daemon_close_notify_thread@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%r14d, %ecx
	leaq	-40(%rbp), %rdi
	movq	%r15, %rsi
	callq	_pthread_create
	testq	%rax, %rax
	je	LBB0_8
LBB0_7:
	leaq	L_.str(%rip), %rdi
	callq	_dief
LBB0_8:
	movq	_daemon_conn_thread@GOTPCREL(%rip), %r12
	leaq	-40(%rbp), %r14
	leaq	-36(%rbp), %r15
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_accept
	cmpl	$-1, %eax
	je	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movl	(%r12), %edx
	movl	%eax, %ecx
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_pthread_create
	testq	%rax, %rax
	je	LBB0_9
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	__SC_OPEN_MAX,4,2               ## @_SC_OPEN_MAX
	.comm	_daemon_close_notify_thread,4,2 ## @daemon_close_notify_thread
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"pthread_create failed"

	.comm	_daemon_conn_thread,4,2         ## @daemon_conn_thread
	.no_dead_strip	_daemon_main
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function daemon_main
_daemon_main:                           ; @daemon_main
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x8, __SC_OPEN_MAX@GOTPAGE
Lloh1:
	ldr	x8, [x8, __SC_OPEN_MAX@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_sysconf
	cmp	w0, #4
	b.lt	LBB0_6
; %bb.1:
	sub	w21, w0, #1
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	w8, w21, #1
	sub	w21, w21, #1
	cmp	w8, #4
	b.ls	LBB0_6
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	cmp	w19, w21
	b.eq	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	cmp	w20, w21
	b.eq	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x21
	bl	_close
	b	LBB0_2
LBB0_6:
	add	x0, sp, #8
	bl	_pthread_attr_init
	add	x0, sp, #8
	mov	w1, #1
	bl	_pthread_attr_setdetachstate
Lloh3:
	adrp	x8, _daemon_close_notify_thread@GOTPAGE
Lloh4:
	ldr	x8, [x8, _daemon_close_notify_thread@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	w3, w20
	add	x0, sp, #12
	add	x1, sp, #8
	bl	_pthread_create
	cbz	x0, LBB0_8
LBB0_7:
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_dief
LBB0_8:
Lloh8:
	adrp	x20, _daemon_conn_thread@GOTPAGE
Lloh9:
	ldr	x20, [x20, _daemon_conn_thread@GOTPAGEOFF]
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	mov	x1, #0
	mov	x2, #0
	bl	_accept
	cmn	w0, #1
	b.eq	LBB0_9
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w2, [x20]
	mov	w3, w0
	add	x0, sp, #12
	add	x1, sp, #8
	bl	_pthread_create
	cbz	x0, LBB0_9
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	__SC_OPEN_MAX,4,2               ; @_SC_OPEN_MAX
	.comm	_daemon_close_notify_thread,4,2 ; @daemon_close_notify_thread
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"pthread_create failed"

	.comm	_daemon_conn_thread,4,2         ; @daemon_conn_thread
	.no_dead_strip	_daemon_main
.subsections_via_symbols
