	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mp3_write_packet
_mp3_write_packet:                      ## @mp3_write_packet
	.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
	movq	%rsi, %r14
	movq	%rdi, %r12
	movq	8(%rdi), %rbx
	movq	(%rsi), %rcx
	cmpq	(%rbx), %rcx
	jne	LBB0_5
## %bb.1:
	cmpq	$0, 8(%rbx)
	je	LBB0_4
## %bb.2:
	leaq	24(%rbx), %rdi
	leaq	20(%rbx), %rsi
	movq	_FF_PACKETLIST_FLAG_REF_PACKET@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdx
	callq	_ff_packet_list_put
	xorl	%r15d, %r15d
	testl	%eax, %eax
	jns	LBB0_13
## %bb.3:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_av_log
	movq	$0, 8(%rbx)
	movq	%r12, %rdi
	callq	_mp3_queue_flush
LBB0_4:
	movq	%r12, %rdi
	movq	%r14, %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_mp3_write_audio_packet         ## TAILCALL
LBB0_5:
	movq	(%r12), %rax
	movq	(%rax,%rcx,8), %rax
	cmpl	$1, (%rax)
	jne	LBB0_7
## %bb.6:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_av_log
LBB0_7:
	xorl	%r15d, %r15d
	cmpq	$0, 8(%rbx)
	je	LBB0_13
## %bb.8:
	movq	(%r12), %rax
	movq	(%r14), %rcx
	movq	(%rax,%rcx,8), %rax
	cmpl	$0, (%rax)
	jg	LBB0_13
## %bb.9:
	leaq	16(%rbx), %rsi
	movq	%r12, %rdi
	movq	%r14, %rdx
	callq	_ff_id3v2_write_apic
	testl	%eax, %eax
	js	LBB0_12
## %bb.10:
	xorl	%r15d, %r15d
	decq	8(%rbx)
	jne	LBB0_13
## %bb.11:
	movq	%r12, %rdi
	callq	_mp3_queue_flush
	testl	%eax, %eax
	jns	LBB0_13
LBB0_12:
	movl	%eax, %r15d
LBB0_13:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FF_PACKETLIST_FLAG_REF_PACKET,4,2 ## @FF_PACKETLIST_FLAG_REF_PACKET
	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Not enough memory to buffer audio. Skipping picture streams\n"

L_.str.1:                               ## @.str.1
	.asciz	"Got more than one picture in stream %d, ignoring.\n"

	.no_dead_strip	_mp3_write_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mp3_write_packet
_mp3_write_packet:                      ; @mp3_write_packet
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x20, x1
	mov	x19, x0
	ldr	x21, [x0, #8]
	ldr	x8, [x1]
	ldr	x9, [x21]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.1:
	ldr	x8, [x21, #8]
	cbz	x8, LBB0_4
; %bb.2:
	add	x0, x21, #24
	add	x1, x21, #20
Lloh0:
	adrp	x8, _FF_PACKETLIST_FLAG_REF_PACKET@GOTPAGE
Lloh1:
	ldr	x8, [x8, _FF_PACKETLIST_FLAG_REF_PACKET@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	mov	x2, x20
	bl	_ff_packet_list_put
	tbz	w0, #31, LBB0_9
; %bb.3:
Lloh3:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x2, l_.str@PAGE
Lloh7:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
	str	xzr, [x21, #8]
	mov	x0, x19
	bl	_mp3_queue_flush
LBB0_4:
	mov	x0, x19
	mov	x1, x20
	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
	add	sp, sp, #64
	b	_mp3_write_audio_packet
LBB0_5:
	ldr	x9, [x19]
	ldr	x9, [x9, x8, lsl #3]
	ldr	w9, [x9]
	cmp	w9, #1
	b.ne	LBB0_7
; %bb.6:
Lloh8:
	adrp	x9, _AV_LOG_WARNING@GOTPAGE
Lloh9:
	ldr	x9, [x9, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x9]
	str	x8, [sp]
Lloh11:
	adrp	x2, l_.str.1@PAGE
Lloh12:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_7:
	ldr	x8, [x21, #8]
	cbz	x8, LBB0_9
; %bb.8:
	ldr	x8, [x19]
	ldr	x9, [x20]
	ldr	x8, [x8, x9, lsl #3]
	ldr	w8, [x8]
	cmp	w8, #0
	b.le	LBB0_11
LBB0_9:
	mov	w0, #0
LBB0_10:
	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
	add	sp, sp, #64
	ret
LBB0_11:
	add	x1, x21, #16
	mov	x0, x19
	mov	x2, x20
	bl	_ff_id3v2_write_apic
	tbnz	w0, #31, LBB0_10
; %bb.12:
	ldr	x8, [x21, #8]
	subs	x8, x8, #1
	str	x8, [x21, #8]
	b.ne	LBB0_9
; %bb.13:
	mov	x0, x19
	bl	_mp3_queue_flush
	tbz	w0, #31, LBB0_9
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_FF_PACKETLIST_FLAG_REF_PACKET,4,2 ; @FF_PACKETLIST_FLAG_REF_PACKET
	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Not enough memory to buffer audio. Skipping picture streams\n"

l_.str.1:                               ; @.str.1
	.asciz	"Got more than one picture in stream %d, ignoring.\n"

	.no_dead_strip	_mp3_write_packet
.subsections_via_symbols
