	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_blk_cleanup_queue              ## -- Begin function blk_cleanup_queue
	.p2align	4, 0x90
_blk_cleanup_queue:                     ## @blk_cleanup_queue
	.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
	movq	%rdi, %rbx
	movq	16(%rdi), %r15
	leaq	8(%rdi), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	_QUEUE_FLAG_DEAD@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	movq	%rbx, %rsi
	callq	_queue_flag_set_unlocked
	movq	%r15, %rdi
	callq	_spin_lock_irq
	movq	_QUEUE_FLAG_NOMERGES@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_queue_flag_set
	movl	(%r12), %edi
	movq	%rbx, %rsi
	callq	_queue_flag_set
	leaq	12(%rbx), %rax
	cmpq	%rax, 16(%rbx)
	je	LBB0_2
## %bb.1:
	movq	%rax, 16(%rbx)
LBB0_2:
	movq	%r15, %rdi
	callq	_spin_unlock_irq
	movq	%r14, %rdi
	callq	_mutex_unlock
	cmpq	$0, (%rbx)
	je	LBB0_4
## %bb.3:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_blk_drain_queue
LBB0_4:
	movq	%rbx, %rdi
	callq	_blk_sync_queue
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_blk_put_queue                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_QUEUE_FLAG_DEAD,4,2            ## @QUEUE_FLAG_DEAD
	.comm	_QUEUE_FLAG_NOMERGES,4,2        ## @QUEUE_FLAG_NOMERGES
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_blk_cleanup_queue              ; -- Begin function blk_cleanup_queue
	.p2align	2
_blk_cleanup_queue:                     ; @blk_cleanup_queue
	.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
	mov	x19, x0
	ldr	x21, [x0, #16]
	add	x20, x0, #8
	mov	x0, x20
	bl	_mutex_lock
Lloh0:
	adrp	x22, _QUEUE_FLAG_DEAD@GOTPAGE
Lloh1:
	ldr	x22, [x22, _QUEUE_FLAG_DEAD@GOTPAGEOFF]
	ldr	w0, [x22]
	mov	x1, x19
	bl	_queue_flag_set_unlocked
	mov	x0, x21
	bl	_spin_lock_irq
Lloh2:
	adrp	x8, _QUEUE_FLAG_NOMERGES@GOTPAGE
Lloh3:
	ldr	x8, [x8, _QUEUE_FLAG_NOMERGES@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_queue_flag_set
	ldr	w0, [x22]
	mov	x1, x19
	bl	_queue_flag_set
	ldr	x9, [x19, #16]
	add	x8, x19, #12
	cmp	x9, x8
	b.eq	LBB0_2
; %bb.1:
	str	x8, [x19, #16]
LBB0_2:
	mov	x0, x21
	bl	_spin_unlock_irq
	mov	x0, x20
	bl	_mutex_unlock
	ldr	x8, [x19]
	cbz	x8, LBB0_4
; %bb.3:
	mov	x0, x19
	mov	w1, #1
	bl	_blk_drain_queue
LBB0_4:
	mov	x0, x19
	bl	_blk_sync_queue
	mov	x0, x19
	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
	b	_blk_put_queue
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_QUEUE_FLAG_DEAD,4,2            ; @QUEUE_FLAG_DEAD
	.comm	_QUEUE_FLAG_NOMERGES,4,2        ; @QUEUE_FLAG_NOMERGES
.subsections_via_symbols
