	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function opus_flush_resample
LCPI0_0:
	.quad	0x3ff0000000000000              ## double 1
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_opus_flush_resample:                   ## @opus_flush_resample
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r12
	movl	48(%rdi), %edi
	callq	_av_audio_fifo_size
	movl	%eax, %r15d
	movl	56(%r12), %edi
	movq	(%r12), %rsi
	movl	%r14d, %edx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_swr_convert
	testl	%eax, %eax
	js	LBB0_17
## %bb.1:
	cmpl	%r14d, %eax
	jne	LBB0_2
## %bb.3:
	testl	%r15d, %r15d
	je	LBB0_10
## %bb.4:
	cmpl	%r14d, %r15d
	jne	LBB0_5
## %bb.7:
	movl	48(%r12), %edi
	movq	32(%r12), %rsi
	movl	%r14d, %edx
	callq	_av_audio_fifo_read
	cmpl	$0, 8(%r12)
	jle	LBB0_10
## %bb.8:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	40(%r12), %rax
	movq	(%r12), %rcx
	movq	32(%r12), %rdx
	movl	(%rcx,%rbx,4), %edi
	movl	(%rdx,%rbx,4), %esi
	movsd	LCPI0_0(%rip), %xmm0            ## xmm0 = mem[0],zero
	movl	%r14d, %edx
	callq	*(%rax)
	incq	%rbx
	movslq	8(%r12), %rax
	cmpq	%rax, %rbx
	jl	LBB0_9
LBB0_10:
	movq	16(%r12), %rcx
	testq	%rcx, %rcx
	je	LBB0_16
## %bb.11:
	cmpl	$0, 8(%r12)
	jle	LBB0_15
## %bb.12:
	movl	$1, %ebx
	movq	_ff_celt_window2@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r12), %rax
	movq	24(%r12), %rdx
	movl	-4(%rax,%rbx,4), %edi
	movq	-8(%rdx,%rbx,8), %rax
	leaq	(%rax,%rcx), %rdx
	addq	$120, %rdx
	movl	$120, %r8d
	subq	%rcx, %r8
	addq	(%r15), %rcx
	movl	%edi, %esi
	callq	_opus_fade
	movslq	8(%r12), %rax
	cmpq	%rax, %rbx
	jge	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	16(%r12), %rcx
	incq	%rbx
	jmp	LBB0_13
LBB0_2:
	movl	52(%r12), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str(%rip), %rdx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_6
LBB0_15:
	movq	$0, 16(%r12)
LBB0_16:
	movq	(%r12), %rax
	addl	%r14d, (%rax)
	addl	%r14d, 4(%rax)
	shll	$2, %r14d
	subl	%r14d, 12(%r12)
	xorl	%eax, %eax
	jmp	LBB0_17
LBB0_5:
	movl	52(%r12), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	xorl	%eax, %eax
	callq	_av_log
LBB0_6:
	movq	_AVERROR_BUG@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_17:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Wrong number of flushed samples: %d\n"

	.comm	_AVERROR_BUG,4,2                ## @AVERROR_BUG
L_.str.1:                               ## @.str.1
	.asciz	"Wrong number of CELT delay samples.\n"

	.comm	_ff_celt_window2,8,3            ## @ff_celt_window2
	.no_dead_strip	_opus_flush_resample
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function opus_flush_resample
_opus_flush_resample:                   ; @opus_flush_resample
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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, x1
	mov	x19, x0
	ldr	w0, [x0, #48]
	bl	_av_audio_fifo_size
	mov	x21, x0
	ldr	w0, [x19, #56]
	ldr	x1, [x19]
	mov	x2, x20
	mov	x3, #0
	mov	w4, #0
	bl	_swr_convert
                                        ; kill: def $w0 killed $w0 def $x0
	tbnz	w0, #31, LBB0_17
; %bb.1:
	cmp	w0, w20
	b.ne	LBB0_12
; %bb.2:
	cbz	w21, LBB0_7
; %bb.3:
	cmp	w21, w20
	b.ne	LBB0_15
; %bb.4:
	ldr	w0, [x19, #48]
	ldr	x1, [x19, #32]
	mov	x2, x20
	bl	_av_audio_fifo_read
	ldr	w8, [x19, #8]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.5:
	mov	x21, #0
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldp	x9, x8, [x19, #32]
	ldr	x8, [x8]
	ldr	x10, [x19]
	lsl	x11, x21, #2
	ldr	w0, [x10, x11]
	ldr	w1, [x9, x11]
	fmov	d0, #1.00000000
	mov	x2, x20
	blr	x8
	add	x21, x21, #1
	ldrsw	x8, [x19, #8]
	cmp	x21, x8
	b.lt	LBB0_6
LBB0_7:
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_14
; %bb.8:
	ldr	w9, [x19, #8]
	cmp	w9, #1
	b.lt	LBB0_13
; %bb.9:
	mov	x21, #0
Lloh0:
	adrp	x22, _ff_celt_window2@GOTPAGE
Lloh1:
	ldr	x22, [x22, _ff_celt_window2@GOTPAGEOFF]
	mov	w23, #120
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19]
	ldr	w0, [x9, x21, lsl #2]
	ldr	x9, [x19, #24]
	ldr	x9, [x9, x21, lsl #3]
	add	x9, x9, x8
	add	x2, x9, #120
	ldr	x9, [x22]
	add	x3, x9, x8
	sub	x4, x23, x8
	mov	x1, x0
	bl	_opus_fade
	add	x21, x21, #1
	ldrsw	x8, [x19, #8]
	cmp	x21, x8
	b.ge	LBB0_13
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	ldr	x8, [x19, #16]
	b	LBB0_10
LBB0_12:
	ldr	w8, [x19, #52]
Lloh2:
	adrp	x9, _AV_LOG_ERROR@GOTPAGE
Lloh3:
	ldr	x9, [x9, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x9]
	str	x0, [sp]
Lloh5:
	adrp	x2, l_.str@PAGE
Lloh6:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x8
	b	LBB0_16
LBB0_13:
	str	xzr, [x19, #16]
LBB0_14:
	mov	w0, #0
	ldr	x8, [x19]
	dup.2s	v0, w20
	ldr	d1, [x8]
	add.2s	v0, v1, v0
	str	d0, [x8]
	ldr	w8, [x19, #12]
	sub	w8, w8, w20, lsl #2
	str	w8, [x19, #12]
	b	LBB0_17
LBB0_15:
	ldr	w0, [x19, #52]
Lloh7:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh8:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
Lloh10:
	adrp	x2, l_.str.1@PAGE
Lloh11:
	add	x2, x2, l_.str.1@PAGEOFF
LBB0_16:
	bl	_av_log
Lloh12:
	adrp	x8, _AVERROR_BUG@GOTPAGE
Lloh13:
	ldr	x8, [x8, _AVERROR_BUG@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
LBB0_17:
                                        ; kill: def $w0 killed $w0 killed $x0
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Wrong number of flushed samples: %d\n"

	.comm	_AVERROR_BUG,4,2                ; @AVERROR_BUG
l_.str.1:                               ; @.str.1
	.asciz	"Wrong number of CELT delay samples.\n"

	.comm	_ff_celt_window2,8,3            ; @ff_celt_window2
	.no_dead_strip	_opus_flush_resample
.subsections_via_symbols
