	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dce_v8_0_pick_pll
_dce_v8_0_pick_pll:                     ## @dce_v8_0_pick_pll
	.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, %rbx
	callq	_to_amdgpu_crtc
	movq	(%rbx), %rcx
	movq	(%rcx), %r14
	movl	(%rax), %edi
	callq	_amdgpu_atombios_encoder_get_encoder_mode
	movl	%eax, %edi
	callq	_ENCODER_MODE_IS_DP
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	cmpq	$0, 8(%r14)
	jne	LBB0_14
## %bb.2:
	movq	%rbx, %rdi
	callq	_amdgpu_pll_get_shared_dp_ppll
	jmp	LBB0_4
LBB0_3:
	movq	%rbx, %rdi
	callq	_amdgpu_pll_get_shared_nondp_ppll
LBB0_4:
	movq	_ATOM_PPLL_INVALID@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_15
## %bb.5:
	movq	(%r14), %r14
	movq	_CHIP_KABINI@GOTPCREL(%rip), %rax
	movq	(%rax), %r12
	movq	_CHIP_MULLINS@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	movq	%rbx, %rdi
	callq	_amdgpu_pll_get_use_mask
	movl	%eax, %edx
	movq	_ATOM_PPLL2@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	$1, %esi
	movl	%eax, %ecx
	shll	%cl, %esi
	cmpq	%r12, %r14
	je	LBB0_7
## %bb.6:
	cmpq	%r15, %r14
	je	LBB0_7
## %bb.9:
	testl	%edx, %esi
	je	LBB0_15
## %bb.10:
	movq	_ATOM_PPLL1@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	btl	%eax, %edx
	jae	LBB0_15
## %bb.11:
	movq	_ATOM_PPLL0@GOTPCREL(%rip), %rax
	jmp	LBB0_12
LBB0_7:
	testl	%edx, %esi
	je	LBB0_15
## %bb.8:
	movq	_ATOM_PPLL1@GOTPCREL(%rip), %rax
LBB0_12:
	movl	(%rax), %eax
	btl	%eax, %edx
	jae	LBB0_15
## %bb.13:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_ERROR
LBB0_14:
	movq	_ATOM_PPLL_INVALID@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_15:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ATOM_PPLL_INVALID,4,2          ## @ATOM_PPLL_INVALID
	.comm	_CHIP_KABINI,8,3                ## @CHIP_KABINI
	.comm	_CHIP_MULLINS,8,3               ## @CHIP_MULLINS
	.comm	_ATOM_PPLL2,4,2                 ## @ATOM_PPLL2
	.comm	_ATOM_PPLL1,4,2                 ## @ATOM_PPLL1
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unable to allocate a PPLL\n"

	.comm	_ATOM_PPLL0,4,2                 ## @ATOM_PPLL0
	.no_dead_strip	_dce_v8_0_pick_pll
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dce_v8_0_pick_pll
_dce_v8_0_pick_pll:                     ; @dce_v8_0_pick_pll
	.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	x19, x0
	bl	_to_amdgpu_crtc
	ldr	x8, [x19]
	ldr	x20, [x8]
	ldr	w0, [x0]
	bl	_amdgpu_atombios_encoder_get_encoder_mode
	bl	_ENCODER_MODE_IS_DP
	cbz	x0, LBB0_3
; %bb.1:
	ldr	x8, [x20, #8]
	cbnz	x8, LBB0_13
; %bb.2:
	mov	x0, x19
	bl	_amdgpu_pll_get_shared_dp_ppll
	b	LBB0_4
LBB0_3:
	mov	x0, x19
	bl	_amdgpu_pll_get_shared_nondp_ppll
LBB0_4:
                                        ; kill: def $w0 killed $w0 def $x0
Lloh0:
	adrp	x8, _ATOM_PPLL_INVALID@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ATOM_PPLL_INVALID@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_14
; %bb.5:
	ldr	x20, [x20]
Lloh3:
	adrp	x8, _CHIP_KABINI@GOTPAGE
Lloh4:
	ldr	x8, [x8, _CHIP_KABINI@GOTPAGEOFF]
Lloh5:
	ldr	x21, [x8]
Lloh6:
	adrp	x8, _CHIP_MULLINS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _CHIP_MULLINS@GOTPAGEOFF]
Lloh8:
	ldr	x22, [x8]
	mov	x0, x19
	bl	_amdgpu_pll_get_use_mask
	mov	x8, x0
Lloh9:
	adrp	x9, _ATOM_PPLL2@GOTPAGE
Lloh10:
	ldr	x9, [x9, _ATOM_PPLL2@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x9]
	mov	w9, #1
	lsl	w9, w9, w0
	and	w9, w9, w8
	cmp	x20, x21
	ccmp	x20, x22, #4, ne
	b.ne	LBB0_8
; %bb.6:
	cbz	w9, LBB0_14
; %bb.7:
Lloh12:
	adrp	x9, _ATOM_PPLL1@GOTPAGE
Lloh13:
	ldr	x9, [x9, _ATOM_PPLL1@GOTPAGEOFF]
	b	LBB0_11
LBB0_8:
	cbz	w9, LBB0_14
; %bb.9:
Lloh14:
	adrp	x9, _ATOM_PPLL1@GOTPAGE
Lloh15:
	ldr	x9, [x9, _ATOM_PPLL1@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x9]
	lsr	w9, w8, w0
                                        ; kill: def $w0 killed $w0 killed $x0 def $x0
	tbz	w9, #0, LBB0_14
; %bb.10:
Lloh17:
	adrp	x9, _ATOM_PPLL0@GOTPAGE
Lloh18:
	ldr	x9, [x9, _ATOM_PPLL0@GOTPAGEOFF]
LBB0_11:
	ldr	w0, [x9]
	lsr	w8, w8, w0
                                        ; kill: def $w0 killed $w0 killed $x0 def $x0
	tbz	w8, #0, LBB0_14
; %bb.12:
Lloh19:
	adrp	x0, l_.str@PAGE
Lloh20:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_ERROR
LBB0_13:
Lloh21:
	adrp	x8, _ATOM_PPLL_INVALID@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ATOM_PPLL_INVALID@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
LBB0_14:
                                        ; kill: def $w0 killed $w0 killed $x0
	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
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_ATOM_PPLL_INVALID,4,2          ; @ATOM_PPLL_INVALID
	.comm	_CHIP_KABINI,8,3                ; @CHIP_KABINI
	.comm	_CHIP_MULLINS,8,3               ; @CHIP_MULLINS
	.comm	_ATOM_PPLL2,4,2                 ; @ATOM_PPLL2
	.comm	_ATOM_PPLL1,4,2                 ; @ATOM_PPLL1
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unable to allocate a PPLL\n"

	.comm	_ATOM_PPLL0,4,2                 ; @ATOM_PPLL0
	.no_dead_strip	_dce_v8_0_pick_pll
.subsections_via_symbols
