	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dce4_afmt_hdmi_write_speaker_allocation ## -- Begin function dce4_afmt_hdmi_write_speaker_allocation
	.p2align	4, 0x90
_dce4_afmt_hdmi_write_speaker_allocation: ## @dce4_afmt_hdmi_write_speaker_allocation
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	_AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edi, %edi
	callq	_RREG32_ENDPOINT
	movl	%eax, %ebx
	movq	_DP_CONNECTION@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	_SPEAKER_ALLOCATION_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	_HDMI_CONNECTION@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	testl	%r15d, %r15d
	je	LBB0_1
## %bb.2:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	jmp	LBB0_3
LBB0_1:
	movl	$5, %edi
LBB0_3:
	callq	_SPEAKER_ALLOCATION
	orl	%r14d, %r12d
	notl	%r12d
	andl	%r12d, %ebx
	orl	%r13d, %ebx
	orl	%eax, %ebx
	movq	_AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edi, %edi
	movl	%ebx, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_WREG32_ENDPOINT                ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER,4,2 ## @AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER
	.comm	_DP_CONNECTION,4,2              ## @DP_CONNECTION
	.comm	_SPEAKER_ALLOCATION_MASK,4,2    ## @SPEAKER_ALLOCATION_MASK
	.comm	_HDMI_CONNECTION,4,2            ## @HDMI_CONNECTION
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dce4_afmt_hdmi_write_speaker_allocation ; -- Begin function dce4_afmt_hdmi_write_speaker_allocation
	.p2align	2
_dce4_afmt_hdmi_write_speaker_allocation: ; @dce4_afmt_hdmi_write_speaker_allocation
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x21, x2
	mov	x20, x1
Lloh0:
	adrp	x22, _AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER@GOTPAGE
Lloh1:
	ldr	x22, [x22, _AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	w0, #0
	bl	_RREG32_ENDPOINT
	mov	x19, x0
Lloh2:
	adrp	x8, _DP_CONNECTION@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DP_CONNECTION@GOTPAGEOFF]
Lloh4:
	ldr	w23, [x8]
Lloh5:
	adrp	x8, _SPEAKER_ALLOCATION_MASK@GOTPAGE
Lloh6:
	ldr	x8, [x8, _SPEAKER_ALLOCATION_MASK@GOTPAGEOFF]
Lloh7:
	ldr	w24, [x8]
Lloh8:
	adrp	x8, _HDMI_CONNECTION@GOTPAGE
Lloh9:
	ldr	x8, [x8, _HDMI_CONNECTION@GOTPAGEOFF]
Lloh10:
	ldr	w25, [x8]
	cbz	w21, LBB0_2
; %bb.1:
	ldr	w0, [x20]
	b	LBB0_3
LBB0_2:
	mov	w0, #5
LBB0_3:
	bl	_SPEAKER_ALLOCATION
	orr	w8, w24, w23
	bic	w8, w19, w8
	orr	w8, w8, w25
	orr	w2, w8, w0
	ldr	w1, [x22]
	mov	w0, #0
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_WREG32_ENDPOINT
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER,4,2 ; @AZ_F0_CODEC_PIN0_CONTROL_CHANNEL_SPEAKER
	.comm	_DP_CONNECTION,4,2              ; @DP_CONNECTION
	.comm	_SPEAKER_ALLOCATION_MASK,4,2    ; @SPEAKER_ALLOCATION_MASK
	.comm	_HDMI_CONNECTION,4,2            ; @HDMI_CONNECTION
.subsections_via_symbols
