	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipsec_newpolicies
_ipsec_newpolicies:                     ## @ipsec_newpolicies
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, -44(%rbp)                 ## 4-byte Spill
	movq	%rcx, %rbx
	movq	%rdx, %r12
	movq	%rsi, %r15
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	_IPSEC_SPCOUNT@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	shll	$3, %edx
	xorl	%r14d, %r14d
	movq	%rsi, %rdi
	xorl	%esi, %esi
	callq	_memset
	cmpl	$0, (%r13)
	jle	LBB0_13
## %bb.1:
	xorl	%r13d, %r13d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_IPSEC_DIR_OUTBOUND@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 20(%rax)
	movq	%r14, %rdi
	addq	$4, %rdi
	movl	(%r12), %edx
	movq	%r12, %rsi
	callq	_memmove
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	(%rbx), %edx
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_memmove
	movq	_IPSEC_ULPROTO_ANY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	(%r15,%r13,8), %rcx
	movl	%eax, 16(%rcx)
	incq	%r13
	movq	_IPSEC_SPCOUNT@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	cmpq	%rax, %r13
	jge	LBB0_8
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%eax, %eax
	callq	_key_newsp
	movq	%rax, (%r15,%r13,8)
	testq	%rax, %rax
	je	LBB0_9
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%eax, %eax
	callq	_ipsec_newisr
	testq	%rax, %rax
	je	LBB0_9
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%rax, %r14
	movq	_IPSEC_POLICY_IPSEC@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	(%r15,%r13,8), %rcx
	movl	%eax, 52(%rcx)
	movq	_IPSEC_SPSTATE_DEAD@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 48(%rcx)
	movq	40(%rcx), %rax
	movslq	32(%rcx), %rdx
	leal	1(%rdx), %esi
	movl	%esi, 32(%rcx)
	movq	%r14, (%rax,%rdx,8)
	movq	_time_second@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	(%r15,%r13,8), %rax
	movl	%ecx, 28(%rax)
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	(%rcx), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 24(%rax)
	movq	_IPSEC_LEVEL_UNIQUE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 20(%r14)
	movq	_IPPROTO_ESP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 16(%r14)
	movq	_IPSEC_MODE_TUNNEL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 12(%r14)
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	movl	%ecx, 8(%r14)
	testb	$1, %r13b
	jne	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_IPSEC_DIR_INBOUND@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 20(%rax)
	movl	(%r12), %edx
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_memmove
	addq	$4, %r14
	jmp	LBB0_7
LBB0_9:
	movq	_IPSEC_SPCOUNT@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_12
## %bb.10:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdi
	callq	_key_freesp
	incq	%rbx
	movslq	(%r14), %rax
	addq	$8, %r15
	cmpq	%rax, %rbx
	jl	LBB0_11
LBB0_12:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	jmp	LBB0_13
LBB0_8:
	xorl	%r14d, %r14d
LBB0_13:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IPSEC_SPCOUNT,4,2              ## @IPSEC_SPCOUNT
	.comm	_IPSEC_POLICY_IPSEC,4,2         ## @IPSEC_POLICY_IPSEC
	.comm	_IPSEC_SPSTATE_DEAD,4,2         ## @IPSEC_SPSTATE_DEAD
	.comm	_time_second,4,2                ## @time_second
	.comm	_IPSEC_LEVEL_UNIQUE,4,2         ## @IPSEC_LEVEL_UNIQUE
	.comm	_IPPROTO_ESP,4,2                ## @IPPROTO_ESP
	.comm	_IPSEC_MODE_TUNNEL,4,2          ## @IPSEC_MODE_TUNNEL
	.comm	_IPSEC_DIR_INBOUND,4,2          ## @IPSEC_DIR_INBOUND
	.comm	_IPSEC_DIR_OUTBOUND,4,2         ## @IPSEC_DIR_OUTBOUND
	.comm	_IPSEC_ULPROTO_ANY,4,2          ## @IPSEC_ULPROTO_ANY
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_AF_INET,4,2                    ## @AF_INET
	.comm	_AF_INET6,4,2                   ## @AF_INET6
	.no_dead_strip	_ipsec_newpolicies
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipsec_newpolicies
_ipsec_newpolicies:                     ; @ipsec_newpolicies
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x4
	mov	x21, x3
	mov	x22, x2
	mov	x19, x1
	mov	x23, x0
Lloh0:
	adrp	x25, _IPSEC_SPCOUNT@GOTPAGE
Lloh1:
	ldr	x25, [x25, _IPSEC_SPCOUNT@GOTPAGEOFF]
	ldr	w8, [x25]
	lsl	w2, w8, #3
	mov	x0, x1
	mov	w1, #0
	bl	_memset
	ldr	w8, [x25]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.1:
	mov	x26, #0
Lloh2:
	adrp	x28, _IPSEC_MODE_TUNNEL@GOTPAGE
Lloh3:
	ldr	x28, [x28, _IPSEC_MODE_TUNNEL@GOTPAGEOFF]
Lloh4:
	adrp	x27, _IPSEC_ULPROTO_ANY@GOTPAGE
Lloh5:
	ldr	x27, [x27, _IPSEC_ULPROTO_ANY@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
Lloh6:
	adrp	x9, _IPSEC_DIR_OUTBOUND@GOTPAGE
Lloh7:
	ldr	x9, [x9, _IPSEC_DIR_OUTBOUND@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	str	w9, [x8, #20]
	add	x0, x24, #4
	ldr	w2, [x22]
	mov	x1, x22
	bl	_memmove
	ldr	w2, [x21]
	mov	x0, x24
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x1, x21
	bl	_memmove
	ldr	w8, [x27]
	ldr	x9, [x19, x26, lsl #3]
	str	w8, [x9, #16]
	add	x26, x26, #1
	ldrsw	x8, [x25]
	cmp	x26, x8
	b.ge	LBB0_8
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	bl	_key_newsp
	str	x0, [x19, x26, lsl #3]
	cbz	x0, LBB0_9
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	bl	_ipsec_newisr
	cbz	x0, LBB0_9
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	mov	x24, x0
	lsl	x8, x26, #3
	ldr	x9, [x19, x8]
Lloh9:
	adrp	x10, _IPSEC_POLICY_IPSEC@GOTPAGE
Lloh10:
	ldr	x10, [x10, _IPSEC_POLICY_IPSEC@GOTPAGEOFF]
Lloh11:
	ldr	w10, [x10]
Lloh12:
	adrp	x11, _IPSEC_SPSTATE_DEAD@GOTPAGE
Lloh13:
	ldr	x11, [x11, _IPSEC_SPSTATE_DEAD@GOTPAGEOFF]
Lloh14:
	ldr	w11, [x11]
	stp	w11, w10, [x9, #48]
	ldr	x10, [x9, #40]
	ldrsw	x11, [x9, #32]
	add	w12, w11, #1
	str	w12, [x9, #32]
	str	x0, [x10, x11, lsl #3]
	ldr	x8, [x19, x8]
Lloh15:
	adrp	x9, _time_second@GOTPAGE
Lloh16:
	ldr	x9, [x9, _time_second@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	ldr	x10, [x23]
	ldr	w10, [x10]
	stp	w10, w9, [x8, #24]
Lloh18:
	adrp	x9, _IPSEC_LEVEL_UNIQUE@GOTPAGE
Lloh19:
	ldr	x9, [x9, _IPSEC_LEVEL_UNIQUE@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x9]
Lloh21:
	adrp	x10, _IPPROTO_ESP@GOTPAGE
Lloh22:
	ldr	x10, [x10, _IPPROTO_ESP@GOTPAGEOFF]
Lloh23:
	ldr	w10, [x10]
	stp	w10, w9, [x0, #16]
	ldr	w9, [x28]
	stp	w20, w9, [x0, #8]
	tbnz	w26, #0, LBB0_2
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
Lloh24:
	adrp	x9, _IPSEC_DIR_INBOUND@GOTPAGE
Lloh25:
	ldr	x9, [x9, _IPSEC_DIR_INBOUND@GOTPAGEOFF]
Lloh26:
	ldr	w9, [x9]
	str	w9, [x8, #20]
	ldr	w2, [x22]
	mov	x0, x24
	mov	x1, x22
	bl	_memmove
	add	x0, x24, #4
	ldr	w2, [x21]
	b	LBB0_3
LBB0_8:
	mov	w0, #0
	b	LBB0_13
LBB0_9:
	ldr	w8, [x25]
	cmp	w8, #1
	b.lt	LBB0_12
; %bb.10:
	mov	x20, #0
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_key_freesp
	add	x20, x20, #1
	ldrsw	x8, [x25]
	add	x19, x19, #8
	cmp	x20, x8
	b.lt	LBB0_11
LBB0_12:
Lloh27:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh28:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh29:
	ldr	w0, [x8]
LBB0_13:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_IPSEC_SPCOUNT,4,2              ; @IPSEC_SPCOUNT
	.comm	_IPSEC_POLICY_IPSEC,4,2         ; @IPSEC_POLICY_IPSEC
	.comm	_IPSEC_SPSTATE_DEAD,4,2         ; @IPSEC_SPSTATE_DEAD
	.comm	_time_second,4,2                ; @time_second
	.comm	_IPSEC_LEVEL_UNIQUE,4,2         ; @IPSEC_LEVEL_UNIQUE
	.comm	_IPPROTO_ESP,4,2                ; @IPPROTO_ESP
	.comm	_IPSEC_MODE_TUNNEL,4,2          ; @IPSEC_MODE_TUNNEL
	.comm	_IPSEC_DIR_INBOUND,4,2          ; @IPSEC_DIR_INBOUND
	.comm	_IPSEC_DIR_OUTBOUND,4,2         ; @IPSEC_DIR_OUTBOUND
	.comm	_IPSEC_ULPROTO_ANY,4,2          ; @IPSEC_ULPROTO_ANY
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_AF_INET,4,2                    ; @AF_INET
	.comm	_AF_INET6,4,2                   ; @AF_INET6
	.no_dead_strip	_ipsec_newpolicies
.subsections_via_symbols
