	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__vcos_log_platform_init        ## -- Begin function _vcos_log_platform_init
	.p2align	4, 0x90
__vcos_log_platform_init:               ## @_vcos_log_platform_init
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	subq	$120, %rsp
	.cfi_offset %rbx, -24
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -16(%rbp)
	movq	_vcos_log_to_file@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_2
## %bb.1:
	xorl	%eax, %eax
	callq	_vcos_process_id_current
	leaq	L_.str(%rip), %rdx
	leaq	-128(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$100, %esi
	movl	%eax, %ecx
	callq	_snprintf
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_fopen
	jmp	LBB0_3
LBB0_2:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_3:
	movq	_log_fhandle@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-16(%rbp), %rax
	jne	LBB0_5
## %bb.4:
	addq	$120, %rsp
	popq	%rbx
	popq	%rbp
	retq
LBB0_5:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_vcos_log_to_file,8,3           ## @vcos_log_to_file
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"/var/log/vcos_log%u.txt"

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

	.comm	_log_fhandle,4,2                ## @log_fhandle
	.comm	_stderr,4,2                     ## @stderr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__vcos_log_platform_init        ; -- Begin function _vcos_log_platform_init
	.p2align	2
__vcos_log_platform_init:               ; @_vcos_log_platform_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-8]
Lloh3:
	adrp	x8, _vcos_log_to_file@GOTPAGE
Lloh4:
	ldr	x8, [x8, _vcos_log_to_file@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cbz	x8, LBB0_2
; %bb.1:
	bl	_vcos_process_id_current
	mov	x3, x0
Lloh6:
	adrp	x2, l_.str@PAGE
Lloh7:
	add	x2, x2, l_.str@PAGEOFF
	add	x0, sp, #4
	mov	w1, #100
	bl	_snprintf
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x0, sp, #4
	bl	_fopen
Lloh10:
	adrp	x8, _log_fhandle@GOTPAGE
Lloh11:
	ldr	x8, [x8, _log_fhandle@GOTPAGEOFF]
Lloh12:
	str	w0, [x8]
	b	LBB0_3
LBB0_2:
Lloh13:
	adrp	x8, _stderr@GOTPAGE
Lloh14:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
Lloh16:
	adrp	x9, _log_fhandle@GOTPAGE
Lloh17:
	ldr	x9, [x9, _log_fhandle@GOTPAGEOFF]
Lloh18:
	str	w8, [x9]
LBB0_3:
	ldur	x8, [x29, #-8]
Lloh19:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh20:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_5
; %bb.4:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_5:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotStr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotStr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_vcos_log_to_file,8,3           ; @vcos_log_to_file
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"/var/log/vcos_log%u.txt"

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

	.comm	_log_fhandle,4,2                ; @log_fhandle
	.comm	_stderr,4,2                     ; @stderr
.subsections_via_symbols
