	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_snd_trident_free_voice         ## -- Begin function snd_trident_free_voice
	.p2align	4, 0x90
_snd_trident_free_voice:                ## @snd_trident_free_voice
	.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
	testq	%rsi, %rsi
	je	LBB0_7
## %bb.1:
	movq	%rsi, %rbx
	cmpq	$0, 72(%rsi)
	je	LBB0_7
## %bb.2:
	movq	%rdi, %r14
	movl	80(%rbx), %edx
	movl	%edx, %esi
	callq	_snd_trident_clear_voices
	movq	%r14, %rdi
	callq	_spin_lock_irqsave
	movq	(%rbx), %r15
	movq	$0, (%rbx)
	movq	$0, 88(%rbx)
	cmpq	$0, 64(%rbx)
	je	LBB0_4
## %bb.3:
	movl	80(%rbx), %esi
	movq	%r14, %rdi
	callq	_snd_trident_free_pcm_channel
LBB0_4:
	cmpq	$0, 56(%rbx)
	je	LBB0_6
## %bb.5:
	movl	80(%rbx), %esi
	movq	%r14, %rdi
	callq	_snd_trident_free_synth_channel
LBB0_6:
	xorps	%xmm0, %xmm0
	movups	%xmm0, 56(%rbx)
	movups	%xmm0, 40(%rbx)
	movups	%xmm0, 24(%rbx)
	movups	%xmm0, 8(%rbx)
	movq	$0, 72(%rbx)
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	testq	%r15, %r15
	je	LBB0_7
## %bb.8:
	movq	%r15, %rax
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmpq	*%rax                           ## TAILCALL
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_snd_trident_free_voice         ; -- Begin function snd_trident_free_voice
	.p2align	2
_snd_trident_free_voice:                ; @snd_trident_free_voice
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	cbz	x1, LBB0_8
; %bb.1:
	mov	x19, x1
	ldr	x8, [x1, #72]
	cbz	x8, LBB0_8
; %bb.2:
	mov	x20, x0
	ldr	w1, [x19, #80]
	mov	x2, x1
	bl	_snd_trident_clear_voices
	mov	x0, x20
	bl	_spin_lock_irqsave
	ldr	x0, [x19]
	str	x0, [sp, #8]                    ; 8-byte Folded Spill
	str	xzr, [x19]
	str	xzr, [x19, #88]
	ldr	x8, [x19, #64]
	cbz	x8, LBB0_4
; %bb.3:
	ldr	w1, [x19, #80]
	mov	x0, x20
	bl	_snd_trident_free_pcm_channel
LBB0_4:
	ldr	x8, [x19, #56]
	cbz	x8, LBB0_6
; %bb.5:
	ldr	w1, [x19, #80]
	mov	x0, x20
	bl	_snd_trident_free_synth_channel
LBB0_6:
	str	xzr, [x19, #72]
	movi.2d	v0, #0000000000000000
	stur	q0, [x19, #56]
	stur	q0, [x19, #40]
	stur	q0, [x19, #24]
	stur	q0, [x19, #8]
	mov	x0, x20
	bl	_spin_unlock_irqrestore
	ldr	x1, [sp, #8]                    ; 8-byte Folded Reload
	cbz	x1, LBB0_8
; %bb.7:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	br	x1
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
