	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mov_write_track_udta_tag
_mov_write_track_udta_tag:              ## @mov_write_track_udta_tag
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%r15d, %r15d
	testq	%rdx, %rdx
	je	LBB0_8
## %bb.1:
	movq	%rdx, %rbx
	movq	%rsi, %r12
	movq	%rdi, %r14
	leaq	-48(%rbp), %rdi
	callq	_avio_open_dyn_buf
	testl	%eax, %eax
	js	LBB0_2
## %bb.3:
	movq	_MODE_MP4@GOTPCREL(%rip), %rax
	movq	_MODE_MOV@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	testl	%ecx, (%r12)
	je	LBB0_5
## %bb.4:
	movq	-48(%rbp), %rdi
	leaq	L_.str(%rip), %rdx
	leaq	L_.str.1(%rip), %rcx
	movq	%rbx, %rsi
	callq	_mov_write_track_metadata
LBB0_5:
	movq	-48(%rbp), %rdi
	leaq	-40(%rbp), %rsi
	callq	_avio_close_dyn_buf
	testl	%eax, %eax
	jle	LBB0_7
## %bb.6:
	movl	%eax, %ebx
	movl	%eax, %esi
	addl	$8, %esi
	movq	%r14, %rdi
	callq	_avio_wb32
	leaq	L_.str.2(%rip), %rsi
	movq	%r14, %rdi
	callq	_ffio_wfourcc
	movq	-40(%rbp), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_avio_write
LBB0_7:
	movq	-40(%rbp), %rdi
	callq	_av_free
	jmp	LBB0_8
LBB0_2:
	movl	%eax, %r15d
LBB0_8:
	movl	%r15d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MODE_MP4,4,2                   ## @MODE_MP4
	.comm	_MODE_MOV,4,2                   ## @MODE_MOV
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"name"

L_.str.1:                               ## @.str.1
	.asciz	"title"

L_.str.2:                               ## @.str.2
	.asciz	"udta"

	.no_dead_strip	_mov_write_track_udta_tag
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mov_write_track_udta_tag
_mov_write_track_udta_tag:              ; @mov_write_track_udta_tag
	.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
	cbz	x2, LBB0_7
; %bb.1:
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	add	x0, sp, #8
	bl	_avio_open_dyn_buf
	tbnz	w0, #31, LBB0_8
; %bb.2:
	ldr	w8, [x21]
Lloh0:
	adrp	x9, _MODE_MP4@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MODE_MP4@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
Lloh3:
	adrp	x10, _MODE_MOV@GOTPAGE
Lloh4:
	ldr	x10, [x10, _MODE_MOV@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_4
; %bb.3:
	ldr	x0, [sp, #8]
Lloh6:
	adrp	x2, l_.str@PAGE
Lloh7:
	add	x2, x2, l_.str@PAGEOFF
Lloh8:
	adrp	x3, l_.str.1@PAGE
Lloh9:
	add	x3, x3, l_.str.1@PAGEOFF
	mov	x1, x20
	bl	_mov_write_track_metadata
LBB0_4:
	ldr	x0, [sp, #8]
	mov	x1, sp
	bl	_avio_close_dyn_buf
	cmp	w0, #1
	b.lt	LBB0_6
; %bb.5:
	mov	x20, x0
	add	w1, w0, #8
	mov	x0, x19
	bl	_avio_wb32
Lloh10:
	adrp	x1, l_.str.2@PAGE
Lloh11:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_ffio_wfourcc
	ldr	x1, [sp]
	mov	x0, x19
	mov	x2, x20
	bl	_avio_write
LBB0_6:
	ldr	x0, [sp]
	bl	_av_free
LBB0_7:
	mov	w0, #0
LBB0_8:
	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
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_MODE_MP4,4,2                   ; @MODE_MP4
	.comm	_MODE_MOV,4,2                   ; @MODE_MOV
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"name"

l_.str.1:                               ; @.str.1
	.asciz	"title"

l_.str.2:                               ; @.str.2
	.asciz	"udta"

	.no_dead_strip	_mov_write_track_udta_tag
.subsections_via_symbols
