	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function swf_write_audio
_swf_write_audio:                       ## @swf_write_audio
	.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
	movl	%ecx, %ebx
	movq	%rdx, %r12
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	%rdi, %r15
	movq	(%rdi), %r14
	cmpl	$16000, (%r14)                  ## imm = 0x3E80
	jne	LBB0_2
## %bb.1:
	movq	_AV_LOG_INFO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rdi
	callq	_av_log
LBB0_2:
	movl	12(%r14), %edi
	callq	_av_fifo_size
	movslq	%ebx, %rcx
	addq	%rax, %rcx
	movq	_AUDIO_FIFO_SIZE@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jle	LBB0_4
## %bb.3:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	%r15, %rdi
	callq	_av_log
	movl	$-1, %r13d
	jmp	LBB0_6
LBB0_4:
	movl	12(%r14), %edi
	xorl	%r13d, %r13d
	movq	%r12, %rsi
	movl	%ebx, %edx
	xorl	%ecx, %ecx
	callq	_av_fifo_generic_write
	movq	-48(%rbp), %r12                 ## 8-byte Reload
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_av_get_audio_frame_duration2
	addl	%eax, 8(%r14)
	cmpl	$0, 4(%r14)
	jne	LBB0_6
## %bb.5:
	xorl	%r13d, %r13d
	movq	%r15, %rdi
	movq	%r12, %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_swf_write_video
LBB0_6:
	movl	%r13d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_INFO,4,2                ## @AV_LOG_INFO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"warning: Flash Player limit of 16000 frames reached\n"

	.comm	_AUDIO_FIFO_SIZE,8,3            ## @AUDIO_FIFO_SIZE
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
L_.str.1:                               ## @.str.1
	.asciz	"audio fifo too small to mux audio essence\n"

	.no_dead_strip	_swf_write_audio
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function swf_write_audio
_swf_write_audio:                       ; @swf_write_audio
	.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	x21, x3
	mov	x22, x2
	mov	x20, x1
	mov	x19, x0
	ldr	x23, [x0]
	ldr	w8, [x23]
	mov	w9, #16000
	cmp	w8, w9
	b.ne	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _AV_LOG_INFO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AV_LOG_INFO@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_2:
	ldr	w0, [x23, #12]
	bl	_av_fifo_size
	add	x8, x0, w21, sxtw
Lloh5:
	adrp	x9, _AUDIO_FIFO_SIZE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _AUDIO_FIFO_SIZE@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	b.le	LBB0_4
; %bb.3:
Lloh8:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
Lloh11:
	adrp	x2, l_.str.1@PAGE
Lloh12:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_av_log
	mov	w0, #-1
	b	LBB0_7
LBB0_4:
	ldr	w0, [x23, #12]
	mov	x1, x22
	mov	x2, x21
	mov	x3, #0
	bl	_av_fifo_generic_write
	mov	x0, x20
	mov	x1, x21
	bl	_av_get_audio_frame_duration2
	ldp	w9, w8, [x23, #4]
	add	w8, w8, w0
	str	w8, [x23, #8]
	cbnz	w9, LBB0_6
; %bb.5:
	mov	x0, x19
	mov	x1, x20
	mov	w2, #0
	mov	w3, #0
	bl	_swf_write_video
LBB0_6:
	mov	w0, #0
LBB0_7:
	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 AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_INFO,4,2                ; @AV_LOG_INFO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"warning: Flash Player limit of 16000 frames reached\n"

	.comm	_AUDIO_FIFO_SIZE,8,3            ; @AUDIO_FIFO_SIZE
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
l_.str.1:                               ; @.str.1
	.asciz	"audio fifo too small to mux audio essence\n"

	.no_dead_strip	_swf_write_audio
.subsections_via_symbols
