	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qxl_display_copy_rom_client_monitors_config
_qxl_display_copy_rom_client_monitors_config: ## @qxl_display_copy_rom_client_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
	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
	movq	_MONITORS_CONFIG_UNCHANGED@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	8(%rdi), %rsi
	movl	8(%rsi), %r15d
	addq	$8, %rsi
	xorl	%edi, %edi
	movl	$16, %edx
	callq	_crc32
	movq	8(%r14), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
## %bb.1:
	testl	%r15d, %r15d
	je	LBB0_5
## %bb.2:
	movq	_qxl_num_crtc@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	cmpl	%esi, %r15d
	jle	LBB0_6
## %bb.3:
	leaq	L_.str.1(%rip), %rdi
	movl	%r15d, %edx
	xorl	%eax, %eax
	callq	_DRM_DEBUG_KMS
	movq	%rbx, %rcx
	jmp	LBB0_7
LBB0_4:
	movq	_MONITORS_CONFIG_BAD_CRC@GOTPCREL(%rip), %rax
	jmp	LBB0_12
LBB0_5:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_DEBUG_KMS
	jmp	LBB0_13
LBB0_6:
	addq	$8, %rcx
LBB0_7:
	movl	(%rcx), %esi
	movq	(%r14), %rax
	testq	%rax, %rax
	je	LBB0_10
## %bb.8:
	cmpl	(%rax), %esi
	je	LBB0_10
## %bb.9:
	movq	_MONITORS_CONFIG_MODIFIED@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
LBB0_10:
	movq	%r14, %rdi
	callq	_qxl_alloc_client_monitors_config
	testq	%rax, %rax
	je	LBB0_14
## %bb.11:
	movq	_MONITORS_CONFIG_ERROR@GOTPCREL(%rip), %rax
LBB0_12:
	movl	(%rax), %r12d
LBB0_13:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	movl	(%rbx), %ecx
	movq	(%r14), %rax
	movl	%ecx, 4(%rax)
	cmpl	$0, (%rax)
	jle	LBB0_13
## %bb.15:
	movl	$48, %ebx
	movl	$24, %r13d
	movq	_MONITORS_CONFIG_MODIFIED@GOTPCREL(%rip), %r11
	xorl	%r15d, %r15d
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_17
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_17 Depth=1
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	movq	%r11, %r14
	callq	_DRM_DEBUG_KMS
	movq	%r14, %r11
	incq	%r15
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	(%r14), %rax
	movslq	(%rax), %rcx
	addq	$56, %rbx
	addq	$32, %r13
	cmpq	%rcx, %r15
	jge	LBB0_13
LBB0_17:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r14), %rcx
	movq	16(%rcx), %r9
	movq	8(%rax), %rax
	movq	-48(%rax,%rbx), %rcx
	movq	-24(%r9,%r13), %rdx
	cmpq	%rdx, %rcx
	je	LBB0_19
## %bb.18:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	%rdx, -48(%rax,%rbx)
	movl	(%r11), %r12d
	movq	%rdx, %rcx
LBB0_19:                                ##   in Loop: Header=BB0_17 Depth=1
	movq	-40(%rax,%rbx), %r8
	movq	-16(%r9,%r13), %r10
	cmpq	%r10, %r8
	je	LBB0_21
## %bb.20:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	%r10, -40(%rax,%rbx)
	movl	(%r11), %r12d
	movq	%r10, %r8
LBB0_21:                                ##   in Loop: Header=BB0_17 Depth=1
	movq	-32(%rax,%rbx), %rsi
	movq	-8(%r9,%r13), %rdi
	subq	%rdx, %rdi
	cmpq	%rdi, %rsi
	je	LBB0_23
## %bb.22:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	%rdi, -32(%rax,%rbx)
	movl	(%r11), %r12d
	movq	%rdi, %rsi
LBB0_23:                                ##   in Loop: Header=BB0_17 Depth=1
	movq	-24(%rax,%rbx), %rdx
	movq	(%r9,%r13), %rdi
	subq	%r10, %rdi
	cmpq	%rdi, %rdx
	je	LBB0_25
## %bb.24:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	%rdi, -24(%rax,%rbx)
	movl	(%r11), %r12d
	movq	%rdi, %rdx
LBB0_25:                                ##   in Loop: Header=BB0_17 Depth=1
	cmpq	$0, -16(%rax,%rbx)
	je	LBB0_27
## %bb.26:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	$0, -16(%rax,%rbx)
	movl	(%r11), %r12d
LBB0_27:                                ##   in Loop: Header=BB0_17 Depth=1
	movl	-8(%rax,%rbx), %edi
	cmpq	%rdi, %r15
	je	LBB0_29
## %bb.28:                              ##   in Loop: Header=BB0_17 Depth=1
	movl	%r15d, -8(%rax,%rbx)
	movl	(%r11), %r12d
LBB0_29:                                ##   in Loop: Header=BB0_17 Depth=1
	cmpq	$0, (%rax,%rbx)
	je	LBB0_16
## %bb.30:                              ##   in Loop: Header=BB0_17 Depth=1
	movq	$0, (%rax,%rbx)
	movl	(%r11), %r12d
	jmp	LBB0_16
	.cfi_endproc
                                        ## -- End function
	.comm	_MONITORS_CONFIG_UNCHANGED,4,2  ## @MONITORS_CONFIG_UNCHANGED
	.comm	_MONITORS_CONFIG_BAD_CRC,4,2    ## @MONITORS_CONFIG_BAD_CRC
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"no client monitors configured\n"

	.comm	_qxl_num_crtc,4,2               ## @qxl_num_crtc
L_.str.1:                               ## @.str.1
	.asciz	"client monitors list will be truncated: %d < %d\n"

	.comm	_MONITORS_CONFIG_MODIFIED,4,2   ## @MONITORS_CONFIG_MODIFIED
	.comm	_MONITORS_CONFIG_ERROR,4,2      ## @MONITORS_CONFIG_ERROR
L_.str.2:                               ## @.str.2
	.asciz	"read %dx%d+%d+%d\n"

	.no_dead_strip	_qxl_display_copy_rom_client_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_display_copy_rom_client_monitors_config
_qxl_display_copy_rom_client_monitors_config: ; @qxl_display_copy_rom_client_monitors_config
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x0
Lloh0:
	adrp	x8, _MONITORS_CONFIG_UNCHANGED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MONITORS_CONFIG_UNCHANGED@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x8]
	ldr	x1, [x0, #8]
	ldr	w22, [x1, #8]!
	mov	w0, #0
	mov	w2, #16
	bl	_crc32
	ldr	x8, [x19, #8]
	ldr	x9, [x8]
	cmp	x0, x9
	b.ne	LBB0_4
; %bb.1:
	cbz	w22, LBB0_5
; %bb.2:
Lloh3:
	adrp	x21, _qxl_num_crtc@GOTPAGE
Lloh4:
	ldr	x21, [x21, _qxl_num_crtc@GOTPAGEOFF]
	ldr	w9, [x21]
	cmp	w22, w9
	b.le	LBB0_6
; %bb.3:
	stp	x9, x22, [sp]
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_DEBUG_KMS
Lloh7:
	adrp	x8, _qxl_num_crtc@GOTPAGE
Lloh8:
	ldr	x8, [x8, _qxl_num_crtc@GOTPAGEOFF]
	b	LBB0_7
LBB0_4:
Lloh9:
	adrp	x8, _MONITORS_CONFIG_BAD_CRC@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MONITORS_CONFIG_BAD_CRC@GOTPAGEOFF]
	b	LBB0_11
LBB0_5:
Lloh11:
	adrp	x0, l_.str@PAGE
Lloh12:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG_KMS
	b	LBB0_12
LBB0_6:
	add	x8, x8, #8
LBB0_7:
	ldr	w1, [x8]
	ldr	x8, [x19]
	cbz	x8, LBB0_9
; %bb.8:
	ldr	w8, [x8]
Lloh13:
	adrp	x9, _MONITORS_CONFIG_MODIFIED@GOTPAGE
Lloh14:
	ldr	x9, [x9, _MONITORS_CONFIG_MODIFIED@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	cmp	w1, w8
	csel	w20, w20, w9, eq
LBB0_9:
	mov	x0, x19
	bl	_qxl_alloc_client_monitors_config
	cbz	x0, LBB0_13
; %bb.10:
Lloh16:
	adrp	x8, _MONITORS_CONFIG_ERROR@GOTPAGE
Lloh17:
	ldr	x8, [x8, _MONITORS_CONFIG_ERROR@GOTPAGEOFF]
LBB0_11:
	ldr	w20, [x8]
LBB0_12:
	mov	x0, x20
	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
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_13:
	ldr	w9, [x21]
	ldr	x8, [x19]
	str	w9, [x8, #4]
	ldr	w9, [x8]
	cmp	w9, #1
	b.lt	LBB0_12
; %bb.14:
	mov	x22, #0
	mov	x23, #0
	mov	w24, #24
Lloh18:
	adrp	x25, _MONITORS_CONFIG_MODIFIED@GOTPAGE
Lloh19:
	ldr	x25, [x25, _MONITORS_CONFIG_MODIFIED@GOTPAGEOFF]
Lloh20:
	adrp	x21, l_.str.2@PAGE
Lloh21:
	add	x21, x21, l_.str.2@PAGEOFF
	b	LBB0_16
LBB0_15:                                ;   in Loop: Header=BB0_16 Depth=1
	stp	x8, x10, [sp, #16]
	stp	x11, x13, [sp]
	mov	x0, x21
	bl	_DRM_DEBUG_KMS
	add	x23, x23, #1
	ldr	x8, [x19]
	ldrsw	x9, [x8]
	add	x24, x24, #56
	add	x22, x22, #32
	cmp	x23, x9
	b.ge	LBB0_12
LBB0_16:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #8]
	ldr	x12, [x9, #16]
	ldr	x9, [x8, #8]
	add	x11, x9, x24
	ldur	x8, [x11, #-24]
	ldr	x13, [x12, x22]
	cmp	x8, x13
	b.eq	LBB0_18
; %bb.17:                               ;   in Loop: Header=BB0_16 Depth=1
	stur	x13, [x11, #-24]
	ldr	w20, [x25]
	mov	x8, x13
LBB0_18:                                ;   in Loop: Header=BB0_16 Depth=1
	ldur	x10, [x11, #-16]
	add	x15, x12, x22
	ldr	x14, [x15, #8]
	cmp	x10, x14
	b.eq	LBB0_20
; %bb.19:                               ;   in Loop: Header=BB0_16 Depth=1
	stur	x14, [x11, #-16]
	ldr	w20, [x25]
	mov	x10, x14
LBB0_20:                                ;   in Loop: Header=BB0_16 Depth=1
	add	x16, x9, x24
	ldur	x11, [x16, #-8]
	ldr	x15, [x15, #16]
	sub	x13, x15, x13
	cmp	x11, x13
	b.eq	LBB0_22
; %bb.21:                               ;   in Loop: Header=BB0_16 Depth=1
	stur	x13, [x16, #-8]
	ldr	w20, [x25]
	mov	x11, x13
LBB0_22:                                ;   in Loop: Header=BB0_16 Depth=1
	ldr	x13, [x9, x24]
	add	x12, x12, x22
	ldr	x12, [x12, #24]
	sub	x12, x12, x14
	cmp	x13, x12
	b.eq	LBB0_24
; %bb.23:                               ;   in Loop: Header=BB0_16 Depth=1
	str	x12, [x9, x24]
	ldr	w20, [x25]
	mov	x13, x12
LBB0_24:                                ;   in Loop: Header=BB0_16 Depth=1
	add	x12, x9, x24
	ldr	x14, [x12, #8]
	cbz	x14, LBB0_26
; %bb.25:                               ;   in Loop: Header=BB0_16 Depth=1
	str	xzr, [x12, #8]
	ldr	w20, [x25]
LBB0_26:                                ;   in Loop: Header=BB0_16 Depth=1
	ldr	w14, [x12, #16]
	cmp	x23, x14
	b.eq	LBB0_28
; %bb.27:                               ;   in Loop: Header=BB0_16 Depth=1
	str	w23, [x12, #16]
	ldr	w20, [x25]
LBB0_28:                                ;   in Loop: Header=BB0_16 Depth=1
	add	x9, x9, x24
	ldr	x12, [x9, #24]
	cbz	x12, LBB0_15
; %bb.29:                               ;   in Loop: Header=BB0_16 Depth=1
	str	xzr, [x9, #24]
	ldr	w20, [x25]
	b	LBB0_15
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_MONITORS_CONFIG_UNCHANGED,4,2  ; @MONITORS_CONFIG_UNCHANGED
	.comm	_MONITORS_CONFIG_BAD_CRC,4,2    ; @MONITORS_CONFIG_BAD_CRC
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"no client monitors configured\n"

	.comm	_qxl_num_crtc,4,2               ; @qxl_num_crtc
l_.str.1:                               ; @.str.1
	.asciz	"client monitors list will be truncated: %d < %d\n"

	.comm	_MONITORS_CONFIG_MODIFIED,4,2   ; @MONITORS_CONFIG_MODIFIED
	.comm	_MONITORS_CONFIG_ERROR,4,2      ; @MONITORS_CONFIG_ERROR
l_.str.2:                               ; @.str.2
	.asciz	"read %dx%d+%d+%d\n"

	.no_dead_strip	_qxl_display_copy_rom_client_monitors_config
.subsections_via_symbols
