	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qxl_cursor_atomic_update
_qxl_cursor_atomic_update:              ## @qxl_cursor_atomic_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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r13
	movq	(%rdi), %rax
	movq	8(%rdi), %rcx
	movq	(%rcx), %r14
	movq	24(%rax), %r12
	movl	16(%rax), %edi
	callq	_to_qxl_crtc
	movq	%rax, %r15
	movq	$0, -48(%rbp)
	movq	$0, -64(%rbp)
	movq	_QXL_RELEASE_CURSOR_CMD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-56(%rbp), %rcx
	movq	%r14, %rdi
	movl	$40, %esi
	xorl	%r8d, %r8d
	callq	_qxl_alloc_release_reserved
	testl	%eax, %eax
	jne	LBB0_18
## %bb.1:
	cmpq	(%rbx), %r12
	je	LBB0_8
## %bb.2:
	movq	16(%r12), %rax
	movq	(%rax), %rdi
	callq	_gem_to_qxl_bo
	movq	%rax, %rbx
	leaq	-72(%rbp), %rsi
	movq	%rax, %rdi
	callq	_qxl_bo_kmap
	testl	%eax, %eax
	jne	LBB0_17
## %bb.3:
	movq	-56(%rbp), %rsi
	leaq	-48(%rbp), %rcx
	movq	%r14, %rdi
	movl	$16456, %edx                    ## imm = 0x4048
	callq	_qxl_alloc_bo_reserved
	testl	%eax, %eax
	jne	LBB0_16
## %bb.4:
	movq	-48(%rbp), %rdi
	callq	_qxl_bo_pin
	testl	%eax, %eax
	jne	LBB0_15
## %bb.5:
	movq	-56(%rbp), %rdi
	movl	$1, %esi
	callq	_qxl_release_reserve_list
	testl	%eax, %eax
	jne	LBB0_14
## %bb.6:
	movq	-48(%rbp), %rdi
	leaq	-80(%rbp), %rsi
	callq	_qxl_bo_kmap
	testl	%eax, %eax
	je	LBB0_7
## %bb.13:
	movq	-56(%rbp), %rdi
	callq	_qxl_release_backoff_reserve_list
LBB0_14:
	movq	-48(%rbp), %rdi
	callq	_qxl_bo_unpin
LBB0_15:
	leaq	-48(%rbp), %rdi
	callq	_qxl_bo_unref
LBB0_16:
	movq	%rbx, %rdi
	callq	_qxl_bo_kunmap
	jmp	LBB0_17
LBB0_8:
	movq	-56(%rbp), %rdi
	movl	$1, %esi
	callq	_qxl_release_reserve_list
	testl	%eax, %eax
	je	LBB0_9
LBB0_17:
	movq	-56(%rbp), %rsi
	movq	%r14, %rdi
	callq	_qxl_release_free
LBB0_18:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movq	-56(%rbp), %rsi
	movq	%r14, %rdi
	callq	_qxl_release_map
	movq	%rax, %rbx
	movq	_QXL_CURSOR_MOVE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%rbx)
	xorl	%r15d, %r15d
LBB0_10:
	movq	(%r13), %rax
	movdqu	(%rax), %xmm0
	movdqu	(%r12), %xmm1
	paddq	%xmm0, %xmm1
	movdqu	%xmm1, 8(%rbx)
	movq	-56(%rbp), %rsi
	movq	%r14, %rdi
	movq	%rbx, %rdx
	callq	_qxl_release_unmap
	movq	-56(%rbp), %rsi
	movq	_QXL_CMD_CURSOR@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	xorl	%ecx, %ecx
	callq	_qxl_push_cursor_ring_release
	movq	-56(%rbp), %rdi
	callq	_qxl_release_fence_buffer_objects
	testq	%r15, %r15
	je	LBB0_12
## %bb.11:
	movq	%r15, %rdi
	callq	_qxl_bo_unpin
LBB0_12:
	leaq	-64(%rbp), %rdi
	callq	_qxl_bo_unref
	leaq	-48(%rbp), %rdi
	callq	_qxl_bo_unref
	jmp	LBB0_18
LBB0_7:
	movq	-80(%rbp), %rax
	movq	$0, 64(%rax)
	movq	_SPICE_CURSOR_TYPE_ALPHA@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 56(%rax)
	movabsq	$274877907008, %rcx             ## imm = 0x4000000040
	movq	%rcx, 32(%rax)
	movups	(%r12), %xmm0
	movups	%xmm0, 40(%rax)
	movl	$16384, (%rax)                  ## imm = 0x4000
	xorps	%xmm0, %xmm0
	movups	%xmm0, 16(%rax)
	movl	$16384, 8(%rax)                 ## imm = 0x4000
	movl	12(%rax), %edi
	movq	-72(%rbp), %rsi
	movl	$16384, %edx                    ## imm = 0x4000
	callq	_memcpy
	movq	-48(%rbp), %rdi
	callq	_qxl_bo_kunmap
	movq	%rbx, %rdi
	callq	_qxl_bo_kunmap
	movq	-56(%rbp), %rsi
	movq	%r14, %rdi
	callq	_qxl_release_map
	movq	%rax, %rbx
	movl	$1, 24(%rax)
	movq	-48(%rbp), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_qxl_bo_physical_address
	movl	%eax, 28(%rbx)
	movq	_QXL_CURSOR_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%rbx)
	movq	(%r15), %rax
	movq	%rax, -64(%rbp)
	movq	-48(%rbp), %rax
	movq	%rax, (%r15)
	movq	$0, -48(%rbp)
	movq	-64(%rbp), %r15
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_QXL_RELEASE_CURSOR_CMD,4,2     ## @QXL_RELEASE_CURSOR_CMD
	.comm	_SPICE_CURSOR_TYPE_ALPHA,4,2    ## @SPICE_CURSOR_TYPE_ALPHA
	.comm	_QXL_CURSOR_SET,4,2             ## @QXL_CURSOR_SET
	.comm	_QXL_CURSOR_MOVE,4,2            ## @QXL_CURSOR_MOVE
	.comm	_QXL_CMD_CURSOR,4,2             ## @QXL_CMD_CURSOR
	.no_dead_strip	_qxl_cursor_atomic_update
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qxl_cursor_atomic_update
_qxl_cursor_atomic_update:              ; @qxl_cursor_atomic_update
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x22, x1
	mov	x20, x0
	ldp	x9, x8, [x0]
	ldr	x19, [x8]
	ldr	x23, [x9, #24]
	ldr	w0, [x9, #16]
	bl	_to_qxl_crtc
	mov	x21, x0
	stp	xzr, xzr, [sp, #16]
Lloh0:
	adrp	x8, _QXL_RELEASE_CURSOR_CMD@GOTPAGE
Lloh1:
	ldr	x8, [x8, _QXL_RELEASE_CURSOR_CMD@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	add	x3, sp, #40
	mov	x0, x19
	mov	w1, #40
	mov	x4, #0
	bl	_qxl_alloc_release_reserved
	cbnz	w0, LBB0_13
; %bb.1:
	ldr	x8, [x22]
	cmp	x23, x8
	b.eq	LBB0_11
; %bb.2:
	ldr	x8, [x23, #16]
	ldr	x0, [x8]
	bl	_gem_to_qxl_bo
	mov	x22, x0
	add	x1, sp, #8
	bl	_qxl_bo_kmap
	cbnz	w0, LBB0_12
; %bb.3:
	ldr	x1, [sp, #40]
	add	x3, sp, #24
	mov	x0, x19
	mov	w2, #16456
	bl	_qxl_alloc_bo_reserved
	cbnz	w0, LBB0_10
; %bb.4:
	ldr	x0, [sp, #24]
	bl	_qxl_bo_pin
	cbnz	w0, LBB0_9
; %bb.5:
	ldr	x0, [sp, #40]
	mov	w1, #1
	bl	_qxl_release_reserve_list
	cbnz	w0, LBB0_8
; %bb.6:
	ldr	x0, [sp, #24]
	add	x1, sp, #32
	bl	_qxl_bo_kmap
	cbz	w0, LBB0_18
; %bb.7:
	ldr	x0, [sp, #40]
	bl	_qxl_release_backoff_reserve_list
LBB0_8:
	ldr	x0, [sp, #24]
	bl	_qxl_bo_unpin
LBB0_9:
	add	x0, sp, #24
	bl	_qxl_bo_unref
LBB0_10:
	mov	x0, x22
	bl	_qxl_bo_kunmap
	b	LBB0_12
LBB0_11:
	ldr	x0, [sp, #40]
	mov	w1, #1
	bl	_qxl_release_reserve_list
	cbz	w0, LBB0_14
LBB0_12:
	ldr	x1, [sp, #40]
	mov	x0, x19
	bl	_qxl_release_free
LBB0_13:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_14:
	ldr	x1, [sp, #40]
	mov	x0, x19
	bl	_qxl_release_map
	mov	x22, x0
	mov	x21, #0
Lloh3:
	adrp	x8, _QXL_CURSOR_MOVE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _QXL_CURSOR_MOVE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	str	w8, [x0, #32]
LBB0_15:
	ldr	x8, [x20]
	ldr	q0, [x8]
	ldr	q1, [x23]
	add.2d	v0, v1, v0
	stur	q0, [x22, #8]
	ldr	x1, [sp, #40]
	mov	x0, x19
	mov	x2, x22
	bl	_qxl_release_unmap
	ldr	x1, [sp, #40]
Lloh6:
	adrp	x8, _QXL_CMD_CURSOR@GOTPAGE
Lloh7:
	ldr	x8, [x8, _QXL_CMD_CURSOR@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w3, #0
	bl	_qxl_push_cursor_ring_release
	ldr	x0, [sp, #40]
	bl	_qxl_release_fence_buffer_objects
	cbz	x21, LBB0_17
; %bb.16:
	mov	x0, x21
	bl	_qxl_bo_unpin
LBB0_17:
	add	x0, sp, #16
	bl	_qxl_bo_unref
	add	x0, sp, #24
	bl	_qxl_bo_unref
	b	LBB0_13
LBB0_18:
	ldr	x8, [sp, #32]
	str	xzr, [x8, #64]
Lloh9:
	adrp	x9, _SPICE_CURSOR_TYPE_ALPHA@GOTPAGE
Lloh10:
	ldr	x9, [x9, _SPICE_CURSOR_TYPE_ALPHA@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	str	w9, [x8, #56]
	movi.2s	v0, #64
	str	d0, [x8, #32]
	ldr	q0, [x23]
	stur	q0, [x8, #40]
	mov	w9, #16384
	str	w9, [x8]
	stp	xzr, xzr, [x8, #16]
	str	w9, [x8, #8]
	ldr	w0, [x8, #12]
	ldr	x1, [sp, #8]
	mov	w2, #16384
	bl	_memcpy
	ldr	x0, [sp, #24]
	bl	_qxl_bo_kunmap
	mov	x0, x22
	bl	_qxl_bo_kunmap
	ldr	x1, [sp, #40]
	mov	x0, x19
	bl	_qxl_release_map
	mov	x22, x0
	mov	w8, #1
	str	w8, [x0, #24]
	ldr	x1, [sp, #24]
	mov	x0, x19
	mov	w2, #0
	bl	_qxl_bo_physical_address
Lloh12:
	adrp	x8, _QXL_CURSOR_SET@GOTPAGE
Lloh13:
	ldr	x8, [x8, _QXL_CURSOR_SET@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	stp	w0, w8, [x22, #28]
	ldr	x8, [x21]
	str	x8, [sp, #16]
	ldr	x8, [sp, #24]
	str	x8, [x21]
	str	xzr, [sp, #24]
	ldr	x21, [sp, #16]
	b	LBB0_15
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_QXL_RELEASE_CURSOR_CMD,4,2     ; @QXL_RELEASE_CURSOR_CMD
	.comm	_SPICE_CURSOR_TYPE_ALPHA,4,2    ; @SPICE_CURSOR_TYPE_ALPHA
	.comm	_QXL_CURSOR_SET,4,2             ; @QXL_CURSOR_SET
	.comm	_QXL_CURSOR_MOVE,4,2            ; @QXL_CURSOR_MOVE
	.comm	_QXL_CMD_CURSOR,4,2             ; @QXL_CMD_CURSOR
	.no_dead_strip	_qxl_cursor_atomic_update
.subsections_via_symbols
