	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function channel_waveform
_channel_waveform:                      ## @channel_waveform
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
                                        ## kill: def $edx killed $edx def $rdx
                                        ## kill: def $esi killed $esi def $rsi
	decl	%edx
	cmpl	$7, %edx
	ja	LBB0_6
## %bb.1:
	leaq	LJTI0_0(%rip), %rax
	movslq	(%rax,%rdx,4), %rcx
	addq	%rax, %rcx
	jmpq	*%rcx
LBB0_2:
	leal	256(,%rsi,8), %ecx
	andl	$504, %ecx                      ## imm = 0x1F8
	movl	$255, %eax
	subl	%ecx, %eax
	popq	%rbp
	retq
LBB0_3:
	testb	$32, %sil
	movl	$-255, %ecx
	movl	$255, %eax
	jmp	LBB0_4
LBB0_5:
	movl	(%rdi), %eax
	movl	%eax, %ecx
	shll	$6, %ecx
	addl	%eax, %ecx
	addl	$17, %ecx
                                        ## kill: def $eax killed $eax killed $rax
	sarl	$20, %eax
	addl	$-255, %eax
	andl	$536870911, %ecx                ## imm = 0x1FFFFFFF
	movl	%ecx, (%rdi)
	popq	%rbp
	retq
LBB0_6:
	movq	_sine_table@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	%esi, %ecx
	andl	$31, %ecx
	movl	(%rax,%rcx,4), %ecx
	movl	%ecx, %eax
	negl	%eax
	testb	$32, %sil
LBB0_4:
	cmovel	%ecx, %eax
	popq	%rbp
	retq
LBB0_7:
	leal	256(,%rsi,8), %eax
	andl	$504, %eax                      ## imm = 0x1F8
	addl	$-255, %eax
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
LJTI0_0:
	.long	L0_0_set_2
	.long	L0_0_set_3
	.long	L0_0_set_5
	.long	L0_0_set_6
	.long	L0_0_set_3
	.long	L0_0_set_7
	.long	L0_0_set_2
	.long	L0_0_set_5
	.end_data_region
                                        ## -- End function
	.comm	_sine_table,8,3                 ## @sine_table
	.no_dead_strip	_channel_waveform
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function channel_waveform
_channel_waveform:                      ; @channel_waveform
	.cfi_startproc
; %bb.0:
	sub	w9, w2, #1
	cmp	w9, #7
	b.hi	LBB0_5
; %bb.1:
Lloh0:
	adrp	x10, lJTI0_0@PAGE
Lloh1:
	add	x10, x10, lJTI0_0@PAGEOFF
	adr	x11, LBB0_2
	ldrb	w12, [x10, x9]
	add	x11, x11, x12, lsl #2
	br	x11
LBB0_2:
	lsl	w8, w1, #3
	add	w8, w8, #256
	and	w8, w8, #0x1f8
	mov	w9, #255
	sub	w0, w9, w8
	ret
LBB0_3:
	tst	w1, #0x20
	mov	w8, #-255
	cneg	w0, w8, ne
	ret
LBB0_4:
	mov	x8, x0
	ldr	w9, [x0]
	asr	w10, w9, #20
	sub	w0, w10, #255
	add	w9, w9, w9, lsl #6
	add	w9, w9, #17
	and	w9, w9, #0x1fffffff
	str	w9, [x8]
	ret
LBB0_5:
Lloh2:
	adrp	x8, _sine_table@GOTPAGE
Lloh3:
	ldr	x8, [x8, _sine_table@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	and	w9, w1, #0x1f
	ldr	w8, [x8, w9, uxtw #2]
	tst	w1, #0x20
	cneg	w0, w8, ne
	ret
LBB0_6:
	lsl	w8, w1, #3
	add	w8, w8, #256
	and	w8, w8, #0x1f8
	sub	w0, w8, #255
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_4-LBB0_2)>>2
	.byte	(LBB0_5-LBB0_2)>>2
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_6-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_4-LBB0_2)>>2
                                        ; -- End function
	.comm	_sine_table,8,3                 ; @sine_table
	.no_dead_strip	_channel_waveform
.subsections_via_symbols
