	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function loopback_prepare
_loopback_prepare:                      ## @loopback_prepare
	.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	%rdi, %r14
	movq	8(%rdi), %rbx
	movq	24(%rbx), %r15
	movq	64(%r15), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movl	20(%rbx), %edi
	callq	_snd_pcm_format_width
                                        ## kill: def $eax killed $eax def $rax
	imull	(%rbx), %eax
	leal	7(%rax), %r13d
	testl	%eax, %eax
	cmovnsl	%eax, %r13d
	sarl	$3, %r13d
	movl	4(%rbx), %r12d
	imull	%r13d, %r12d
	testl	%r12d, %r12d
	jle	LBB0_2
## %bb.1:
	cmpl	$7, %eax
	jle	LBB0_2
## %bb.3:
	movq	$0, 56(%r15)
	movl	8(%rbx), %esi
	movq	%rbx, %rdi
	callq	_frames_to_bytes
	movq	%rax, 40(%r15)
	movl	(%r14), %ecx
	movq	_SNDRV_PCM_STREAM_CAPTURE@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %ecx
	jne	LBB0_5
## %bb.4:
	movq	%rax, 48(%r15)
	movl	20(%rbx), %edi
	movl	(%rbx), %edx
	movl	16(%rbx), %esi
	imull	8(%rbx), %edx
	callq	_snd_pcm_format_set_silence
LBB0_5:
	xorps	%xmm0, %xmm0
	movups	%xmm0, 24(%r15)
	movl	%r12d, (%r15)
	movl	%r13d, 4(%r15)
	movl	12(%rbx), %esi
	movq	%rbx, %rdi
	callq	_frames_to_bytes
	movq	%rax, 16(%r15)
	movq	8(%r15), %rdi
	callq	_mutex_lock
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movl	(%rbx), %eax
	movb	(%r14), %cl
	btrl	%ecx, %eax
	testl	%eax, %eax
	je	LBB0_8
## %bb.6:
	movq	%r15, %rdi
	callq	_get_setup
	cmpq	$0, (%rax)
	je	LBB0_9
## %bb.7:
	movl	(%r14), %eax
	movq	_SNDRV_PCM_STREAM_PLAYBACK@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_9
LBB0_8:
	movq	%r14, %rdi
	callq	_params_change
LBB0_9:
	movb	(%r14), %cl
	movl	$1, %eax
	shll	%cl, %eax
	orl	%eax, (%rbx)
	movq	8(%r15), %rdi
	callq	_mutex_unlock
	xorl	%eax, %eax
	jmp	LBB0_10
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_SNDRV_PCM_STREAM_CAPTURE,4,2   ## @SNDRV_PCM_STREAM_CAPTURE
	.comm	_SNDRV_PCM_STREAM_PLAYBACK,4,2  ## @SNDRV_PCM_STREAM_PLAYBACK
	.no_dead_strip	_loopback_prepare
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function loopback_prepare
_loopback_prepare:                      ; @loopback_prepare
	.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, x0
	ldr	x21, [x0, #8]
	ldr	x19, [x21, #24]
	ldr	x22, [x19, #64]
	ldr	w0, [x21, #20]
	bl	_snd_pcm_format_width
	ldp	w8, w9, [x21]
	mul	w8, w8, w0
	add	w10, w8, #7
	cmp	w8, #0
	csel	w10, w10, w8, lt
	asr	w23, w10, #3
	mul	w24, w23, w9
	cmp	w24, #1
	ccmp	w8, #7, #4, ge
	b.gt	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_9
LBB0_2:
	str	xzr, [x19, #56]
	ldr	w1, [x21, #8]
	mov	x0, x21
	bl	_frames_to_bytes
	str	x0, [x19, #40]
	ldr	w8, [x20]
Lloh3:
	adrp	x9, _SNDRV_PCM_STREAM_CAPTURE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _SNDRV_PCM_STREAM_CAPTURE@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_4
; %bb.3:
	str	x0, [x19, #48]
	ldp	w1, w0, [x21, #16]
	ldr	w8, [x21, #8]
	ldr	w9, [x21]
	mul	w2, w9, w8
	bl	_snd_pcm_format_set_silence
LBB0_4:
	stp	xzr, xzr, [x19, #24]
	stp	w24, w23, [x19]
	ldr	w1, [x21, #12]
	mov	x0, x21
	bl	_frames_to_bytes
	str	x0, [x19, #16]
	ldr	x0, [x19, #8]
	bl	_mutex_lock
	ldr	w8, [x22]
	ldr	w9, [x20]
	mov	w10, #1
	lsl	w9, w10, w9
	bics	wzr, w8, w9
	b.eq	LBB0_7
; %bb.5:
	mov	x0, x19
	bl	_get_setup
	ldr	x8, [x0]
	cbz	x8, LBB0_8
; %bb.6:
	ldr	w8, [x20]
Lloh6:
	adrp	x9, _SNDRV_PCM_STREAM_PLAYBACK@GOTPAGE
Lloh7:
	ldr	x9, [x9, _SNDRV_PCM_STREAM_PLAYBACK@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_8
LBB0_7:
	mov	x0, x20
	bl	_params_change
LBB0_8:
	ldr	w8, [x20]
	mov	w9, #1
	lsl	w8, w9, w8
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
	ldr	x0, [x19, #8]
	bl	_mutex_unlock
	mov	w0, #0
LBB0_9:
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_SNDRV_PCM_STREAM_CAPTURE,4,2   ; @SNDRV_PCM_STREAM_CAPTURE
	.comm	_SNDRV_PCM_STREAM_PLAYBACK,4,2  ; @SNDRV_PCM_STREAM_PLAYBACK
	.no_dead_strip	_loopback_prepare
.subsections_via_symbols
