	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_playlist_write_runtime_file    ## -- Begin function playlist_write_runtime_file
	.p2align	4, 0x90
_playlist_write_runtime_file:           ## @playlist_write_runtime_file
	.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	$104, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -112(%rbp)
	movq	$0, -96(%rbp)
	testq	%rdi, %rdi
	je	LBB0_16
## %bb.1:
	movq	%rdi, %rbx
	cmpl	$0, (%rdi)
	je	LBB0_16
## %bb.2:
	movl	16(%rbx), %edi
	movq	_RETRO_VFS_FILE_ACCESS_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_RETRO_VFS_FILE_ACCESS_HINT_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_filestream_open
	testq	%rax, %rax
	je	LBB0_3
## %bb.5:
	movq	%rax, %r15
	xorl	%edi, %edi
	callq	_JSON_Writer_Create
	movl	%eax, -112(%rbp)
	movq	%r15, -104(%rbp)
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	movl	%eax, %r14d
	movq	%r15, -136(%rbp)                ## 8-byte Spill
	movq	_JSON_UTF8@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movl	%eax, %edi
	callq	_JSON_Writer_SetOutputEncoding
	movq	_JSONOutputHandler@GOTPCREL(%rip), %rsi
	movl	%r14d, %edi
	callq	_JSON_Writer_SetOutputHandler
	leaq	-112(%rbp), %rsi
	movl	%r14d, %edi
	callq	_JSON_Writer_SetUserData
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteStartObject
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movl	-112(%rbp), %edi
	movl	$2, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %r14d
	movq	%rbx, -120(%rbp)                ## 8-byte Spill
	leaq	L_.str.2(%rip), %r15
	movq	%r15, %rdi
	callq	_STRLEN_CONST
	movl	(%r12), %ecx
	movl	%r14d, %edi
	movq	%r15, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %r14d
	leaq	L_.str.3(%rip), %r15
	movq	%r15, %rdi
	callq	_STRLEN_CONST
	movl	(%r12), %ecx
	movl	%r14d, %edi
	movq	%r15, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movl	-112(%rbp), %edi
	movl	$2, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %r14d
	leaq	L_.str.4(%rip), %r15
	movq	%r15, %rdi
	callq	_STRLEN_CONST
	movl	(%r12), %ecx
	movl	%r14d, %edi
	movq	%r15, %rsi
	movq	-120(%rbp), %rbx                ## 8-byte Reload
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteStartArray
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%rbx, %r14
	cmpq	$0, 8(%rbx)
	je	LBB0_14
## %bb.8:
	xorl	%r15d, %r15d
	xorl	%ebx, %ebx
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_9 Depth=1
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	incq	%rbx
	movq	-128(%rbp), %r15                ## 8-byte Reload
	addq	$56, %r15
	cmpq	8(%r14), %rbx
	jae	LBB0_14
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, -144(%rbp)                ## 8-byte Spill
	movl	-112(%rbp), %edi
	movl	$4, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteStartObject
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.5(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %r12d
	movq	24(%r14), %rax
	movq	%r15, %r14
	movq	(%rax,%r15), %rdi
	movq	%rdi, %r15
	movl	$0, %edx
	testq	%rdi, %rdi
	leaq	L_.str.6(%rip), %rax
	cmoveq	%rax, %r15
	je	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	callq	_strlen
	movl	%eax, %edx
LBB0_11:                                ##   in Loop: Header=BB0_9 Depth=1
	movq	_JSON_UTF8@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rax, %r13
	movl	%r12d, %edi
	movq	%r15, %rsi
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.7(%rip), %r15
	movq	%r15, %rdi
	callq	_STRLEN_CONST
	movl	(%r13), %ecx
	movl	%ebx, %edi
	movq	%r15, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %r15d
	movq	-120(%rbp), %r12                ## 8-byte Reload
	movq	24(%r12), %rax
	movq	8(%rax,%r14), %rbx
	movq	%rbx, %rdi
	callq	_strlen
	movl	(%r13), %ecx
	movl	%r15d, %edi
	movq	%r12, %r13
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -64(%rbp)
	movaps	%xmm0, -80(%rbp)
	movq	24(%r12), %rax
	movl	16(%rax,%r14), %ecx
	leaq	-80(%rbp), %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.9(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %r15
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	-80(%rbp), %r12
	movq	%r12, %rdi
	callq	_strlen
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	24(%r13), %rax
	movl	20(%rax,%r14), %ecx
	movq	%r14, %r15
	movq	%r12, %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.10(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %r14
	movl	(%r14), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	-80(%rbp), %r12
	movq	%r12, %rdi
	callq	_strlen
	movl	(%r14), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	24(%r13), %rax
	movl	24(%rax,%r15), %ecx
	movq	%r15, -128(%rbp)                ## 8-byte Spill
	movq	%r12, %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.11(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movl	(%r14), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	-80(%rbp), %r12
	movq	%r12, %rdi
	callq	_strlen
	movl	(%r14), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movq	%r12, %r14
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	24(%r13), %rax
	movl	28(%rax,%r15), %ecx
	movq	%r12, %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.12(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %r15
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	movq	%r14, %rdi
	callq	_strlen
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r14, %rsi
	movq	%r14, %r15
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	24(%r13), %rax
	movq	%r13, %r14
	movq	-128(%rbp), %rcx                ## 8-byte Reload
	movl	32(%rax,%rcx), %ecx
	movq	%r15, %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.13(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %r13
	movl	(%r13), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	movq	%r15, %rdi
	callq	_strlen
	movl	(%r13), %ecx
	movl	%ebx, %edi
	movq	%r15, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	24(%r14), %rax
	movq	-128(%rbp), %r13                ## 8-byte Reload
	movl	36(%rax,%r13), %ecx
	movq	%r15, %rdi
	movq	%r15, %r14
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.14(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %r15
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	movq	%r14, %rdi
	callq	_strlen
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r14, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	-120(%rbp), %r15                ## 8-byte Reload
	movq	24(%r15), %rax
	movl	40(%rax,%r13), %ecx
	movq	%r14, %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.15(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	movq	%r14, %rdi
	callq	_strlen
	movq	_JSON_UTF8@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ebx, %edi
	movq	%r14, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	24(%r15), %rax
	movl	44(%rax,%r13), %ecx
	movq	%r14, %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.16(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movq	_JSON_UTF8@GOTPCREL(%rip), %r15
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	movq	%r14, %rdi
	callq	_strlen
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r14, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	-120(%rbp), %r13                ## 8-byte Reload
	movq	24(%r13), %rax
	movq	-128(%rbp), %rcx                ## 8-byte Reload
	movl	48(%rax,%rcx), %ecx
	movq	%r14, %rdi
	movl	$32, %esi
	leaq	L_.str.8(%rip), %rdx
	callq	_snprintf
	movl	-112(%rbp), %edi
	movl	$6, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	leaq	L_.str.17(%rip), %r12
	movq	%r12, %rdi
	callq	_STRLEN_CONST
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteString
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteColon
	movl	-112(%rbp), %edi
	movl	$1, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %ebx
	movq	%r14, %rdi
	callq	_strlen
	movl	(%r15), %ecx
	movl	%ebx, %edi
	movq	%r14, %rsi
	movl	%eax, %edx
	callq	_JSON_Writer_WriteNumber
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movl	-112(%rbp), %edi
	movl	$4, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteEndObject
	movq	%r13, %r14
	movq	8(%r13), %rax
	decq	%rax
	movq	-144(%rbp), %rbx                ## 8-byte Reload
	cmpq	%rax, %rbx
	jae	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_9 Depth=1
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteComma
	jmp	LBB0_13
LBB0_14:
	movl	-112(%rbp), %edi
	movl	$2, %esi
	callq	_JSON_Writer_WriteSpace
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteEndArray
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteEndObject
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_WriteNewLine
	movl	-112(%rbp), %edi
	callq	_JSON_Writer_Free
	movl	$0, (%r14)
	movl	16(%r14), %esi
	leaq	L_.str.18(%rip), %rdi
	callq	_RARCH_LOG
	movq	-136(%rbp), %r15                ## 8-byte Reload
	jmp	LBB0_15
LBB0_3:
	movl	16(%rbx), %esi
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_18
## %bb.4:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	addq	$104, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_RARCH_ERR                      ## TAILCALL
LBB0_6:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_RARCH_ERR
LBB0_15:
	movq	%r15, %rdi
	callq	_filestream_close
LBB0_16:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_18
## %bb.17:
	addq	$104, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_RETRO_VFS_FILE_ACCESS_WRITE,4,2 ## @RETRO_VFS_FILE_ACCESS_WRITE
	.comm	_RETRO_VFS_FILE_ACCESS_HINT_NONE,4,2 ## @RETRO_VFS_FILE_ACCESS_HINT_NONE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to write to playlist file: %s\n"

L_.str.1:                               ## @.str.1
	.asciz	"Failed to create JSON writer\n"

	.comm	_JSON_UTF8,4,2                  ## @JSON_UTF8
	.comm	_JSONOutputHandler,4,2          ## @JSONOutputHandler
L_.str.2:                               ## @.str.2
	.asciz	"version"

L_.str.3:                               ## @.str.3
	.asciz	"1.0"

L_.str.4:                               ## @.str.4
	.asciz	"items"

L_.str.5:                               ## @.str.5
	.asciz	"path"

L_.str.6:                               ## @.str.6
	.space	1

L_.str.7:                               ## @.str.7
	.asciz	"core_path"

L_.str.8:                               ## @.str.8
	.asciz	"%u"

L_.str.9:                               ## @.str.9
	.asciz	"runtime_hours"

L_.str.10:                              ## @.str.10
	.asciz	"runtime_minutes"

L_.str.11:                              ## @.str.11
	.asciz	"runtime_seconds"

L_.str.12:                              ## @.str.12
	.asciz	"last_played_year"

L_.str.13:                              ## @.str.13
	.asciz	"last_played_month"

L_.str.14:                              ## @.str.14
	.asciz	"last_played_day"

L_.str.15:                              ## @.str.15
	.asciz	"last_played_hour"

L_.str.16:                              ## @.str.16
	.asciz	"last_played_minute"

L_.str.17:                              ## @.str.17
	.asciz	"last_played_second"

L_.str.18:                              ## @.str.18
	.asciz	"Written to playlist file: %s\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_playlist_write_runtime_file    ; -- Begin function playlist_write_runtime_file
	.p2align	2
_playlist_write_runtime_file:           ; @playlist_write_runtime_file
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #192
	.cfi_def_cfa_offset 192
	stp	x28, x27, [sp, #96]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #112]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #128]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #144]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #160]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #176]            ; 16-byte Folded Spill
	add	x29, sp, #176
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #88]
	stp	xzr, xzr, [sp, #24]
	str	xzr, [sp, #40]
	cbz	x0, LBB0_16
; %bb.1:
	mov	x19, x0
	ldr	w8, [x0]
	cbz	w8, LBB0_16
; %bb.2:
	ldr	w0, [x19, #16]
Lloh3:
	adrp	x8, _RETRO_VFS_FILE_ACCESS_WRITE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _RETRO_VFS_FILE_ACCESS_WRITE@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x8, _RETRO_VFS_FILE_ACCESS_HINT_NONE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _RETRO_VFS_FILE_ACCESS_HINT_NONE@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	bl	_filestream_open
	cbz	x0, LBB0_13
; %bb.3:
	mov	x21, x0
	mov	x0, #0
	bl	_JSON_Writer_Create
	str	w0, [sp, #24]
	str	x21, [sp, #32]
	cbz	w0, LBB0_14
; %bb.4:
	mov	x20, x0
	str	x21, [sp, #16]                  ; 8-byte Folded Spill
Lloh9:
	adrp	x27, _JSON_UTF8@GOTPAGE
Lloh10:
	ldr	x27, [x27, _JSON_UTF8@GOTPAGEOFF]
	ldr	w1, [x27]
	bl	_JSON_Writer_SetOutputEncoding
Lloh11:
	adrp	x1, _JSONOutputHandler@GOTPAGE
Lloh12:
	ldr	x1, [x1, _JSONOutputHandler@GOTPAGEOFF]
	mov	x0, x20
	bl	_JSON_Writer_SetOutputHandler
	add	x1, sp, #24
	mov	x0, x20
	bl	_JSON_Writer_SetUserData
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteStartObject
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	w0, [sp, #24]
	mov	w1, #2
	bl	_JSON_Writer_WriteSpace
	ldr	w20, [sp, #24]
Lloh13:
	adrp	x21, l_.str.2@PAGE
Lloh14:
	add	x21, x21, l_.str.2@PAGEOFF
	mov	x0, x21
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x20
	mov	x1, x21
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w20, [sp, #24]
Lloh15:
	adrp	x21, l_.str.3@PAGE
Lloh16:
	add	x21, x21, l_.str.3@PAGEOFF
	mov	x0, x21
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x20
	mov	x1, x21
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	w0, [sp, #24]
	mov	w1, #2
	bl	_JSON_Writer_WriteSpace
	ldr	w20, [sp, #24]
Lloh17:
	adrp	x21, l_.str.4@PAGE
Lloh18:
	add	x21, x21, l_.str.4@PAGEOFF
	mov	x0, x21
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x20
	mov	x1, x21
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteStartArray
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_12
; %bb.5:
	mov	x28, #0
	mov	x20, #0
Lloh19:
	adrp	x23, l_.str.8@PAGE
Lloh20:
	add	x23, x23, l_.str.8@PAGEOFF
Lloh21:
	adrp	x21, l_.str.15@PAGE
Lloh22:
	add	x21, x21, l_.str.15@PAGEOFF
Lloh23:
	adrp	x22, l_.str.16@PAGE
Lloh24:
	add	x22, x22, l_.str.16@PAGEOFF
Lloh25:
	adrp	x24, l_.str.17@PAGE
Lloh26:
	add	x24, x24, l_.str.17@PAGEOFF
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x20, x20, #1
	ldr	x8, [x19, #8]
	add	x28, x28, #56
	cmp	x20, x8
	b.hs	LBB0_12
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [sp, #24]
	mov	w1, #4
	bl	_JSON_Writer_WriteSpace
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteStartObject
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh27:
	adrp	x26, l_.str.5@PAGE
Lloh28:
	add	x26, x26, l_.str.5@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	ldr	x8, [x19, #24]
	ldr	x0, [x8, x28]
	cmp	x0, #0
Lloh29:
	adrp	x8, l_.str.6@PAGE
Lloh30:
	add	x8, x8, l_.str.6@PAGEOFF
	csel	x26, x8, x0, eq
	cbz	x0, LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	bl	_strlen
	mov	x2, x0
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	w2, #0
LBB0_10:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh31:
	adrp	x26, l_.str.7@PAGE
Lloh32:
	add	x26, x26, l_.str.7@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	x26, [x8, #8]
	mov	x0, x26
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	movi.2d	v0, #0000000000000000
	stp	q0, q0, [sp, #48]
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #16]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh33:
	adrp	x26, l_.str.9@PAGE
Lloh34:
	add	x26, x26, l_.str.9@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #20]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh35:
	adrp	x26, l_.str.10@PAGE
Lloh36:
	add	x26, x26, l_.str.10@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #24]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh37:
	adrp	x26, l_.str.11@PAGE
Lloh38:
	add	x26, x26, l_.str.11@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #28]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh39:
	adrp	x26, l_.str.12@PAGE
Lloh40:
	add	x26, x26, l_.str.12@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #32]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh41:
	adrp	x26, l_.str.13@PAGE
Lloh42:
	add	x26, x26, l_.str.13@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #36]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
Lloh43:
	adrp	x26, l_.str.14@PAGE
Lloh44:
	add	x26, x26, l_.str.14@PAGEOFF
	mov	x0, x26
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x26
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #40]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	mov	x0, x21
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x21
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #44]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	mov	x0, x22
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x22
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	ldr	x8, [x19, #24]
	add	x8, x8, x28
	ldr	w3, [x8, #48]
	add	x0, sp, #48
	mov	w1, #32
	mov	x2, x23
	bl	_snprintf
	ldr	w0, [sp, #24]
	mov	w1, #6
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	mov	x0, x24
	bl	_STRLEN_CONST
	mov	x2, x0
	ldr	w3, [x27]
	mov	x0, x25
	mov	x1, x24
	bl	_JSON_Writer_WriteString
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteColon
	ldr	w0, [sp, #24]
	mov	w1, #1
	bl	_JSON_Writer_WriteSpace
	ldr	w25, [sp, #24]
	add	x0, sp, #48
	bl	_strlen
	mov	x2, x0
	ldr	w3, [x27]
	add	x1, sp, #48
	mov	x0, x25
	bl	_JSON_Writer_WriteNumber
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	w0, [sp, #24]
	mov	w1, #4
	bl	_JSON_Writer_WriteSpace
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteEndObject
	ldr	x8, [x19, #8]
	sub	x8, x8, #1
	cmp	x20, x8
	b.hs	LBB0_6
; %bb.11:                               ;   in Loop: Header=BB0_7 Depth=1
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteComma
	b	LBB0_6
LBB0_12:
	ldr	w0, [sp, #24]
	mov	w1, #2
	bl	_JSON_Writer_WriteSpace
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteEndArray
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteEndObject
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_WriteNewLine
	ldr	w0, [sp, #24]
	bl	_JSON_Writer_Free
	str	wzr, [x19]
	ldr	w1, [x19, #16]
Lloh45:
	adrp	x0, l_.str.18@PAGE
Lloh46:
	add	x0, x0, l_.str.18@PAGEOFF
	bl	_RARCH_LOG
	ldr	x21, [sp, #16]                  ; 8-byte Folded Reload
	b	LBB0_15
LBB0_13:
	ldr	w8, [x19, #16]
	str	x8, [sp]
Lloh47:
	adrp	x0, l_.str@PAGE
Lloh48:
	add	x0, x0, l_.str@PAGEOFF
	bl	_RARCH_ERR
	b	LBB0_16
LBB0_14:
Lloh49:
	adrp	x0, l_.str.1@PAGE
Lloh50:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_RARCH_ERR
LBB0_15:
	mov	x0, x21
	bl	_filestream_close
LBB0_16:
	ldr	x8, [sp, #88]
Lloh51:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh52:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh53:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_18
; %bb.17:
	ldp	x29, x30, [sp, #176]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #160]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #144]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #128]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #112]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #96]             ; 16-byte Folded Reload
	add	sp, sp, #192
	ret
LBB0_18:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpAdd	Lloh41, Lloh42
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpAdd	Lloh47, Lloh48
	.loh AdrpAdd	Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.cfi_endproc
                                        ; -- End function
	.comm	_RETRO_VFS_FILE_ACCESS_WRITE,4,2 ; @RETRO_VFS_FILE_ACCESS_WRITE
	.comm	_RETRO_VFS_FILE_ACCESS_HINT_NONE,4,2 ; @RETRO_VFS_FILE_ACCESS_HINT_NONE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to write to playlist file: %s\n"

l_.str.1:                               ; @.str.1
	.asciz	"Failed to create JSON writer\n"

	.comm	_JSON_UTF8,4,2                  ; @JSON_UTF8
	.comm	_JSONOutputHandler,4,2          ; @JSONOutputHandler
l_.str.2:                               ; @.str.2
	.asciz	"version"

l_.str.3:                               ; @.str.3
	.asciz	"1.0"

l_.str.4:                               ; @.str.4
	.asciz	"items"

l_.str.5:                               ; @.str.5
	.asciz	"path"

l_.str.6:                               ; @.str.6
	.space	1

l_.str.7:                               ; @.str.7
	.asciz	"core_path"

l_.str.8:                               ; @.str.8
	.asciz	"%u"

l_.str.9:                               ; @.str.9
	.asciz	"runtime_hours"

l_.str.10:                              ; @.str.10
	.asciz	"runtime_minutes"

l_.str.11:                              ; @.str.11
	.asciz	"runtime_seconds"

l_.str.12:                              ; @.str.12
	.asciz	"last_played_year"

l_.str.13:                              ; @.str.13
	.asciz	"last_played_month"

l_.str.14:                              ; @.str.14
	.asciz	"last_played_day"

l_.str.15:                              ; @.str.15
	.asciz	"last_played_hour"

l_.str.16:                              ; @.str.16
	.asciz	"last_played_minute"

l_.str.17:                              ; @.str.17
	.asciz	"last_played_second"

l_.str.18:                              ; @.str.18
	.asciz	"Written to playlist file: %s\n"

.subsections_via_symbols
