	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function virtual_submit_request
_virtual_submit_request:                ## @virtual_submit_request
	.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, %r14
	movl	12(%rdi), %edi
	callq	_to_virtual_engine
	movq	%rax, %r13
	movl	20(%rax), %esi
	movl	4(%r14), %ecx
	movl	8(%r14), %edx
	leaq	L_.str(%rip), %rdi
	callq	_GEM_TRACE
	leaq	_virtual_submit_request(%rip), %rax
	xorl	%edi, %edi
	cmpq	%rax, (%r13)
	setne	%dil
	callq	_GEM_BUG_ON
	leaq	8(%r13), %r15
	movq	%r15, %rdi
	callq	_spin_lock_irqsave
	movq	24(%r13), %rbx
	testq	%rbx, %rbx
	je	LBB0_2
## %bb.1:
	movq	%rbx, %rdi
	callq	_i915_request_completed
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_GEM_BUG_ON
	movq	%rbx, %rdi
	callq	___i915_request_submit
	movq	%rbx, %rdi
	callq	_i915_request_put
LBB0_2:
	movq	%r14, %rdi
	callq	_i915_request_completed
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	callq	___i915_request_submit
	movq	_INT_MIN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%r13)
	movq	$0, 24(%r13)
	jmp	LBB0_5
LBB0_4:
	movq	%r14, %rdi
	callq	_rq_prio
	movq	%r13, %r12
	addq	$12, %r12
	movl	%eax, 16(%r13)
	movq	%r14, %rdi
	callq	_i915_request_get
	movq	%rax, 24(%r13)
	movq	%r13, %rdi
	callq	_virtual_queue
	movl	%eax, %edi
	callq	_list_empty
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_GEM_BUG_ON
	movq	%r13, %rdi
	callq	_virtual_queue
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_list_move_tail
	movq	%r12, %rdi
	callq	_tasklet_schedule
LBB0_5:
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irqrestore         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: rq=%llx:%lld\n"

	.comm	_INT_MIN,4,2                    ## @INT_MIN
	.no_dead_strip	_virtual_submit_request
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function virtual_submit_request
_virtual_submit_request:                ; @virtual_submit_request
	.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	w0, [x0, #12]
	bl	_to_virtual_engine
	mov	x20, x0
	ldr	w1, [x0, #20]
	ldp	w3, w2, [x19, #4]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_GEM_TRACE
	ldr	x8, [x20]
Lloh2:
	adrp	x9, _virtual_submit_request@PAGE
Lloh3:
	add	x9, x9, _virtual_submit_request@PAGEOFF
	cmp	x8, x9
	cset	w0, ne
	bl	_GEM_BUG_ON
	add	x21, x20, #8
	mov	x0, x21
	bl	_spin_lock_irqsave
	ldr	x22, [x20, #24]
	cbz	x22, LBB0_2
; %bb.1:
	mov	x0, x22
	bl	_i915_request_completed
	cmp	x0, #0
	cset	w0, eq
	bl	_GEM_BUG_ON
	mov	x0, x22
	bl	___i915_request_submit
	mov	x0, x22
	bl	_i915_request_put
LBB0_2:
	mov	x0, x19
	bl	_i915_request_completed
	cbz	x0, LBB0_4
; %bb.3:
	mov	x0, x19
	bl	___i915_request_submit
Lloh4:
	adrp	x8, _INT_MIN@GOTPAGE
Lloh5:
	ldr	x8, [x8, _INT_MIN@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	str	w8, [x20, #16]
	str	xzr, [x20, #24]
	b	LBB0_5
LBB0_4:
	mov	x0, x19
	bl	_rq_prio
	add	x22, x20, #12
	str	w0, [x20, #16]
	mov	x0, x19
	bl	_i915_request_get
	str	x0, [x20, #24]
	mov	x0, x20
	bl	_virtual_queue
	bl	_list_empty
	cmp	w0, #0
	cset	w0, eq
	bl	_GEM_BUG_ON
	mov	x0, x20
	bl	_virtual_queue
	mov	x1, x0
	mov	x0, x19
	bl	_list_move_tail
	mov	x0, x22
	bl	_tasklet_schedule
LBB0_5:
	mov	x0, x21
	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	_spin_unlock_irqrestore
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: rq=%llx:%lld\n"

	.comm	_INT_MIN,4,2                    ; @INT_MIN
	.no_dead_strip	_virtual_submit_request
.subsections_via_symbols
