	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rn_vbios_smu_set_dispclk       ## -- Begin function rn_vbios_smu_set_dispclk
	.p2align	4, 0x90
_rn_vbios_smu_set_dispclk:              ## @rn_vbios_smu_set_dispclk
	.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
	movq	%rdi, %r12
	movq	8(%rdi), %rax
	movq	(%rax), %rbx
	movq	8(%rbx), %rax
	movq	(%rax), %r14
	movslq	%esi, %rax
	imulq	$274877907, %rax, %rax          ## imm = 0x10624DD3
	movq	%rax, %rcx
	shrq	$63, %rcx
	sarq	$38, %rax
	addl	%ecx, %eax
	cmpl	$102, %eax
	movl	$101, %edx
	cmovgel	%eax, %edx
	movq	_VBIOSSMC_MSG_SetDispclkFreq@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_rn_vbios_smu_send_msg_with_param
	movl	%eax, %r15d
	movq	(%rbx), %rax
	movl	(%rax), %edi
	callq	_IS_FPGA_MAXIMUS_DC
	testl	%eax, %eax
	jne	LBB0_5
## %bb.1:
	testq	%r14, %r14
	je	LBB0_5
## %bb.2:
	movq	(%r14), %rax
	movq	%r14, %rdi
	callq	*8(%rax)
	testq	%rax, %rax
	je	LBB0_5
## %bb.3:
	cmpl	%r15d, (%r12)
	je	LBB0_5
## %bb.4:
	movq	(%r14), %rax
	movslq	%r15d, %rcx
	imulq	$-1840700269, %rcx, %rsi        ## imm = 0x92492493
	shrq	$32, %rsi
	addl	%r15d, %esi
	movl	%esi, %ecx
	shrl	$31, %ecx
	sarl	$2, %esi
	addl	%ecx, %esi
	movq	%r14, %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	*(%rax)
LBB0_5:
	imull	$1000, %r15d, %eax              ## imm = 0x3E8
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_VBIOSSMC_MSG_SetDispclkFreq,4,2 ## @VBIOSSMC_MSG_SetDispclkFreq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rn_vbios_smu_set_dispclk       ; -- Begin function rn_vbios_smu_set_dispclk
	.p2align	2
_rn_vbios_smu_set_dispclk:              ; @rn_vbios_smu_set_dispclk
	.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	x20, x0
	ldr	x8, [x0, #8]
	ldr	x22, [x8]
	ldr	x8, [x22, #8]
	ldr	x19, [x8]
	mov	w8, #19923
	movk	w8, #4194, lsl #16
	smull	x8, w1, w8
	lsr	x9, x8, #63
	asr	x8, x8, #38
	add	w8, w8, w9
	mov	w9, #101
	cmp	w8, #101
	csel	w2, w8, w9, gt
Lloh0:
	adrp	x8, _VBIOSSMC_MSG_SetDispclkFreq@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VBIOSSMC_MSG_SetDispclkFreq@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_rn_vbios_smu_send_msg_with_param
	mov	x21, x0
	ldr	x8, [x22]
	ldr	w0, [x8]
	bl	_IS_FPGA_MAXIMUS_DC
	cmp	w0, #0
	ccmp	x19, #0, #4, eq
	b.eq	LBB0_4
; %bb.1:
	ldr	x8, [x19]
	ldr	x8, [x8, #8]
	mov	x0, x19
	blr	x8
	cbz	x0, LBB0_4
; %bb.2:
	ldr	w8, [x20]
	cmp	w8, w21
	b.eq	LBB0_4
; %bb.3:
	ldr	x8, [x19]
	ldr	x8, [x8]
	mov	w9, #9363
	movk	w9, #37449, lsl #16
	smull	x9, w21, w9
	lsr	x9, x9, #32
	add	w9, w9, w21
	asr	w10, w9, #2
	add	w1, w10, w9, lsr #31
	mov	x0, x19
	blr	x8
LBB0_4:
	mov	w8, #1000
	mul	w0, w21, w8
	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
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_VBIOSSMC_MSG_SetDispclkFreq,4,2 ; @VBIOSSMC_MSG_SetDispclkFreq
.subsections_via_symbols
