	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function niu_set_hash_opts
_niu_set_hash_opts:                     ## @niu_set_hash_opts
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	$0, -48(%rbp)
	movl	4(%rsi), %edi
	leaq	-40(%rbp), %rsi
	callq	_niu_ethflow_to_class
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movq	-40(%rbp), %rcx
	movq	_CLASS_CODE_USER_PROG1@GOTPCREL(%rip), %r12
	movq	%rcx, %rax
	subq	(%r12), %rax
	jl	LBB0_1
## %bb.3:
	movq	_CLASS_CODE_SCTP_IPV6@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jg	LBB0_1
## %bb.4:
	movl	(%rbx), %edi
	movq	_RXH_DISCARD@GOTPCREL(%rip), %rcx
	testl	%edi, (%rcx)
	je	LBB0_6
## %bb.5:
	movq	%r14, %rdi
	callq	_niu_lock_parent
	movq	(%r14), %rax
	movq	(%rax), %rax
	movq	-40(%rbp), %rdi
	subq	(%r12), %rdi
	movq	_TCAM_KEY_DISC@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rbx
	orq	(%rax,%rdi,8), %rbx
	callq	_TCAM_KEY
	movl	%eax, %edi
	movq	%rbx, %rsi
	callq	_nw64
	movq	(%r14), %rax
	movq	(%rax), %rax
	movq	-40(%rbp), %rcx
	subq	(%r12), %rcx
	movq	%rbx, (%rax,%rcx,8)
	jmp	LBB0_10
LBB0_6:
	movq	(%r14), %rcx
	movq	(%rcx), %rcx
	movq	_TCAM_KEY_DISC@GOTPCREL(%rip), %r15
	movq	(%r15), %rdx
	testq	%rdx, (%rcx,%rax,8)
	je	LBB0_8
## %bb.7:
	movq	%r14, %rdi
	callq	_niu_lock_parent
	movq	(%r14), %rax
	movq	(%rax), %rax
	movq	-40(%rbp), %rdi
	subq	(%r12), %rdi
	movq	(%r15), %r15
	notq	%r15
	andq	(%rax,%rdi,8), %r15
	movq	%r15, -48(%rbp)
	callq	_TCAM_KEY
	movl	%eax, %edi
	movq	%r15, %rsi
	callq	_nw64
	movq	(%r14), %rax
	movq	(%rax), %rax
	movq	-40(%rbp), %rcx
	subq	(%r12), %rcx
	movq	%r15, (%rax,%rcx,8)
	movq	%r14, %rdi
	callq	_niu_unlock_parent
	movl	(%rbx), %edi
LBB0_8:
	leaq	-48(%rbp), %rsi
	callq	_niu_ethflow_to_flowkey
	testl	%eax, %eax
	je	LBB0_1
## %bb.9:
	movq	%r14, %rdi
	callq	_niu_lock_parent
	movq	-40(%rbp), %rdi
	subq	(%r12), %rdi
	callq	_FLOW_KEY
	movq	-48(%rbp), %rsi
	movl	%eax, %edi
	callq	_nw64
	movq	-48(%rbp), %rax
	movq	(%r14), %rcx
	movq	8(%rcx), %rcx
	movq	-40(%rbp), %rdx
	subq	(%r12), %rdx
	movq	%rax, (%rcx,%rdx,8)
LBB0_10:
	movq	%r14, %rdi
	callq	_niu_unlock_parent
	xorl	%eax, %eax
	jmp	LBB0_11
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_11:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_CLASS_CODE_USER_PROG1,8,3      ## @CLASS_CODE_USER_PROG1
	.comm	_CLASS_CODE_SCTP_IPV6,8,3       ## @CLASS_CODE_SCTP_IPV6
	.comm	_RXH_DISCARD,4,2                ## @RXH_DISCARD
	.comm	_TCAM_KEY_DISC,8,3              ## @TCAM_KEY_DISC
	.no_dead_strip	_niu_set_hash_opts
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function niu_set_hash_opts
_niu_set_hash_opts:                     ; @niu_set_hash_opts
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x20, x1
	mov	x19, x0
	str	xzr, [sp]
	ldr	w0, [x1, #4]
	add	x1, sp, #8
	bl	_niu_ethflow_to_class
	cbz	w0, LBB0_2
; %bb.1:
	ldr	x9, [sp, #8]
Lloh0:
	adrp	x22, _CLASS_CODE_USER_PROG1@GOTPAGE
Lloh1:
	ldr	x22, [x22, _CLASS_CODE_USER_PROG1@GOTPAGEOFF]
	ldr	x8, [x22]
Lloh2:
	adrp	x10, _CLASS_CODE_SCTP_IPV6@GOTPAGE
Lloh3:
	ldr	x10, [x10, _CLASS_CODE_SCTP_IPV6@GOTPAGEOFF]
Lloh4:
	ldr	x10, [x10]
	subs	x8, x9, x8
	ccmp	x9, x10, #0, ge
	b.le	LBB0_3
LBB0_2:
Lloh5:
	adrp	x8, _EINVAL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_10
LBB0_3:
	ldr	w0, [x20]
Lloh8:
	adrp	x9, _RXH_DISCARD@GOTPAGE
Lloh9:
	ldr	x9, [x9, _RXH_DISCARD@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	tst	w9, w0
	b.eq	LBB0_5
; %bb.4:
	mov	x0, x19
	bl	_niu_lock_parent
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldr	x9, [sp, #8]
	ldr	x10, [x22]
	sub	x0, x9, x10
	ldr	x8, [x8, x0, lsl #3]
Lloh11:
	adrp	x9, _TCAM_KEY_DISC@GOTPAGE
Lloh12:
	ldr	x9, [x9, _TCAM_KEY_DISC@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	orr	x20, x9, x8
	bl	_TCAM_KEY
	mov	x1, x20
	bl	_nw64
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldr	x9, [sp, #8]
	ldr	x10, [x22]
	sub	x9, x9, x10
	str	x20, [x8, x9, lsl #3]
	b	LBB0_9
LBB0_5:
	ldr	x9, [x19]
	ldr	x9, [x9]
	ldr	x8, [x9, x8, lsl #3]
Lloh14:
	adrp	x21, _TCAM_KEY_DISC@GOTPAGE
Lloh15:
	ldr	x21, [x21, _TCAM_KEY_DISC@GOTPAGEOFF]
	ldr	x9, [x21]
	tst	x9, x8
	b.eq	LBB0_7
; %bb.6:
	mov	x0, x19
	bl	_niu_lock_parent
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldr	x9, [sp, #8]
	ldr	x10, [x22]
	sub	x0, x9, x10
	ldr	x8, [x8, x0, lsl #3]
	ldr	x9, [x21]
	bic	x21, x8, x9
	str	x21, [sp]
	bl	_TCAM_KEY
	mov	x1, x21
	bl	_nw64
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldr	x9, [sp, #8]
	ldr	x10, [x22]
	sub	x9, x9, x10
	str	x21, [x8, x9, lsl #3]
	mov	x0, x19
	bl	_niu_unlock_parent
	ldr	w0, [x20]
LBB0_7:
	mov	x1, sp
	bl	_niu_ethflow_to_flowkey
	cbz	w0, LBB0_2
; %bb.8:
	mov	x0, x19
	bl	_niu_lock_parent
	ldr	x8, [sp, #8]
	ldr	x9, [x22]
	sub	x0, x8, x9
	bl	_FLOW_KEY
	ldr	x1, [sp]
	bl	_nw64
	ldp	x8, x10, [sp]
	ldr	x9, [x19]
	ldr	x9, [x9, #8]
	ldr	x11, [x22]
	sub	x10, x10, x11
	str	x8, [x9, x10, lsl #3]
LBB0_9:
	mov	x0, x19
	bl	_niu_unlock_parent
	mov	w0, #0
LBB0_10:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_CLASS_CODE_USER_PROG1,8,3      ; @CLASS_CODE_USER_PROG1
	.comm	_CLASS_CODE_SCTP_IPV6,8,3       ; @CLASS_CODE_SCTP_IPV6
	.comm	_RXH_DISCARD,4,2                ; @RXH_DISCARD
	.comm	_TCAM_KEY_DISC,8,3              ; @TCAM_KEY_DISC
	.no_dead_strip	_niu_set_hash_opts
.subsections_via_symbols
