	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function icl_calc_mg_pll_link
_icl_calc_mg_pll_link:                  ## @icl_calc_mg_pll_link
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	8(%rsi), %r10d
	movq	_MG_CLKTOP2_HSCLKCTL_HSDIV_RATIO_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	%r10d, %eax
	addl	$-128, %eax
	cmpl	$4, %eax
	jae	LBB0_1
## %bb.2:
	movq	_MG_PLL_DIV0_FRACNEN_H@GOTPCREL(%rip), %rcx
	movl	4(%rsi), %r8d
	movl	(%rcx), %edx
	andl	%r8d, %edx
	movq	_MG_PLL_DIV0_FBDIV_FRAC_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r9d
	andl	%r8d, %r9d
	movq	_MG_PLL_DIV0_FBDIV_FRAC_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %r9d
	testl	%edx, %edx
	cmovel	%edx, %r9d
	movq	_MG_PLL_DIV0_FBDIV_INT_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %r8d
	movq	_MG_PLL_DIV1_FBPREDIV_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	andl	(%rsi), %edx
	cltq
	leaq	L_switch.table.icl_calc_mg_pll_link(%rip), %r11
	movq	_MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %r10d
	movq	_MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %r10d
	testl	%r10d, %r10d
	movl	$1, %esi
	cmovnel	%r10d, %esi
	imull	(%rdi), %edx
	imull	%edx, %r8d
	imull	%r9d, %edx
	sarl	$22, %edx
	addl	%r8d, %edx
	imull	(%r11,%rax,4), %esi
	movl	%edx, %edi
	popq	%rbp
	jmp	_div_u64                        ## TAILCALL
LBB0_1:
	movl	%r10d, %edi
	callq	_MISSING_CASE
	xorl	%eax, %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MG_PLL_DIV1_FBPREDIV_MASK,4,2  ## @MG_PLL_DIV1_FBPREDIV_MASK
	.comm	_MG_PLL_DIV0_FBDIV_INT_MASK,4,2 ## @MG_PLL_DIV0_FBDIV_INT_MASK
	.comm	_MG_PLL_DIV0_FRACNEN_H,4,2      ## @MG_PLL_DIV0_FRACNEN_H
	.comm	_MG_PLL_DIV0_FBDIV_FRAC_MASK,4,2 ## @MG_PLL_DIV0_FBDIV_FRAC_MASK
	.comm	_MG_PLL_DIV0_FBDIV_FRAC_SHIFT,4,2 ## @MG_PLL_DIV0_FBDIV_FRAC_SHIFT
	.comm	_MG_CLKTOP2_HSCLKCTL_HSDIV_RATIO_MASK,4,2 ## @MG_CLKTOP2_HSCLKCTL_HSDIV_RATIO_MASK
	.comm	_MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_MASK,4,2 ## @MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_MASK
	.comm	_MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_SHIFT,4,2 ## @MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_SHIFT
	.no_dead_strip	_icl_calc_mg_pll_link
	.section	__TEXT,__literal16,16byte_literals
	.p2align	2                               ## @switch.table.icl_calc_mg_pll_link
L_switch.table.icl_calc_mg_pll_link:
	.long	35                              ## 0x23
	.long	25                              ## 0x19
	.long	15                              ## 0xf
	.long	10                              ## 0xa

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function icl_calc_mg_pll_link
_icl_calc_mg_pll_link:                  ; @icl_calc_mg_pll_link
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	mov	x8, x0
	ldr	w0, [x1, #8]
Lloh0:
	adrp	x9, _MG_CLKTOP2_HSCLKCTL_HSDIV_RATIO_MASK@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MG_CLKTOP2_HSCLKCTL_HSDIV_RATIO_MASK@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	and	w9, w9, w0
	sub	w9, w9, #128
	cmp	w9, #4
	b.hs	LBB0_2
; %bb.1:
Lloh3:
	adrp	x10, _MG_PLL_DIV0_FRACNEN_H@GOTPAGE
Lloh4:
	ldr	x10, [x10, _MG_PLL_DIV0_FRACNEN_H@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
Lloh6:
	adrp	x11, _MG_PLL_DIV0_FBDIV_FRAC_MASK@GOTPAGE
Lloh7:
	ldr	x11, [x11, _MG_PLL_DIV0_FBDIV_FRAC_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w11, [x11]
	ldp	w13, w12, [x1]
	and	w11, w11, w12
Lloh9:
	adrp	x14, _MG_PLL_DIV0_FBDIV_FRAC_SHIFT@GOTPAGE
Lloh10:
	ldr	x14, [x14, _MG_PLL_DIV0_FBDIV_FRAC_SHIFT@GOTPAGEOFF]
Lloh11:
	ldr	w14, [x14]
	asr	w11, w11, w14
	tst	w10, w12
	csel	w10, wzr, w11, eq
Lloh12:
	adrp	x11, _MG_PLL_DIV0_FBDIV_INT_MASK@GOTPAGE
Lloh13:
	ldr	x11, [x11, _MG_PLL_DIV0_FBDIV_INT_MASK@GOTPAGEOFF]
Lloh14:
	ldr	w11, [x11]
	and	w11, w11, w12
Lloh15:
	adrp	x12, _MG_PLL_DIV1_FBPREDIV_MASK@GOTPAGE
Lloh16:
	ldr	x12, [x12, _MG_PLL_DIV1_FBPREDIV_MASK@GOTPAGEOFF]
Lloh17:
	ldr	w12, [x12]
	and	w12, w12, w13
Lloh18:
	adrp	x13, l_switch.table.icl_calc_mg_pll_link@PAGE
Lloh19:
	add	x13, x13, l_switch.table.icl_calc_mg_pll_link@PAGEOFF
	ldr	w9, [x13, w9, sxtw #2]
	ldr	w8, [x8]
Lloh20:
	adrp	x13, _MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_MASK@GOTPAGE
Lloh21:
	ldr	x13, [x13, _MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_MASK@GOTPAGEOFF]
Lloh22:
	ldr	w13, [x13]
Lloh23:
	adrp	x14, _MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_SHIFT@GOTPAGE
Lloh24:
	ldr	x14, [x14, _MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_SHIFT@GOTPAGEOFF]
	and	w13, w13, w0
Lloh25:
	ldr	w14, [x14]
	asr	w13, w13, w14
	cmp	w13, #0
	csinc	w13, w13, wzr, ne
	mul	w8, w12, w8
	mul	w11, w8, w11
	mul	w8, w8, w10
	add	w0, w11, w8, asr #22
	mul	w1, w13, w9
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	b	_div_u64
LBB0_2:
	bl	_MISSING_CASE
	mov	w0, #0
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_MG_PLL_DIV1_FBPREDIV_MASK,4,2  ; @MG_PLL_DIV1_FBPREDIV_MASK
	.comm	_MG_PLL_DIV0_FBDIV_INT_MASK,4,2 ; @MG_PLL_DIV0_FBDIV_INT_MASK
	.comm	_MG_PLL_DIV0_FRACNEN_H,4,2      ; @MG_PLL_DIV0_FRACNEN_H
	.comm	_MG_PLL_DIV0_FBDIV_FRAC_MASK,4,2 ; @MG_PLL_DIV0_FBDIV_FRAC_MASK
	.comm	_MG_PLL_DIV0_FBDIV_FRAC_SHIFT,4,2 ; @MG_PLL_DIV0_FBDIV_FRAC_SHIFT
	.comm	_MG_CLKTOP2_HSCLKCTL_HSDIV_RATIO_MASK,4,2 ; @MG_CLKTOP2_HSCLKCTL_HSDIV_RATIO_MASK
	.comm	_MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_MASK,4,2 ; @MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_MASK
	.comm	_MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_SHIFT,4,2 ; @MG_CLKTOP2_HSCLKCTL_DSDIV_RATIO_SHIFT
	.no_dead_strip	_icl_calc_mg_pll_link
	.section	__TEXT,__literal16,16byte_literals
	.p2align	2                               ; @switch.table.icl_calc_mg_pll_link
l_switch.table.icl_calc_mg_pll_link:
	.long	35                              ; 0x23
	.long	25                              ; 0x19
	.long	15                              ; 0xf
	.long	10                              ; 0xa

.subsections_via_symbols
