	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_setup_ws_server                ## -- Begin function setup_ws_server
	.p2align	4, 0x90
_setup_ws_server:                       ## @setup_ws_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	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	addq	$16, %rdi
	xorl	%esi, %esi
	callq	_pthread_mutex_init
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_FATAL
LBB0_2:
	leaq	16(%r14), %rdi
	xorl	%esi, %esi
	callq	_pthread_mutex_init
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_FATAL
LBB0_4:
	movq	_set_ws_opts@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rdi
	leaq	L_.str.3(%rip), %rsi
	callq	_ws_init
	movq	%rax, 8(%rbx)
	testq	%rax, %rax
	jne	LBB0_6
## %bb.5:
	leaq	L_.str.4(%rip), %rdi
	xorl	%eax, %eax
	callq	_FATAL
LBB0_6:
	movq	_start_server@GOTPCREL(%rip), %rdx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	movq	%rbx, %rcx
	callq	_pthread_create
	testl	%eax, %eax
	je	LBB0_8
## %bb.7:
	leaq	L_.str.5(%rip), %rdi
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_FATAL
LBB0_8:
	movq	_read_client@GOTPCREL(%rip), %rdx
	movq	%r14, %rdi
	xorl	%esi, %esi
	movq	%r14, %rcx
	callq	_pthread_create
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	leaq	L_.str.5(%rip), %rdi
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_FATAL
LBB0_10:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed init gwswriter mutex"

L_.str.1:                               ## @.str.1
	.asciz	"Failed init gwsreader mutex"

L_.str.2:                               ## @.str.2
	.asciz	"0.0.0.0"

L_.str.3:                               ## @.str.3
	.asciz	"7890"

	.comm	_set_ws_opts,4,2                ## @set_ws_opts
L_.str.4:                               ## @.str.4
	.asciz	"Failed init websocket"

	.comm	_start_server,4,2               ## @start_server
L_.str.5:                               ## @.str.5
	.asciz	"Return code from pthread_create(): %d"

	.comm	_read_client,4,2                ## @read_client
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_setup_ws_server                ; -- Begin function setup_ws_server
	.p2align	2
_setup_ws_server:                       ; @setup_ws_server
	.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
	add	x0, x0, #16
	mov	x1, #0
	bl	_pthread_mutex_init
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_FATAL
LBB0_2:
	add	x0, x19, #16
	mov	x1, #0
	bl	_pthread_mutex_init
	cbz	x0, LBB0_4
; %bb.3:
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_FATAL
LBB0_4:
Lloh4:
	adrp	x8, _set_ws_opts@GOTPAGE
Lloh5:
	ldr	x8, [x8, _set_ws_opts@GOTPAGEOFF]
Lloh6:
	ldr	w2, [x8]
Lloh7:
	adrp	x0, l_.str.2@PAGE
Lloh8:
	add	x0, x0, l_.str.2@PAGEOFF
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_ws_init
	str	x0, [x20, #8]
	cbnz	x0, LBB0_6
; %bb.5:
Lloh11:
	adrp	x0, l_.str.4@PAGE
Lloh12:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_FATAL
LBB0_6:
Lloh13:
	adrp	x2, _start_server@GOTPAGE
Lloh14:
	ldr	x2, [x2, _start_server@GOTPAGEOFF]
	mov	x0, x20
	mov	x1, #0
	mov	x3, x20
	bl	_pthread_create
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_8
; %bb.7:
	str	x0, [sp]
Lloh15:
	adrp	x0, l_.str.5@PAGE
Lloh16:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_FATAL
LBB0_8:
Lloh17:
	adrp	x2, _read_client@GOTPAGE
Lloh18:
	ldr	x2, [x2, _read_client@GOTPAGEOFF]
	mov	x0, x19
	mov	x1, #0
	mov	x3, x19
	bl	_pthread_create
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_10
; %bb.9:
	str	x0, [sp]
Lloh19:
	adrp	x0, l_.str.5@PAGE
Lloh20:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_FATAL
LBB0_10:
	mov	w0, #0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed init gwswriter mutex"

l_.str.1:                               ; @.str.1
	.asciz	"Failed init gwsreader mutex"

l_.str.2:                               ; @.str.2
	.asciz	"0.0.0.0"

l_.str.3:                               ; @.str.3
	.asciz	"7890"

	.comm	_set_ws_opts,4,2                ; @set_ws_opts
l_.str.4:                               ; @.str.4
	.asciz	"Failed init websocket"

	.comm	_start_server,4,2               ; @start_server
l_.str.5:                               ; @.str.5
	.asciz	"Return code from pthread_create(): %d"

	.comm	_read_client,4,2                ; @read_client
.subsections_via_symbols
