	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vmw_query_bo_switch_commit
_vmw_query_bo_switch_commit:            ## @vmw_query_bo_switch_commit
	.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	%rsi, %r15
	movq	%rdi, %r14
	cmpq	$0, 16(%rsi)
	je	LBB0_3
## %bb.1:
	movq	24(%r15), %r12
	movq	_vmw_res_context@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	shlq	$4, %rbx
	xorl	%edi, %edi
	cmpl	$0, 8(%r12,%rbx)
	sete	%dil
	callq	_BUG_ON
	movq	(%r12,%rbx), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_vmw_fifo_emit_dummy_query
	xorl	%edi, %edi
	testl	%eax, %eax
	setne	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rdi
	callq	_VMW_DEBUG_USER
LBB0_3:
	movq	(%r14), %rdi
	cmpq	(%r15), %rdi
	je	LBB0_10
## %bb.4:
	testq	%rdi, %rdi
	je	LBB0_6
## %bb.5:
	xorl	%esi, %esi
	callq	_vmw_bo_pin_reserved
	movq	%r14, %rdi
	callq	_vmw_bo_unreference
LBB0_6:
	cmpq	$0, 16(%r15)
	jne	LBB0_10
## %bb.7:
	movq	(%r15), %rdi
	movl	$1, %esi
	callq	_vmw_bo_pin_reserved
	cmpl	$0, 8(%r14)
	jne	LBB0_9
## %bb.8:
	movq	16(%r14), %rdi
	movl	$1, %esi
	callq	_vmw_bo_pin_reserved
	movl	$1, 8(%r14)
LBB0_9:
	xorl	%edi, %edi
	cmpq	$0, 8(%r15)
	sete	%dil
	callq	_BUG_ON
	movq	8(%r15), %rax
	movl	(%rax), %eax
	movl	%eax, 28(%r14)
	movl	$1, 24(%r14)
	movq	(%r15), %rdi
	callq	_vmw_bo_reference
	movq	%rax, (%r14)
LBB0_10:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_vmw_res_context,8,3            ## @vmw_res_context
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Out of fifo space for dummy query.\n"

	.no_dead_strip	_vmw_query_bo_switch_commit
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vmw_query_bo_switch_commit
_vmw_query_bo_switch_commit:            ; @vmw_query_bo_switch_commit
	.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	x20, x1
	mov	x19, x0
	ldr	x8, [x1, #16]
	cbz	x8, LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _vmw_res_context@GOTPAGE
Lloh1:
	ldr	x8, [x8, _vmw_res_context@GOTPAGEOFF]
	ldr	x9, [x20, #24]
Lloh2:
	ldr	x8, [x8]
	add	x21, x9, x8, lsl #4
	ldr	w8, [x21, #8]
	cmp	w8, #0
	cset	w0, eq
	bl	_BUG_ON
	ldr	x8, [x21]
	ldr	w1, [x8]
	mov	x0, x19
	bl	_vmw_fifo_emit_dummy_query
	cmp	w0, #0
	cset	w0, ne
	bl	_unlikely
	cbz	x0, LBB0_3
; %bb.2:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_VMW_DEBUG_USER
LBB0_3:
	ldr	x0, [x19]
	ldr	x8, [x20]
	cmp	x0, x8
	b.eq	LBB0_10
; %bb.4:
	cbz	x0, LBB0_6
; %bb.5:
	mov	w1, #0
	bl	_vmw_bo_pin_reserved
	mov	x0, x19
	bl	_vmw_bo_unreference
LBB0_6:
	ldr	x8, [x20, #16]
	cbnz	x8, LBB0_10
; %bb.7:
	ldr	x0, [x20]
	mov	w21, #1
	mov	w1, #1
	bl	_vmw_bo_pin_reserved
	ldr	w8, [x19, #8]
	cbnz	w8, LBB0_9
; %bb.8:
	ldr	x0, [x19, #16]
	mov	w1, #1
	bl	_vmw_bo_pin_reserved
	str	w21, [x19, #8]
LBB0_9:
	ldr	x8, [x20, #8]
	cmp	x8, #0
	cset	w0, eq
	bl	_BUG_ON
	ldp	x0, x8, [x20]
	ldr	w8, [x8]
	stp	w21, w8, [x19, #24]
	bl	_vmw_bo_reference
	str	x0, [x19]
LBB0_10:
	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
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_vmw_res_context,8,3            ; @vmw_res_context
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Out of fifo space for dummy query.\n"

	.no_dead_strip	_vmw_query_bo_switch_commit
.subsections_via_symbols
