	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function IpPort
_IpPort:                                ## @IpPort
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movl	%esi, %r15d
	movq	%rdi, %rbx
	leaq	L_.str(%rip), %rsi
	callq	_sscanf
	movl	%eax, %ecx
	xorl	%eax, %eax
	cmpl	$1, %ecx
	je	LBB0_8
## %bb.1:
	movq	_IPPROTO_TCP@GOTPCREL(%rip), %rax
	cmpl	%r15d, (%rax)
	jne	LBB0_3
## %bb.2:
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_5
LBB0_3:
	movq	_IPPROTO_UDP@GOTPCREL(%rip), %rcx
	movl	$-1, %eax
	cmpl	%r15d, (%rcx)
	jne	LBB0_8
## %bb.4:
	leaq	L_.str.2(%rip), %rsi
LBB0_5:
	movq	%rbx, %rdi
	callq	_getservbyname
	testq	%rax, %rax
	je	LBB0_6
## %bb.7:
	movl	(%rax), %edi
	callq	_ntohs
	movl	%eax, (%r14)
	xorl	%eax, %eax
	jmp	LBB0_8
LBB0_6:
	movl	$-1, %eax
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%d"

	.comm	_IPPROTO_TCP,4,2                ## @IPPROTO_TCP
L_.str.1:                               ## @.str.1
	.asciz	"tcp"

	.comm	_IPPROTO_UDP,4,2                ## @IPPROTO_UDP
L_.str.2:                               ## @.str.2
	.asciz	"udp"

	.no_dead_strip	_IpPort
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function IpPort
_IpPort:                                ; @IpPort
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x2
	mov	x21, x1
	mov	x20, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_sscanf
	cmp	w0, #1
	b.ne	LBB0_2
; %bb.1:
	mov	w0, #0
	b	LBB0_9
LBB0_2:
Lloh2:
	adrp	x8, _IPPROTO_TCP@GOTPAGE
Lloh3:
	ldr	x8, [x8, _IPPROTO_TCP@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	cmp	w8, w21
	b.ne	LBB0_4
; %bb.3:
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_6
LBB0_4:
Lloh7:
	adrp	x8, _IPPROTO_UDP@GOTPAGE
Lloh8:
	ldr	x8, [x8, _IPPROTO_UDP@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	cmp	w8, w21
	b.ne	LBB0_8
; %bb.5:
Lloh10:
	adrp	x1, l_.str.2@PAGE
Lloh11:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_6:
	mov	x0, x20
	bl	_getservbyname
	cbz	x0, LBB0_8
; %bb.7:
	ldr	w0, [x0]
	bl	_ntohs
	mov	x8, x0
	mov	w0, #0
	str	w8, [x19]
	b	LBB0_9
LBB0_8:
	mov	w0, #-1
LBB0_9:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%d"

	.comm	_IPPROTO_TCP,4,2                ; @IPPROTO_TCP
l_.str.1:                               ; @.str.1
	.asciz	"tcp"

	.comm	_IPPROTO_UDP,4,2                ; @IPPROTO_UDP
l_.str.2:                               ; @.str.2
	.asciz	"udp"

	.no_dead_strip	_IpPort
.subsections_via_symbols
