	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nfp_abm_offload_compile_red
_nfp_abm_offload_compile_red:           ## @nfp_abm_offload_compile_red
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movq	%rsi, %r15
	movq	%rdi, %r12
	movq	(%rsi), %rcx
	movq	_NFP_QDISC_RED@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jne	LBB0_5
## %bb.1:
	cmpq	$0, 32(%r15)
	je	LBB0_5
## %bb.2:
	cmpl	$1, 8(%r15)
	jne	LBB0_5
## %bb.3:
	cmpl	$0, 8(%r12)
	je	LBB0_8
LBB0_5:
	xorl	%eax, %eax
LBB0_9:
	movq	_NFP_QDISC_GRED@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_13
## %bb.10:
	cmpq	$0, 32(%r15)
	je	LBB0_13
## %bb.11:
	cmpl	$1, 8(%r15)
	sete	%cl
	jmp	LBB0_14
LBB0_13:
	xorl	%ecx, %ecx
LBB0_14:
	orb	%cl, %al
	movzbl	%al, %eax
	movl	%eax, 12(%r15)
	cmpb	$1, %al
	jne	LBB0_23
## %bb.15:
	cmpl	$0, 24(%r15)
	je	LBB0_21
LBB0_16:
	movq	(%r12), %rax
	cmpl	$0, (%rax)
	je	LBB0_23
## %bb.17:
	xorl	%r13d, %r13d
	xorl	%ebx, %ebx
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_19 Depth=1
	movl	(%rax), %ecx
	movq	%r12, %rdi
	movl	%ebx, %esi
	movl	%r14d, %edx
	callq	_nfp_abm_ctrl_set_q_act
	incq	%rbx
	movq	(%r12), %rax
	movl	(%rax), %eax
	addq	$16, %r13
	cmpq	%rax, %rbx
	jae	LBB0_23
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	16(%r15), %rax
	movl	8(%rax,%r13), %ecx
	movq	%r12, %rdi
	movl	%ebx, %esi
	movl	%r14d, %edx
	callq	_nfp_abm_ctrl_set_q_lvl
	movq	16(%r15), %rax
	cmpq	$0, (%rax,%r13)
	movq	_NFP_ABM_ACT_MARK_DROP@GOTPCREL(%rip), %rax
	jne	LBB0_18
## %bb.20:                              ##   in Loop: Header=BB0_19 Depth=1
	movq	_NFP_ABM_ACT_DROP@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_21:
	movq	%r12, %rdi
	movq	%r15, %rsi
	movl	%r14d, %edx
	callq	_nfp_abm_stats_init
	testq	%rax, %rax
	je	LBB0_24
## %bb.22:
	movl	$0, 12(%r15)
LBB0_23:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_24:
	cmpl	$0, 12(%r15)
	jne	LBB0_16
	jmp	LBB0_23
LBB0_8:
	movq	40(%r15), %rax
	cmpl	$0, (%rax)
	sete	%al
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_NFP_QDISC_RED,8,3              ## @NFP_QDISC_RED
	.comm	_NFP_QDISC_GRED,8,3             ## @NFP_QDISC_GRED
	.comm	_NFP_ABM_ACT_MARK_DROP,4,2      ## @NFP_ABM_ACT_MARK_DROP
	.comm	_NFP_ABM_ACT_DROP,4,2           ## @NFP_ABM_ACT_DROP
	.no_dead_strip	_nfp_abm_offload_compile_red
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nfp_abm_offload_compile_red
_nfp_abm_offload_compile_red:           ; @nfp_abm_offload_compile_red
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x20, x2
	mov	x19, x1
	mov	x21, x0
	ldr	x8, [x1]
Lloh0:
	adrp	x9, _NFP_QDISC_RED@GOTPAGE
Lloh1:
	ldr	x9, [x9, _NFP_QDISC_RED@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.1:
	ldr	x9, [x19, #32]
	cbz	x9, LBB0_5
; %bb.2:
	ldr	w9, [x19, #8]
	cmp	w9, #1
	b.ne	LBB0_4
; %bb.3:
	ldr	w9, [x21, #8]
	cbz	w9, LBB0_18
LBB0_4:
	mov	w9, #0
LBB0_5:
Lloh3:
	adrp	x10, _NFP_QDISC_GRED@GOTPAGE
Lloh4:
	ldr	x10, [x10, _NFP_QDISC_GRED@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x8, x10
	b.ne	LBB0_8
; %bb.6:
	ldr	x8, [x19, #32]
	cbz	x8, LBB0_9
; %bb.7:
	ldr	w8, [x19, #8]
	cmp	w8, #1
	cset	w8, eq
	b	LBB0_9
LBB0_8:
	mov	w8, #0
LBB0_9:
	orr	w8, w9, w8
	str	w8, [x19, #12]
	cmp	w8, #1
	b.ne	LBB0_16
; %bb.10:
	ldr	w8, [x19, #24]
	cbz	w8, LBB0_14
LBB0_11:
	ldr	x8, [x21]
	ldr	w8, [x8]
	cbz	w8, LBB0_16
; %bb.12:
	mov	x23, #0
	mov	x22, #0
Lloh6:
	adrp	x24, _NFP_ABM_ACT_MARK_DROP@GOTPAGE
Lloh7:
	ldr	x24, [x24, _NFP_ABM_ACT_MARK_DROP@GOTPAGEOFF]
Lloh8:
	adrp	x25, _NFP_ABM_ACT_DROP@GOTPAGE
Lloh9:
	ldr	x25, [x25, _NFP_ABM_ACT_DROP@GOTPAGEOFF]
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #16]
	add	x8, x8, x23
	ldr	w3, [x8, #8]
	mov	x0, x21
	mov	x1, x22
	mov	x2, x20
	bl	_nfp_abm_ctrl_set_q_lvl
	ldr	x8, [x19, #16]
	ldr	x8, [x8, x23]
	cmp	x8, #0
	csel	x8, x25, x24, eq
	ldr	w3, [x8]
	mov	x0, x21
	mov	x1, x22
	mov	x2, x20
	bl	_nfp_abm_ctrl_set_q_act
	add	x22, x22, #1
	ldr	x8, [x21]
	ldr	w8, [x8]
	add	x23, x23, #16
	cmp	x22, x8
	b.lo	LBB0_13
	b	LBB0_16
LBB0_14:
	mov	x0, x21
	mov	x1, x19
	mov	x2, x20
	bl	_nfp_abm_stats_init
	cbz	x0, LBB0_17
; %bb.15:
	str	wzr, [x19, #12]
LBB0_16:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_17:
	ldr	w8, [x19, #12]
	cbnz	w8, LBB0_11
	b	LBB0_16
LBB0_18:
	ldr	x9, [x19, #40]
	ldr	w9, [x9]
	cmp	w9, #0
	cset	w9, eq
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_NFP_QDISC_RED,8,3              ; @NFP_QDISC_RED
	.comm	_NFP_QDISC_GRED,8,3             ; @NFP_QDISC_GRED
	.comm	_NFP_ABM_ACT_MARK_DROP,4,2      ; @NFP_ABM_ACT_MARK_DROP
	.comm	_NFP_ABM_ACT_DROP,4,2           ; @NFP_ABM_ACT_DROP
	.no_dead_strip	_nfp_abm_offload_compile_red
.subsections_via_symbols
