	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ca0132_set_vipsource
_ca0132_set_vipsource:                  ## @ca0132_set_vipsource
	.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
	movq	(%rbx), %rcx
	movq	_DSP_DOWNLOADED@GOTPCREL(%rip), %rdx
	xorl	%eax, %eax
	cmpq	(%rdx), %rcx
	jne	LBB0_11
## %bb.1:
	movl	%esi, %r14d
	movq	%rdi, %r15
	testl	%esi, %esi
	je	LBB0_3
## %bb.2:
	movq	16(%rbx), %rax
	movq	_CRYSTAL_VOICE@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	_EFFECT_START_NID@GOTPCREL(%rip), %rdx
	subq	(%rdx), %rcx
	cmpl	$0, (%rax,%rcx,4)
	je	LBB0_3
## %bb.7:
	movq	_MEM_CONNID_MICIN1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_SR_16_000@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	movq	%r15, %rdi
	callq	_chipio_set_conn_rate
	movq	_MEM_CONNID_MICOUT1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r12), %edx
	movq	%r15, %rdi
	callq	_chipio_set_conn_rate
	movq	8(%rbx), %rcx
	movq	_DIGITAL_MIC@GOTPCREL(%rip), %rdx
	movq	_FLOAT_ONE@GOTPCREL(%rip), %rbx
	movq	%rbx, %rax
	cmpq	(%rdx), %rcx
	jne	LBB0_9
## %bb.8:
	movq	_FLOAT_TWO@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %ecx
	movq	%r15, %rdi
	movl	$128, %esi
	xorl	%edx, %edx
	callq	_dspio_set_uint_param
	movl	(%rbx), %ecx
	movq	%r15, %rdi
	movl	$128, %esi
	movl	$5, %edx
	callq	_dspio_set_uint_param
	movl	$20, %edi
	callq	_msleep
	movq	_CONTROL_PARAM_VIP_SOURCE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%r14d, %edx
	callq	_chipio_set_control_param
	jmp	LBB0_10
LBB0_3:
	movq	_CONTROL_PARAM_VIP_SOURCE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_chipio_set_control_param
	movq	_MEM_CONNID_MICIN1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_SR_96_000@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	movq	%r15, %rdi
	callq	_chipio_set_conn_rate
	movq	_MEM_CONNID_MICOUT1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r14), %edx
	movq	%r15, %rdi
	callq	_chipio_set_conn_rate
	movq	8(%rbx), %rax
	movq	_DIGITAL_MIC@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
## %bb.5:
	movq	_FLOAT_TWO@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_4:
	movq	_FLOAT_ONE@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %ecx
	movq	%r15, %rdi
	movl	$128, %esi
	xorl	%edx, %edx
	callq	_dspio_set_uint_param
	movq	_FLOAT_ZERO@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r15, %rdi
	movl	$128, %esi
	movl	$5, %edx
	callq	_dspio_set_uint_param
LBB0_10:
	movl	$1, %eax
LBB0_11:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DSP_DOWNLOADED,8,3             ## @DSP_DOWNLOADED
	.comm	_CRYSTAL_VOICE,8,3              ## @CRYSTAL_VOICE
	.comm	_EFFECT_START_NID,8,3           ## @EFFECT_START_NID
	.comm	_CONTROL_PARAM_VIP_SOURCE,4,2   ## @CONTROL_PARAM_VIP_SOURCE
	.comm	_MEM_CONNID_MICIN1,4,2          ## @MEM_CONNID_MICIN1
	.comm	_SR_96_000,4,2                  ## @SR_96_000
	.comm	_MEM_CONNID_MICOUT1,4,2         ## @MEM_CONNID_MICOUT1
	.comm	_DIGITAL_MIC,8,3                ## @DIGITAL_MIC
	.comm	_FLOAT_TWO,4,2                  ## @FLOAT_TWO
	.comm	_FLOAT_ONE,4,2                  ## @FLOAT_ONE
	.comm	_FLOAT_ZERO,4,2                 ## @FLOAT_ZERO
	.comm	_SR_16_000,4,2                  ## @SR_16_000
	.no_dead_strip	_ca0132_set_vipsource
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ca0132_set_vipsource
_ca0132_set_vipsource:                  ; @ca0132_set_vipsource
	.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
	ldr	x21, [x0]
	ldr	x8, [x21]
Lloh0:
	adrp	x9, _DSP_DOWNLOADED@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DSP_DOWNLOADED@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.1:
	mov	x20, x1
	mov	x19, x0
	cbz	w1, LBB0_5
; %bb.2:
	ldr	x8, [x21, #16]
Lloh3:
	adrp	x9, _CRYSTAL_VOICE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _CRYSTAL_VOICE@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
Lloh6:
	adrp	x10, _EFFECT_START_NID@GOTPAGE
Lloh7:
	ldr	x10, [x10, _EFFECT_START_NID@GOTPAGEOFF]
Lloh8:
	ldr	x10, [x10]
	sub	x9, x9, x10
	ldr	w8, [x8, x9, lsl #2]
	cbz	w8, LBB0_5
; %bb.3:
Lloh9:
	adrp	x8, _MEM_CONNID_MICIN1@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MEM_CONNID_MICIN1@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x22, _SR_16_000@GOTPAGE
Lloh13:
	ldr	x22, [x22, _SR_16_000@GOTPAGEOFF]
	ldr	w2, [x22]
	mov	x0, x19
	bl	_chipio_set_conn_rate
Lloh14:
	adrp	x8, _MEM_CONNID_MICOUT1@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MEM_CONNID_MICOUT1@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	ldr	w2, [x22]
	mov	x0, x19
	bl	_chipio_set_conn_rate
	ldr	x8, [x21, #8]
Lloh17:
	adrp	x9, _DIGITAL_MIC@GOTPAGE
Lloh18:
	ldr	x9, [x9, _DIGITAL_MIC@GOTPAGEOFF]
Lloh19:
	adrp	x10, _FLOAT_TWO@GOTPAGE
Lloh20:
	ldr	x10, [x10, _FLOAT_TWO@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
Lloh22:
	adrp	x21, _FLOAT_ONE@GOTPAGE
Lloh23:
	ldr	x21, [x21, _FLOAT_ONE@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x10, x21, eq
	ldr	w3, [x8]
	mov	x0, x19
	mov	w1, #128
	mov	w2, #0
	bl	_dspio_set_uint_param
	ldr	w3, [x21]
	mov	x0, x19
	mov	w1, #128
	mov	w2, #5
	bl	_dspio_set_uint_param
	mov	w0, #20
	bl	_msleep
Lloh24:
	adrp	x8, _CONTROL_PARAM_VIP_SOURCE@GOTPAGE
Lloh25:
	ldr	x8, [x8, _CONTROL_PARAM_VIP_SOURCE@GOTPAGEOFF]
Lloh26:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_chipio_set_control_param
	b	LBB0_6
LBB0_4:
	mov	w0, #0
	b	LBB0_7
LBB0_5:
Lloh27:
	adrp	x8, _CONTROL_PARAM_VIP_SOURCE@GOTPAGE
Lloh28:
	ldr	x8, [x8, _CONTROL_PARAM_VIP_SOURCE@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_chipio_set_control_param
Lloh30:
	adrp	x8, _MEM_CONNID_MICIN1@GOTPAGE
Lloh31:
	ldr	x8, [x8, _MEM_CONNID_MICIN1@GOTPAGEOFF]
Lloh32:
	ldr	w1, [x8]
Lloh33:
	adrp	x20, _SR_96_000@GOTPAGE
Lloh34:
	ldr	x20, [x20, _SR_96_000@GOTPAGEOFF]
	ldr	w2, [x20]
	mov	x0, x19
	bl	_chipio_set_conn_rate
Lloh35:
	adrp	x8, _MEM_CONNID_MICOUT1@GOTPAGE
Lloh36:
	ldr	x8, [x8, _MEM_CONNID_MICOUT1@GOTPAGEOFF]
Lloh37:
	ldr	w1, [x8]
	ldr	w2, [x20]
	mov	x0, x19
	bl	_chipio_set_conn_rate
	ldr	x8, [x21, #8]
Lloh38:
	adrp	x9, _DIGITAL_MIC@GOTPAGE
Lloh39:
	ldr	x9, [x9, _DIGITAL_MIC@GOTPAGEOFF]
Lloh40:
	adrp	x10, _FLOAT_TWO@GOTPAGE
Lloh41:
	ldr	x10, [x10, _FLOAT_TWO@GOTPAGEOFF]
Lloh42:
	ldr	x9, [x9]
Lloh43:
	adrp	x11, _FLOAT_ONE@GOTPAGE
Lloh44:
	ldr	x11, [x11, _FLOAT_ONE@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x10, x11, eq
	ldr	w3, [x8]
	mov	x0, x19
	mov	w1, #128
	mov	w2, #0
	bl	_dspio_set_uint_param
Lloh45:
	adrp	x8, _FLOAT_ZERO@GOTPAGE
Lloh46:
	ldr	x8, [x8, _FLOAT_ZERO@GOTPAGEOFF]
Lloh47:
	ldr	w3, [x8]
	mov	x0, x19
	mov	w1, #128
	mov	w2, #5
	bl	_dspio_set_uint_param
LBB0_6:
	mov	w0, #1
LBB0_7:
	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	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh21
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh43, Lloh44
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh42
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_DSP_DOWNLOADED,8,3             ; @DSP_DOWNLOADED
	.comm	_CRYSTAL_VOICE,8,3              ; @CRYSTAL_VOICE
	.comm	_EFFECT_START_NID,8,3           ; @EFFECT_START_NID
	.comm	_CONTROL_PARAM_VIP_SOURCE,4,2   ; @CONTROL_PARAM_VIP_SOURCE
	.comm	_MEM_CONNID_MICIN1,4,2          ; @MEM_CONNID_MICIN1
	.comm	_SR_96_000,4,2                  ; @SR_96_000
	.comm	_MEM_CONNID_MICOUT1,4,2         ; @MEM_CONNID_MICOUT1
	.comm	_DIGITAL_MIC,8,3                ; @DIGITAL_MIC
	.comm	_FLOAT_TWO,4,2                  ; @FLOAT_TWO
	.comm	_FLOAT_ONE,4,2                  ; @FLOAT_ONE
	.comm	_FLOAT_ZERO,4,2                 ; @FLOAT_ZERO
	.comm	_SR_16_000,4,2                  ; @SR_16_000
	.no_dead_strip	_ca0132_set_vipsource
.subsections_via_symbols
