	.file	"extr_wave.c_wave_generate_silence.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	wave_generate_silence, @function
wave_generate_silence:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	xor	eax, eax
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 8
	.cfi_def_cfa_offset 64
	mov	r12d, DWORD PTR 8[rdi]
	mulsd	xmm0, QWORD PTR [rdi]
	cvttsd2si	r13d, xmm0
	imul	r12d, r13d
	mov	DWORD PTR [rsi], r12d
	call	GetProcessHeap@PLT
	mov	edx, r12d
	xor	esi, esi
	mov	edi, eax
	call	HeapAlloc@PLT
	mov	r14, rax
	test	r13d, r13d
	jle	.L1
	mov	rbx, rax
	xor	r12d, r12d
	lea	r15, KSDATAFORMAT_SUBTYPE_PCM[rip]
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L4:
	add	r12d, 1
	cmp	r13d, r12d
	je	.L1
.L2:
	mov	eax, DWORD PTR 12[rbp]
	cmp	eax, 8
	je	.L32
	cmp	eax, 16
	je	.L33
	cmp	eax, 24
	je	.L34
	cmp	eax, 32
	jne	.L4
	mov	rax, QWORD PTR 24[rbp]
	cmp	rax, QWORD PTR WAVE_FORMAT_PCM[rip]
	je	.L12
	cmp	rax, QWORD PTR WAVE_FORMAT_EXTENSIBLE[rip]
	jne	.L4
	mov	rsi, r15
	mov	rdi, rbp
	call	IsEqualGUID@PLT
	test	rax, rax
	jne	.L12
	cmp	DWORD PTR 12[rbp], 32
	jne	.L4
	mov	rax, QWORD PTR WAVE_FORMAT_EXTENSIBLE[rip]
	cmp	QWORD PTR 24[rbp], rax
	jne	.L4
	lea	rsi, KSDATAFORMAT_SUBTYPE_IEEE_FLOAT[rip]
	mov	rdi, rbp
	call	IsEqualGUID@PLT
	test	rax, rax
	je	.L4
	mov	eax, DWORD PTR 16[rbp]
	test	eax, eax
	jle	.L4
	xor	eax, eax
	.p2align 4,,10
	.p2align 3
.L14:
	mov	BYTE PTR [rbx], 0
	add	eax, 1
	add	rbx, 4
	mov	BYTE PTR -3[rbx], 0
	mov	BYTE PTR -2[rbx], 0
	mov	BYTE PTR -1[rbx], 0
	cmp	DWORD PTR 16[rbp], eax
	jg	.L14
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L32:
	mov	edi, DWORD PTR 16[rbp]
	test	edi, edi
	jle	.L4
	xor	eax, eax
	.p2align 4,,10
	.p2align 3
.L5:
	add	rbx, 1
	add	eax, 1
	mov	BYTE PTR -1[rbx], -128
	cmp	DWORD PTR 16[rbp], eax
	jg	.L5
	add	r12d, 1
	cmp	r13d, r12d
	jne	.L2
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	rax, r14
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L33:
	.cfi_restore_state
	mov	esi, DWORD PTR 16[rbp]
	test	esi, esi
	jle	.L4
	xor	eax, eax
	.p2align 4,,10
	.p2align 3
.L7:
	mov	BYTE PTR [rbx], 0
	add	eax, 1
	add	rbx, 2
	mov	BYTE PTR -1[rbx], 0
	cmp	DWORD PTR 16[rbp], eax
	jg	.L7
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L34:
	mov	ecx, DWORD PTR 16[rbp]
	test	ecx, ecx
	jle	.L4
	xor	eax, eax
	.p2align 4,,10
	.p2align 3
.L9:
	mov	BYTE PTR [rbx], 0
	add	eax, 1
	add	rbx, 3
	mov	BYTE PTR -2[rbx], 0
	mov	BYTE PTR -1[rbx], 0
	cmp	DWORD PTR 16[rbp], eax
	jg	.L9
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L12:
	mov	edx, DWORD PTR 16[rbp]
	xor	eax, eax
	test	edx, edx
	jle	.L4
	.p2align 4,,10
	.p2align 3
.L11:
	mov	BYTE PTR [rbx], 0
	add	eax, 1
	add	rbx, 4
	mov	BYTE PTR -3[rbx], 0
	mov	BYTE PTR -2[rbx], 0
	mov	BYTE PTR -1[rbx], 0
	cmp	DWORD PTR 16[rbp], eax
	jg	.L11
	jmp	.L4
	.cfi_endproc
.LFE0:
	.size	wave_generate_silence, .-wave_generate_silence
	.comm	WAVE_FORMAT_PCM,8,8
	.comm	WAVE_FORMAT_EXTENSIBLE,8,8
	.comm	KSDATAFORMAT_SUBTYPE_PCM,4,4
	.comm	KSDATAFORMAT_SUBTYPE_IEEE_FLOAT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.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, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_wave.c_wave_generate_silence.c"
	.text
	.global	__aeabi_dmul
	.global	__aeabi_d2iz
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	wave_generate_silence, %function
wave_generate_silence:
	@ args = 4, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r5, r0
	mov	r1, r3
	mov	r0, r2
	ldmia	r5, {r2-r3}
	bl	__aeabi_dmul
	bl	__aeabi_d2iz
	ldr	r3, [r5, #8]
	ldr	r4, [sp, #40]
	mul	r3, r0, r3
	str	r3, [r4]
	mov	r8, r0
	bl	GetProcessHeap
	mov	r1, #0
	ldr	r2, [r4]
	bl	HeapAlloc
	cmp	r8, #0
	mov	r10, r0
	ble	.L1
	mov	r7, #0
	mov	r6, r0
	mov	r4, r7
	mvn	r9, #127
	ldr	r2, .L33
	ldr	r3, .L33+4
	b	.L2
.L4:
	add	r7, r7, #1
	cmp	r8, r7
	beq	.L1
.L2:
	ldr	r1, [r5, #12]
	cmp	r1, #8
	beq	.L30
	cmp	r1, #16
	beq	.L31
	cmp	r1, #24
	beq	.L32
	cmp	r1, #32
	bne	.L4
	ldr	r1, [r5, #20]
	ldr	r0, [r2]
	cmp	r1, r0
	beq	.L12
	ldr	r0, [r3]
	cmp	r1, r0
	bne	.L4
	mov	r0, r5
	ldr	r1, .L33+8
	bl	IsEqualGUID
	subs	fp, r0, #0
	ldr	r2, .L33
	ldr	r3, .L33+4
	bne	.L12
	ldr	r1, [r5, #12]
	cmp	r1, #32
	bne	.L4
	ldr	r0, [r5, #20]
	ldr	r1, [r3]
	cmp	r0, r1
	bne	.L4
	mov	r0, r5
	ldr	r1, .L33+12
	bl	IsEqualGUID
	cmp	r0, #0
	ldr	r2, .L33
	ldr	r3, .L33+4
	beq	.L4
	ldr	r1, [r5, #16]
	cmp	r1, #0
	ble	.L4
	add	r1, r6, #4
.L15:
	strb	r4, [r1, #-4]
	strb	r4, [r1, #-3]
	strb	r4, [r1, #-2]
	strb	r4, [r1, #-1]
	ldr	r0, [r5, #16]
	add	fp, fp, #1
	cmp	r0, fp
	mov	r6, r1
	add	r1, r1, #4
	bgt	.L15
	b	.L4
.L30:
	ldr	r1, [r5, #16]
	cmp	r1, #0
	ble	.L4
	mov	r1, #0
.L5:
	strb	r9, [r6], #1
	ldr	r0, [r5, #16]
	add	r1, r1, #1
	cmp	r0, r1
	bgt	.L5
	add	r7, r7, #1
	cmp	r8, r7
	bne	.L2
.L1:
	mov	r0, r10
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L31:
	ldr	r1, [r5, #16]
	cmp	r1, #0
	ble	.L4
	mov	r0, #0
	add	r1, r6, #2
.L7:
	strb	r4, [r1, #-2]
	strb	r4, [r1, #-1]
	ldr	ip, [r5, #16]
	add	r0, r0, #1
	cmp	ip, r0
	mov	r6, r1
	add	r1, r1, #2
	bgt	.L7
	b	.L4
.L32:
	ldr	r1, [r5, #16]
	cmp	r1, #0
	ble	.L4
	mov	r0, #0
	add	r1, r6, #3
.L9:
	strb	r4, [r1, #-3]
	strb	r4, [r1, #-2]
	strb	r4, [r1, #-1]
	ldr	ip, [r5, #16]
	add	r0, r0, #1
	cmp	ip, r0
	mov	r6, r1
	add	r1, r1, #3
	bgt	.L9
	b	.L4
.L12:
	ldr	r1, [r5, #16]
	cmp	r1, #0
	movgt	r0, #0
	addgt	r1, r6, #4
	ble	.L4
.L14:
	strb	r4, [r1, #-4]
	strb	r4, [r1, #-3]
	strb	r4, [r1, #-2]
	strb	r4, [r1, #-1]
	ldr	ip, [r5, #16]
	add	r0, r0, #1
	cmp	ip, r0
	mov	r6, r1
	add	r1, r1, #4
	bgt	.L14
	b	.L4
.L34:
	.align	2
.L33:
	.word	WAVE_FORMAT_PCM
	.word	WAVE_FORMAT_EXTENSIBLE
	.word	KSDATAFORMAT_SUBTYPE_PCM
	.word	KSDATAFORMAT_SUBTYPE_IEEE_FLOAT
	.size	wave_generate_silence, .-wave_generate_silence
	.comm	WAVE_FORMAT_PCM,4,4
	.comm	WAVE_FORMAT_EXTENSIBLE,4,4
	.comm	KSDATAFORMAT_SUBTYPE_PCM,4,4
	.comm	KSDATAFORMAT_SUBTYPE_IEEE_FLOAT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
