	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qxl_crtc_update_monitors_config
_qxl_crtc_update_monitors_config:       ## @qxl_crtc_update_monitors_config
	.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, %r14
	movq	%rdi, %r13
	movq	40(%rdi), %rax
	movq	(%rax), %r12
	callq	_to_qxl_crtc
	movq	(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.3:
	movq	16(%r12), %rbx
	testq	%rbx, %rbx
	je	LBB0_24
## %bb.4:
	movl	(%rax), %r15d
	movq	_qxl_num_crtc@GOTPCREL(%rip), %rax
	cmpl	%r15d, (%rax)
	jle	LBB0_24
## %bb.5:
	movslq	%r15d, %r9
	movl	(%rbx), %r11d
	movq	16(%r13), %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	je	LBB0_18
## %bb.6:
	movq	24(%r13), %rdx
	movq	32(%r13), %rcx
	movq	(%r13), %r8
	movq	8(%r13), %rsi
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movl	%r11d, %r10d
	cmpl	%r15d, %r11d
	jg	LBB0_8
## %bb.7:
	leal	1(%r15), %r10d
	movl	%r10d, (%rbx)
LBB0_8:
	cmpq	8(%r12), %rdi
	jne	LBB0_10
## %bb.9:
	movq	24(%r12), %rdi
	addq	(%rdi,%r9,8), %r8
	jmp	LBB0_10
LBB0_1:
	leaq	L_.str(%rip), %rdi
LBB0_2:
	movq	%r14, %rsi
	xorl	%eax, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DRM_DEBUG_KMS                  ## TAILCALL
LBB0_18:
	testl	%r15d, %r15d
	jle	LBB0_23
## %bb.19:
	leal	1(%r15), %esi
	cmpl	%esi, %r11d
	jne	LBB0_20
## %bb.22:
	movl	%r15d, (%rbx)
	xorl	%edx, %edx
	movl	%r15d, %r10d
	jmp	LBB0_21
LBB0_23:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_2
LBB0_20:
	xorl	%edx, %edx
	movl	%r11d, %r10d
LBB0_21:
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	xorl	%edi, %edi
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
LBB0_10:
	movq	8(%rbx), %rdi
	leaq	(%r9,%r9,2), %rbx
	shlq	$4, %rbx
	cmpq	8(%rdi,%rbx), %rdx
	jne	LBB0_15
## %bb.11:
	cmpq	16(%rdi,%rbx), %rcx
	jne	LBB0_15
## %bb.12:
	cmpq	24(%rdi,%rbx), %r8
	jne	LBB0_15
## %bb.13:
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	cmpq	32(%rdi,%rbx), %rsi
	jne	LBB0_15
## %bb.14:
	cmpl	%r10d, %r11d
	jne	LBB0_15
LBB0_24:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	testq	%rax, %rax
	leaq	L_.str.4(%rip), %rax
	leaq	L_.str.3(%rip), %r10
	cmoveq	%rax, %r10
	leaq	L_.str.2(%rip), %rdi
	movl	%r15d, %esi
	movq	%rdx, -72(%rbp)                 ## 8-byte Spill
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movl	%r11d, %r13d
	movq	%r8, -56(%rbp)                  ## 8-byte Spill
	movq	-48(%rbp), %r9                  ## 8-byte Reload
	xorl	%eax, %eax
	pushq	%r14
	pushq	%r10
	callq	_DRM_DEBUG_KMS
	addq	$16, %rsp
	movq	16(%r12), %rax
	movl	(%rax), %edx
	cmpl	%edx, %r13d
	movq	_qxl_num_crtc@GOTPCREL(%rip), %r14
	je	LBB0_17
## %bb.16:
	movl	%r13d, %esi
	movl	(%r14), %ecx
	leaq	L_.str.5(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_DEBUG_KMS
	movq	16(%r12), %rax
LBB0_17:
	movq	8(%rax), %rax
	movl	%r15d, (%rax,%rbx)
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, 8(%rax,%rbx)
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, 16(%rax,%rbx)
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, 24(%rax,%rbx)
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, 32(%rax,%rbx)
	movq	$0, 40(%rax,%rbx)
	movl	(%r14), %eax
	movq	16(%r12), %rcx
	movl	%eax, 4(%rcx)
	movq	%r12, %rdi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_qxl_send_monitors_config       ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"no primary surface, skip (%s)\n"

	.comm	_qxl_num_crtc,4,2               ## @qxl_num_crtc
L_.str.1:                               ## @.str.1
	.asciz	"inactive head 0, skip (%s)\n"

L_.str.2:                               ## @.str.2
	.asciz	"head %d, %dx%d, at +%d+%d, %s (%s)\n"

L_.str.3:                               ## @.str.3
	.asciz	"on"

L_.str.4:                               ## @.str.4
	.asciz	"off"

L_.str.5:                               ## @.str.5
	.asciz	"active heads %d -> %d (%d total)\n"

	.no_dead_strip	_qxl_crtc_update_monitors_config
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qxl_crtc_update_monitors_config
_qxl_crtc_update_monitors_config:       ; @qxl_crtc_update_monitors_config
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x28, x27, [sp, #64]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x1
	mov	x21, x0
	ldr	x8, [x0, #40]
	ldr	x19, [x8]
	bl	_to_qxl_crtc
	ldr	x11, [x19]
	cbz	x11, LBB0_7
; %bb.1:
	ldr	w23, [x0]
	ldr	x9, [x19, #16]
Lloh0:
	adrp	x22, _qxl_num_crtc@GOTPAGE
Lloh1:
	ldr	x22, [x22, _qxl_num_crtc@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	x9, #0
	ccmp	w8, w23, #4, ne
	b.le	LBB0_9
; %bb.2:
	mov	x8, x23
	sxtw	x24, w8
	ldr	w25, [x9]
	ldr	x8, [x21, #16]
	ldr	x8, [x8]
	cbz	x8, LBB0_10
; %bb.3:
	ldp	x26, x27, [x21, #24]
	mov	x10, x25
	ldp	x28, x21, [x21]
	cmp	w25, w23
	b.gt	LBB0_5
; %bb.4:
	add	w10, w23, #1
	str	w10, [x9]
LBB0_5:
	ldr	x12, [x19, #8]
	cmp	x11, x12
	b.ne	LBB0_15
; %bb.6:
	ldr	x11, [x19, #24]
	ldr	x11, [x11, x24, lsl #3]
	add	x28, x11, x28
	b	LBB0_15
LBB0_7:
	str	x20, [sp]
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
LBB0_8:
	bl	_DRM_DEBUG_KMS
LBB0_9:
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
LBB0_10:
	cmp	w23, #1
	b.lt	LBB0_13
; %bb.11:
	add	w10, w23, #1
	cmp	w25, w10
	b.ne	LBB0_14
; %bb.12:
	mov	x26, #0
	mov	x27, #0
	mov	x28, #0
	mov	x21, #0
	str	w23, [x9]
	mov	x10, x23
	b	LBB0_15
LBB0_13:
	str	x20, [sp]
Lloh4:
	adrp	x0, l_.str.1@PAGE
Lloh5:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_8
LBB0_14:
	mov	x26, #0
	mov	x27, #0
	mov	x28, #0
	mov	x21, #0
	mov	x10, x25
LBB0_15:
	ldr	x9, [x9, #8]
	mov	w11, #48
	madd	x11, x24, x11, x9
	ldr	x11, [x11, #8]
	cmp	x26, x11
	b.ne	LBB0_19
; %bb.16:
	mov	w11, #48
	madd	x11, x24, x11, x9
	ldr	x11, [x11, #16]
	cmp	x27, x11
	b.ne	LBB0_19
; %bb.17:
	mov	w11, #48
	madd	x11, x24, x11, x9
	ldr	x11, [x11, #24]
	cmp	x28, x11
	b.ne	LBB0_19
; %bb.18:
	mov	w11, #48
	madd	x9, x24, x11, x9
	ldr	x9, [x9, #32]
	cmp	x21, x9
	ccmp	w25, w10, #0, eq
	b.eq	LBB0_9
LBB0_19:
Lloh6:
	adrp	x9, l_.str.3@PAGE
Lloh7:
	add	x9, x9, l_.str.3@PAGEOFF
Lloh8:
	adrp	x10, l_.str.4@PAGE
Lloh9:
	add	x10, x10, l_.str.4@PAGEOFF
	cmp	x8, #0
	csel	x8, x10, x9, eq
	stp	x8, x20, [sp, #40]
	stp	x27, x28, [sp, #16]
	stp	x23, x26, [sp]
Lloh10:
	adrp	x0, l_.str.2@PAGE
Lloh11:
	add	x0, x0, l_.str.2@PAGEOFF
	str	x21, [sp, #32]
	bl	_DRM_DEBUG_KMS
	ldr	x9, [x19, #16]
	ldr	w8, [x9]
	cmp	w25, w8
	b.eq	LBB0_21
; %bb.20:
	ldr	w9, [x22]
	stp	x8, x9, [sp, #8]
	str	x25, [sp]
Lloh12:
	adrp	x0, l_.str.5@PAGE
Lloh13:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_DRM_DEBUG_KMS
	ldr	x9, [x19, #16]
LBB0_21:
	ldr	x8, [x9, #8]
	mov	w9, #48
	madd	x8, x24, x9, x8
	str	w23, [x8]
	stp	x26, x27, [x8, #8]
	stp	x28, x21, [x8, #24]
	str	xzr, [x8, #40]
	ldr	w8, [x22]
	ldr	x9, [x19, #16]
	str	w8, [x9, #4]
	mov	x0, x19
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	b	_qxl_send_monitors_config
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"no primary surface, skip (%s)\n"

	.comm	_qxl_num_crtc,4,2               ; @qxl_num_crtc
l_.str.1:                               ; @.str.1
	.asciz	"inactive head 0, skip (%s)\n"

l_.str.2:                               ; @.str.2
	.asciz	"head %d, %dx%d, at +%d+%d, %s (%s)\n"

l_.str.3:                               ; @.str.3
	.asciz	"on"

l_.str.4:                               ; @.str.4
	.asciz	"off"

l_.str.5:                               ; @.str.5
	.asciz	"active heads %d -> %d (%d total)\n"

	.no_dead_strip	_qxl_crtc_update_monitors_config
.subsections_via_symbols
