	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bfa_msgq_cmdq_ci_update
_bfa_msgq_cmdq_ci_update:               ## @bfa_msgq_cmdq_ci_update
	.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
	movq	%rdi, %r12
	movl	(%rsi), %edi
	callq	_ntohs
	movq	%rax, 8(%r12)
	movq	%r12, %rdi
	callq	_list_empty
	testl	%eax, %eax
	jne	LBB0_7
## %bb.1:
	movq	%r12, %rdi
	callq	_bfa_q_first
	movq	%rax, %rbx
	movq	8(%rax), %rax
	movl	(%rax), %edi
	callq	_ntohs
	movq	%rax, %r14
	movq	%r12, %rdi
	callq	_BFA_MSGQ_FREE_CNT
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	cmpq	%rax, %r14
	jg	LBB0_7
## %bb.2:
	movq	%rax, %r15
	movq	_BFA_STATUS_OK@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_list_del
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	___cmd_copy
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_call_cmdq_ent_cbfn
	movq	%r12, %rdi
	callq	_list_empty
	testl	%eax, %eax
	jne	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%r12, %rdi
	callq	_bfa_q_first
	movq	%rax, %rbx
	movq	8(%rax), %rax
	movl	(%rax), %edi
	callq	_ntohs
	movq	%rax, %r13
	movq	%r12, %rdi
	callq	_BFA_MSGQ_FREE_CNT
	cmpq	%rax, %r13
	jle	LBB0_4
## %bb.6:
	cmpq	%r15, -48(%rbp)                 ## 8-byte Folded Reload
	jle	LBB0_5
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	_CMDQ_E_POST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_bfa_fsm_send_event             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_BFA_STATUS_OK,4,2              ## @BFA_STATUS_OK
	.comm	_CMDQ_E_POST,4,2                ## @CMDQ_E_POST
	.no_dead_strip	_bfa_msgq_cmdq_ci_update
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bfa_msgq_cmdq_ci_update
_bfa_msgq_cmdq_ci_update:               ; @bfa_msgq_cmdq_ci_update
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	ldr	w0, [x1]
	bl	_ntohs
	str	x0, [x19, #8]
	mov	x0, x19
	bl	_list_empty
	cbnz	w0, LBB0_6
; %bb.1:
	mov	x0, x19
	bl	_bfa_q_first
	mov	x22, x0
	ldr	x8, [x0, #8]
	ldr	w0, [x8]
	bl	_ntohs
	mov	x20, x0
	mov	x0, x19
	bl	_BFA_MSGQ_FREE_CNT
	cmp	x20, x0
	b.gt	LBB0_6
; %bb.2:
	mov	x21, x0
Lloh0:
	adrp	x24, _BFA_STATUS_OK@GOTPAGE
Lloh1:
	ldr	x24, [x24, _BFA_STATUS_OK@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	bl	_list_del
	mov	x0, x19
	mov	x1, x22
	bl	___cmd_copy
	ldr	w1, [x24]
	mov	x0, x22
	bl	_call_cmdq_ent_cbfn
	mov	x0, x19
	bl	_list_empty
	cbnz	w0, LBB0_7
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x19
	bl	_bfa_q_first
	mov	x22, x0
	ldr	x8, [x0, #8]
	ldr	w0, [x8]
	bl	_ntohs
	mov	x23, x0
	mov	x0, x19
	bl	_BFA_MSGQ_FREE_CNT
	cmp	x23, x0
	b.le	LBB0_3
; %bb.5:
	cmp	x20, x21
	b.le	LBB0_7
LBB0_6:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_7:
Lloh2:
	adrp	x8, _CMDQ_E_POST@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CMDQ_E_POST@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x19
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_bfa_fsm_send_event
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_BFA_STATUS_OK,4,2              ; @BFA_STATUS_OK
	.comm	_CMDQ_E_POST,4,2                ; @CMDQ_E_POST
	.no_dead_strip	_bfa_msgq_cmdq_ci_update
.subsections_via_symbols
