	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function enable_spread_spectrum_on_ppll_v1
_enable_spread_spectrum_on_ppll_v1:     ## @enable_spread_spectrum_on_ppll_v1
	.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	%rbx
	subq	$88, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rsi, %rbx
	movq	_BP_RESULT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	leaq	-64(%rbp), %rdi
	xorl	%esi, %esi
	movl	$40, %edx
	callq	_memset
	movq	(%rbx), %rdi
	movq	_ATOM_DISABLE@GOTPCREL(%rip), %rax
	movq	%rax, %rcx
	testq	%rdi, %rdi
	jle	LBB0_2
## %bb.1:
	movq	_ATOM_ENABLE@GOTPCREL(%rip), %rcx
LBB0_2:
	cmpl	$1, %r15d
	cmoveq	%rcx, %rax
	movl	(%rax), %eax
	movl	%eax, -28(%rbp)
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_cpu_to_le16
	movl	%eax, -32(%rbp)
	movups	40(%rbx), %xmm0
	movups	%xmm0, -48(%rbp)
	movslq	32(%rbx), %rax
	imulq	$1759218605, %rax, %rax         ## imm = 0x68DB8BAD
	movq	%rax, %rcx
	shrq	$63, %rcx
	sarq	$44, %rax
	addl	%ecx, %eax
	cltq
	movq	%rax, -56(%rbp)
	cmpq	$0, 24(%rbx)
	je	LBB0_4
## %bb.3:
	movq	_ATOM_EXTERNAL_SS_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, -60(%rbp)
LBB0_4:
	cmpq	$0, 16(%rbx)
	je	LBB0_6
## %bb.5:
	movq	_ATOM_SS_CENTRE_SPREAD_MODE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, -60(%rbp)
LBB0_6:
	movq	8(%rbx), %rax
	movq	_CLOCK_SOURCE_ID_PLL1@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.7:
	movq	_ATOM_PPLL1@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_9:
	movq	_CLOCK_SOURCE_ID_PLL2@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_11
## %bb.10:
	movq	_ATOM_PPLL2@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %eax
	movl	%eax, -64(%rbp)
	jmp	LBB0_12
LBB0_11:
	xorl	%eax, %eax
	callq	_BREAK_TO_DEBUGGER
LBB0_12:
	movq	_EnableSpreadSpectrumOnPPLL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	-32(%rbp), %rax
	movq	%rax, 32(%rsp)
	movups	-64(%rbp), %xmm0
	movups	-48(%rbp), %xmm1
	movups	%xmm1, 16(%rsp)
	movups	%xmm0, (%rsp)
	callq	_EXEC_BIOS_CMD_TABLE
	testq	%rax, %rax
	je	LBB0_14
## %bb.13:
	movq	_BP_RESULT_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
LBB0_14:
	movl	%r14d, %eax
	addq	$88, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BP_RESULT_FAILURE,4,2          ## @BP_RESULT_FAILURE
	.comm	_ATOM_ENABLE,4,2                ## @ATOM_ENABLE
	.comm	_ATOM_DISABLE,4,2               ## @ATOM_DISABLE
	.comm	_ATOM_EXTERNAL_SS_MASK,4,2      ## @ATOM_EXTERNAL_SS_MASK
	.comm	_ATOM_SS_CENTRE_SPREAD_MODE,4,2 ## @ATOM_SS_CENTRE_SPREAD_MODE
	.comm	_CLOCK_SOURCE_ID_PLL1,8,3       ## @CLOCK_SOURCE_ID_PLL1
	.comm	_ATOM_PPLL1,4,2                 ## @ATOM_PPLL1
	.comm	_CLOCK_SOURCE_ID_PLL2,8,3       ## @CLOCK_SOURCE_ID_PLL2
	.comm	_ATOM_PPLL2,4,2                 ## @ATOM_PPLL2
	.comm	_EnableSpreadSpectrumOnPPLL,4,2 ## @EnableSpreadSpectrumOnPPLL
	.comm	_BP_RESULT_OK,4,2               ## @BP_RESULT_OK
	.no_dead_strip	_enable_spread_spectrum_on_ppll_v1
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function enable_spread_spectrum_on_ppll_v1
_enable_spread_spectrum_on_ppll_v1:     ; @enable_spread_spectrum_on_ppll_v1
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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, x2
	mov	x19, x1
Lloh0:
	adrp	x8, _BP_RESULT_FAILURE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BP_RESULT_FAILURE@GOTPAGEOFF]
Lloh2:
	ldr	w21, [x8]
	add	x0, sp, #40
	mov	w1, #0
	mov	w2, #40
	bl	_memset
	ldr	x0, [x19]
	cmp	x0, #0
Lloh3:
	adrp	x8, _ATOM_ENABLE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ATOM_ENABLE@GOTPAGEOFF]
	ccmp	w20, #1, #0, gt
Lloh5:
	adrp	x9, _ATOM_DISABLE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _ATOM_DISABLE@GOTPAGEOFF]
	csel	x8, x8, x9, eq
	ldr	w8, [x8]
	str	w8, [sp, #76]
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_cpu_to_le16
	str	w0, [sp, #72]
	ldp	x9, x8, [x19, #40]
	stp	x9, x8, [sp, #56]
	ldrsw	x8, [x19, #32]
	mov	w10, #35757
	movk	w10, #26843, lsl #16
	mul	x8, x8, x10
	lsr	x10, x8, #32
	lsr	x8, x8, #63
	add	w8, w8, w10, asr #12
	sxtw	x8, w8
	str	x8, [sp, #48]
	ldr	x8, [x19, #24]
	cbz	x8, LBB0_2
; %bb.1:
Lloh7:
	adrp	x8, _ATOM_EXTERNAL_SS_MASK@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ATOM_EXTERNAL_SS_MASK@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	ldr	w9, [sp, #44]
	orr	w8, w9, w8
	str	w8, [sp, #44]
LBB0_2:
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_4
; %bb.3:
Lloh10:
	adrp	x8, _ATOM_SS_CENTRE_SPREAD_MODE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ATOM_SS_CENTRE_SPREAD_MODE@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	ldr	w9, [sp, #44]
	orr	w8, w9, w8
	str	w8, [sp, #44]
LBB0_4:
	ldr	x8, [x19, #8]
Lloh13:
	adrp	x9, _CLOCK_SOURCE_ID_PLL1@GOTPAGE
Lloh14:
	ldr	x9, [x9, _CLOCK_SOURCE_ID_PLL1@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.5:
Lloh16:
	adrp	x8, _ATOM_PPLL1@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ATOM_PPLL1@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:
Lloh18:
	adrp	x9, _CLOCK_SOURCE_ID_PLL2@GOTPAGE
Lloh19:
	ldr	x9, [x9, _CLOCK_SOURCE_ID_PLL2@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_9
; %bb.7:
Lloh21:
	adrp	x8, _ATOM_PPLL2@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ATOM_PPLL2@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	str	w8, [sp, #40]
	b	LBB0_10
LBB0_9:
	bl	_BREAK_TO_DEBUGGER
LBB0_10:
Lloh23:
	adrp	x8, _EnableSpreadSpectrumOnPPLL@GOTPAGE
Lloh24:
	ldr	x8, [x8, _EnableSpreadSpectrumOnPPLL@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
	ldur	q0, [sp, #40]
	ldur	q1, [sp, #56]
	stp	q0, q1, [sp]
	ldr	x8, [sp, #72]
	str	x8, [sp, #32]
	mov	x1, sp
	bl	_EXEC_BIOS_CMD_TABLE
Lloh26:
	adrp	x8, _BP_RESULT_OK@GOTPAGE
Lloh27:
	ldr	x8, [x8, _BP_RESULT_OK@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	cmp	x0, #0
	csel	w0, w21, w8, eq
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_BP_RESULT_FAILURE,4,2          ; @BP_RESULT_FAILURE
	.comm	_ATOM_ENABLE,4,2                ; @ATOM_ENABLE
	.comm	_ATOM_DISABLE,4,2               ; @ATOM_DISABLE
	.comm	_ATOM_EXTERNAL_SS_MASK,4,2      ; @ATOM_EXTERNAL_SS_MASK
	.comm	_ATOM_SS_CENTRE_SPREAD_MODE,4,2 ; @ATOM_SS_CENTRE_SPREAD_MODE
	.comm	_CLOCK_SOURCE_ID_PLL1,8,3       ; @CLOCK_SOURCE_ID_PLL1
	.comm	_ATOM_PPLL1,4,2                 ; @ATOM_PPLL1
	.comm	_CLOCK_SOURCE_ID_PLL2,8,3       ; @CLOCK_SOURCE_ID_PLL2
	.comm	_ATOM_PPLL2,4,2                 ; @ATOM_PPLL2
	.comm	_EnableSpreadSpectrumOnPPLL,4,2 ; @EnableSpreadSpectrumOnPPLL
	.comm	_BP_RESULT_OK,4,2               ; @BP_RESULT_OK
	.no_dead_strip	_enable_spread_spectrum_on_ppll_v1
.subsections_via_symbols
