	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_xen_drm_front_kms_init         ## -- Begin function xen_drm_front_kms_init
	.p2align	4, 0x90
_xen_drm_front_kms_init:                ## @xen_drm_front_kms_init
	.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, %r15
	movq	16(%rdi), %r14
	movq	%r14, %rdi
	callq	_drm_mode_config_init
	xorps	%xmm0, %xmm0
	movups	%xmm0, 16(%r14)
	movabsq	$8791798059007, %rax            ## imm = 0x7FF00000FFF
	movq	%rax, (%r14)
	movq	_mode_config_funcs@GOTPCREL(%rip), %rax
	movq	%rax, 8(%r14)
	movq	8(%r15), %rax
	cmpl	$0, (%rax)
	jle	LBB0_5
## %bb.1:
	xorl	%r13d, %r13d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rax), %rdx
	addq	%r13, %rdx
	movq	(%r15), %rcx
	addq	%r13, %rcx
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_display_pipe_init
	testl	%eax, %eax
	jne	LBB0_4
## %bb.2:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%rbx
	movq	8(%r15), %rax
	movslq	(%rax), %rcx
	addq	$4, %r13
	cmpq	%rcx, %rbx
	jl	LBB0_3
LBB0_5:
	movq	%r14, %rdi
	callq	_drm_mode_config_reset
	movq	%r14, %rdi
	callq	_drm_kms_helper_poll_init
	xorl	%r12d, %r12d
	jmp	LBB0_6
LBB0_4:
	movl	%eax, %r12d
	movq	%r14, %rdi
	callq	_drm_mode_config_cleanup
LBB0_6:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mode_config_funcs,4,2          ## @mode_config_funcs
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function xen_drm_front_kms_init
lCPI0_0:
	.long	4095                            ; 0xfff
	.long	2047                            ; 0x7ff
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_xen_drm_front_kms_init
	.p2align	2
_xen_drm_front_kms_init:                ; @xen_drm_front_kms_init
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x20, x0
	ldr	x19, [x0, #16]
	mov	x0, x19
	bl	_drm_mode_config_init
	str	xzr, [x19, #24]
Lloh0:
	adrp	x8, lCPI0_0@PAGE
Lloh1:
	ldr	d0, [x8, lCPI0_0@PAGEOFF]
Lloh2:
	adrp	x8, _mode_config_funcs@GOTPAGE
Lloh3:
	ldr	x8, [x8, _mode_config_funcs@GOTPAGEOFF]
	str	d0, [x19]
	stp	x8, xzr, [x19, #8]
	ldr	x8, [x20, #8]
	ldr	w9, [x8]
	cmp	w9, #1
	b.lt	LBB0_4
; %bb.1:
	mov	x23, #0
	mov	x21, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x8, #8]
	add	x2, x8, x23
	ldr	x8, [x20]
	add	x3, x8, x23
	mov	x0, x20
	mov	x1, x21
	bl	_display_pipe_init
	cbnz	w0, LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	add	x21, x21, #1
	ldr	x8, [x20, #8]
	ldrsw	x9, [x8]
	add	x23, x23, #4
	cmp	x21, x9
	b.lt	LBB0_2
LBB0_4:
	mov	x0, x19
	bl	_drm_mode_config_reset
	mov	x0, x19
	bl	_drm_kms_helper_poll_init
	mov	w22, #0
	b	LBB0_6
LBB0_5:
	mov	x22, x0
	mov	x0, x19
	bl	_drm_mode_config_cleanup
LBB0_6:
	mov	x0, x22
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdrp	Lloh0, Lloh2
	.loh AdrpLdr	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_mode_config_funcs,4,2          ; @mode_config_funcs
.subsections_via_symbols
