	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mga_set_start_address
_mga_set_start_address:                 ## @mga_set_start_address
	.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
	movl	%esi, %r15d
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	$8154, %edi                     ## imm = 0x1FDA
	callq	_RREG8
	testb	$8, %al
	jne	LBB0_1
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	$8154, %edi                     ## imm = 0x1FDA
	callq	_RREG8
	testb	$8, %al
	je	LBB0_2
## %bb.3:
	movq	_MGAREG_VCOUNT@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	callq	_RREG8
	movl	%eax, %ebx
	addl	$2, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %edi
	callq	_RREG8
	cmpl	%ebx, %eax
	jl	LBB0_4
## %bb.5:
	movq	_MGAREG_CRTCEXT_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	callq	_WREG8
	movq	_MGAREG_CRTCEXT_DATA@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_RREG8
	movl	%eax, %r14d
	andl	$176, %r14d
	movl	%r15d, %r12d
	shrl	$3, %r12d
	xorl	%edi, %edi
	cmpl	$16777216, %r15d                ## imm = 0x1000000
	setae	%dil
	callq	_WARN_ON
	movl	%r15d, %ebx
	shrl	$17, %ebx
	andl	$64, %ebx
	movzbl	%r12b, %esi
	movl	$13, %edi
	callq	_WREG_CRT
	movl	%r15d, %eax
	shrl	$11, %eax
	movzbl	%al, %esi
	movl	$12, %edi
	callq	_WREG_CRT
	shrl	$19, %r15d
	andl	$15, %r15d
	orl	%ebx, %r15d
	orl	%r14d, %r15d
	xorl	%edi, %edi
	movl	%r15d, %esi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_WREG_ECRT                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MGAREG_VCOUNT,4,2              ## @MGAREG_VCOUNT
	.comm	_MGAREG_CRTCEXT_INDEX,4,2       ## @MGAREG_CRTCEXT_INDEX
	.comm	_MGAREG_CRTCEXT_DATA,4,2        ## @MGAREG_CRTCEXT_DATA
	.no_dead_strip	_mga_set_start_address
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mga_set_start_address
_mga_set_start_address:                 ; @mga_set_start_address
	.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	x19, x1
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	mov	w0, #8154
	bl	_RREG8
	tbnz	w0, #3, LBB0_1
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	w0, #8154
	bl	_RREG8
	tbz	w0, #3, LBB0_2
; %bb.3:
Lloh0:
	adrp	x20, _MGAREG_VCOUNT@GOTPAGE
Lloh1:
	ldr	x20, [x20, _MGAREG_VCOUNT@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	_RREG8
	add	w21, w0, #2
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x20]
	bl	_RREG8
	cmp	w0, w21
	b.lt	LBB0_4
; %bb.5:
Lloh2:
	adrp	x8, _MGAREG_CRTCEXT_INDEX@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MGAREG_CRTCEXT_INDEX@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	mov	w1, #0
	bl	_WREG8
Lloh5:
	adrp	x8, _MGAREG_CRTCEXT_DATA@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MGAREG_CRTCEXT_DATA@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	bl	_RREG8
	mov	w8, #176
	and	w20, w0, w8
	tst	w19, #0xff000000
	cset	w0, ne
	bl	_WARN_ON
	lsr	w8, w19, #17
	and	w21, w8, #0x40
	ubfx	w1, w19, #3, #8
	mov	w0, #13
	bl	_WREG_CRT
	ubfx	w1, w19, #11, #8
	mov	w0, #12
	bl	_WREG_CRT
	bfxil	w21, w19, #19, #4
	orr	w1, w21, w20
	mov	w0, #0
	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
	b	_WREG_ECRT
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_MGAREG_VCOUNT,4,2              ; @MGAREG_VCOUNT
	.comm	_MGAREG_CRTCEXT_INDEX,4,2       ; @MGAREG_CRTCEXT_INDEX
	.comm	_MGAREG_CRTCEXT_DATA,4,2        ; @MGAREG_CRTCEXT_DATA
	.no_dead_strip	_mga_set_start_address
.subsections_via_symbols
