	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pfkey_get_base_msg
_pfkey_get_base_msg:                    ## @pfkey_get_base_msg
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movslq	(%rdi), %rcx
	cmpq	$31, %rcx
	ja	LBB0_1
LBB0_9:
	movq	_EMSGSIZE@GOTPCREL(%rip), %rdx
	jmp	LBB0_10
LBB0_1:
	movq	8(%rdi), %rax
	movq	(%rax), %rdx
	movq	_PF_KEY_V2@GOTPCREL(%rip), %rdi
	cmpq	(%rdi), %rdx
	jne	LBB0_5
## %bb.2:
	cmpq	$0, 8(%rax)
	je	LBB0_3
LBB0_5:
	movq	_EINVAL@GOTPCREL(%rip), %rdx
LBB0_10:
	xorl	%eax, %eax
	xorl	%ecx, %ecx
	subl	(%rdx), %ecx
LBB0_11:
	movl	%ecx, (%rsi)
	popq	%rbp
	retq
LBB0_3:
	movq	16(%rax), %rdx
	movq	_SADB_RESERVED@GOTPCREL(%rip), %rdi
	cmpq	(%rdi), %rdx
	jle	LBB0_5
## %bb.4:
	movq	_SADB_MAX@GOTPCREL(%rip), %rdi
	cmpq	(%rdi), %rdx
	jg	LBB0_5
## %bb.6:
	movslq	24(%rax), %rdx
	cmpq	$8, %rdx
	jb	LBB0_9
## %bb.7:
	shrq	$2, %rcx
	cmpq	%rdx, %rcx
	jne	LBB0_9
## %bb.8:
	xorl	%ecx, %ecx
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_EMSGSIZE,4,2                   ## @EMSGSIZE
	.comm	_PF_KEY_V2,8,3                  ## @PF_KEY_V2
	.comm	_SADB_RESERVED,8,3              ## @SADB_RESERVED
	.comm	_SADB_MAX,8,3                   ## @SADB_MAX
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_pfkey_get_base_msg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pfkey_get_base_msg
_pfkey_get_base_msg:                    ; @pfkey_get_base_msg
	.cfi_startproc
; %bb.0:
	ldrsw	x8, [x0]
	cmp	w8, #31
	b.hi	LBB0_2
LBB0_1:
	mov	x0, #0
Lloh0:
	adrp	x8, _EMSGSIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EMSGSIZE@GOTPAGEOFF]
	b	LBB0_6
LBB0_2:
	ldr	x0, [x0, #8]
	ldr	x9, [x0]
Lloh2:
	adrp	x10, _PF_KEY_V2@GOTPAGE
Lloh3:
	ldr	x10, [x10, _PF_KEY_V2@GOTPAGEOFF]
Lloh4:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_5
; %bb.3:
	ldr	x9, [x0, #8]
	cbnz	x9, LBB0_5
; %bb.4:
	ldr	x9, [x0, #16]
Lloh5:
	adrp	x10, _SADB_RESERVED@GOTPAGE
Lloh6:
	ldr	x10, [x10, _SADB_RESERVED@GOTPAGEOFF]
Lloh7:
	ldr	x10, [x10]
Lloh8:
	adrp	x11, _SADB_MAX@GOTPAGE
Lloh9:
	ldr	x11, [x11, _SADB_MAX@GOTPAGEOFF]
Lloh10:
	ldr	x11, [x11]
	cmp	x9, x10
	ccmp	x9, x11, #0, gt
	b.le	LBB0_7
LBB0_5:
	mov	x0, #0
Lloh11:
	adrp	x8, _EINVAL@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_6:
	ldr	w8, [x8]
	neg	w8, w8
	str	w8, [x1]
	ret
LBB0_7:
	ldrsw	x9, [x0, #24]
	lsr	x8, x8, #2
	cmp	w9, #8
	ccmp	x8, x9, #0, hs
	b.ne	LBB0_1
; %bb.8:
	str	wzr, [x1]
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_EMSGSIZE,4,2                   ; @EMSGSIZE
	.comm	_PF_KEY_V2,8,3                  ; @PF_KEY_V2
	.comm	_SADB_RESERVED,8,3              ; @SADB_RESERVED
	.comm	_SADB_MAX,8,3                   ; @SADB_MAX
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_pfkey_get_base_msg
.subsections_via_symbols
