	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_IkeBuildSaPayload              ## -- Begin function IkeBuildSaPayload
	.p2align	4, 0x90
_IkeBuildSaPayload:                     ## @IkeBuildSaPayload
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.2:
	movq	%rdi, %r15
	leaq	-40(%rbp), %r14
	movq	%r14, %rdi
	movl	$16, %esi
	callq	_Zero
	movq	_IKE_SA_DOI_IPSEC@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_Endian32
	movq	%rax, -32(%rbp)
	movq	_IKE_SA_SITUATION_IDENTITY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_Endian32
	movq	%rax, -40(%rbp)
	xorl	%eax, %eax
	callq	_NewBuf
	movq	%rax, %rbx
	movq	%rax, %rdi
	movq	%r14, %rsi
	movl	$16, %edx
	callq	_WriteBuf
	movl	(%r15), %edi
	callq	_IkeBuildPayloadList
	movq	%rax, %r14
	movq	%rbx, %rdi
	movq	%rax, %rsi
	callq	_WriteBufBuf
	movq	%r14, %rdi
	callq	_FreeBuf
	jmp	LBB0_3
LBB0_1:
	xorl	%ebx, %ebx
LBB0_3:
	movq	%rbx, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IKE_SA_DOI_IPSEC,4,2           ## @IKE_SA_DOI_IPSEC
	.comm	_IKE_SA_SITUATION_IDENTITY,4,2  ## @IKE_SA_SITUATION_IDENTITY
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_IkeBuildSaPayload              ; -- Begin function IkeBuildSaPayload
	.p2align	2
_IkeBuildSaPayload:                     ; @IkeBuildSaPayload
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	cbz	x0, LBB0_2
; %bb.1:
	mov	x19, x0
	mov	x0, sp
	mov	w1, #16
	bl	_Zero
Lloh0:
	adrp	x8, _IKE_SA_DOI_IPSEC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IKE_SA_DOI_IPSEC@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_Endian32
	str	x0, [sp, #8]
Lloh3:
	adrp	x8, _IKE_SA_SITUATION_IDENTITY@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IKE_SA_SITUATION_IDENTITY@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_Endian32
	str	x0, [sp]
	bl	_NewBuf
	mov	x20, x0
	mov	x1, sp
	mov	w2, #16
	bl	_WriteBuf
	ldr	w0, [x19]
	bl	_IkeBuildPayloadList
	mov	x19, x0
	mov	x0, x20
	mov	x1, x19
	bl	_WriteBufBuf
	mov	x0, x19
	bl	_FreeBuf
	b	LBB0_3
LBB0_2:
	mov	x20, #0
LBB0_3:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_IKE_SA_DOI_IPSEC,4,2           ; @IKE_SA_DOI_IPSEC
	.comm	_IKE_SA_SITUATION_IDENTITY,4,2  ; @IKE_SA_SITUATION_IDENTITY
.subsections_via_symbols
