	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_start_server                   ## -- Begin function start_server
	.p2align	4, 0x90
_start_server:                          ## @start_server
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%eax, %eax
	callq	_init_epoll
	xorl	%eax, %eax
	callq	_init_netbuffers
	movq	_username@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdi
	callq	_change_user
	testq	%rax, %rax
	js	LBB0_25
## %bb.1:
	xorl	%eax, %eax
	callq	_create_all_outbound_connections
	movq	_SIGINT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_sigint_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_signal
	movq	_SIGTERM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_sigterm_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_signal
	movq	_pending_signals@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_2
LBB0_24:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_cleanup                        ## TAILCALL
LBB0_2:
	movq	_now@GOTPCREL(%rip), %r14
	movq	_quit_steps@GOTPCREL(%rip), %r13
	xorl	%r15d, %r15d
	xorl	%r12d, %r12d
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_23:                                ##   in Loop: Header=BB0_3 Depth=1
	incl	%r15d
	movq	_pending_signals@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jne	LBB0_24
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_15 Depth 2
	testb	%r15b, %r15b
	jne	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	_active_connections@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_maxconn@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_NB_used@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	_NB_alloc@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movq	_NB_max@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%rsp)
	movl	$1, %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_vkprintf
LBB0_5:                                 ##   in Loop: Header=BB0_3 Depth=1
	movl	$97, %edi
	callq	_epoll_work
	movl	(%r14), %ebx
	cmpl	%r12d, %ebx
	je	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	xorl	%eax, %eax
	callq	_cron
	movq	_connected@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_3 Depth=1
	movl	%ebx, %r12d
	jmp	LBB0_9
LBB0_8:                                 ##   in Loop: Header=BB0_3 Depth=1
	movl	(%r14), %eax
	movq	_start_time@GOTPCREL(%rip), %rcx
	subl	(%rcx), %eax
	movl	%ebx, %r12d
	cmpl	$11, %eax
	jge	LBB0_26
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	_expect_input@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_21
## %bb.10:                              ##   in Loop: Header=BB0_3 Depth=1
	movl	$4, %edi
	leaq	L_.str.4(%rip), %rsi
	xorl	%eax, %eax
	callq	_vkprintf
	leaq	L_.str.5(%rip), %rdi
	callq	_readline
	movq	%rax, %rbx
	cmpb	$0, (%rax)
	je	LBB0_20
## %bb.11:                              ##   in Loop: Header=BB0_3 Depth=1
	movq	_log_file@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	testq	%rdi, %rdi
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_3 Depth=1
	leaq	L_.str.6(%rip), %rsi
	movq	%rbx, %rdx
	callq	_fprintf
LBB0_13:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	%rbx, %rdi
	callq	_add_history
	movq	%rbx, %rdi
	callq	_strlen
	cmpl	$2, %eax
	jl	LBB0_17
## %bb.14:                              ##   in Loop: Header=BB0_3 Depth=1
	movl	%eax, %eax
	incq	%rax
	.p2align	4, 0x90
LBB0_15:                                ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	leal	-2(%rax), %ecx
	cmpb	$32, (%rbx,%rcx)
	jne	LBB0_17
## %bb.16:                              ##   in Loop: Header=BB0_15 Depth=2
	movb	$0, (%rbx,%rcx)
	decq	%rax
	cmpq	$2, %rax
	ja	LBB0_15
LBB0_17:                                ##   in Loop: Header=BB0_3 Depth=1
	cmpb	$40, (%rbx)
	jne	LBB0_19
## %bb.18:                              ##   in Loop: Header=BB0_3 Depth=1
	movq	%rbx, %rdi
	callq	_send_rpc_command
	jmp	LBB0_20
LBB0_19:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	%rbx, %rdi
	callq	_exec_command
LBB0_20:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	%rbx, %rdi
	callq	_free
LBB0_21:                                ##   in Loop: Header=BB0_3 Depth=1
	movq	(%r13), %rax
	testq	%rax, %rax
	je	LBB0_23
## %bb.22:                              ##   in Loop: Header=BB0_3 Depth=1
	decq	%rax
	movq	%rax, (%r13)
	jne	LBB0_23
	jmp	LBB0_24
LBB0_26:
	leaq	L_.str.3(%rip), %rdi
	xorl	%eax, %eax
	callq	_kprintf
	movl	$1, %edi
	callq	_exit
LBB0_25:
	movq	(%rbx), %rax
	testq	%rax, %rax
	leaq	L_.str.1(%rip), %rsi
	cmovneq	%rax, %rsi
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_kprintf
	movl	$1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.comm	_username,8,3                   ## @username
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fatal: cannot change user to %s\n"

L_.str.1:                               ## @.str.1
	.asciz	"(none)"

	.comm	_SIGINT,4,2                     ## @SIGINT
	.comm	_sigint_handler,4,2             ## @sigint_handler
	.comm	_SIGTERM,4,2                    ## @SIGTERM
	.comm	_sigterm_handler,4,2            ## @sigterm_handler
	.comm	_pending_signals,4,2            ## @pending_signals
L_.str.2:                               ## @.str.2
	.asciz	"epoll_work(): %d out of %d connections, network buffers: %d used, %d out of %d allocated\n"

	.comm	_active_connections,4,2         ## @active_connections
	.comm	_maxconn,4,2                    ## @maxconn
	.comm	_NB_used,4,2                    ## @NB_used
	.comm	_NB_alloc,4,2                   ## @NB_alloc
	.comm	_NB_max,4,2                     ## @NB_max
	.comm	_now,4,2                        ## @now
	.comm	_connected,4,2                  ## @connected
	.comm	_start_time,4,2                 ## @start_time
L_.str.3:                               ## @.str.3
	.asciz	"Didn't connect to server after 10 seconds.\n"

	.comm	_expect_input,8,3               ## @expect_input
L_.str.4:                               ## @.str.4
	.asciz	"Before readline call.\n"

L_.str.5:                               ## @.str.5
	.asciz	"TL>"

	.comm	_log_file,8,3                   ## @log_file
L_.str.6:                               ## @.str.6
	.asciz	"TL>%s\n"

	.comm	_quit_steps,8,3                 ## @quit_steps
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_start_server                   ; -- Begin function start_server
	.p2align	2
_start_server:                          ; @start_server
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	bl	_init_epoll
	bl	_init_netbuffers
Lloh0:
	adrp	x19, _username@GOTPAGE
Lloh1:
	ldr	x19, [x19, _username@GOTPAGEOFF]
	ldr	x0, [x19]
	bl	_change_user
	tbnz	x0, #63, LBB0_26
; %bb.1:
	bl	_create_all_outbound_connections
Lloh2:
	adrp	x8, _SIGINT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _SIGINT@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
Lloh5:
	adrp	x8, _sigint_handler@GOTPAGE
Lloh6:
	ldr	x8, [x8, _sigint_handler@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	bl	_signal
Lloh8:
	adrp	x8, _SIGTERM@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SIGTERM@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
Lloh11:
	adrp	x8, _sigterm_handler@GOTPAGE
Lloh12:
	ldr	x8, [x8, _sigterm_handler@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	bl	_signal
Lloh14:
	adrp	x24, _pending_signals@GOTPAGE
Lloh15:
	ldr	x24, [x24, _pending_signals@GOTPAGEOFF]
	ldr	w8, [x24]
	cbz	w8, LBB0_3
LBB0_2:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	b	_cleanup
LBB0_3:
	mov	w25, #0
	mov	w28, #0
Lloh16:
	adrp	x27, _now@GOTPAGE
Lloh17:
	ldr	x27, [x27, _now@GOTPAGEOFF]
Lloh18:
	adrp	x20, l_.str.4@PAGE
Lloh19:
	add	x20, x20, l_.str.4@PAGEOFF
Lloh20:
	adrp	x22, _expect_input@GOTPAGE
Lloh21:
	ldr	x22, [x22, _expect_input@GOTPAGEOFF]
Lloh22:
	adrp	x26, _quit_steps@GOTPAGE
Lloh23:
	ldr	x26, [x26, _quit_steps@GOTPAGEOFF]
Lloh24:
	adrp	x21, l_.str.5@PAGE
Lloh25:
	add	x21, x21, l_.str.5@PAGEOFF
Lloh26:
	adrp	x19, _connected@GOTPAGE
Lloh27:
	ldr	x19, [x19, _connected@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	w25, w25, #1
	ldr	w8, [x24]
	cbnz	w8, LBB0_2
LBB0_5:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_17 Depth 2
	tst	w25, #0xff
	b.ne	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
Lloh28:
	adrp	x8, _active_connections@GOTPAGE
Lloh29:
	ldr	x8, [x8, _active_connections@GOTPAGEOFF]
Lloh30:
	ldr	w8, [x8]
Lloh31:
	adrp	x9, _maxconn@GOTPAGE
Lloh32:
	ldr	x9, [x9, _maxconn@GOTPAGEOFF]
Lloh33:
	ldr	w9, [x9]
Lloh34:
	adrp	x10, _NB_used@GOTPAGE
Lloh35:
	ldr	x10, [x10, _NB_used@GOTPAGEOFF]
Lloh36:
	ldr	w10, [x10]
Lloh37:
	adrp	x11, _NB_alloc@GOTPAGE
Lloh38:
	ldr	x11, [x11, _NB_alloc@GOTPAGEOFF]
Lloh39:
	ldr	w11, [x11]
Lloh40:
	adrp	x12, _NB_max@GOTPAGE
Lloh41:
	ldr	x12, [x12, _NB_max@GOTPAGEOFF]
Lloh42:
	ldr	w12, [x12]
	stp	x11, x12, [sp, #24]
	stp	x9, x10, [sp, #8]
	str	x8, [sp]
	mov	w0, #1
Lloh43:
	adrp	x1, l_.str.2@PAGE
Lloh44:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_vkprintf
LBB0_7:                                 ;   in Loop: Header=BB0_5 Depth=1
	mov	w0, #97
	bl	_epoll_work
	ldr	w23, [x27]
	cmp	w23, w28
	b.eq	LBB0_11
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	bl	_cron
	ldr	w8, [x19]
	cbz	w8, LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x28, x23
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x27]
Lloh45:
	adrp	x9, _start_time@GOTPAGE
Lloh46:
	ldr	x9, [x9, _start_time@GOTPAGEOFF]
Lloh47:
	ldr	w9, [x9]
	sub	w8, w8, w9
	mov	x28, x23
	cmp	w8, #11
	b.ge	LBB0_25
LBB0_11:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x22]
	cbz	x8, LBB0_23
; %bb.12:                               ;   in Loop: Header=BB0_5 Depth=1
	mov	w0, #4
	mov	x1, x20
	bl	_vkprintf
	mov	x0, x21
	bl	_readline
	mov	x23, x0
	ldrb	w8, [x0]
	cbz	w8, LBB0_22
; %bb.13:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh48:
	adrp	x8, _log_file@GOTPAGE
Lloh49:
	ldr	x8, [x8, _log_file@GOTPAGEOFF]
Lloh50:
	ldr	x0, [x8]
	cbz	x0, LBB0_15
; %bb.14:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh51:
	adrp	x1, l_.str.6@PAGE
Lloh52:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x2, x23
	bl	_fprintf
LBB0_15:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x23
	bl	_add_history
	mov	x0, x23
	bl	_strlen
	cmp	w0, #2
	b.lt	LBB0_19
; %bb.16:                               ;   in Loop: Header=BB0_5 Depth=1
	mov	w8, w0
	add	x8, x8, #1
LBB0_17:                                ;   Parent Loop BB0_5 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	sub	w9, w8, #2
	ldrb	w10, [x23, x9]
	cmp	w10, #32
	b.ne	LBB0_19
; %bb.18:                               ;   in Loop: Header=BB0_17 Depth=2
	strb	wzr, [x23, x9]
	sub	x8, x8, #1
	cmp	x8, #2
	b.hi	LBB0_17
LBB0_19:                                ;   in Loop: Header=BB0_5 Depth=1
	ldrb	w8, [x23]
	mov	x0, x23
	cmp	w8, #40
	b.ne	LBB0_21
; %bb.20:                               ;   in Loop: Header=BB0_5 Depth=1
	bl	_send_rpc_command
	b	LBB0_22
LBB0_21:                                ;   in Loop: Header=BB0_5 Depth=1
	bl	_exec_command
LBB0_22:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x23
	bl	_free
LBB0_23:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [x26]
	cbz	x8, LBB0_4
; %bb.24:                               ;   in Loop: Header=BB0_5 Depth=1
	subs	x8, x8, #1
	str	x8, [x26]
	b.ne	LBB0_4
	b	LBB0_2
LBB0_25:
Lloh53:
	adrp	x0, l_.str.3@PAGE
Lloh54:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_27
LBB0_26:
	ldr	x8, [x19]
Lloh55:
	adrp	x9, l_.str.1@PAGE
Lloh56:
	add	x9, x9, l_.str.1@PAGEOFF
	cmp	x8, #0
	csel	x8, x9, x8, eq
	str	x8, [sp]
Lloh57:
	adrp	x0, l_.str@PAGE
Lloh58:
	add	x0, x0, l_.str@PAGEOFF
LBB0_27:
	bl	_kprintf
	mov	w0, #1
	bl	_exit
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpAdd	Lloh51, Lloh52
	.loh AdrpAdd	Lloh53, Lloh54
	.loh AdrpAdd	Lloh57, Lloh58
	.loh AdrpAdd	Lloh55, Lloh56
	.cfi_endproc
                                        ; -- End function
	.comm	_username,8,3                   ; @username
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fatal: cannot change user to %s\n"

l_.str.1:                               ; @.str.1
	.asciz	"(none)"

	.comm	_SIGINT,4,2                     ; @SIGINT
	.comm	_sigint_handler,4,2             ; @sigint_handler
	.comm	_SIGTERM,4,2                    ; @SIGTERM
	.comm	_sigterm_handler,4,2            ; @sigterm_handler
	.comm	_pending_signals,4,2            ; @pending_signals
l_.str.2:                               ; @.str.2
	.asciz	"epoll_work(): %d out of %d connections, network buffers: %d used, %d out of %d allocated\n"

	.comm	_active_connections,4,2         ; @active_connections
	.comm	_maxconn,4,2                    ; @maxconn
	.comm	_NB_used,4,2                    ; @NB_used
	.comm	_NB_alloc,4,2                   ; @NB_alloc
	.comm	_NB_max,4,2                     ; @NB_max
	.comm	_now,4,2                        ; @now
	.comm	_connected,4,2                  ; @connected
	.comm	_start_time,4,2                 ; @start_time
l_.str.3:                               ; @.str.3
	.asciz	"Didn't connect to server after 10 seconds.\n"

	.comm	_expect_input,8,3               ; @expect_input
l_.str.4:                               ; @.str.4
	.asciz	"Before readline call.\n"

l_.str.5:                               ; @.str.5
	.asciz	"TL>"

	.comm	_log_file,8,3                   ; @log_file
l_.str.6:                               ; @.str.6
	.asciz	"TL>%s\n"

	.comm	_quit_steps,8,3                 ; @quit_steps
.subsections_via_symbols
