	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function id3v2_put_ttag
_id3v2_put_ttag:                        ## @id3v2_put_ttag
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r9d, %ebx
	movl	%r8d, -52(%rbp)                 ## 4-byte Spill
	movq	%rcx, %r13
	movq	%rdx, %r14
	movq	%rsi, %r12
	movq	%rdi, %r15
	leaq	-48(%rbp), %rdi
	callq	_avio_open_dyn_buf
	testq	%rax, %rax
	js	LBB0_1
## %bb.2:
	movq	_ID3v2_ENCODING_UTF16BOM@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jne	LBB0_7
## %bb.3:
	movq	%r14, %rdi
	callq	_string_is_ascii
	testq	%rax, %rax
	je	LBB0_7
## %bb.4:
	testq	%r13, %r13
	je	LBB0_6
## %bb.5:
	movq	%r13, %rdi
	callq	_string_is_ascii
	testq	%rax, %rax
	je	LBB0_7
LBB0_6:
	movq	_ID3v2_ENCODING_ISO8859@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_7:
	movq	-48(%rbp), %rdi
	movl	%ebx, %esi
	callq	_avio_w8
	movq	-48(%rbp), %rdi
	movq	%r14, %rsi
	movl	%ebx, %edx
	callq	_id3v2_encode_string
	testq	%r13, %r13
	je	LBB0_9
## %bb.8:
	movq	-48(%rbp), %rdi
	movq	%r13, %rsi
	movl	%ebx, %edx
	callq	_id3v2_encode_string
LBB0_9:
	movq	-48(%rbp), %rdi
	leaq	-64(%rbp), %rsi
	callq	_avio_close_dyn_buf
	movl	%eax, %ebx
	movq	%r12, %rdi
	movl	-52(%rbp), %esi                 ## 4-byte Reload
	callq	_avio_wb32
	cmpl	$3, (%r15)
	jne	LBB0_11
## %bb.10:
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_avio_wb32
	jmp	LBB0_12
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	movl	%eax, %ebx
	jmp	LBB0_13
LBB0_11:
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_id3v2_put_size
LBB0_12:
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_avio_wb16
	movq	-64(%rbp), %rsi
	movq	%r12, %rdi
	movl	%ebx, %edx
	callq	_avio_write
	leaq	-64(%rbp), %rdi
	callq	_av_freep
	movq	_ID3v2_HEADER_SIZE@GOTPCREL(%rip), %rax
	addl	(%rax), %ebx
LBB0_13:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_ID3v2_ENCODING_UTF16BOM,4,2    ## @ID3v2_ENCODING_UTF16BOM
	.comm	_ID3v2_ENCODING_ISO8859,4,2     ## @ID3v2_ENCODING_ISO8859
	.comm	_ID3v2_HEADER_SIZE,4,2          ## @ID3v2_HEADER_SIZE
	.no_dead_strip	_id3v2_put_ttag
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function id3v2_put_ttag
_id3v2_put_ttag:                        ; @id3v2_put_ttag
	.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	x22, x5
	mov	x20, x4
	mov	x23, x3
	mov	x24, x2
	mov	x19, x1
	mov	x21, x0
	mov	x0, sp
	bl	_avio_open_dyn_buf
	tbnz	x0, #63, LBB0_10
; %bb.1:
Lloh0:
	adrp	x8, _ID3v2_ENCODING_UTF16BOM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ID3v2_ENCODING_UTF16BOM@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, w22
	b.ne	LBB0_6
; %bb.2:
	mov	x0, x24
	bl	_string_is_ascii
	cbz	x0, LBB0_6
; %bb.3:
	cbz	x23, LBB0_5
; %bb.4:
	mov	x0, x23
	bl	_string_is_ascii
	cbz	x0, LBB0_6
LBB0_5:
Lloh3:
	adrp	x8, _ID3v2_ENCODING_ISO8859@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ID3v2_ENCODING_ISO8859@GOTPAGEOFF]
Lloh5:
	ldr	w22, [x8]
LBB0_6:
	ldr	x0, [sp]
	mov	x1, x22
	bl	_avio_w8
	ldr	x0, [sp]
	mov	x1, x24
	mov	x2, x22
	bl	_id3v2_encode_string
	cbz	x23, LBB0_8
; %bb.7:
	ldr	x0, [sp]
	mov	x1, x23
	mov	x2, x22
	bl	_id3v2_encode_string
LBB0_8:
	ldr	x0, [sp]
	add	x1, sp, #8
	bl	_avio_close_dyn_buf
	mov	x22, x0
	mov	x0, x19
	mov	x1, x20
	bl	_avio_wb32
	ldr	w8, [x21]
	mov	x0, x19
	mov	x1, x22
	cmp	w8, #3
	b.ne	LBB0_11
; %bb.9:
	bl	_avio_wb32
	b	LBB0_12
LBB0_10:
Lloh6:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_AVERROR
	b	LBB0_13
LBB0_11:
	bl	_id3v2_put_size
LBB0_12:
	mov	x0, x19
	mov	w1, #0
	bl	_avio_wb16
	ldr	x1, [sp, #8]
	mov	x0, x19
	mov	x2, x22
	bl	_avio_write
	add	x0, sp, #8
	bl	_av_freep
Lloh9:
	adrp	x8, _ID3v2_HEADER_SIZE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ID3v2_HEADER_SIZE@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	add	w0, w8, w22
LBB0_13:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_ID3v2_ENCODING_UTF16BOM,4,2    ; @ID3v2_ENCODING_UTF16BOM
	.comm	_ID3v2_ENCODING_ISO8859,4,2     ; @ID3v2_ENCODING_ISO8859
	.comm	_ID3v2_HEADER_SIZE,4,2          ; @ID3v2_HEADER_SIZE
	.no_dead_strip	_id3v2_put_ttag
.subsections_via_symbols
