	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function clear_rules
_clear_rules:                           ## @clear_rules
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpl	$8, (%rdx)
	jne	LBB0_1
## %bb.2:
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	%rdx, %rdi
	movl	$8, %esi
	callq	_ipfw_get_sopt_space
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_check_range_tlv
	testq	%rax, %rax
	je	LBB0_3
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_6:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	(%rbx), %r12
	movq	_IP_FW_XRESETLOG@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	xorl	%edx, %edx
	cmpq	%rbx, %r12
	sete	%dl
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_clear_range
	movl	%eax, %r14d
	movq	_V_fw_verbose@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_5
## %bb.4:
	movq	_IPFW_RCFLAG_ALL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%r15), %eax
	cmpq	%rbx, %r12
	leaq	L_.str.2(%rip), %rcx
	leaq	L_.str.3(%rip), %rsi
	cmoveq	%rcx, %rsi
	leaq	L_.str(%rip), %rcx
	leaq	L_.str.1(%rip), %rdx
	cmoveq	%rcx, %rdx
	testl	%eax, %eax
	cmoveq	%rsi, %rdx
	movq	_LOG_SECURITY@GOTPCREL(%rip), %rax
	movq	_LOG_NOTICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	orl	(%rax), %edi
	leaq	L_.str.4(%rip), %rsi
	callq	_log
LBB0_5:
	movl	%r14d, 4(%r15)
	xorl	%eax, %eax
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_IP_FW_XRESETLOG,8,3            ## @IP_FW_XRESETLOG
	.comm	_IPFW_RCFLAG_ALL,4,2            ## @IPFW_RCFLAG_ALL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"All logging counts reset"

L_.str.1:                               ## @.str.1
	.asciz	"Accounting cleared"

L_.str.2:                               ## @.str.2
	.asciz	"logging count reset"

L_.str.3:                               ## @.str.3
	.asciz	"cleared"

	.comm	_V_fw_verbose,8,3               ## @V_fw_verbose
	.comm	_LOG_SECURITY,4,2               ## @LOG_SECURITY
	.comm	_LOG_NOTICE,4,2                 ## @LOG_NOTICE
L_.str.4:                               ## @.str.4
	.asciz	"ipfw: %s.\n"

	.no_dead_strip	_clear_rules
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function clear_rules
_clear_rules:                           ; @clear_rules
	.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
	ldr	w8, [x2]
	cmp	w8, #8
	b.ne	LBB0_2
; %bb.1:
	mov	x21, x1
	mov	x20, x0
	mov	x0, x2
	mov	w1, #8
	bl	_ipfw_get_sopt_space
	mov	x19, x0
	bl	_check_range_tlv
	cbz	x0, LBB0_4
LBB0_2:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
LBB0_3:
	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
LBB0_4:
	ldr	x21, [x21]
Lloh3:
	adrp	x8, _IP_FW_XRESETLOG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IP_FW_XRESETLOG@GOTPAGEOFF]
Lloh5:
	ldr	x22, [x8]
	cmp	x21, x22
	cset	w2, eq
	mov	x0, x20
	mov	x1, x19
	bl	_clear_range
	mov	x20, x0
Lloh6:
	adrp	x8, _V_fw_verbose@GOTPAGE
Lloh7:
	ldr	x8, [x8, _V_fw_verbose@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	cbz	x8, LBB0_6
; %bb.5:
	ldr	w8, [x19]
Lloh9:
	adrp	x9, _IPFW_RCFLAG_ALL@GOTPAGE
Lloh10:
	ldr	x9, [x9, _IPFW_RCFLAG_ALL@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
Lloh12:
	adrp	x10, l_.str.3@PAGE
Lloh13:
	add	x10, x10, l_.str.3@PAGEOFF
Lloh14:
	adrp	x11, l_.str.2@PAGE
Lloh15:
	add	x11, x11, l_.str.2@PAGEOFF
	cmp	x21, x22
	csel	x10, x11, x10, eq
Lloh16:
	adrp	x11, l_.str.1@PAGE
Lloh17:
	add	x11, x11, l_.str.1@PAGEOFF
Lloh18:
	adrp	x12, l_.str@PAGE
Lloh19:
	add	x12, x12, l_.str@PAGEOFF
	csel	x11, x12, x11, eq
	tst	w9, w8
Lloh20:
	adrp	x8, _LOG_SECURITY@GOTPAGE
Lloh21:
	ldr	x8, [x8, _LOG_SECURITY@GOTPAGEOFF]
	csel	x2, x10, x11, eq
Lloh22:
	ldr	w8, [x8]
Lloh23:
	adrp	x9, _LOG_NOTICE@GOTPAGE
Lloh24:
	ldr	x9, [x9, _LOG_NOTICE@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	orr	w0, w9, w8
Lloh26:
	adrp	x1, l_.str.4@PAGE
Lloh27:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_log
LBB0_6:
	mov	w0, #0
	str	w20, [x19, #4]
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_IP_FW_XRESETLOG,8,3            ; @IP_FW_XRESETLOG
	.comm	_IPFW_RCFLAG_ALL,4,2            ; @IPFW_RCFLAG_ALL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"All logging counts reset"

l_.str.1:                               ; @.str.1
	.asciz	"Accounting cleared"

l_.str.2:                               ; @.str.2
	.asciz	"logging count reset"

l_.str.3:                               ; @.str.3
	.asciz	"cleared"

	.comm	_V_fw_verbose,8,3               ; @V_fw_verbose
	.comm	_LOG_SECURITY,4,2               ; @LOG_SECURITY
	.comm	_LOG_NOTICE,4,2                 ; @LOG_NOTICE
l_.str.4:                               ; @.str.4
	.asciz	"ipfw: %s.\n"

	.no_dead_strip	_clear_rules
.subsections_via_symbols
