	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rv770_program_display_gap
_rv770_program_display_gap:             ## @rv770_program_display_gap
	.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, %rbx
	movq	_CG_DISPLAY_GAP_CNTL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_RREG32
	movl	%eax, %r14d
	movq	_DISP1_GAP_MCHG_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_DISP2_GAP_MCHG_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	(%rbx), %r13d
	testb	$1, %r13b
	jne	LBB0_1
## %bb.2:
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movq	_R600_PM_DISPLAY_GAP_IGNORE@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	callq	_DISP1_GAP_MCHG
	movl	%eax, %ebx
	testb	$2, %r13b
	je	LBB0_4
## %bb.3:
	movq	_R600_PM_DISPLAY_GAP_VBLANK@GOTPCREL(%rip), %r15
LBB0_4:
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	jmp	LBB0_5
LBB0_1:
	movq	_R600_PM_DISPLAY_GAP_VBLANK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%ecx, %ebx
	callq	_DISP1_GAP_MCHG
	movl	%ebx, %ecx
	movl	%eax, %ebx
	movq	_R600_PM_DISPLAY_GAP_IGNORE@GOTPCREL(%rip), %r15
LBB0_5:
	orl	%ecx, %r12d
	notl	%r12d
	andl	%r12d, %r14d
	movl	(%r15), %edi
	callq	_DISP2_GAP_MCHG
	orl	%eax, %ebx
	orl	%r14d, %ebx
	movq	_CG_DISPLAY_GAP_CNTL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%ebx, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_WREG32                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_CG_DISPLAY_GAP_CNTL,4,2        ## @CG_DISPLAY_GAP_CNTL
	.comm	_DISP1_GAP_MCHG_MASK,4,2        ## @DISP1_GAP_MCHG_MASK
	.comm	_DISP2_GAP_MCHG_MASK,4,2        ## @DISP2_GAP_MCHG_MASK
	.comm	_R600_PM_DISPLAY_GAP_VBLANK,4,2 ## @R600_PM_DISPLAY_GAP_VBLANK
	.comm	_R600_PM_DISPLAY_GAP_IGNORE,4,2 ## @R600_PM_DISPLAY_GAP_IGNORE
	.no_dead_strip	_rv770_program_display_gap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rv770_program_display_gap
_rv770_program_display_gap:             ; @rv770_program_display_gap
	.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
Lloh0:
	adrp	x21, _CG_DISPLAY_GAP_CNTL@GOTPAGE
Lloh1:
	ldr	x21, [x21, _CG_DISPLAY_GAP_CNTL@GOTPAGEOFF]
	ldr	w0, [x21]
	bl	_RREG32
	mov	x19, x0
Lloh2:
	adrp	x8, _DISP1_GAP_MCHG_MASK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DISP1_GAP_MCHG_MASK@GOTPAGEOFF]
Lloh4:
	ldr	w22, [x8]
Lloh5:
	adrp	x8, _DISP2_GAP_MCHG_MASK@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DISP2_GAP_MCHG_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w23, [x8]
	ldr	w20, [x20]
	tbnz	w20, #0, LBB0_2
; %bb.1:
Lloh8:
	adrp	x24, _R600_PM_DISPLAY_GAP_IGNORE@GOTPAGE
Lloh9:
	ldr	x24, [x24, _R600_PM_DISPLAY_GAP_IGNORE@GOTPAGEOFF]
	ldr	w0, [x24]
	bl	_DISP1_GAP_MCHG
Lloh10:
	adrp	x8, _R600_PM_DISPLAY_GAP_VBLANK@GOTPAGE
Lloh11:
	ldr	x8, [x8, _R600_PM_DISPLAY_GAP_VBLANK@GOTPAGEOFF]
	tst	w20, #0x2
	csel	x8, x24, x8, eq
	b	LBB0_3
LBB0_2:
Lloh12:
	adrp	x8, _R600_PM_DISPLAY_GAP_VBLANK@GOTPAGE
Lloh13:
	ldr	x8, [x8, _R600_PM_DISPLAY_GAP_VBLANK@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	bl	_DISP1_GAP_MCHG
Lloh15:
	adrp	x8, _R600_PM_DISPLAY_GAP_IGNORE@GOTPAGE
Lloh16:
	ldr	x8, [x8, _R600_PM_DISPLAY_GAP_IGNORE@GOTPAGEOFF]
LBB0_3:
	orr	w9, w23, w22
	bic	w9, w19, w9
	orr	w19, w0, w9
	ldr	w0, [x8]
	bl	_DISP2_GAP_MCHG
	orr	w1, w19, w0
	ldr	w0, [x21]
	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
	b	_WREG32
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_CG_DISPLAY_GAP_CNTL,4,2        ; @CG_DISPLAY_GAP_CNTL
	.comm	_DISP1_GAP_MCHG_MASK,4,2        ; @DISP1_GAP_MCHG_MASK
	.comm	_DISP2_GAP_MCHG_MASK,4,2        ; @DISP2_GAP_MCHG_MASK
	.comm	_R600_PM_DISPLAY_GAP_VBLANK,4,2 ; @R600_PM_DISPLAY_GAP_VBLANK
	.comm	_R600_PM_DISPLAY_GAP_IGNORE,4,2 ; @R600_PM_DISPLAY_GAP_IGNORE
	.no_dead_strip	_rv770_program_display_gap
.subsections_via_symbols
