	.file	"840351.c"
	.intel_syntax noprefix
	.text
	.type	myrnd, @function
myrnd:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	imul	eax, eax, 314159
	add	eax, 1
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -28[rbp], 256
	jne	.L2
	mov	eax, DWORD PTR -4[rbp]
	shr	eax, 24
	mov	DWORD PTR -8[rbp], eax
	jmp	.L3
.L2:
	mov	ecx, DWORD PTR -28[rbp]
	mov	eax, DWORD PTR -4[rbp]
	mov	edx, 0
	div	ecx
	mov	DWORD PTR -8[rbp], edx
.L3:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	mov	DWORD PTR [rax], edx
	mov	eax, DWORD PTR -8[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	myrnd, .-myrnd
	.section	.rodata
	.align 32
	.type	cos_table, @object
	.size	cos_table, 260
cos_table:
	.value	-32768
	.value	32766
	.value	32758
	.value	32746
	.value	32729
	.value	32706
	.value	32679
	.value	32647
	.value	32610
	.value	32568
	.value	32522
	.value	32470
	.value	32413
	.value	32352
	.value	32286
	.value	32214
	.value	32138
	.value	32058
	.value	31972
	.value	31881
	.value	31786
	.value	31686
	.value	31581
	.value	31471
	.value	31357
	.value	31238
	.value	31114
	.value	30986
	.value	30853
	.value	30715
	.value	30572
	.value	30425
	.value	30274
	.value	30118
	.value	29957
	.value	29792
	.value	29622
	.value	29448
	.value	29269
	.value	29086
	.value	28899
	.value	28707
	.value	28511
	.value	28311
	.value	28106
	.value	27897
	.value	27684
	.value	27467
	.value	27246
	.value	27020
	.value	26791
	.value	26557
	.value	26320
	.value	26078
	.value	25833
	.value	25583
	.value	25330
	.value	25073
	.value	24812
	.value	24548
	.value	24279
	.value	24008
	.value	23732
	.value	23453
	.value	23170
	.value	22884
	.value	22595
	.value	22302
	.value	22006
	.value	21706
	.value	21403
	.value	21097
	.value	20788
	.value	20475
	.value	20160
	.value	19841
	.value	19520
	.value	19195
	.value	18868
	.value	18538
	.value	18205
	.value	17869
	.value	17531
	.value	17190
	.value	16846
	.value	16500
	.value	16151
	.value	15800
	.value	15447
	.value	15091
	.value	14733
	.value	14373
	.value	14010
	.value	13646
	.value	13279
	.value	12910
	.value	12540
	.value	12167
	.value	11793
	.value	11417
	.value	11039
	.value	10660
	.value	10279
	.value	9896
	.value	9512
	.value	9127
	.value	8740
	.value	8351
	.value	7962
	.value	7571
	.value	7180
	.value	6787
	.value	6393
	.value	5998
	.value	5602
	.value	5205
	.value	4808
	.value	4410
	.value	4011
	.value	3612
	.value	3212
	.value	2811
	.value	2411
	.value	2009
	.value	1608
	.value	1206
	.value	804
	.value	402
	.value	0
	.value	0
	.text
	.type	int_cos, @function
int_cos:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -36[rbp], edi
	and	DWORD PTR -36[rbp], 65535
	cmp	DWORD PTR -36[rbp], 32767
	jle	.L6
	mov	eax, 65536
	sub	eax, DWORD PTR -36[rbp]
	mov	DWORD PTR -36[rbp], eax
.L6:
	mov	DWORD PTR -20[rbp], 0
	cmp	DWORD PTR -36[rbp], 16384
	jle	.L7
	mov	DWORD PTR -20[rbp], -1
	mov	eax, 32768
	sub	eax, DWORD PTR -36[rbp]
	mov	DWORD PTR -36[rbp], eax
.L7:
	mov	eax, DWORD PTR -36[rbp]
	sar	eax, 7
	cdqe
	lea	rdx, [rax+rax]
	lea	rax, cos_table[rip]
	add	rax, rdx
	mov	QWORD PTR -8[rbp], rax
	mov	eax, DWORD PTR -36[rbp]
	and	eax, 127
	mov	DWORD PTR -16[rbp], eax
	mov	rax, QWORD PTR -8[rbp]
	movzx	eax, WORD PTR [rax]
	movzx	ecx, ax
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 2
	movzx	eax, WORD PTR [rax]
	movzx	edx, ax
	mov	rax, QWORD PTR -8[rbp]
	movzx	eax, WORD PTR [rax]
	movzx	esi, ax
	mov	eax, edx
	sub	eax, esi
	imul	eax, DWORD PTR -16[rbp]
	add	eax, 64
	sar	eax, 7
	add	eax, ecx
	mov	DWORD PTR -12[rbp], eax
	mov	eax, DWORD PTR -12[rbp]
	xor	eax, DWORD PTR -20[rbp]
	sub	eax, DWORD PTR -20[rbp]
	mov	DWORD PTR -12[rbp], eax
	sal	DWORD PTR -12[rbp]
	mov	eax, DWORD PTR -12[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	int_cos, .-int_cos
	.globl	outfile
	.bss
	.align 8
	.type	outfile, @object
	.size	outfile, 8
outfile:
	.zero	8
	.text
	.type	put_sample, @function
put_sample:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	DWORD PTR -4[rbp], edi
	mov	rdx, QWORD PTR outfile[rip]
	mov	eax, DWORD PTR -4[rbp]
	movzx	eax, al
	mov	rsi, rdx
	mov	edi, eax
	call	fputc@PLT
	mov	rdx, QWORD PTR outfile[rip]
	mov	eax, DWORD PTR -4[rbp]
	sar	eax, 8
	movzx	eax, al
	mov	rsi, rdx
	mov	edi, eax
	call	fputc@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	put_sample, .-put_sample
	.section	.rodata
	.align 8
.LC0:
	.string	"usage: %s file [<sample rate> [<channels>]]\ngenerate a test raw 16 bit audio stream\ndefault: 44100 Hz stereo\n"
.LC1:
	.string	"invalid sample rate: %d\n"
	.align 8
.LC2:
	.string	"invalid number of channels: %d\n"
.LC3:
	.string	"wb"
	.text
	.globl	main
	.type	main, @function
main:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 176
	mov	DWORD PTR -164[rbp], edi
	mov	QWORD PTR -176[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -152[rbp], 1
	mov	DWORD PTR -128[rbp], 44100
	mov	DWORD PTR -124[rbp], 2
	cmp	DWORD PTR -164[rbp], 1
	jle	.L11
	cmp	DWORD PTR -164[rbp], 4
	jle	.L12
.L11:
	mov	rax, QWORD PTR -176[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L12:
	cmp	DWORD PTR -164[rbp], 2
	jle	.L13
	mov	rax, QWORD PTR -176[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -128[rbp], eax
	cmp	DWORD PTR -128[rbp], 0
	jg	.L13
	mov	rax, QWORD PTR stderr[rip]
	mov	edx, DWORD PTR -128[rbp]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L45
.L13:
	cmp	DWORD PTR -164[rbp], 3
	jle	.L15
	mov	rax, QWORD PTR -176[rbp]
	add	rax, 24
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -124[rbp], eax
	cmp	DWORD PTR -124[rbp], 0
	jle	.L16
	cmp	DWORD PTR -124[rbp], 8
	jle	.L15
.L16:
	mov	rax, QWORD PTR stderr[rip]
	mov	edx, DWORD PTR -124[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 1
	jmp	.L45
.L15:
	mov	rax, QWORD PTR -176[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR outfile[rip], rax
	mov	rax, QWORD PTR outfile[rip]
	test	rax, rax
	jne	.L17
	mov	rax, QWORD PTR -176[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	perror@PLT
	mov	eax, 1
	jmp	.L45
.L17:
	mov	DWORD PTR -144[rbp], 0
	mov	DWORD PTR -148[rbp], 0
	jmp	.L18
.L21:
	mov	eax, DWORD PTR -144[rbp]
	mov	edi, eax
	call	int_cos
	imul	eax, eax, 10000
	sar	eax, 16
	mov	DWORD PTR -120[rbp], eax
	mov	DWORD PTR -140[rbp], 0
	jmp	.L19
.L20:
	mov	eax, DWORD PTR -120[rbp]
	mov	edi, eax
	call	put_sample
	add	DWORD PTR -140[rbp], 1
.L19:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -124[rbp]
	jl	.L20
	mov	eax, 65536000
	cdq
	idiv	DWORD PTR -128[rbp]
	add	DWORD PTR -144[rbp], eax
	add	DWORD PTR -148[rbp], 1
.L18:
	mov	eax, DWORD PTR -148[rbp]
	cmp	eax, DWORD PTR -128[rbp]
	jl	.L21
	mov	DWORD PTR -144[rbp], 0
	mov	DWORD PTR -148[rbp], 0
	jmp	.L22
.L25:
	mov	eax, DWORD PTR -144[rbp]
	mov	edi, eax
	call	int_cos
	imul	eax, eax, 10000
	sar	eax, 16
	mov	DWORD PTR -120[rbp], eax
	mov	DWORD PTR -140[rbp], 0
	jmp	.L23
.L24:
	mov	eax, DWORD PTR -120[rbp]
	mov	edi, eax
	call	put_sample
	add	DWORD PTR -140[rbp], 1
.L23:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -124[rbp]
	jl	.L24
	mov	eax, DWORD PTR -148[rbp]
	imul	eax, eax, 9900
	cdq
	idiv	DWORD PTR -128[rbp]
	add	eax, 100
	mov	DWORD PTR -116[rbp], eax
	mov	eax, DWORD PTR -116[rbp]
	sal	eax, 16
	cdq
	idiv	DWORD PTR -128[rbp]
	add	DWORD PTR -144[rbp], eax
	add	DWORD PTR -148[rbp], 1
.L22:
	mov	eax, DWORD PTR -148[rbp]
	cmp	eax, DWORD PTR -128[rbp]
	jl	.L25
	mov	DWORD PTR -148[rbp], 0
	jmp	.L26
.L29:
	lea	rax, -152[rbp]
	mov	esi, 20000
	mov	rdi, rax
	call	myrnd
	sub	eax, 10000
	mov	DWORD PTR -120[rbp], eax
	mov	DWORD PTR -140[rbp], 0
	jmp	.L27
.L28:
	mov	eax, DWORD PTR -120[rbp]
	mov	edi, eax
	call	put_sample
	add	DWORD PTR -140[rbp], 1
.L27:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -124[rbp]
	jl	.L28
	add	DWORD PTR -148[rbp], 1
.L26:
	mov	eax, DWORD PTR -128[rbp]
	mov	edx, eax
	shr	edx, 31
	add	eax, edx
	sar	eax
	cmp	DWORD PTR -148[rbp], eax
	jl	.L29
	mov	DWORD PTR -148[rbp], 0
	jmp	.L30
.L33:
	lea	rax, -152[rbp]
	mov	esi, 65535
	mov	rdi, rax
	call	myrnd
	sub	eax, 32768
	mov	DWORD PTR -120[rbp], eax
	mov	DWORD PTR -140[rbp], 0
	jmp	.L31
.L32:
	mov	eax, DWORD PTR -120[rbp]
	mov	edi, eax
	call	put_sample
	add	DWORD PTR -140[rbp], 1
.L31:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -124[rbp]
	jl	.L32
	add	DWORD PTR -148[rbp], 1
.L30:
	mov	eax, DWORD PTR -128[rbp]
	mov	edx, eax
	shr	edx, 31
	add	eax, edx
	sar	eax
	cmp	DWORD PTR -148[rbp], eax
	jl	.L33
	mov	DWORD PTR -140[rbp], 0
	jmp	.L34
.L35:
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	DWORD PTR -48[rbp+rax*4], 0
	lea	rax, -152[rbp]
	mov	esi, 5000
	mov	rdi, rax
	call	myrnd
	add	eax, 100
	mov	edx, eax
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	DWORD PTR -112[rbp+rax*4], edx
	lea	rax, -152[rbp]
	mov	esi, 5000
	mov	rdi, rax
	call	myrnd
	add	eax, 100
	mov	edx, eax
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	DWORD PTR -80[rbp+rax*4], edx
	add	DWORD PTR -140[rbp], 1
.L34:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -124[rbp]
	jl	.L35
	mov	DWORD PTR -148[rbp], 0
	jmp	.L36
.L39:
	mov	DWORD PTR -140[rbp], 0
	jmp	.L37
.L38:
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	eax, DWORD PTR -48[rbp+rax*4]
	mov	edi, eax
	call	int_cos
	imul	eax, eax, 10000
	sar	eax, 16
	mov	DWORD PTR -120[rbp], eax
	mov	eax, DWORD PTR -120[rbp]
	mov	edi, eax
	call	put_sample
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	ecx, DWORD PTR -112[rbp+rax*4]
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	edx, DWORD PTR -80[rbp+rax*4]
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	esi, DWORD PTR -112[rbp+rax*4]
	mov	eax, edx
	sub	eax, esi
	imul	eax, DWORD PTR -148[rbp]
	cdq
	idiv	DWORD PTR -128[rbp]
	add	eax, ecx
	mov	DWORD PTR -116[rbp], eax
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	ecx, DWORD PTR -48[rbp+rax*4]
	mov	eax, DWORD PTR -116[rbp]
	sal	eax, 16
	cdq
	idiv	DWORD PTR -128[rbp]
	lea	edx, [rcx+rax]
	mov	eax, DWORD PTR -140[rbp]
	cdqe
	mov	DWORD PTR -48[rbp+rax*4], edx
	add	DWORD PTR -140[rbp], 1
.L37:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -124[rbp]
	jl	.L38
	add	DWORD PTR -148[rbp], 1
.L36:
	mov	eax, DWORD PTR -148[rbp]
	cmp	eax, DWORD PTR -128[rbp]
	jl	.L39
	mov	DWORD PTR -144[rbp], 0
	mov	DWORD PTR -132[rbp], 0
	mov	DWORD PTR -148[rbp], 0
	jmp	.L40
.L44:
	mov	DWORD PTR -140[rbp], 0
	jmp	.L41
.L43:
	mov	eax, DWORD PTR -132[rbp]
	mov	edi, eax
	call	int_cos
	add	eax, 65536
	imul	eax, eax, 5000
	sar	eax, 16
	mov	DWORD PTR -136[rbp], eax
	mov	eax, DWORD PTR -140[rbp]
	and	eax, 1
	test	eax, eax
	je	.L42
	mov	eax, 10000
	sub	eax, DWORD PTR -136[rbp]
	mov	DWORD PTR -136[rbp], eax
.L42:
	mov	eax, DWORD PTR -144[rbp]
	mov	edi, eax
	call	int_cos
	imul	eax, DWORD PTR -136[rbp]
	sar	eax, 16
	mov	DWORD PTR -120[rbp], eax
	mov	eax, DWORD PTR -120[rbp]
	mov	edi, eax
	call	put_sample
	mov	eax, 32768000
	cdq
	idiv	DWORD PTR -128[rbp]
	add	DWORD PTR -144[rbp], eax
	mov	eax, 131072
	cdq
	idiv	DWORD PTR -128[rbp]
	add	DWORD PTR -132[rbp], eax
	add	DWORD PTR -140[rbp], 1
.L41:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -124[rbp]
	jl	.L43
	add	DWORD PTR -148[rbp], 1
.L40:
	mov	eax, DWORD PTR -128[rbp]
	add	eax, eax
	cmp	DWORD PTR -148[rbp], eax
	jl	.L44
	mov	rax, QWORD PTR outfile[rip]
	mov	rdi, rax
	call	fclose@PLT
	mov	eax, 0
.L45:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L46
	call	__stack_chk_fail@PLT
.L46:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"840351.c"
	.text
	.global	__aeabi_uidivmod
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	myrnd, %function
myrnd:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	ldr	r1, [fp, #-8]
	mov	r3, r1
	lsl	r3, r3, #2
	add	r3, r3, r1
	lsl	r3, r3, #1
	add	r3, r3, r1
	lsl	r2, r3, #3
	sub	r2, r2, r3
	lsl	r3, r2, #8
	sub	r3, r3, r2
	lsl	r3, r3, #4
	sub	r3, r3, r1
	add	r3, r3, #1
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-20]
	cmp	r3, #256
	bne	.L2
	ldr	r3, [fp, #-8]
	lsr	r3, r3, #24
	str	r3, [fp, #-12]
	b	.L3
.L2:
	ldr	r2, [fp, #-20]
	ldr	r3, [fp, #-8]
	mov	r1, r2
	mov	r0, r3
	bl	__aeabi_uidivmod
	mov	r3, r1
	str	r3, [fp, #-12]
.L3:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	str	r2, [r3]
	ldr	r3, [fp, #-12]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	myrnd, .-myrnd
	.section	.rodata
	.align	2
	.type	cos_table, %object
	.size	cos_table, 260
cos_table:
	.short	-32768
	.short	32766
	.short	32758
	.short	32746
	.short	32729
	.short	32706
	.short	32679
	.short	32647
	.short	32610
	.short	32568
	.short	32522
	.short	32470
	.short	32413
	.short	32352
	.short	32286
	.short	32214
	.short	32138
	.short	32058
	.short	31972
	.short	31881
	.short	31786
	.short	31686
	.short	31581
	.short	31471
	.short	31357
	.short	31238
	.short	31114
	.short	30986
	.short	30853
	.short	30715
	.short	30572
	.short	30425
	.short	30274
	.short	30118
	.short	29957
	.short	29792
	.short	29622
	.short	29448
	.short	29269
	.short	29086
	.short	28899
	.short	28707
	.short	28511
	.short	28311
	.short	28106
	.short	27897
	.short	27684
	.short	27467
	.short	27246
	.short	27020
	.short	26791
	.short	26557
	.short	26320
	.short	26078
	.short	25833
	.short	25583
	.short	25330
	.short	25073
	.short	24812
	.short	24548
	.short	24279
	.short	24008
	.short	23732
	.short	23453
	.short	23170
	.short	22884
	.short	22595
	.short	22302
	.short	22006
	.short	21706
	.short	21403
	.short	21097
	.short	20788
	.short	20475
	.short	20160
	.short	19841
	.short	19520
	.short	19195
	.short	18868
	.short	18538
	.short	18205
	.short	17869
	.short	17531
	.short	17190
	.short	16846
	.short	16500
	.short	16151
	.short	15800
	.short	15447
	.short	15091
	.short	14733
	.short	14373
	.short	14010
	.short	13646
	.short	13279
	.short	12910
	.short	12540
	.short	12167
	.short	11793
	.short	11417
	.short	11039
	.short	10660
	.short	10279
	.short	9896
	.short	9512
	.short	9127
	.short	8740
	.short	8351
	.short	7962
	.short	7571
	.short	7180
	.short	6787
	.short	6393
	.short	5998
	.short	5602
	.short	5205
	.short	4808
	.short	4410
	.short	4011
	.short	3612
	.short	3212
	.short	2811
	.short	2411
	.short	2009
	.short	1608
	.short	1206
	.short	804
	.short	402
	.short	0
	.short	0
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	int_cos, %function
int_cos:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #28
	str	r0, [fp, #-24]
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	str	r3, [fp, #-24]
	ldr	r3, [fp, #-24]
	cmp	r3, #32768
	blt	.L6
	ldr	r3, [fp, #-24]
	rsb	r3, r3, #65536
	str	r3, [fp, #-24]
.L6:
	mov	r3, #0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-24]
	cmp	r3, #16384
	ble	.L7
	mvn	r3, #0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-24]
	rsb	r3, r3, #32768
	str	r3, [fp, #-24]
.L7:
	ldr	r3, [fp, #-24]
	asr	r3, r3, #7
	lsl	r3, r3, #1
	ldr	r2, .L9
	add	r3, r3, r2
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-24]
	and	r3, r3, #127
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-16]
	ldrh	r3, [r3]
	mov	r1, r3
	ldr	r3, [fp, #-16]
	add	r3, r3, #2
	ldrh	r3, [r3]
	mov	r2, r3
	ldr	r3, [fp, #-16]
	ldrh	r3, [r3]
	sub	r3, r2, r3
	ldr	r2, [fp, #-12]
	mul	r3, r2, r3
	add	r3, r3, #64
	asr	r3, r3, #7
	add	r3, r1, r3
	str	r3, [fp, #-8]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-20]
	eor	r2, r2, r3
	ldr	r3, [fp, #-20]
	sub	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #1
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L10:
	.align	2
.L9:
	.word	cos_table
	.size	int_cos, .-int_cos
	.comm	outfile,4,4
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	put_sample, %function
put_sample:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	and	r3, r3, #255
	ldr	r2, .L12
	ldr	r2, [r2]
	mov	r1, r2
	mov	r0, r3
	bl	fputc
	ldr	r3, [fp, #-8]
	asr	r3, r3, #8
	and	r3, r3, #255
	ldr	r2, .L12
	ldr	r2, [r2]
	mov	r1, r2
	mov	r0, r3
	bl	fputc
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L13:
	.align	2
.L12:
	.word	outfile
	.size	put_sample, .-put_sample
	.section	.rodata
	.align	2
.LC0:
	.ascii	"usage: %s file [<sample rate> [<channels>]]\012gene"
	.ascii	"rate a test raw 16 bit audio stream\012default: 441"
	.ascii	"00 Hz stereo\012\000"
	.align	2
.LC1:
	.ascii	"invalid sample rate: %d\012\000"
	.align	2
.LC2:
	.ascii	"invalid number of channels: %d\012\000"
	.align	2
.LC3:
	.ascii	"wb\000"
	.global	__aeabi_idiv
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 152
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #156
	str	r0, [fp, #-160]
	str	r1, [fp, #-164]
	ldr	r3, .L51
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #1
	str	r3, [fp, #-152]
	ldr	r3, .L51+4
	str	r3, [fp, #-128]
	mov	r3, #2
	str	r3, [fp, #-124]
	ldr	r3, [fp, #-160]
	cmp	r3, #1
	ble	.L15
	ldr	r3, [fp, #-160]
	cmp	r3, #4
	ble	.L16
.L15:
	ldr	r3, [fp, #-164]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L51+8
	bl	printf
	mov	r0, #1
	bl	exit
.L16:
	ldr	r3, [fp, #-160]
	cmp	r3, #2
	ble	.L17
	ldr	r3, [fp, #-164]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	str	r0, [fp, #-128]
	ldr	r3, [fp, #-128]
	cmp	r3, #0
	bgt	.L17
	ldr	r3, .L51+12
	ldr	r3, [r3]
	ldr	r2, [fp, #-128]
	ldr	r1, .L51+16
	mov	r0, r3
	bl	fprintf
	mov	r3, #1
	b	.L49
.L17:
	ldr	r3, [fp, #-160]
	cmp	r3, #3
	ble	.L19
	ldr	r3, [fp, #-164]
	add	r3, r3, #12
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	str	r0, [fp, #-124]
	ldr	r3, [fp, #-124]
	cmp	r3, #0
	ble	.L20
	ldr	r3, [fp, #-124]
	cmp	r3, #8
	ble	.L19
.L20:
	ldr	r3, .L51+12
	ldr	r3, [r3]
	ldr	r2, [fp, #-124]
	ldr	r1, .L51+20
	mov	r0, r3
	bl	fprintf
	mov	r3, #1
	b	.L49
.L19:
	ldr	r3, [fp, #-164]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldr	r1, .L51+24
	mov	r0, r3
	bl	fopen
	mov	r3, r0
	ldr	r2, .L51+28
	str	r3, [r2]
	ldr	r3, .L51+28
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L21
	ldr	r3, [fp, #-164]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r0, r3
	bl	perror
	mov	r3, #1
	b	.L49
.L21:
	mov	r3, #0
	str	r3, [fp, #-144]
	mov	r3, #0
	str	r3, [fp, #-148]
	b	.L22
.L25:
	ldr	r0, [fp, #-144]
	bl	int_cos
	mov	r2, r0
	mov	r3, r2
	lsl	r3, r3, #5
	sub	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r2, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #4
	asr	r3, r3, #16
	str	r3, [fp, #-120]
	mov	r3, #0
	str	r3, [fp, #-140]
	b	.L23
.L24:
	ldr	r0, [fp, #-120]
	bl	put_sample
	ldr	r3, [fp, #-140]
	add	r3, r3, #1
	str	r3, [fp, #-140]
.L23:
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-124]
	cmp	r2, r3
	blt	.L24
	ldr	r1, [fp, #-128]
	mov	r0, #65536000
	bl	__aeabi_idiv
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-144]
	add	r3, r3, r2
	str	r3, [fp, #-144]
	ldr	r3, [fp, #-148]
	add	r3, r3, #1
	str	r3, [fp, #-148]
.L22:
	ldr	r2, [fp, #-148]
	ldr	r3, [fp, #-128]
	cmp	r2, r3
	blt	.L25
	mov	r3, #0
	str	r3, [fp, #-144]
	mov	r3, #0
	str	r3, [fp, #-148]
	b	.L26
.L29:
	ldr	r0, [fp, #-144]
	bl	int_cos
	mov	r2, r0
	mov	r3, r2
	lsl	r3, r3, #5
	sub	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r2, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #4
	asr	r3, r3, #16
	str	r3, [fp, #-120]
	mov	r3, #0
	str	r3, [fp, #-140]
	b	.L27
.L28:
	ldr	r0, [fp, #-120]
	bl	put_sample
	ldr	r3, [fp, #-140]
	add	r3, r3, #1
	str	r3, [fp, #-140]
.L27:
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-124]
	cmp	r2, r3
	blt	.L28
	ldr	r3, [fp, #-148]
	mov	r2, r3
	lsl	r2, r2, #2
	add	r2, r2, r3
	lsl	r3, r2, #4
	sub	r3, r3, r2
	lsl	r2, r3, #5
	add	r3, r3, r2
	lsl	r3, r3, #2
	ldr	r1, [fp, #-128]
	mov	r0, r3
	bl	__aeabi_idiv
	mov	r3, r0
	add	r3, r3, #100
	str	r3, [fp, #-116]
	ldr	r3, [fp, #-116]
	lsl	r3, r3, #16
	ldr	r1, [fp, #-128]
	mov	r0, r3
	bl	__aeabi_idiv
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-144]
	add	r3, r3, r2
	str	r3, [fp, #-144]
	ldr	r3, [fp, #-148]
	add	r3, r3, #1
	str	r3, [fp, #-148]
.L26:
	ldr	r2, [fp, #-148]
	ldr	r3, [fp, #-128]
	cmp	r2, r3
	blt	.L29
	mov	r3, #0
	str	r3, [fp, #-148]
	b	.L30
.L33:
	sub	r3, fp, #152
	ldr	r1, .L51+32
	mov	r0, r3
	bl	myrnd
	mov	r3, r0
	sub	r3, r3, #9984
	sub	r3, r3, #16
	str	r3, [fp, #-120]
	mov	r3, #0
	str	r3, [fp, #-140]
	b	.L31
.L32:
	ldr	r0, [fp, #-120]
	bl	put_sample
	ldr	r3, [fp, #-140]
	add	r3, r3, #1
	str	r3, [fp, #-140]
.L31:
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-124]
	cmp	r2, r3
	blt	.L32
	ldr	r3, [fp, #-148]
	add	r3, r3, #1
	str	r3, [fp, #-148]
.L30:
	ldr	r3, [fp, #-128]
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r2, r3
	ldr	r3, [fp, #-148]
	cmp	r3, r2
	blt	.L33
	mov	r3, #0
	str	r3, [fp, #-148]
	b	.L34
.L37:
	sub	r3, fp, #152
	ldr	r1, .L51+36
	mov	r0, r3
	bl	myrnd
	mov	r3, r0
	sub	r3, r3, #32768
	str	r3, [fp, #-120]
	mov	r3, #0
	str	r3, [fp, #-140]
	b	.L35
.L36:
	ldr	r0, [fp, #-120]
	bl	put_sample
	ldr	r3, [fp, #-140]
	add	r3, r3, #1
	str	r3, [fp, #-140]
.L35:
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-124]
	cmp	r2, r3
	blt	.L36
	ldr	r3, [fp, #-148]
	add	r3, r3, #1
	str	r3, [fp, #-148]
.L34:
	ldr	r3, [fp, #-128]
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r2, r3
	ldr	r3, [fp, #-148]
	cmp	r3, r2
	blt	.L37
	mov	r3, #0
	str	r3, [fp, #-140]
	b	.L38
.L39:
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	mov	r2, #0
	str	r2, [r3, #-36]
	sub	r3, fp, #152
	ldr	r1, .L51+40
	mov	r0, r3
	bl	myrnd
	mov	r3, r0
	add	r3, r3, #100
	mov	r2, r3
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	str	r2, [r3, #-100]
	sub	r3, fp, #152
	ldr	r1, .L51+40
	mov	r0, r3
	bl	myrnd
	mov	r3, r0
	add	r3, r3, #100
	mov	r2, r3
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	str	r2, [r3, #-68]
	ldr	r3, [fp, #-140]
	add	r3, r3, #1
	str	r3, [fp, #-140]
.L38:
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-124]
	cmp	r2, r3
	blt	.L39
	mov	r3, #0
	str	r3, [fp, #-148]
	b	.L40
.L43:
	mov	r3, #0
	str	r3, [fp, #-140]
	b	.L41
.L42:
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r3, [r3, #-36]
	mov	r0, r3
	bl	int_cos
	mov	r2, r0
	mov	r3, r2
	lsl	r3, r3, #5
	sub	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r2, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #4
	asr	r3, r3, #16
	str	r3, [fp, #-120]
	ldr	r0, [fp, #-120]
	bl	put_sample
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r4, [r3, #-100]
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r2, [r3, #-68]
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	ldr	r3, [r3, #-100]
	sub	r3, r2, r3
	ldr	r2, [fp, #-148]
	mul	r3, r2, r3
	ldr	r1, [fp, #-128]
	mov	r0, r3
	bl	__aeabi_idiv
	mov	r3, r0
	add	r3, r4, r3
	str	r3, [fp, #-116]
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r4, [r3, #-36]
	ldr	r3, [fp, #-116]
	lsl	r3, r3, #16
	ldr	r1, [fp, #-128]
	mov	r0, r3
	bl	__aeabi_idiv
	mov	r3, r0
	add	r2, r4, r3
	ldr	r3, [fp, #-140]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	str	r2, [r3, #-36]
	ldr	r3, [fp, #-140]
	add	r3, r3, #1
	str	r3, [fp, #-140]
.L41:
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-124]
	cmp	r2, r3
	blt	.L42
	ldr	r3, [fp, #-148]
	add	r3, r3, #1
	str	r3, [fp, #-148]
.L40:
	ldr	r2, [fp, #-148]
	ldr	r3, [fp, #-128]
	cmp	r2, r3
	blt	.L43
	mov	r3, #0
	str	r3, [fp, #-144]
	mov	r3, #0
	str	r3, [fp, #-132]
	mov	r3, #0
	str	r3, [fp, #-148]
	b	.L44
.L48:
	mov	r3, #0
	str	r3, [fp, #-140]
	b	.L45
.L47:
	ldr	r0, [fp, #-132]
	bl	int_cos
	mov	r3, r0
	add	r2, r3, #65536
	mov	r3, r2
	lsl	r3, r3, #5
	sub	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r2, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #3
	asr	r3, r3, #16
	str	r3, [fp, #-136]
	ldr	r3, [fp, #-140]
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L46
	ldr	r3, [fp, #-136]
	rsb	r3, r3, #9984
	add	r3, r3, #16
	str	r3, [fp, #-136]
.L46:
	ldr	r0, [fp, #-144]
	bl	int_cos
	mov	r2, r0
	ldr	r3, [fp, #-136]
	mul	r3, r2, r3
	asr	r3, r3, #16
	str	r3, [fp, #-120]
	ldr	r0, [fp, #-120]
	bl	put_sample
	ldr	r1, [fp, #-128]
	mov	r0, #32768000
	bl	__aeabi_idiv
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-144]
	add	r3, r3, r2
	str	r3, [fp, #-144]
	ldr	r1, [fp, #-128]
	mov	r0, #131072
	bl	__aeabi_idiv
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-132]
	add	r3, r3, r2
	str	r3, [fp, #-132]
	ldr	r3, [fp, #-140]
	add	r3, r3, #1
	str	r3, [fp, #-140]
.L45:
	ldr	r2, [fp, #-140]
	ldr	r3, [fp, #-124]
	cmp	r2, r3
	blt	.L47
	ldr	r3, [fp, #-148]
	add	r3, r3, #1
	str	r3, [fp, #-148]
.L44:
	ldr	r3, [fp, #-128]
	lsl	r3, r3, #1
	ldr	r2, [fp, #-148]
	cmp	r2, r3
	blt	.L48
	ldr	r3, .L51+28
	ldr	r3, [r3]
	mov	r0, r3
	bl	fclose
	mov	r3, #0
.L49:
	ldr	r2, .L51
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L50
	bl	__stack_chk_fail
.L50:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L52:
	.align	2
.L51:
	.word	.LC4
	.word	44100
	.word	.LC0
	.word	stderr
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	outfile
	.word	20000
	.word	65535
	.word	5000
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
