	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_amdgpu_atombios_crtc_overscan_setup ## -- Begin function amdgpu_atombios_crtc_overscan_setup
	.p2align	4, 0x90
_amdgpu_atombios_crtc_overscan_setup:   ## @amdgpu_atombios_crtc_overscan_setup
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r12
	movq	%rsi, %r15
	movq	(%rdi), %rax
	movq	(%rax), %r14
	callq	_to_amdgpu_crtc
	movq	%rax, %rbx
	movq	_COMMAND@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SetCRTC_OverScan@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_GetIndexIntoMasterTable
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	leaq	-88(%rbp), %rdi
	xorl	%esi, %esi
	movl	$40, %edx
	callq	_memset
	movl	12(%rbx), %eax
	movl	%eax, -56(%rbp)
	movl	(%rbx), %eax
	cmpl	$130, %eax
	je	LBB0_3
## %bb.1:
	cmpl	$129, %eax
	jne	LBB0_8
## %bb.2:
	movl	(%r12), %eax
	subl	(%r15), %eax
	movl	%eax, %edi
	shrl	$31, %edi
	addl	%eax, %edi
	sarl	%edi
	callq	_cpu_to_le16
	movq	%rax, -88(%rbp)
	movl	(%r12), %eax
	subl	(%r15), %eax
	movl	%eax, %edi
	shrl	$31, %edi
	addl	%eax, %edi
	sarl	%edi
	callq	_cpu_to_le16
	movq	%rax, -80(%rbp)
	movl	4(%r12), %eax
	subl	4(%r15), %eax
	movl	%eax, %edi
	shrl	$31, %edi
	addl	%eax, %edi
	sarl	%edi
	callq	_cpu_to_le16
	movq	%rax, -72(%rbp)
	movl	4(%r12), %eax
	subl	4(%r15), %eax
	movl	%eax, %edi
	shrl	$31, %edi
	addl	%eax, %edi
	jmp	LBB0_5
LBB0_3:
	movl	(%r15), %edi
	movl	4(%r15), %r8d
	movl	(%r12), %ecx
	movl	4(%r12), %esi
	movl	%esi, %r13d
	imull	%edi, %r13d
	movl	%r8d, %ebx
	imull	%ecx, %ebx
	cmpl	%ebx, %r13d
	jle	LBB0_6
## %bb.4:
	movl	%ebx, %eax
	cltd
	idivl	%edi
	subl	%eax, %esi
	movl	%esi, %edi
	shrl	$31, %edi
	addl	%esi, %edi
	sarl	%edi
	callq	_cpu_to_le16
	movq	%rax, -72(%rbp)
	movl	4(%r12), %ecx
	movl	%ebx, %eax
	cltd
	idivl	(%r15)
	subl	%eax, %ecx
	movl	%ecx, %edi
	shrl	$31, %edi
	addl	%ecx, %edi
LBB0_5:
	sarl	%edi
	callq	_cpu_to_le16
	movq	%rax, -64(%rbp)
	jmp	LBB0_9
LBB0_8:
	movl	4(%rbx), %edi
	callq	_cpu_to_le16
	movq	%rax, -64(%rbp)
	movl	4(%rbx), %edi
	callq	_cpu_to_le16
	movq	%rax, -72(%rbp)
	movl	8(%rbx), %edi
	callq	_cpu_to_le16
	movq	%rax, -80(%rbp)
	movl	8(%rbx), %edi
	callq	_cpu_to_le16
	movq	%rax, -88(%rbp)
LBB0_9:
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
LBB0_10:
	movl	(%r14), %edi
	leaq	-88(%rbp), %rdx
	movl	%ebx, %esi
	callq	_amdgpu_atom_execute_table
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	jge	LBB0_10
## %bb.7:
	movl	%r13d, %eax
	cltd
	idivl	%r8d
	subl	%eax, %ecx
	movl	%ecx, %edi
	shrl	$31, %edi
	addl	%ecx, %edi
	sarl	%edi
	callq	_cpu_to_le16
	movq	%rax, -88(%rbp)
	movl	(%r12), %ecx
	movl	%r13d, %eax
	cltd
	idivl	4(%r15)
	subl	%eax, %ecx
	movl	%ecx, %edi
	shrl	$31, %edi
	addl	%ecx, %edi
	sarl	%edi
	callq	_cpu_to_le16
	movq	%rax, -80(%rbp)
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_COMMAND,4,2                    ## @COMMAND
	.comm	_SetCRTC_OverScan,4,2           ## @SetCRTC_OverScan
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_amdgpu_atombios_crtc_overscan_setup ; -- Begin function amdgpu_atombios_crtc_overscan_setup
	.p2align	2
_amdgpu_atombios_crtc_overscan_setup:   ; @amdgpu_atombios_crtc_overscan_setup
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
	mov	x21, x2
	mov	x20, x1
	ldr	x8, [x0]
	ldr	x23, [x8]
	bl	_to_amdgpu_crtc
	mov	x22, x0
Lloh0:
	adrp	x8, _COMMAND@GOTPAGE
Lloh1:
	ldr	x8, [x8, _COMMAND@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x8, _SetCRTC_OverScan@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SetCRTC_OverScan@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_GetIndexIntoMasterTable
	mov	x19, x0
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #40
	bl	_memset
	ldr	w8, [x22, #12]
	str	w8, [sp, #40]
	ldr	w8, [x22]
	cmp	w8, #130
	b.eq	LBB0_3
; %bb.1:
	cmp	w8, #129
	b.ne	LBB0_6
; %bb.2:
	ldr	w8, [x21]
	ldr	w9, [x20]
	sub	w8, w8, w9
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w0, w8, #1
	bl	_cpu_to_le16
	str	x0, [sp, #8]
	ldr	w8, [x21]
	ldr	w9, [x20]
	sub	w8, w8, w9
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w0, w8, #1
	bl	_cpu_to_le16
	str	x0, [sp, #16]
	ldr	w8, [x21, #4]
	ldr	w9, [x20, #4]
	sub	w8, w8, w9
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w0, w8, #1
	bl	_cpu_to_le16
	str	x0, [sp, #24]
	ldr	w8, [x21, #4]
	ldr	w9, [x20, #4]
	b	LBB0_5
LBB0_3:
	ldp	w8, w9, [x21]
	ldp	w11, w10, [x20]
	mul	w22, w9, w11
	mul	w24, w10, w8
	cmp	w22, w24
	b.le	LBB0_7
; %bb.4:
	sdiv	w8, w24, w11
	sub	w8, w9, w8
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w0, w8, #1
	bl	_cpu_to_le16
	str	x0, [sp, #24]
	ldr	w8, [x21, #4]
	ldr	w9, [x20]
	sdiv	w9, w24, w9
LBB0_5:
	sub	w8, w8, w9
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w0, w8, #1
	bl	_cpu_to_le16
	str	x0, [sp, #32]
	b	LBB0_9
LBB0_6:
	ldr	w0, [x22, #4]
	bl	_cpu_to_le16
	str	x0, [sp, #32]
	ldr	w0, [x22, #4]
	bl	_cpu_to_le16
	str	x0, [sp, #24]
	ldr	w0, [x22, #8]
	bl	_cpu_to_le16
	str	x0, [sp, #16]
	ldr	w0, [x22, #8]
	bl	_cpu_to_le16
	str	x0, [sp, #8]
	b	LBB0_9
LBB0_7:
	cmp	w24, w22
	b.le	LBB0_9
; %bb.8:
	sdiv	w9, w22, w10
	sub	w8, w8, w9
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w0, w8, #1
	bl	_cpu_to_le16
	str	x0, [sp, #8]
	ldr	w8, [x21]
	ldr	w9, [x20, #4]
	sdiv	w9, w22, w9
	sub	w8, w8, w9
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w0, w8, #1
	bl	_cpu_to_le16
	str	x0, [sp, #16]
LBB0_9:
	ldr	w0, [x23]
	add	x2, sp, #8
	mov	x1, x19
	bl	_amdgpu_atom_execute_table
	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
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_COMMAND,4,2                    ; @COMMAND
	.comm	_SetCRTC_OverScan,4,2           ; @SetCRTC_OverScan
.subsections_via_symbols
