	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function add_open
_add_open:                              ## @add_open
	.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
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, %r13
	movl	%ecx, %r12d
	movq	%rdx, %rbx
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movl	$0, -68(%rbp)
	leaq	L_.str(%rip), %rdx
	leaq	-63(%rbp), %rdi
	movl	$15, %esi
	movl	%r14d, %ecx
	callq	_snprintf
	movb	$0, -49(%rbp)
	leaq	-80(%rbp), %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	%r15, %rdi
	callq	_log_assert
	cmpb	$47, (%r15)
	jne	LBB0_2
## %bb.1:
	movq	%rbx, -88(%rbp)                 ## 8-byte Spill
	movl	(%r13), %edx
	leaq	-68(%rbp), %rsi
	movq	%r15, %rdi
	callq	_create_local_accept_sock
	movl	%eax, %ebx
	cmpl	$-1, %ebx
	je	LBB0_7
	jmp	LBB0_12
LBB0_2:
	movq	_SOCK_STREAM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -76(%rbp)
	movq	_AI_PASSIVE@GOTPCREL(%rip), %rax
	movq	_AI_NUMERICHOST@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movl	%ecx, -80(%rbp)
	leaq	-63(%rbp), %rsi
	leaq	-80(%rbp), %rdx
	leaq	-96(%rbp), %rcx
	movq	%r15, %rdi
	callq	_getaddrinfo
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	movq	-96(%rbp), %rdi
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.5:
	movq	%rbx, -88(%rbp)                 ## 8-byte Spill
	movl	8(%r13), %r8d
	movl	(%r13), %eax
	movl	4(%r13), %ebx
	leaq	-68(%rbp), %rdx
	movl	$1, %esi
	xorl	%ecx, %ecx
	xorl	%r9d, %r9d
	pushq	%rax
	pushq	%rbx
	callq	_create_tcp_accept_sock
	addq	$16, %rsp
	movl	%eax, %ebx
	movq	-96(%rbp), %rdi
	callq	_freeaddrinfo
	cmpl	$-1, %ebx
	jne	LBB0_12
LBB0_7:
	cmpl	$0, -68(%rbp)
	je	LBB0_12
## %bb.8:
	testl	%r12d, %r12d
	je	LBB0_9
## %bb.10:
	leaq	L_.str.4(%rip), %rdi
	jmp	LBB0_11
LBB0_12:
	cmpl	$-1, %ebx
	je	LBB0_13
## %bb.14:
	movl	$1, %r12d
	movl	$1, %edi
	movl	$16, %esi
	callq	_calloc
	testq	%rax, %rax
	je	LBB0_15
## %bb.16:
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
	movq	(%rdx), %rcx
	movq	%rcx, 8(%rax)
	movq	%rax, (%rdx)
	movl	%ebx, (%rax)
	jmp	LBB0_17
LBB0_4:
	movl	%eax, %edi
	callq	_gai_strerror
	leaq	L_.str.1(%rip), %rdi
	leaq	L_.str.3(%rip), %r8
	xorl	%r12d, %r12d
	leaq	-63(%rbp), %rdx
	movq	%r15, %rsi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_log_err
	jmp	LBB0_17
LBB0_13:
	leaq	L_.str.5(%rip), %rdi
LBB0_11:
	xorl	%r12d, %r12d
	movq	%r15, %rsi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_log_err
	jmp	LBB0_17
LBB0_9:
	movl	$1, %r12d
	jmp	LBB0_17
LBB0_15:
	movl	%ebx, %edi
	callq	_close
	leaq	L_.str.6(%rip), %rdi
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	callq	_log_err
LBB0_17:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_19
## %bb.18:
	movl	%r12d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%d"

	.comm	_SOCK_STREAM,4,2                ## @SOCK_STREAM
	.comm	_AI_PASSIVE,4,2                 ## @AI_PASSIVE
	.comm	_AI_NUMERICHOST,4,2             ## @AI_NUMERICHOST
L_.str.1:                               ## @.str.1
	.asciz	"control interface %s:%s getaddrinfo: %s %s"

L_.str.3:                               ## @.str.3
	.space	1

L_.str.4:                               ## @.str.4
	.asciz	"cannot open control interface %s %d : protocol not supported"

L_.str.5:                               ## @.str.5
	.asciz	"cannot open control interface %s %d"

L_.str.6:                               ## @.str.6
	.asciz	"out of memory"

	.comm	_EAI_NONAME,4,2                 ## @EAI_NONAME
	.comm	_EAI_SYSTEM,4,2                 ## @EAI_SYSTEM
	.comm	_S_IRGRP,4,2                    ## @S_IRGRP
	.comm	_S_IRUSR,4,2                    ## @S_IRUSR
	.comm	_S_IWGRP,4,2                    ## @S_IWGRP
	.comm	_S_IWUSR,4,2                    ## @S_IWUSR
	.comm	_VERB_QUERY,4,2                 ## @VERB_QUERY
	.comm	_cfg_gid,8,3                    ## @cfg_gid
	.comm	_cfg_uid,8,3                    ## @cfg_uid
	.comm	_errno,4,2                      ## @errno
	.no_dead_strip	_add_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function add_open
_add_open:                              ; @add_open
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	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
	mov	x23, x4
	mov	x22, x3
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	str	wzr, [sp, #36]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	add	x0, sp, #57
	mov	w1, #15
	mov	x3, x21
	bl	_snprintf
	strb	wzr, [sp, #71]
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	mov	x0, x19
	bl	_log_assert
	ldrb	w8, [x19]
	cmp	w8, #47
	b.ne	LBB0_2
; %bb.1:
	ldr	w2, [x23]
	add	x1, sp, #36
	mov	x0, x19
	bl	_create_local_accept_sock
	mov	x23, x0
	b	LBB0_5
LBB0_2:
Lloh5:
	adrp	x8, _SOCK_STREAM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _SOCK_STREAM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	adrp	x9, _AI_PASSIVE@GOTPAGE
Lloh9:
	ldr	x9, [x9, _AI_PASSIVE@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
Lloh11:
	adrp	x10, _AI_NUMERICHOST@GOTPAGE
Lloh12:
	ldr	x10, [x10, _AI_NUMERICHOST@GOTPAGEOFF]
Lloh13:
	ldr	w10, [x10]
	orr	w9, w10, w9
	stp	w9, w8, [sp, #48]
	add	x24, sp, #57
	add	x1, sp, #57
	add	x2, sp, #48
	add	x3, sp, #40
	mov	x0, x19
	bl	_getaddrinfo
	mov	x8, x0
	cbnz	w0, LBB0_12
; %bb.3:
	ldr	x0, [sp, #40]
	cbz	x0, LBB0_12
; %bb.4:
	ldp	w6, w4, [x23, #4]
	ldr	w7, [x23]
	add	x2, sp, #36
	mov	w1, #1
	mov	w3, #0
	mov	w5, #0
	bl	_create_tcp_accept_sock
	mov	x23, x0
	ldr	x0, [sp, #40]
	bl	_freeaddrinfo
LBB0_5:
	ldr	w8, [sp, #36]
	cmn	w23, #1
	ccmp	w8, #0, #4, eq
	b.ne	LBB0_9
; %bb.6:
	cmn	w23, #1
	b.eq	LBB0_13
; %bb.7:
	mov	w0, #1
	mov	w1, #16
	bl	_calloc
	cbz	x0, LBB0_14
; %bb.8:
	ldr	x8, [x20]
	str	x8, [x0, #8]
	str	x0, [x20]
	str	w23, [x0]
	b	LBB0_11
LBB0_9:
	cbz	w22, LBB0_11
; %bb.10:
	stp	x19, x21, [sp]
Lloh14:
	adrp	x0, l_.str.4@PAGE
Lloh15:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_15
LBB0_11:
	mov	w0, #1
	b	LBB0_16
LBB0_12:
	mov	x0, x8
	bl	_gai_strerror
                                        ; kill: def $w0 killed $w0 def $x0
Lloh16:
	adrp	x8, l_.str.3@PAGE
Lloh17:
	add	x8, x8, l_.str.3@PAGEOFF
	stp	x0, x8, [sp, #16]
	stp	x19, x24, [sp]
Lloh18:
	adrp	x0, l_.str.1@PAGE
Lloh19:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_15
LBB0_13:
                                        ; kill: def $w21 killed $w21 killed $x21 def $x21
	stp	x19, x21, [sp]
Lloh20:
	adrp	x0, l_.str.5@PAGE
Lloh21:
	add	x0, x0, l_.str.5@PAGEOFF
	b	LBB0_15
LBB0_14:
	mov	x0, x23
	bl	_close
Lloh22:
	adrp	x0, l_.str.6@PAGE
Lloh23:
	add	x0, x0, l_.str.6@PAGEOFF
LBB0_15:
	bl	_log_err
	mov	w0, #0
LBB0_16:
	ldur	x8, [x29, #-56]
Lloh24:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh25:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh26:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_18
; %bb.17:
	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
	add	sp, sp, #144
	ret
LBB0_18:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%d"

	.comm	_SOCK_STREAM,4,2                ; @SOCK_STREAM
	.comm	_AI_PASSIVE,4,2                 ; @AI_PASSIVE
	.comm	_AI_NUMERICHOST,4,2             ; @AI_NUMERICHOST
l_.str.1:                               ; @.str.1
	.asciz	"control interface %s:%s getaddrinfo: %s %s"

l_.str.3:                               ; @.str.3
	.space	1

l_.str.4:                               ; @.str.4
	.asciz	"cannot open control interface %s %d : protocol not supported"

l_.str.5:                               ; @.str.5
	.asciz	"cannot open control interface %s %d"

l_.str.6:                               ; @.str.6
	.asciz	"out of memory"

	.comm	_EAI_NONAME,4,2                 ; @EAI_NONAME
	.comm	_EAI_SYSTEM,4,2                 ; @EAI_SYSTEM
	.comm	_S_IRGRP,4,2                    ; @S_IRGRP
	.comm	_S_IRUSR,4,2                    ; @S_IRUSR
	.comm	_S_IWGRP,4,2                    ; @S_IWGRP
	.comm	_S_IWUSR,4,2                    ; @S_IWUSR
	.comm	_VERB_QUERY,4,2                 ; @VERB_QUERY
	.comm	_cfg_gid,8,3                    ; @cfg_gid
	.comm	_cfg_uid,8,3                    ; @cfg_uid
	.comm	_errno,4,2                      ; @errno
	.no_dead_strip	_add_open
.subsections_via_symbols
