	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_create_udp_sock                ## -- Begin function create_udp_sock
	.p2align	4, 0x90
_create_udp_sock:                       ## @create_udp_sock
	.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	%r9, %r14
	movl	%ecx, %r15d
	movq	%rdx, %r12
	movq	16(%rbp), %r13
	xorl	%edx, %edx
	callq	_socket
	cmpl	$-1, %eax
	je	LBB0_1
## %bb.5:
	movl	%eax, %ebx
	movl	%eax, %edi
	movq	%r12, %rsi
	movl	%r15d, %edx
	callq	_bind
	testq	%rax, %rax
	je	LBB0_6
LBB0_7:
	movl	$0, (%r13)
	movl	$0, (%r14)
	movl	%ebx, %edi
	callq	_close
	jmp	LBB0_8
LBB0_1:
	movl	$0, (%r14)
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movq	_EAFNOSUPPORT@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdi
	je	LBB0_3
## %bb.2:
	movq	_EPROTONOSUPPORT@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdi
	je	LBB0_3
## %bb.4:
	callq	_strerror
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_log_err
	movl	$0, (%r13)
	jmp	LBB0_8
LBB0_6:
	movl	%ebx, %edi
	callq	_fd_set_nonblock
	testl	%eax, %eax
	jne	LBB0_9
	jmp	LBB0_7
LBB0_3:
	movl	$1, (%r13)
LBB0_8:
	movl	$-1, %ebx
LBB0_9:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_errno,8,3                      ## @errno
	.comm	_EAFNOSUPPORT,8,3               ## @EAFNOSUPPORT
	.comm	_EPROTONOSUPPORT,8,3            ## @EPROTONOSUPPORT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"can't create socket: %s"

	.comm	_AF_INET6,4,2                   ## @AF_INET6
	.comm	_AF_INET,4,2                    ## @AF_INET
	.comm	_EACCES,8,3                     ## @EACCES
	.comm	_EADDRINUSE,8,3                 ## @EADDRINUSE
	.comm	_EADDRNOTAVAIL,8,3              ## @EADDRNOTAVAIL
	.comm	_EINVAL,8,3                     ## @EINVAL
	.comm	_ENOPROTOOPT,8,3                ## @ENOPROTOOPT
	.comm	_ENOSYS,8,3                     ## @ENOSYS
	.comm	_EPERM,8,3                      ## @EPERM
	.comm	_IPPROTO_IP,4,2                 ## @IPPROTO_IP
	.comm	_IPPROTO_IPV6,4,2               ## @IPPROTO_IPV6
	.comm	_IPV6_BINDANY,4,2               ## @IPV6_BINDANY
	.comm	_IPV6_MIN_MTU,4,2               ## @IPV6_MIN_MTU
	.comm	_IPV6_MTU,4,2                   ## @IPV6_MTU
	.comm	_IPV6_USE_MIN_MTU,4,2           ## @IPV6_USE_MIN_MTU
	.comm	_IPV6_V6ONLY,4,2                ## @IPV6_V6ONLY
	.comm	_IP_BINDANY,4,2                 ## @IP_BINDANY
	.comm	_IP_DONTFRAG,4,2                ## @IP_DONTFRAG
	.comm	_IP_FREEBIND,4,2                ## @IP_FREEBIND
	.comm	_IP_MTU_DISCOVER,4,2            ## @IP_MTU_DISCOVER
	.comm	_IP_PMTUDISC_DONT,4,2           ## @IP_PMTUDISC_DONT
	.comm	_IP_PMTUDISC_OMIT,4,2           ## @IP_PMTUDISC_OMIT
	.comm	_IP_TRANSPARENT,4,2             ## @IP_TRANSPARENT
	.comm	_SOL_SOCKET,4,2                 ## @SOL_SOCKET
	.comm	_SO_BINDANY,4,2                 ## @SO_BINDANY
	.comm	_SO_RCVBUF,4,2                  ## @SO_RCVBUF
	.comm	_SO_RCVBUFFORCE,4,2             ## @SO_RCVBUFFORCE
	.comm	_SO_REUSEADDR,4,2               ## @SO_REUSEADDR
	.comm	_SO_REUSEPORT,4,2               ## @SO_REUSEPORT
	.comm	_SO_REUSEPORT_LB,4,2            ## @SO_REUSEPORT_LB
	.comm	_SO_SNDBUF,4,2                  ## @SO_SNDBUF
	.comm	_SO_SNDBUFFORCE,4,2             ## @SO_SNDBUFFORCE
	.comm	_WSAEACCES,8,3                  ## @WSAEACCES
	.comm	_WSAEADDRINUSE,8,3              ## @WSAEADDRINUSE
	.comm	_WSAEADDRNOTAVAIL,8,3           ## @WSAEADDRNOTAVAIL
	.comm	_WSAEAFNOSUPPORT,8,3            ## @WSAEAFNOSUPPORT
	.comm	_WSAEPROTONOSUPPORT,8,3         ## @WSAEPROTONOSUPPORT
	.comm	_verbosity,4,2                  ## @verbosity
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_create_udp_sock                ; -- Begin function create_udp_sock
	.p2align	2
_create_udp_sock:                       ; @create_udp_sock
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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, x6
	mov	x21, x5
	mov	x22, x3
	mov	x23, x2
	mov	w2, #0
	bl	_socket
	cmn	w0, #1
	b.eq	LBB0_3
; %bb.1:
	mov	x20, x0
	mov	x1, x23
	mov	x2, x22
	bl	_bind
	cbz	x0, LBB0_5
LBB0_2:
	str	wzr, [x19]
	str	wzr, [x21]
	mov	x0, x20
	bl	_close
	b	LBB0_7
LBB0_3:
	str	wzr, [x21]
Lloh0:
	adrp	x8, _errno@GOTPAGE
Lloh1:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh2:
	ldr	x0, [x8]
Lloh3:
	adrp	x8, _EAFNOSUPPORT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EAFNOSUPPORT@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
Lloh6:
	adrp	x9, _EPROTONOSUPPORT@GOTPAGE
Lloh7:
	ldr	x9, [x9, _EPROTONOSUPPORT@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x0, x8
	ccmp	x0, x9, #4, ne
	b.ne	LBB0_6
; %bb.4:
	mov	w8, #1
	str	w8, [x19]
	b	LBB0_7
LBB0_5:
	mov	x0, x20
	bl	_fd_set_nonblock
	cbnz	w0, LBB0_8
	b	LBB0_2
LBB0_6:
	bl	_strerror
	mov	x1, x0
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	bl	_log_err
	str	wzr, [x19]
LBB0_7:
	mov	w20, #-1
LBB0_8:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_errno,8,3                      ; @errno
	.comm	_EAFNOSUPPORT,8,3               ; @EAFNOSUPPORT
	.comm	_EPROTONOSUPPORT,8,3            ; @EPROTONOSUPPORT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"can't create socket: %s"

	.comm	_AF_INET6,4,2                   ; @AF_INET6
	.comm	_AF_INET,4,2                    ; @AF_INET
	.comm	_EACCES,8,3                     ; @EACCES
	.comm	_EADDRINUSE,8,3                 ; @EADDRINUSE
	.comm	_EADDRNOTAVAIL,8,3              ; @EADDRNOTAVAIL
	.comm	_EINVAL,8,3                     ; @EINVAL
	.comm	_ENOPROTOOPT,8,3                ; @ENOPROTOOPT
	.comm	_ENOSYS,8,3                     ; @ENOSYS
	.comm	_EPERM,8,3                      ; @EPERM
	.comm	_IPPROTO_IP,4,2                 ; @IPPROTO_IP
	.comm	_IPPROTO_IPV6,4,2               ; @IPPROTO_IPV6
	.comm	_IPV6_BINDANY,4,2               ; @IPV6_BINDANY
	.comm	_IPV6_MIN_MTU,4,2               ; @IPV6_MIN_MTU
	.comm	_IPV6_MTU,4,2                   ; @IPV6_MTU
	.comm	_IPV6_USE_MIN_MTU,4,2           ; @IPV6_USE_MIN_MTU
	.comm	_IPV6_V6ONLY,4,2                ; @IPV6_V6ONLY
	.comm	_IP_BINDANY,4,2                 ; @IP_BINDANY
	.comm	_IP_DONTFRAG,4,2                ; @IP_DONTFRAG
	.comm	_IP_FREEBIND,4,2                ; @IP_FREEBIND
	.comm	_IP_MTU_DISCOVER,4,2            ; @IP_MTU_DISCOVER
	.comm	_IP_PMTUDISC_DONT,4,2           ; @IP_PMTUDISC_DONT
	.comm	_IP_PMTUDISC_OMIT,4,2           ; @IP_PMTUDISC_OMIT
	.comm	_IP_TRANSPARENT,4,2             ; @IP_TRANSPARENT
	.comm	_SOL_SOCKET,4,2                 ; @SOL_SOCKET
	.comm	_SO_BINDANY,4,2                 ; @SO_BINDANY
	.comm	_SO_RCVBUF,4,2                  ; @SO_RCVBUF
	.comm	_SO_RCVBUFFORCE,4,2             ; @SO_RCVBUFFORCE
	.comm	_SO_REUSEADDR,4,2               ; @SO_REUSEADDR
	.comm	_SO_REUSEPORT,4,2               ; @SO_REUSEPORT
	.comm	_SO_REUSEPORT_LB,4,2            ; @SO_REUSEPORT_LB
	.comm	_SO_SNDBUF,4,2                  ; @SO_SNDBUF
	.comm	_SO_SNDBUFFORCE,4,2             ; @SO_SNDBUFFORCE
	.comm	_WSAEACCES,8,3                  ; @WSAEACCES
	.comm	_WSAEADDRINUSE,8,3              ; @WSAEADDRINUSE
	.comm	_WSAEADDRNOTAVAIL,8,3           ; @WSAEADDRNOTAVAIL
	.comm	_WSAEAFNOSUPPORT,8,3            ; @WSAEAFNOSUPPORT
	.comm	_WSAEPROTONOSUPPORT,8,3         ; @WSAEPROTONOSUPPORT
	.comm	_verbosity,4,2                  ; @verbosity
.subsections_via_symbols
