	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nouveau_hw_get_pllvals         ## -- Begin function nouveau_hw_get_pllvals
	.p2align	4, 0x90
_nouveau_hw_get_pllvals:                ## @nouveau_hw_get_pllvals
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movl	%esi, %ebx
	movq	%rdi, %r13
	callq	_nouveau_drm
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_nvxx_bios
	leaq	-56(%rbp), %rdx
	movq	%rax, %rdi
	movl	%ebx, %esi
	callq	_nvbios_pll_parse
	testl	%eax, %eax
	je	LBB0_1
LBB0_2:
	movq	_ENOENT@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_16
LBB0_1:
	movl	-56(%rbp), %r15d
	testl	%r15d, %r15d
	je	LBB0_2
## %bb.3:
	movq	%r12, %rbx
	addq	$8, %rbx
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_nvif_rd32
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	cmpl	$16476, %r15d                   ## imm = 0x405C
	jg	LBB0_5
## %bb.4:
	leal	4(%r15), %esi
	jmp	LBB0_8
LBB0_5:
	movq	%r13, %rdi
	callq	_nv_two_reg_pll
	testq	%rax, %rax
	je	LBB0_6
## %bb.7:
	movq	_NV_RAMDAC_VPLL2@GOTPCREL(%rip), %rax
	leal	112(%r15), %ecx
	leal	92(%r15), %esi
	cmpl	(%rax), %r15d
	cmovnel	%ecx, %esi
LBB0_8:
	movq	%rbx, %rdi
	callq	_nvif_rd32
	movl	%eax, %ebx
	jmp	LBB0_9
LBB0_6:
	xorl	%ebx, %ebx
LBB0_9:
	movq	(%r12), %rax
	movq	_NV_DEVICE_INFO_V0_CELSIUS@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_15
## %bb.10:
	movq	_NV_PRAMDAC_VPLL_COEFF@GOTPCREL(%rip), %r12
	cmpl	(%r12), %r15d
	jl	LBB0_15
## %bb.11:
	movq	_NV_PRAMDAC_580@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_NVReadRAMDAC
	cmpl	(%r12), %r15d
	jne	LBB0_13
## %bb.12:
	movq	_NV_RAMDAC_580_VPLL1_ACTIVE@GOTPCREL(%rip), %rcx
	jmp	LBB0_14
LBB0_13:
	movq	_NV_RAMDAC_580_VPLL2_ACTIVE@GOTPCREL(%rip), %rcx
LBB0_14:
	testl	%eax, (%rcx)
	movl	$0, %eax
	cmovnel	%eax, %ebx
LBB0_15:
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movq	%r13, %rdi
	movl	%r15d, %esi
	movl	%ebx, %ecx
	movq	%r14, %r8
	callq	_nouveau_hw_decode_pll
	movl	-52(%rbp), %eax
	movl	%eax, (%r14)
	xorl	%eax, %eax
LBB0_16:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_NV_RAMDAC_VPLL2,4,2            ## @NV_RAMDAC_VPLL2
	.comm	_NV_DEVICE_INFO_V0_CELSIUS,8,3  ## @NV_DEVICE_INFO_V0_CELSIUS
	.comm	_NV_PRAMDAC_VPLL_COEFF,4,2      ## @NV_PRAMDAC_VPLL_COEFF
	.comm	_NV_PRAMDAC_580,4,2             ## @NV_PRAMDAC_580
	.comm	_NV_RAMDAC_580_VPLL1_ACTIVE,4,2 ## @NV_RAMDAC_580_VPLL1_ACTIVE
	.comm	_NV_RAMDAC_580_VPLL2_ACTIVE,4,2 ## @NV_RAMDAC_580_VPLL2_ACTIVE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nouveau_hw_get_pllvals         ; -- Begin function nouveau_hw_get_pllvals
	.p2align	2
_nouveau_hw_get_pllvals:                ; @nouveau_hw_get_pllvals
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x19, x2
	mov	x21, x1
	mov	x20, x0
	bl	_nouveau_drm
	mov	x23, x0
	bl	_nvxx_bios
	add	x2, sp, #8
	mov	x1, x21
	bl	_nvbios_pll_parse
	cbz	w0, LBB0_2
LBB0_1:
Lloh0:
	adrp	x8, _ENOENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_15
LBB0_2:
	ldr	w21, [sp, #8]
	cbz	w21, LBB0_1
; %bb.3:
	add	x24, x23, #8
	mov	x0, x24
	mov	x1, x21
	bl	_nvif_rd32
	mov	x22, x0
	mov	w8, #16476
	cmp	w21, w8
	b.gt	LBB0_5
; %bb.4:
	add	w1, w21, #4
	b	LBB0_7
LBB0_5:
	mov	x0, x20
	bl	_nv_two_reg_pll
	cbz	x0, LBB0_8
; %bb.6:
Lloh3:
	adrp	x8, _NV_RAMDAC_VPLL2@GOTPAGE
Lloh4:
	ldr	x8, [x8, _NV_RAMDAC_VPLL2@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	mov	w9, #112
	mov	w10, #92
	cmp	w21, w8
	csel	w8, w10, w9, eq
	add	w1, w8, w21
LBB0_7:
	mov	x0, x24
	bl	_nvif_rd32
	mov	x24, x0
	b	LBB0_9
LBB0_8:
	mov	w24, #0
LBB0_9:
	ldr	x8, [x23]
Lloh6:
	adrp	x9, _NV_DEVICE_INFO_V0_CELSIUS@GOTPAGE
Lloh7:
	ldr	x9, [x9, _NV_DEVICE_INFO_V0_CELSIUS@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
Lloh9:
	adrp	x23, _NV_PRAMDAC_VPLL_COEFF@GOTPAGE
Lloh10:
	ldr	x23, [x23, _NV_PRAMDAC_VPLL_COEFF@GOTPAGEOFF]
	ldr	w10, [x23]
	cmp	x8, x9
	ccmp	w21, w10, #8, eq
	b.lt	LBB0_14
; %bb.10:
Lloh11:
	adrp	x8, _NV_PRAMDAC_580@GOTPAGE
Lloh12:
	ldr	x8, [x8, _NV_PRAMDAC_580@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	mov	x0, x20
	mov	w1, #0
	bl	_NVReadRAMDAC
	ldr	w8, [x23]
	cmp	w21, w8
	b.ne	LBB0_12
; %bb.11:
Lloh14:
	adrp	x8, _NV_RAMDAC_580_VPLL1_ACTIVE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _NV_RAMDAC_580_VPLL1_ACTIVE@GOTPAGEOFF]
	b	LBB0_13
LBB0_12:
Lloh16:
	adrp	x8, _NV_RAMDAC_580_VPLL2_ACTIVE@GOTPAGE
Lloh17:
	ldr	x8, [x8, _NV_RAMDAC_580_VPLL2_ACTIVE@GOTPAGEOFF]
LBB0_13:
	ldr	w8, [x8]
	tst	w8, w0
	csel	w24, w24, wzr, eq
LBB0_14:
	mov	x0, x20
	mov	x1, x21
	mov	x2, x22
	mov	x3, x24
	mov	x4, x19
	bl	_nouveau_hw_decode_pll
	mov	w0, #0
	ldr	w8, [sp, #12]
	str	w8, [x19]
LBB0_15:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_NV_RAMDAC_VPLL2,4,2            ; @NV_RAMDAC_VPLL2
	.comm	_NV_DEVICE_INFO_V0_CELSIUS,8,3  ; @NV_DEVICE_INFO_V0_CELSIUS
	.comm	_NV_PRAMDAC_VPLL_COEFF,4,2      ; @NV_PRAMDAC_VPLL_COEFF
	.comm	_NV_PRAMDAC_580,4,2             ; @NV_PRAMDAC_580
	.comm	_NV_RAMDAC_580_VPLL1_ACTIVE,4,2 ; @NV_RAMDAC_580_VPLL1_ACTIVE
	.comm	_NV_RAMDAC_580_VPLL2_ACTIVE,4,2 ; @NV_RAMDAC_580_VPLL2_ACTIVE
.subsections_via_symbols
