	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nouveau_hw_get_clock           ## -- Begin function nouveau_hw_get_clock
	.p2align	4, 0x90
_nouveau_hw_get_clock:                  ## @nouveau_hw_get_clock
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	subq	$16, %rsp
	movq	_PLL_MEMORY@GOTPCREL(%rip), %rax
	cmpl	%esi, (%rax)
	jne	LBB0_5
## %bb.1:
	movl	$4080, %eax                     ## imm = 0xFF0
	andl	(%rdi), %eax
	movq	_CHIPSET_NFORCE@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_3
## %bb.2:
	xorl	%edi, %edi
	movl	$3, %esi
	callq	_pci_get_bus_and_slot
	leaq	-16(%rbp), %rdx
	movl	%eax, %edi
	movl	$108, %esi
	callq	_pci_read_config_dword
	movl	-16(%rbp), %eax
	testl	%eax, %eax
	movl	$4, %ecx
	cmovnel	%eax, %ecx
	movl	$400000, %eax                   ## imm = 0x61A80
	xorl	%edx, %edx
	idivl	%ecx
	jmp	LBB0_7
LBB0_3:
	movq	_CHIPSET_NFORCE2@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_5
## %bb.4:
	xorl	%edi, %edi
	movl	$5, %esi
	callq	_pci_get_bus_and_slot
	leaq	-12(%rbp), %rdx
	movl	%eax, %edi
	movl	$76, %esi
	callq	_pci_read_config_dword
	movl	-12(%rbp), %eax
	jmp	LBB0_7
LBB0_5:
	leaq	-8(%rbp), %rdx
	callq	_nouveau_hw_get_pllvals
	testl	%eax, %eax
	jne	LBB0_7
## %bb.6:
	leaq	-8(%rbp), %rdi
	callq	_nouveau_hw_pllvals_to_clk
LBB0_7:
	addq	$16, %rsp
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PLL_MEMORY,4,2                 ## @PLL_MEMORY
	.comm	_CHIPSET_NFORCE,4,2             ## @CHIPSET_NFORCE
	.comm	_CHIPSET_NFORCE2,4,2            ## @CHIPSET_NFORCE2
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_nouveau_hw_get_clock           ; -- Begin function nouveau_hw_get_clock
	.p2align	2
_nouveau_hw_get_clock:                  ; @nouveau_hw_get_clock
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #32
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh0:
	adrp	x8, _PLL_MEMORY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PLL_MEMORY@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w1
	b.ne	LBB0_5
; %bb.1:
	ldr	w8, [x0]
	and	w8, w8, #0xff0
Lloh3:
	adrp	x9, _CHIPSET_NFORCE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _CHIPSET_NFORCE@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_3
; %bb.2:
	mov	w0, #0
	mov	w1, #3
	bl	_pci_get_bus_and_slot
	add	x2, sp, #4
	mov	w1, #108
	bl	_pci_read_config_dword
	ldr	w8, [sp, #4]
	mov	w9, #4
	cmp	w8, #0
	csel	w8, w9, w8, eq
	mov	w9, #6784
	movk	w9, #6, lsl #16
	sdiv	w0, w9, w8
	b	LBB0_7
LBB0_3:
Lloh6:
	adrp	x9, _CHIPSET_NFORCE2@GOTPAGE
Lloh7:
	ldr	x9, [x9, _CHIPSET_NFORCE2@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_5
; %bb.4:
	mov	w0, #0
	mov	w1, #5
	bl	_pci_get_bus_and_slot
	mov	x2, sp
	mov	w1, #76
	bl	_pci_read_config_dword
	ldr	w0, [sp]
	b	LBB0_7
LBB0_5:
	add	x2, sp, #8
	bl	_nouveau_hw_get_pllvals
	cbnz	w0, LBB0_7
; %bb.6:
	add	x0, sp, #8
	bl	_nouveau_hw_pllvals_to_clk
LBB0_7:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #32
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_PLL_MEMORY,4,2                 ; @PLL_MEMORY
	.comm	_CHIPSET_NFORCE,4,2             ; @CHIPSET_NFORCE
	.comm	_CHIPSET_NFORCE2,4,2            ; @CHIPSET_NFORCE2
.subsections_via_symbols
