	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_server_init                    ## -- Begin function server_init
	.p2align	4, 0x90
_server_init:                           ## @server_init
	.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
	movq	%rcx, %rbx
	movq	%rdx, %r15
	movq	%rdi, %r14
	testq	%rsi, %rsi
	je	LBB0_9
## %bb.1:
	movq	24(%rsi), %rax
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_sf@GOTPCREL(%rip), %rcx
	movq	%rax, 24(%rcx)
LBB0_3:
	movq	16(%rsi), %rax
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	_sf@GOTPCREL(%rip), %rcx
	movq	%rax, 16(%rcx)
LBB0_5:
	movq	8(%rsi), %rax
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	movq	_sf@GOTPCREL(%rip), %rcx
	movq	%rax, 8(%rcx)
LBB0_7:
	movq	(%rsi), %rax
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	_sf@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
LBB0_9:
	xorl	%eax, %eax
	callq	_init_epoll
	xorl	%eax, %eax
	callq	_init_netbuffers
	movq	_udp_enabled@GOTPCREL(%rip), %r13
	cmpq	$0, (%r13)
	je	LBB0_11
## %bb.10:
	xorl	%edi, %edi
	callq	_init_msg_buffers
LBB0_11:
	movq	_daemonize@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_13
## %bb.12:
	xorl	%eax, %eax
	callq	_setsid
	xorl	%eax, %eax
	callq	_reopen_logs
LBB0_13:
	movq	(%r14), %rax
	testq	%rax, %rax
	jne	LBB0_15
## %bb.14:
	movq	_port@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movl	8(%r14), %esi
	movq	_backlog@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%ecx, %ecx
	callq	_server_socket
	movq	%rax, (%r14)
LBB0_15:
	testq	%rax, %rax
	js	LBB0_16
## %bb.18:
	movq	_username@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	callq	_change_user
	testq	%rax, %rax
	js	LBB0_19
## %bb.20:
	movq	_binlogname@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	movq	_binlog_disabled@GOTPCREL(%rip), %r12
	je	LBB0_23
## %bb.21:
	cmpq	$0, (%r12)
	jne	LBB0_23
## %bb.22:
	movq	_Binlog@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_append_to_binlog
	movq	_log_readto_pos@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_assert
LBB0_23:
	movq	(%r14), %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	callq	_init_listening_connection
	cmpq	$0, (%r13)
	je	LBB0_25
## %bb.24:
	movq	_port@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	xorl	%esi, %esi
	callq	_add_udp_socket
LBB0_25:
	cmpq	$0, (%r12)
	je	LBB0_28
## %bb.26:
	movq	_binlog_fd@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	js	LBB0_28
## %bb.27:
	movq	_read_new_events@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_epoll_pre_event@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
LBB0_28:
	leaq	-48(%rbp), %rbx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	_sigint_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	movq	%rbx, %rdi
	callq	_sigemptyset
	movq	_SIGTERM@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_sigaddset
	movq	_SIGINT@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_sigaction
	movq	_sigterm_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	movq	%rbx, %rdi
	callq	_sigemptyset
	movl	(%r15), %esi
	movq	%rbx, %rdi
	callq	_sigaddset
	movl	(%r14), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_sigaction
	movq	_SIG_IGN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	movq	_SIGPIPE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_sigaction
	movq	_SIGPOLL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_sigaction
	movq	_daemonize@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_30
## %bb.29:
	movq	_sighup_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	leaq	-48(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_sigemptyset
	movq	_SIGHUP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_sigaction
LBB0_30:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_16:
	movq	_port@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_17
LBB0_19:
	movq	(%r12), %rax
	testq	%rax, %rax
	leaq	L_.str.2(%rip), %rsi
	cmovneq	%rax, %rsi
	leaq	L_.str.1(%rip), %rdi
LBB0_17:
	callq	_kprintf
	movl	$1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.comm	_sf,32,3                        ## @sf
	.comm	_udp_enabled,8,3                ## @udp_enabled
	.comm	_daemonize,8,3                  ## @daemonize
	.comm	_port,8,3                       ## @port
	.comm	_backlog,4,2                    ## @backlog
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cannot open server socket at port %d: %m\n"

	.comm	_username,8,3                   ## @username
L_.str.1:                               ## @.str.1
	.asciz	"fatal: cannot change user to %s\n"

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

	.comm	_binlogname,8,3                 ## @binlogname
	.comm	_binlog_disabled,8,3            ## @binlog_disabled
	.comm	_Binlog,4,2                     ## @Binlog
	.comm	_log_readto_pos,8,3             ## @log_readto_pos
	.comm	_binlog_fd,8,3                  ## @binlog_fd
	.comm	_read_new_events,4,2            ## @read_new_events
	.comm	_epoll_pre_event,4,2            ## @epoll_pre_event
	.comm	_sigint_handler,4,2             ## @sigint_handler
	.comm	_SIGTERM,4,2                    ## @SIGTERM
	.comm	_SIGINT,4,2                     ## @SIGINT
	.comm	_sigterm_handler,4,2            ## @sigterm_handler
	.comm	_SIG_IGN,4,2                    ## @SIG_IGN
	.comm	_SIGPIPE,4,2                    ## @SIGPIPE
	.comm	_SIGPOLL,4,2                    ## @SIGPOLL
	.comm	_sighup_handler,4,2             ## @sighup_handler
	.comm	_SIGHUP,4,2                     ## @SIGHUP
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_server_init                    ; -- Begin function server_init
	.p2align	2
_server_init:                           ; @server_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x3
	mov	x20, x2
	mov	x21, x0
	cbz	x1, LBB0_9
; %bb.1:
	ldr	x9, [x1, #24]
Lloh0:
	adrp	x8, _sf@GOTPAGE
Lloh1:
	ldr	x8, [x8, _sf@GOTPAGEOFF]
	cbz	x9, LBB0_3
; %bb.2:
	str	x9, [x8, #24]
LBB0_3:
	ldr	x9, [x1, #16]
	cbz	x9, LBB0_5
; %bb.4:
	str	x9, [x8, #16]
LBB0_5:
	ldr	x9, [x1, #8]
	cbz	x9, LBB0_7
; %bb.6:
	str	x9, [x8, #8]
LBB0_7:
	ldr	x9, [x1]
	cbz	x9, LBB0_9
; %bb.8:
	str	x9, [x8]
LBB0_9:
	bl	_init_epoll
	bl	_init_netbuffers
Lloh2:
	adrp	x23, _udp_enabled@GOTPAGE
Lloh3:
	ldr	x23, [x23, _udp_enabled@GOTPAGEOFF]
	ldr	x8, [x23]
	cbz	x8, LBB0_11
; %bb.10:
	mov	w0, #0
	bl	_init_msg_buffers
LBB0_11:
Lloh4:
	adrp	x22, _daemonize@GOTPAGE
Lloh5:
	ldr	x22, [x22, _daemonize@GOTPAGEOFF]
	ldr	x8, [x22]
	cbz	x8, LBB0_13
; %bb.12:
	bl	_setsid
	bl	_reopen_logs
LBB0_13:
	ldr	x0, [x21]
	cbnz	x0, LBB0_15
; %bb.14:
Lloh6:
	adrp	x8, _port@GOTPAGE
Lloh7:
	ldr	x8, [x8, _port@GOTPAGEOFF]
Lloh8:
	ldr	x0, [x8]
	ldr	w1, [x21, #8]
Lloh9:
	adrp	x8, _backlog@GOTPAGE
Lloh10:
	ldr	x8, [x8, _backlog@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	mov	w3, #0
	bl	_server_socket
	str	x0, [x21]
LBB0_15:
	tbnz	x0, #63, LBB0_28
; %bb.16:
Lloh12:
	adrp	x24, _username@GOTPAGE
Lloh13:
	ldr	x24, [x24, _username@GOTPAGEOFF]
	ldr	x0, [x24]
	bl	_change_user
	tbnz	x0, #63, LBB0_29
; %bb.17:
Lloh14:
	adrp	x8, _binlogname@GOTPAGE
Lloh15:
	ldr	x8, [x8, _binlogname@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
Lloh17:
	adrp	x24, _binlog_disabled@GOTPAGE
Lloh18:
	ldr	x24, [x24, _binlog_disabled@GOTPAGEOFF]
	cbz	x8, LBB0_20
; %bb.18:
	ldr	x8, [x24]
	cbnz	x8, LBB0_20
; %bb.19:
Lloh19:
	adrp	x8, _Binlog@GOTPAGE
Lloh20:
	ldr	x8, [x8, _Binlog@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
	bl	_append_to_binlog
Lloh22:
	adrp	x8, _log_readto_pos@GOTPAGE
Lloh23:
	ldr	x8, [x8, _log_readto_pos@GOTPAGEOFF]
Lloh24:
	ldr	x8, [x8]
	cmp	x0, x8
	cset	w0, eq
	bl	_assert
LBB0_20:
	ldr	x0, [x21]
	mov	x1, x20
	mov	x2, x19
	bl	_init_listening_connection
	ldr	x8, [x23]
	cbz	x8, LBB0_22
; %bb.21:
Lloh25:
	adrp	x8, _port@GOTPAGE
Lloh26:
	ldr	x8, [x8, _port@GOTPAGEOFF]
Lloh27:
	ldr	x0, [x8]
	mov	w1, #0
	bl	_add_udp_socket
LBB0_22:
	ldr	x8, [x24]
	cbz	x8, LBB0_25
; %bb.23:
Lloh28:
	adrp	x8, _binlog_fd@GOTPAGE
Lloh29:
	ldr	x8, [x8, _binlog_fd@GOTPAGEOFF]
Lloh30:
	ldr	x8, [x8]
	tbnz	x8, #63, LBB0_25
; %bb.24:
Lloh31:
	adrp	x8, _read_new_events@GOTPAGE
Lloh32:
	ldr	x8, [x8, _read_new_events@GOTPAGEOFF]
Lloh33:
	ldr	w8, [x8]
Lloh34:
	adrp	x9, _epoll_pre_event@GOTPAGE
Lloh35:
	ldr	x9, [x9, _epoll_pre_event@GOTPAGEOFF]
Lloh36:
	str	w8, [x9]
LBB0_25:
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #8
	bl	_memset
Lloh37:
	adrp	x8, _sigint_handler@GOTPAGE
Lloh38:
	ldr	x8, [x8, _sigint_handler@GOTPAGEOFF]
Lloh39:
	ldr	w8, [x8]
	str	w8, [sp, #12]
	add	x0, sp, #8
	bl	_sigemptyset
Lloh40:
	adrp	x19, _SIGTERM@GOTPAGE
Lloh41:
	ldr	x19, [x19, _SIGTERM@GOTPAGEOFF]
	ldr	w1, [x19]
	add	x0, sp, #8
	bl	_sigaddset
Lloh42:
	adrp	x20, _SIGINT@GOTPAGE
Lloh43:
	ldr	x20, [x20, _SIGINT@GOTPAGEOFF]
	ldr	w0, [x20]
	add	x1, sp, #8
	mov	x2, #0
	bl	_sigaction
Lloh44:
	adrp	x8, _sigterm_handler@GOTPAGE
Lloh45:
	ldr	x8, [x8, _sigterm_handler@GOTPAGEOFF]
Lloh46:
	ldr	w8, [x8]
	str	w8, [sp, #12]
	add	x0, sp, #8
	bl	_sigemptyset
	ldr	w1, [x20]
	add	x0, sp, #8
	bl	_sigaddset
	ldr	w0, [x19]
	add	x1, sp, #8
	mov	x2, #0
	bl	_sigaction
Lloh47:
	adrp	x8, _SIG_IGN@GOTPAGE
Lloh48:
	ldr	x8, [x8, _SIG_IGN@GOTPAGEOFF]
Lloh49:
	ldr	w8, [x8]
	str	w8, [sp, #12]
Lloh50:
	adrp	x8, _SIGPIPE@GOTPAGE
Lloh51:
	ldr	x8, [x8, _SIGPIPE@GOTPAGEOFF]
Lloh52:
	ldr	w0, [x8]
	add	x1, sp, #8
	mov	x2, #0
	bl	_sigaction
Lloh53:
	adrp	x8, _SIGPOLL@GOTPAGE
Lloh54:
	ldr	x8, [x8, _SIGPOLL@GOTPAGEOFF]
Lloh55:
	ldr	w0, [x8]
	add	x1, sp, #8
	mov	x2, #0
	bl	_sigaction
	ldr	x8, [x22]
	cbz	x8, LBB0_27
; %bb.26:
Lloh56:
	adrp	x8, _sighup_handler@GOTPAGE
Lloh57:
	ldr	x8, [x8, _sighup_handler@GOTPAGEOFF]
Lloh58:
	ldr	w8, [x8]
	str	w8, [sp, #12]
	add	x0, sp, #8
	bl	_sigemptyset
Lloh59:
	adrp	x8, _SIGHUP@GOTPAGE
Lloh60:
	ldr	x8, [x8, _SIGHUP@GOTPAGEOFF]
Lloh61:
	ldr	w0, [x8]
	add	x1, sp, #8
	mov	x2, #0
	bl	_sigaction
LBB0_27:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_28:
Lloh62:
	adrp	x8, _port@GOTPAGE
Lloh63:
	ldr	x8, [x8, _port@GOTPAGEOFF]
Lloh64:
	ldr	x1, [x8]
Lloh65:
	adrp	x0, l_.str@PAGE
Lloh66:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_30
LBB0_29:
	ldr	x8, [x24]
Lloh67:
	adrp	x9, l_.str.2@PAGE
Lloh68:
	add	x9, x9, l_.str.2@PAGEOFF
	cmp	x8, #0
	csel	x1, x9, x8, eq
Lloh69:
	adrp	x0, l_.str.1@PAGE
Lloh70:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_30:
	bl	_kprintf
	mov	w0, #1
	bl	_exit
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotStr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGot	Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpAdd	Lloh65, Lloh66
	.loh AdrpLdrGotLdr	Lloh62, Lloh63, Lloh64
	.loh AdrpAdd	Lloh69, Lloh70
	.loh AdrpAdd	Lloh67, Lloh68
	.cfi_endproc
                                        ; -- End function
	.comm	_sf,32,3                        ; @sf
	.comm	_udp_enabled,8,3                ; @udp_enabled
	.comm	_daemonize,8,3                  ; @daemonize
	.comm	_port,8,3                       ; @port
	.comm	_backlog,4,2                    ; @backlog
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cannot open server socket at port %d: %m\n"

	.comm	_username,8,3                   ; @username
l_.str.1:                               ; @.str.1
	.asciz	"fatal: cannot change user to %s\n"

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

	.comm	_binlogname,8,3                 ; @binlogname
	.comm	_binlog_disabled,8,3            ; @binlog_disabled
	.comm	_Binlog,4,2                     ; @Binlog
	.comm	_log_readto_pos,8,3             ; @log_readto_pos
	.comm	_binlog_fd,8,3                  ; @binlog_fd
	.comm	_read_new_events,4,2            ; @read_new_events
	.comm	_epoll_pre_event,4,2            ; @epoll_pre_event
	.comm	_sigint_handler,4,2             ; @sigint_handler
	.comm	_SIGTERM,4,2                    ; @SIGTERM
	.comm	_SIGINT,4,2                     ; @SIGINT
	.comm	_sigterm_handler,4,2            ; @sigterm_handler
	.comm	_SIG_IGN,4,2                    ; @SIG_IGN
	.comm	_SIGPIPE,4,2                    ; @SIGPIPE
	.comm	_SIGPOLL,4,2                    ; @SIGPOLL
	.comm	_sighup_handler,4,2             ; @sighup_handler
	.comm	_SIGHUP,4,2                     ; @SIGHUP
.subsections_via_symbols
