	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_main                           ## -- Begin function main
	.p2align	4, 0x90
_main:                                  ## @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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_PF_INET@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	movq	_SOCK_STREAM@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	xorl	%edx, %edx
	callq	_socket
	movl	%eax, %r14d
	cmpl	$-1, %eax
	jne	LBB0_2
## %bb.1:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str(%rip), %rsi
	movl	$-1, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_2:
	leaq	-80(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$32, %esi
	callq	_bzero
	movl	$32, -80(%rbp)
	movq	_AF_INET@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -56(%rbp)
	movq	_INADDR_LOOPBACK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_htonl
	movq	%rax, -64(%rbp)
	movq	$0, -72(%rbp)
	movl	%r14d, %edi
	movq	%rbx, %rsi
	movl	$32, %edx
	callq	_bind
	testq	%rax, %rax
	jns	LBB0_4
## %bb.3:
	movq	-64(%rbp), %rdi
	callq	_inet_ntoa
	movl	%eax, %ebx
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str.1(%rip), %rsi
	movl	$-1, %edi
	movl	%ebx, %edx
	xorl	%ecx, %ecx
	movl	%eax, %r8d
	xorl	%eax, %eax
	callq	_errx
LBB0_4:
	movl	$32, -48(%rbp)
	leaq	-80(%rbp), %rsi
	leaq	-48(%rbp), %rdx
	movl	%r14d, %edi
	callq	_getsockname
	testq	%rax, %rax
	jns	LBB0_6
## %bb.5:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str.2(%rip), %rsi
	movl	$-1, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_6:
	movq	-72(%rbp), %r13
	movl	%r14d, %edi
	movl	$-1, %esi
	callq	_listen
	testq	%rax, %rax
	jns	LBB0_8
## %bb.7:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str.3(%rip), %rsi
	movl	$-1, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_8:
	movl	(%r15), %edi
	movl	(%r12), %esi
	xorl	%edx, %edx
	callq	_socket
	movl	%eax, %ebx
	cmpl	$-1, %eax
	jne	LBB0_10
## %bb.9:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str.4(%rip), %rsi
	movl	$-1, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_10:
	movq	_O_NONBLOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	movq	_F_SETFL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-44(%rbp), %rdx
	movl	%ebx, %edi
	callq	_fcntl
	testq	%rax, %rax
	jns	LBB0_12
## %bb.11:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str.4(%rip), %rsi
	movl	$-1, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_12:
	leaq	-80(%rbp), %r15
	movq	%r15, %rdi
	movl	$32, %esi
	callq	_bzero
	movl	$32, -80(%rbp)
	movq	_AF_INET@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -56(%rbp)
	movq	_INADDR_LOOPBACK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_htonl
	movq	%rax, -64(%rbp)
	movq	%r13, -72(%rbp)
	movl	%ebx, %edi
	movq	%r15, %rsi
	movl	$32, %edx
	callq	_connect
	testq	%rax, %rax
	jns	LBB0_14
## %bb.13:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str.5(%rip), %rsi
	movl	$-1, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_14:
	movl	%ebx, %edi
	callq	_close
	movl	%r14d, %edi
	callq	_close
	xorl	%eax, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PF_INET,4,2                    ## @PF_INET
	.comm	_SOCK_STREAM,4,2                ## @SOCK_STREAM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"socket(PF_INET, SOCK_STREAM, 0) for listen socket: %s"

	.comm	_errno,4,2                      ## @errno
	.comm	_AF_INET,8,3                    ## @AF_INET
	.comm	_INADDR_LOOPBACK,4,2            ## @INADDR_LOOPBACK
L_.str.1:                               ## @.str.1
	.asciz	"bind(%s, %d) for listen socket: %s"

L_.str.2:                               ## @.str.2
	.asciz	"getsockname() for listen socket: %s"

L_.str.3:                               ## @.str.3
	.asciz	"listen() for listen socket: %s"

L_.str.4:                               ## @.str.4
	.asciz	"socket(PF_INET, SOCK_STREAM, 0) for connect socket: %s"

	.comm	_O_NONBLOCK,4,2                 ## @O_NONBLOCK
	.comm	_F_SETFL,4,2                    ## @F_SETFL
L_.str.5:                               ## @.str.5
	.asciz	"connect() for connect socket: %s"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_main                           ; -- Begin function main
	.p2align	2
_main:                                  ; @main
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	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
Lloh0:
	adrp	x23, _PF_INET@GOTPAGE
Lloh1:
	ldr	x23, [x23, _PF_INET@GOTPAGEOFF]
	ldr	w0, [x23]
Lloh2:
	adrp	x24, _SOCK_STREAM@GOTPAGE
Lloh3:
	ldr	x24, [x24, _SOCK_STREAM@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	w2, #0
	bl	_socket
	mov	x19, x0
	cmn	w0, #1
	b.ne	LBB0_2
; %bb.1:
Lloh4:
	adrp	x8, _errno@GOTPAGE
Lloh5:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh6:
	ldr	w0, [x8]
	bl	_strerror
	mov	x2, x0
Lloh7:
	adrp	x1, l_.str@PAGE
Lloh8:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #-1
	bl	_errx
LBB0_2:
	mov	w25, #32
	add	x0, sp, #32
	mov	w1, #32
	bl	_bzero
Lloh9:
	adrp	x21, _AF_INET@GOTPAGE
Lloh10:
	ldr	x21, [x21, _AF_INET@GOTPAGEOFF]
	str	w25, [sp, #32]
	ldr	x8, [x21]
	str	x8, [sp, #56]
Lloh11:
	adrp	x22, _INADDR_LOOPBACK@GOTPAGE
Lloh12:
	ldr	x22, [x22, _INADDR_LOOPBACK@GOTPAGEOFF]
	ldr	w0, [x22]
	bl	_htonl
	stp	xzr, x0, [sp, #40]
	add	x1, sp, #32
	mov	x0, x19
	mov	w2, #32
	bl	_bind
	tbz	x0, #63, LBB0_4
; %bb.3:
	ldr	x0, [sp, #48]
	bl	_inet_ntoa
	mov	x20, x0
Lloh13:
	adrp	x8, _errno@GOTPAGE
Lloh14:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh15:
	ldr	w0, [x8]
	bl	_strerror
                                        ; kill: def $w0 killed $w0 def $x0
	stp	xzr, x0, [sp]
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w0, #-1
	mov	x2, x20
	bl	_errx
LBB0_4:
	str	w25, [sp, #28]
	add	x1, sp, #32
	add	x2, sp, #28
	mov	x0, x19
	bl	_getsockname
	tbz	x0, #63, LBB0_6
; %bb.5:
Lloh18:
	adrp	x8, _errno@GOTPAGE
Lloh19:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	bl	_strerror
	mov	x2, x0
Lloh21:
	adrp	x1, l_.str.2@PAGE
Lloh22:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #-1
	bl	_errx
LBB0_6:
	ldr	x25, [sp, #40]
	mov	x0, x19
	mov	w1, #-1
	bl	_listen
	tbz	x0, #63, LBB0_8
; %bb.7:
Lloh23:
	adrp	x8, _errno@GOTPAGE
Lloh24:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
	bl	_strerror
	mov	x2, x0
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	w0, #-1
	bl	_errx
LBB0_8:
	ldr	w0, [x23]
	ldr	w1, [x24]
	mov	w2, #0
	bl	_socket
	mov	x20, x0
	cmn	w0, #1
	b.ne	LBB0_10
; %bb.9:
Lloh28:
	adrp	x8, _errno@GOTPAGE
Lloh29:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh30:
	ldr	w0, [x8]
	bl	_strerror
	mov	x2, x0
Lloh31:
	adrp	x1, l_.str.4@PAGE
Lloh32:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	w0, #-1
	bl	_errx
LBB0_10:
Lloh33:
	adrp	x8, _O_NONBLOCK@GOTPAGE
Lloh34:
	ldr	x8, [x8, _O_NONBLOCK@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	str	w8, [sp, #24]
Lloh36:
	adrp	x8, _F_SETFL@GOTPAGE
Lloh37:
	ldr	x8, [x8, _F_SETFL@GOTPAGEOFF]
Lloh38:
	ldr	w1, [x8]
	add	x2, sp, #24
	mov	x0, x20
	bl	_fcntl
	tbz	x0, #63, LBB0_12
; %bb.11:
Lloh39:
	adrp	x8, _errno@GOTPAGE
Lloh40:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh41:
	ldr	w0, [x8]
	bl	_strerror
	mov	x2, x0
Lloh42:
	adrp	x1, l_.str.4@PAGE
Lloh43:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	w0, #-1
	bl	_errx
LBB0_12:
	mov	w23, #32
	add	x0, sp, #32
	mov	w1, #32
	bl	_bzero
	str	w23, [sp, #32]
	ldr	x8, [x21]
	str	x8, [sp, #56]
	ldr	w0, [x22]
	bl	_htonl
	stp	x25, x0, [sp, #40]
	add	x1, sp, #32
	mov	x0, x20
	mov	w2, #32
	bl	_connect
	tbz	x0, #63, LBB0_14
; %bb.13:
Lloh44:
	adrp	x8, _errno@GOTPAGE
Lloh45:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh46:
	ldr	w0, [x8]
	bl	_strerror
	mov	x2, x0
Lloh47:
	adrp	x1, l_.str.5@PAGE
Lloh48:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	w0, #-1
	bl	_errx
LBB0_14:
	mov	x0, x20
	bl	_close
	mov	x0, x19
	bl	_close
	mov	w0, #0
	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
	add	sp, sp, #144
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.cfi_endproc
                                        ; -- End function
	.comm	_PF_INET,4,2                    ; @PF_INET
	.comm	_SOCK_STREAM,4,2                ; @SOCK_STREAM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"socket(PF_INET, SOCK_STREAM, 0) for listen socket: %s"

	.comm	_errno,4,2                      ; @errno
	.comm	_AF_INET,8,3                    ; @AF_INET
	.comm	_INADDR_LOOPBACK,4,2            ; @INADDR_LOOPBACK
l_.str.1:                               ; @.str.1
	.asciz	"bind(%s, %d) for listen socket: %s"

l_.str.2:                               ; @.str.2
	.asciz	"getsockname() for listen socket: %s"

l_.str.3:                               ; @.str.3
	.asciz	"listen() for listen socket: %s"

l_.str.4:                               ; @.str.4
	.asciz	"socket(PF_INET, SOCK_STREAM, 0) for connect socket: %s"

	.comm	_O_NONBLOCK,4,2                 ; @O_NONBLOCK
	.comm	_F_SETFL,4,2                    ; @F_SETFL
l_.str.5:                               ; @.str.5
	.asciz	"connect() for connect socket: %s"

.subsections_via_symbols
