	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hal2_gain_put
_hal2_gain_put:                         ## @hal2_gain_put
	.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
	movq	%rsi, %r15
	movq	%rdi, %rbx
	callq	_snd_kcontrol_chip
	movq	(%r15), %rcx
	movl	(%rcx), %r12d
	movl	4(%rcx), %r13d
	movl	(%rbx), %ecx
	cmpl	$129, %ecx
	je	LBB0_4
## %bb.1:
                                        ## implicit-def: $edx
                                        ## implicit-def: $ebx
	cmpl	$128, %ecx
	jne	LBB0_8
## %bb.2:
	movq	_H2I_DAC_C2@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_hal2_i_read32
	movq	_H2I_C2_L_ATT_M@GOTPCREL(%rip), %rdx
	movq	_H2I_C2_R_ATT_M@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rdx), %ebx
	movq	_H2I_C2_MUTE@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	movl	%r13d, %ecx
	orl	%r12d, %ecx
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	je	LBB0_5
## %bb.3:
	notl	%ebx
	andl	%ebx, %eax
	movl	$31, %ebx
	movl	$31, %edx
	subl	%r12d, %edx
	movq	_H2I_C2_L_ATT_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %edx
	subl	%r13d, %ebx
	orl	%eax, %edx
	movq	_H2I_C2_R_ATT_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %ebx
	orl	%edx, %ebx
	jmp	LBB0_6
LBB0_4:
	movq	_H2I_ADC_C2@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_hal2_i_read32
	movq	_H2I_C2_L_GAIN_M@GOTPCREL(%rip), %rsi
	movq	_H2I_C2_R_GAIN_M@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rsi), %edx
	notl	%edx
	movq	_H2I_C2_L_GAIN_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	shll	%cl, %r12d
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	andl	%eax, %edx
	orl	%edx, %r12d
	movq	_H2I_C2_R_GAIN_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %r13d
	orl	%r12d, %r13d
	movl	%r13d, %ebx
	jmp	LBB0_7
LBB0_5:
	orl	%eax, %ebx
LBB0_6:
	movq	_H2I_DAC_C2@GOTPCREL(%rip), %r14
LBB0_7:
	movl	(%r14), %esi
	movq	%r15, %rdi
	movl	%ebx, %edx
	callq	_hal2_i_write32
	movl	-44(%rbp), %edx                 ## 4-byte Reload
LBB0_8:
	xorl	%eax, %eax
	cmpl	%ebx, %edx
	setne	%al
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_H2I_DAC_C2,4,2                 ## @H2I_DAC_C2
	.comm	_H2I_C2_L_ATT_M,4,2             ## @H2I_C2_L_ATT_M
	.comm	_H2I_C2_R_ATT_M,4,2             ## @H2I_C2_R_ATT_M
	.comm	_H2I_C2_MUTE,4,2                ## @H2I_C2_MUTE
	.comm	_H2I_C2_L_ATT_SHIFT,4,2         ## @H2I_C2_L_ATT_SHIFT
	.comm	_H2I_C2_R_ATT_SHIFT,4,2         ## @H2I_C2_R_ATT_SHIFT
	.comm	_H2I_ADC_C2,4,2                 ## @H2I_ADC_C2
	.comm	_H2I_C2_L_GAIN_M,4,2            ## @H2I_C2_L_GAIN_M
	.comm	_H2I_C2_R_GAIN_M,4,2            ## @H2I_C2_R_GAIN_M
	.comm	_H2I_C2_L_GAIN_SHIFT,4,2        ## @H2I_C2_L_GAIN_SHIFT
	.comm	_H2I_C2_R_GAIN_SHIFT,4,2        ## @H2I_C2_R_GAIN_SHIFT
	.no_dead_strip	_hal2_gain_put
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hal2_gain_put
_hal2_gain_put:                         ; @hal2_gain_put
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x20, x1
	mov	x21, x0
	bl	_snd_kcontrol_chip
	mov	x19, x0
	ldr	x8, [x20]
	ldp	w23, w22, [x8]
	ldr	w8, [x21]
	cmp	w8, #129
	b.eq	LBB0_4
; %bb.1:
                                        ; implicit-def: $w20
                                        ; implicit-def: $w21
	cmp	w8, #128
	b.ne	LBB0_8
; %bb.2:
Lloh0:
	adrp	x8, _H2I_DAC_C2@GOTPAGE
Lloh1:
	ldr	x8, [x8, _H2I_DAC_C2@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_hal2_i_read32
	mov	x20, x0
Lloh3:
	adrp	x8, _H2I_C2_L_ATT_M@GOTPAGE
Lloh4:
	ldr	x8, [x8, _H2I_C2_L_ATT_M@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _H2I_C2_R_ATT_M@GOTPAGE
Lloh7:
	ldr	x9, [x9, _H2I_C2_R_ATT_M@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh9:
	adrp	x9, _H2I_C2_MUTE@GOTPAGE
Lloh10:
	ldr	x9, [x9, _H2I_C2_MUTE@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	orr	w8, w8, w9
	orr	w9, w22, w23
	cbz	w9, LBB0_5
; %bb.3:
	bic	w8, w20, w8
	mov	w9, #31
	sub	w10, w9, w23
	sub	w9, w9, w22
Lloh12:
	adrp	x11, _H2I_C2_L_ATT_SHIFT@GOTPAGE
Lloh13:
	ldr	x11, [x11, _H2I_C2_L_ATT_SHIFT@GOTPAGEOFF]
Lloh14:
	ldr	w11, [x11]
	lsl	w10, w10, w11
Lloh15:
	adrp	x11, _H2I_C2_R_ATT_SHIFT@GOTPAGE
Lloh16:
	ldr	x11, [x11, _H2I_C2_R_ATT_SHIFT@GOTPAGEOFF]
	orr	w8, w10, w8
Lloh17:
	ldr	w10, [x11]
	lsl	w9, w9, w10
	orr	w21, w8, w9
	b	LBB0_6
LBB0_4:
Lloh18:
	adrp	x24, _H2I_ADC_C2@GOTPAGE
Lloh19:
	ldr	x24, [x24, _H2I_ADC_C2@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x0, x19
	bl	_hal2_i_read32
	mov	x20, x0
Lloh20:
	adrp	x8, _H2I_C2_L_GAIN_M@GOTPAGE
Lloh21:
	ldr	x8, [x8, _H2I_C2_L_GAIN_M@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
Lloh23:
	adrp	x9, _H2I_C2_R_GAIN_M@GOTPAGE
Lloh24:
	ldr	x9, [x9, _H2I_C2_R_GAIN_M@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	orr	w8, w9, w8
	bic	w8, w0, w8
Lloh26:
	adrp	x9, _H2I_C2_L_GAIN_SHIFT@GOTPAGE
Lloh27:
	ldr	x9, [x9, _H2I_C2_L_GAIN_SHIFT@GOTPAGEOFF]
Lloh28:
	ldr	w9, [x9]
	lsl	w9, w23, w9
	orr	w8, w8, w9
Lloh29:
	adrp	x9, _H2I_C2_R_GAIN_SHIFT@GOTPAGE
Lloh30:
	ldr	x9, [x9, _H2I_C2_R_GAIN_SHIFT@GOTPAGEOFF]
Lloh31:
	ldr	w9, [x9]
	lsl	w9, w22, w9
	orr	w21, w8, w9
	b	LBB0_7
LBB0_5:
	orr	w21, w8, w20
LBB0_6:
Lloh32:
	adrp	x24, _H2I_DAC_C2@GOTPAGE
Lloh33:
	ldr	x24, [x24, _H2I_DAC_C2@GOTPAGEOFF]
LBB0_7:
	ldr	w1, [x24]
	mov	x0, x19
	mov	x2, x21
	bl	_hal2_i_write32
LBB0_8:
	cmp	w20, w21
	cset	w0, ne
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh32, Lloh33
	.cfi_endproc
                                        ; -- End function
	.comm	_H2I_DAC_C2,4,2                 ; @H2I_DAC_C2
	.comm	_H2I_C2_L_ATT_M,4,2             ; @H2I_C2_L_ATT_M
	.comm	_H2I_C2_R_ATT_M,4,2             ; @H2I_C2_R_ATT_M
	.comm	_H2I_C2_MUTE,4,2                ; @H2I_C2_MUTE
	.comm	_H2I_C2_L_ATT_SHIFT,4,2         ; @H2I_C2_L_ATT_SHIFT
	.comm	_H2I_C2_R_ATT_SHIFT,4,2         ; @H2I_C2_R_ATT_SHIFT
	.comm	_H2I_ADC_C2,4,2                 ; @H2I_ADC_C2
	.comm	_H2I_C2_L_GAIN_M,4,2            ; @H2I_C2_L_GAIN_M
	.comm	_H2I_C2_R_GAIN_M,4,2            ; @H2I_C2_R_GAIN_M
	.comm	_H2I_C2_L_GAIN_SHIFT,4,2        ; @H2I_C2_L_GAIN_SHIFT
	.comm	_H2I_C2_R_GAIN_SHIFT,4,2        ; @H2I_C2_R_GAIN_SHIFT
	.no_dead_strip	_hal2_gain_put
.subsections_via_symbols
