	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dce_v11_0_pick_pll
_dce_v11_0_pick_pll:                    ## @dce_v11_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	callq	_to_amdgpu_crtc
	movq	%rax, %rbx
	movq	(%r14), %rax
	movq	(%rax), %r15
	movq	(%r15), %rax
	movq	_CHIP_POLARIS10@GOTPCREL(%rip), %rcx
	movl	(%rbx), %edi
	cmpq	(%rcx), %rax
	je	LBB0_4
## %bb.1:
	movq	_CHIP_POLARIS11@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_4
## %bb.2:
	movq	_CHIP_POLARIS12@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_4
## %bb.3:
	movq	_CHIP_VEGAM@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_4
## %bb.19:
	callq	_amdgpu_atombios_encoder_get_encoder_mode
	movl	%eax, %edi
	callq	_ENCODER_MODE_IS_DP
	testq	%rax, %rax
	je	LBB0_22
## %bb.20:
	cmpq	$0, 8(%r15)
	je	LBB0_21
LBB0_30:
	movq	_ATOM_PPLL_INVALID@GOTPCREL(%rip), %rax
	jmp	LBB0_31
LBB0_4:
	callq	_to_amdgpu_encoder
	movq	%rax, %r14
	movq	8(%rax), %r15
	movl	(%rbx), %edi
	callq	_amdgpu_atombios_encoder_get_encoder_mode
	movl	%eax, %edi
	callq	_ENCODER_MODE_IS_DP
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movq	_ATOM_DP_DTO@GOTPCREL(%rip), %rax
LBB0_31:
	movl	(%rax), %eax
LBB0_32:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	(%r14), %esi
	cmpl	$128, %esi
	je	LBB0_15
## %bb.7:
	cmpl	$129, %esi
	je	LBB0_12
## %bb.8:
	cmpl	$130, %esi
	jne	LBB0_18
## %bb.9:
	cmpl	$0, (%r15)
	jne	LBB0_10
## %bb.11:
	movq	_ATOM_COMBOPHY_PLL0@GOTPCREL(%rip), %rax
	jmp	LBB0_31
LBB0_22:
	movq	%r14, %rdi
	callq	_amdgpu_pll_get_shared_nondp_ppll
	jmp	LBB0_23
LBB0_21:
	movq	%r14, %rdi
	callq	_amdgpu_pll_get_shared_dp_ppll
LBB0_23:
	movq	_ATOM_PPLL_INVALID@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_32
## %bb.24:
	movq	%r14, %rdi
	callq	_amdgpu_pll_get_use_mask
	movl	%eax, %ecx
	movq	(%r15), %rax
	movq	_CHIP_CARRIZO@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	je	LBB0_27
## %bb.25:
	movq	_CHIP_STONEY@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	je	LBB0_27
## %bb.26:
	movq	_ATOM_PPLL2@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	btl	%eax, %ecx
	jae	LBB0_32
LBB0_27:
	movq	_ATOM_PPLL1@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	btl	%eax, %ecx
	jae	LBB0_32
## %bb.28:
	movq	_ATOM_PPLL0@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	btl	%eax, %ecx
	jae	LBB0_32
## %bb.29:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_ERROR
	jmp	LBB0_30
LBB0_15:
	cmpl	$0, (%r15)
	jne	LBB0_16
## %bb.17:
	movq	_ATOM_COMBOPHY_PLL4@GOTPCREL(%rip), %rax
	jmp	LBB0_31
LBB0_12:
	cmpl	$0, (%r15)
	jne	LBB0_13
## %bb.14:
	movq	_ATOM_COMBOPHY_PLL2@GOTPCREL(%rip), %rax
	jmp	LBB0_31
LBB0_18:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_DRM_ERROR
	jmp	LBB0_30
LBB0_16:
	movq	_ATOM_COMBOPHY_PLL5@GOTPCREL(%rip), %rax
	jmp	LBB0_31
LBB0_13:
	movq	_ATOM_COMBOPHY_PLL3@GOTPCREL(%rip), %rax
	jmp	LBB0_31
LBB0_10:
	movq	_ATOM_COMBOPHY_PLL1@GOTPCREL(%rip), %rax
	jmp	LBB0_31
	.cfi_endproc
                                        ## -- End function
	.comm	_CHIP_POLARIS10,8,3             ## @CHIP_POLARIS10
	.comm	_CHIP_POLARIS11,8,3             ## @CHIP_POLARIS11
	.comm	_CHIP_POLARIS12,8,3             ## @CHIP_POLARIS12
	.comm	_CHIP_VEGAM,8,3                 ## @CHIP_VEGAM
	.comm	_ATOM_DP_DTO,4,2                ## @ATOM_DP_DTO
	.comm	_ATOM_COMBOPHY_PLL1,4,2         ## @ATOM_COMBOPHY_PLL1
	.comm	_ATOM_COMBOPHY_PLL0,4,2         ## @ATOM_COMBOPHY_PLL0
	.comm	_ATOM_COMBOPHY_PLL3,4,2         ## @ATOM_COMBOPHY_PLL3
	.comm	_ATOM_COMBOPHY_PLL2,4,2         ## @ATOM_COMBOPHY_PLL2
	.comm	_ATOM_COMBOPHY_PLL5,4,2         ## @ATOM_COMBOPHY_PLL5
	.comm	_ATOM_COMBOPHY_PLL4,4,2         ## @ATOM_COMBOPHY_PLL4
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid encoder_id: 0x%x\n"

	.comm	_ATOM_PPLL_INVALID,4,2          ## @ATOM_PPLL_INVALID
	.comm	_CHIP_CARRIZO,8,3               ## @CHIP_CARRIZO
	.comm	_CHIP_STONEY,8,3                ## @CHIP_STONEY
	.comm	_ATOM_PPLL1,4,2                 ## @ATOM_PPLL1
	.comm	_ATOM_PPLL0,4,2                 ## @ATOM_PPLL0
L_.str.1:                               ## @.str.1
	.asciz	"unable to allocate a PPLL\n"

	.comm	_ATOM_PPLL2,4,2                 ## @ATOM_PPLL2
	.no_dead_strip	_dce_v11_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_v11_0_pick_pll
_dce_v11_0_pick_pll:                    ; @dce_v11_0_pick_pll
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x20, x0
	ldr	x8, [x19]
	ldr	x21, [x8]
	ldr	x8, [x21]
Lloh0:
	adrp	x9, _CHIP_POLARIS10@GOTPAGE
Lloh1:
	ldr	x9, [x9, _CHIP_POLARIS10@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
Lloh3:
	adrp	x10, _CHIP_POLARIS11@GOTPAGE
Lloh4:
	ldr	x10, [x10, _CHIP_POLARIS11@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
Lloh6:
	adrp	x11, _CHIP_POLARIS12@GOTPAGE
Lloh7:
	ldr	x11, [x11, _CHIP_POLARIS12@GOTPAGEOFF]
Lloh8:
	ldr	x11, [x11]
Lloh9:
	adrp	x12, _CHIP_VEGAM@GOTPAGE
Lloh10:
	ldr	x12, [x12, _CHIP_VEGAM@GOTPAGEOFF]
Lloh11:
	ldr	x12, [x12]
	ldr	w0, [x0]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	ccmp	x8, x11, #4, ne
	ccmp	x8, x12, #4, ne
	b.ne	LBB0_3
; %bb.1:
	bl	_to_amdgpu_encoder
	mov	x19, x0
	ldr	x21, [x0, #8]
	ldr	w0, [x20]
	bl	_amdgpu_atombios_encoder_get_encoder_mode
	bl	_ENCODER_MODE_IS_DP
	cbz	x0, LBB0_6
; %bb.2:
Lloh12:
	adrp	x8, _ATOM_DP_DTO@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ATOM_DP_DTO@GOTPAGEOFF]
	b	LBB0_24
LBB0_3:
	bl	_amdgpu_atombios_encoder_get_encoder_mode
	bl	_ENCODER_MODE_IS_DP
	cbz	x0, LBB0_10
; %bb.4:
	ldr	x8, [x21, #8]
	cbnz	x8, LBB0_23
; %bb.5:
	mov	x0, x19
	bl	_amdgpu_pll_get_shared_dp_ppll
	b	LBB0_11
LBB0_6:
	ldr	w8, [x19]
	cmp	w8, #128
	b.eq	LBB0_18
; %bb.7:
	cmp	w8, #129
	b.eq	LBB0_19
; %bb.8:
	cmp	w8, #130
	b.ne	LBB0_21
; %bb.9:
	ldr	w8, [x21]
Lloh14:
	adrp	x9, _ATOM_COMBOPHY_PLL1@GOTPAGE
Lloh15:
	ldr	x9, [x9, _ATOM_COMBOPHY_PLL1@GOTPAGEOFF]
Lloh16:
	adrp	x10, _ATOM_COMBOPHY_PLL0@GOTPAGE
Lloh17:
	ldr	x10, [x10, _ATOM_COMBOPHY_PLL0@GOTPAGEOFF]
	b	LBB0_20
LBB0_10:
	mov	x0, x19
	bl	_amdgpu_pll_get_shared_nondp_ppll
LBB0_11:
                                        ; kill: def $w0 killed $w0 def $x0
Lloh18:
	adrp	x8, _ATOM_PPLL_INVALID@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ATOM_PPLL_INVALID@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_25
; %bb.12:
	mov	x0, x19
	bl	_amdgpu_pll_get_use_mask
	mov	x8, x0
	ldr	x9, [x21]
Lloh21:
	adrp	x10, _CHIP_CARRIZO@GOTPAGE
Lloh22:
	ldr	x10, [x10, _CHIP_CARRIZO@GOTPAGEOFF]
Lloh23:
	ldr	x10, [x10]
Lloh24:
	adrp	x11, _CHIP_STONEY@GOTPAGE
Lloh25:
	ldr	x11, [x11, _CHIP_STONEY@GOTPAGEOFF]
Lloh26:
	ldr	x11, [x11]
	cmp	x9, x10
	ccmp	x9, x11, #4, ne
	b.ne	LBB0_14
; %bb.13:
Lloh27:
	adrp	x9, _ATOM_PPLL1@GOTPAGE
Lloh28:
	ldr	x9, [x9, _ATOM_PPLL1@GOTPAGEOFF]
Lloh29:
	ldr	w0, [x9]
	lsr	w9, w8, w0
	tbnz	w9, #0, LBB0_16
	b	LBB0_25
LBB0_14:
Lloh30:
	adrp	x9, _ATOM_PPLL2@GOTPAGE
Lloh31:
	ldr	x9, [x9, _ATOM_PPLL2@GOTPAGEOFF]
Lloh32:
	ldr	w0, [x9]
	lsr	w9, w8, w0
                                        ; kill: def $w0 killed $w0 killed $x0 def $x0
	tbz	w9, #0, LBB0_25
; %bb.15:
Lloh33:
	adrp	x9, _ATOM_PPLL1@GOTPAGE
Lloh34:
	ldr	x9, [x9, _ATOM_PPLL1@GOTPAGEOFF]
Lloh35:
	ldr	w0, [x9]
	lsr	w9, w8, w0
                                        ; kill: def $w0 killed $w0 killed $x0 def $x0
	tbz	w9, #0, LBB0_25
LBB0_16:
Lloh36:
	adrp	x9, _ATOM_PPLL0@GOTPAGE
Lloh37:
	ldr	x9, [x9, _ATOM_PPLL0@GOTPAGEOFF]
Lloh38:
	ldr	w0, [x9]
	lsr	w8, w8, w0
                                        ; kill: def $w0 killed $w0 killed $x0 def $x0
	tbz	w8, #0, LBB0_25
; %bb.17:
Lloh39:
	adrp	x0, l_.str.1@PAGE
Lloh40:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_22
LBB0_18:
	ldr	w8, [x21]
Lloh41:
	adrp	x9, _ATOM_COMBOPHY_PLL5@GOTPAGE
Lloh42:
	ldr	x9, [x9, _ATOM_COMBOPHY_PLL5@GOTPAGEOFF]
Lloh43:
	adrp	x10, _ATOM_COMBOPHY_PLL4@GOTPAGE
Lloh44:
	ldr	x10, [x10, _ATOM_COMBOPHY_PLL4@GOTPAGEOFF]
	b	LBB0_20
LBB0_19:
	ldr	w8, [x21]
Lloh45:
	adrp	x9, _ATOM_COMBOPHY_PLL3@GOTPAGE
Lloh46:
	ldr	x9, [x9, _ATOM_COMBOPHY_PLL3@GOTPAGEOFF]
Lloh47:
	adrp	x10, _ATOM_COMBOPHY_PLL2@GOTPAGE
Lloh48:
	ldr	x10, [x10, _ATOM_COMBOPHY_PLL2@GOTPAGEOFF]
LBB0_20:
	cmp	w8, #0
	csel	x8, x10, x9, eq
	b	LBB0_24
LBB0_21:
	str	x8, [sp]
Lloh49:
	adrp	x0, l_.str@PAGE
Lloh50:
	add	x0, x0, l_.str@PAGEOFF
LBB0_22:
	bl	_DRM_ERROR
LBB0_23:
Lloh51:
	adrp	x8, _ATOM_PPLL_INVALID@GOTPAGE
Lloh52:
	ldr	x8, [x8, _ATOM_PPLL_INVALID@GOTPAGEOFF]
LBB0_24:
	ldr	w0, [x8]
LBB0_25:
                                        ; kill: def $w0 killed $w0 killed $x0
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpLdrGot	Lloh43, Lloh44
	.loh AdrpLdrGot	Lloh41, Lloh42
	.loh AdrpLdrGot	Lloh47, Lloh48
	.loh AdrpLdrGot	Lloh45, Lloh46
	.loh AdrpAdd	Lloh49, Lloh50
	.loh AdrpLdrGot	Lloh51, Lloh52
	.cfi_endproc
                                        ; -- End function
	.comm	_CHIP_POLARIS10,8,3             ; @CHIP_POLARIS10
	.comm	_CHIP_POLARIS11,8,3             ; @CHIP_POLARIS11
	.comm	_CHIP_POLARIS12,8,3             ; @CHIP_POLARIS12
	.comm	_CHIP_VEGAM,8,3                 ; @CHIP_VEGAM
	.comm	_ATOM_DP_DTO,4,2                ; @ATOM_DP_DTO
	.comm	_ATOM_COMBOPHY_PLL1,4,2         ; @ATOM_COMBOPHY_PLL1
	.comm	_ATOM_COMBOPHY_PLL0,4,2         ; @ATOM_COMBOPHY_PLL0
	.comm	_ATOM_COMBOPHY_PLL3,4,2         ; @ATOM_COMBOPHY_PLL3
	.comm	_ATOM_COMBOPHY_PLL2,4,2         ; @ATOM_COMBOPHY_PLL2
	.comm	_ATOM_COMBOPHY_PLL5,4,2         ; @ATOM_COMBOPHY_PLL5
	.comm	_ATOM_COMBOPHY_PLL4,4,2         ; @ATOM_COMBOPHY_PLL4
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid encoder_id: 0x%x\n"

	.comm	_ATOM_PPLL_INVALID,4,2          ; @ATOM_PPLL_INVALID
	.comm	_CHIP_CARRIZO,8,3               ; @CHIP_CARRIZO
	.comm	_CHIP_STONEY,8,3                ; @CHIP_STONEY
	.comm	_ATOM_PPLL1,4,2                 ; @ATOM_PPLL1
	.comm	_ATOM_PPLL0,4,2                 ; @ATOM_PPLL0
l_.str.1:                               ; @.str.1
	.asciz	"unable to allocate a PPLL\n"

	.comm	_ATOM_PPLL2,4,2                 ; @ATOM_PPLL2
	.no_dead_strip	_dce_v11_0_pick_pll
.subsections_via_symbols
