	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_octeon_flush_iq                ## -- Begin function octeon_flush_iq
	.p2align	4, 0x90
_octeon_flush_iq:                       ## @octeon_flush_iq
	.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
	movq	%rdx, %r15
	movq	%rsi, %rbx
	movq	%rdi, %r13
	leaq	16(%rsi), %r14
	movq	%r14, %rdi
	callq	_spin_trylock
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	leaq	20(%rbx), %r12
	movq	%r12, %rdi
	callq	_spin_lock_bh
	movq	%rbx, %rdi
	callq	*(%r13)
	movq	%rax, (%rbx)
	cmpq	%rax, 8(%rbx)
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	movq	%r12, -48(%rbp)                 ## 8-byte Spill
	jne	LBB0_4
## %bb.3:
	xorl	%r12d, %r12d
	jmp	LBB0_9
LBB0_1:
	movl	$1, %r15d
	jmp	LBB0_10
LBB0_4:
	leaq	32(%rbx), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r15, %rdx
	subq	%r12, %rdx
	testq	%r15, %r15
	cmoveq	%r15, %rdx
	movq	%r13, %rdi
	movq	%rbx, %rsi
	callq	_lio_process_iq_request_list
	movq	%rax, %r14
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	addl	%r14d, 36(%rbx)
	movq	%r14, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	callq	_atomic_sub
	addl	%r14d, 28(%rbx)
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	addq	%r14, %r12
	cmpq	%r15, %r12
	jge	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	8(%rbx), %rax
	cmpq	(%rbx), %rax
	jne	LBB0_5
LBB0_9:
	testq	%r15, %r15
	sete	%al
	cmpq	%r15, %r12
	setl	%cl
	orb	%al, %cl
	movzbl	%cl, %r15d
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_spin_unlock_bh
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_spin_unlock
LBB0_10:
	movl	%r15d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_jiffies,4,2                    ## @jiffies
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_octeon_flush_iq                ; -- Begin function octeon_flush_iq
	.p2align	2
_octeon_flush_iq:                       ; @octeon_flush_iq
	.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	x21, x2
	mov	x20, x1
	mov	x23, x0
	add	x19, x1, #16
	mov	x0, x19
	bl	_spin_trylock
	cbz	w0, LBB0_3
; %bb.1:
	add	x22, x20, #20
	mov	x0, x22
	bl	_spin_lock_bh
	ldr	x8, [x23]
	mov	x0, x20
	blr	x8
	str	x0, [x20]
	ldr	x8, [x20, #8]
	cmp	x8, x0
	b.ne	LBB0_4
; %bb.2:
	mov	x26, #0
	b	LBB0_9
LBB0_3:
	mov	w21, #1
	b	LBB0_10
LBB0_4:
	mov	x26, #0
	add	x24, x20, #32
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	sub	x8, x21, x26
	cmp	x21, #0
	csel	x2, xzr, x8, eq
	mov	x0, x23
	mov	x1, x20
	bl	_lio_process_iq_request_list
	mov	x25, x0
	cbz	x0, LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x20, #36]
	add	w8, w8, w25
	str	w8, [x20, #36]
	mov	x0, x25
	mov	x1, x24
	bl	_atomic_sub
	ldr	w8, [x20, #28]
	add	w8, w8, w25
	str	w8, [x20, #28]
LBB0_7:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	x26, x25, x26
	cmp	x26, x21
	b.ge	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	ldp	x8, x9, [x20]
	cmp	x9, x8
	b.ne	LBB0_5
LBB0_9:
	cmp	x21, #0
	ccmp	x26, x21, #8, ne
	cset	w21, lt
Lloh0:
	adrp	x8, _jiffies@GOTPAGE
Lloh1:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x20, #24]
	mov	x0, x22
	bl	_spin_unlock_bh
	mov	x0, x19
	bl	_spin_unlock
LBB0_10:
	mov	x0, x21
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_jiffies,4,2                    ; @jiffies
.subsections_via_symbols
