	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function flac_write_block_comment
_flac_write_block_comment:              ## @flac_write_block_comment
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r13d
	movq	%rsi, %rbx
	movq	%rdi, %r14
	testl	%ecx, %ecx
	jne	LBB0_1
## %bb.2:
	movq	_LIBAVFORMAT_IDENT@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	jmp	LBB0_3
LBB0_1:
	leaq	L_.str(%rip), %r15
LBB0_3:
	movq	_ff_vorbiscomment_metadata_conv@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_ff_metadata_conv
	movq	(%rbx), %rdi
	movq	%r15, %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_ff_vorbiscomment_length
	cmpl	$16777212, %eax                 ## imm = 0xFFFFFC
	jl	LBB0_6
## %bb.4:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_6:
	movl	%eax, %r12d
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	leal	4(%r12), %edi
	movl	%edi, -44(%rbp)                 ## 4-byte Spill
	callq	_av_malloc
	movq	%rax, -64(%rbp)
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movq	%rax, %r14
	movq	%rax, -72(%rbp)
	xorl	%esi, %esi
	testl	%r13d, %r13d
	setne	%sil
	shll	$7, %esi
	orl	$4, %esi
	leaq	-72(%rbp), %r13
	movq	%r13, %rdi
	callq	_bytestream_put_byte
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_bytestream_put_be24
	movq	%r13, %rdi
	movq	%rbx, %rsi
	movq	%r15, %rdx
	xorl	%ecx, %ecx
	xorl	%r8d, %r8d
	callq	_ff_vorbiscomment_write
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%r14, %rsi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	callq	_avio_write
	leaq	-64(%rbp), %rdi
	callq	_av_freep
	xorl	%eax, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_5:
	movl	(%rax), %edi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ffmpeg"

	.comm	_LIBAVFORMAT_IDENT,8,3          ## @LIBAVFORMAT_IDENT
	.comm	_ff_vorbiscomment_metadata_conv,4,2 ## @ff_vorbiscomment_metadata_conv
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_flac_write_block_comment
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function flac_write_block_comment
_flac_write_block_comment:              ; @flac_write_block_comment
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x22, x2
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _LIBAVFORMAT_IDENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LIBAVFORMAT_IDENT@GOTPAGEOFF]
Lloh2:
	adrp	x9, l_.str@PAGE
Lloh3:
	add	x9, x9, l_.str@PAGEOFF
Lloh4:
	ldr	x8, [x8]
	cmp	w3, #0
	csel	x21, x8, x9, eq
Lloh5:
	adrp	x8, _ff_vorbiscomment_metadata_conv@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ff_vorbiscomment_metadata_conv@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x0, x20
	mov	x2, #0
	bl	_ff_metadata_conv
	ldr	x0, [x20]
	mov	x1, x21
	mov	x2, #0
	mov	w3, #0
	bl	_ff_vorbiscomment_length
	mov	w8, #16777212
	cmp	w0, w8
	b.lt	LBB0_2
; %bb.1:
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_5
LBB0_2:
	mov	x25, x0
	add	w23, w0, #4
	mov	x0, x23
	bl	_av_malloc
	str	x0, [sp]
	cbz	x0, LBB0_4
; %bb.3:
	mov	x24, x0
	str	x0, [sp, #8]
	mov	w8, #132
	mov	w9, #4
	cmp	w22, #0
	csel	w1, w9, w8, eq
	add	x0, sp, #8
	bl	_bytestream_put_byte
	add	x0, sp, #8
	mov	x1, x25
	bl	_bytestream_put_be24
	add	x0, sp, #8
	mov	x1, x20
	mov	x2, x21
	mov	x3, #0
	mov	w4, #0
	bl	_ff_vorbiscomment_write
	mov	x0, x19
	mov	x1, x24
	mov	x2, x23
	bl	_avio_write
	mov	x0, sp
	bl	_av_freep
	mov	w0, #0
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_4:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_5:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	b	_AVERROR
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ffmpeg"

	.comm	_LIBAVFORMAT_IDENT,8,3          ; @LIBAVFORMAT_IDENT
	.comm	_ff_vorbiscomment_metadata_conv,4,2 ; @ff_vorbiscomment_metadata_conv
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_flac_write_block_comment
.subsections_via_symbols
