	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function LogToFile
_LogToFile:                             ## @LogToFile
	.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	%ecx, %ebx
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movl	%esi, %r14d
	movq	%rdi, %r15
	callq	_wcslen
	movl	%eax, %r13d
	movq	_LOG_ERROR@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_4
## %bb.1:
	movq	_FORMAT_MESSAGE_ALLOCATE_BUFFER@GOTPCREL(%rip), %rax
	movq	_FORMAT_MESSAGE_FROM_SYSTEM@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rax), %ebx
	movq	_LANG_NEUTRAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SUBLANG_DEFAULT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_MAKELANGID
	movq	$0, (%rsp)
	leaq	-64(%rbp), %r8
	movl	%ebx, %edi
	xorl	%esi, %esi
	movl	%r14d, -52(%rbp)                ## 4-byte Spill
	movl	%r14d, %edx
	movl	%eax, %ecx
	xorl	%r9d, %r9d
	callq	_FormatMessageW
	movl	%eax, %r14d
	leal	(%r14,%r13), %ebx
	xorl	%eax, %eax
	callq	_GetProcessHeap
	leal	164(,%rbx,4), %edx
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_HeapAlloc
	movq	%rax, %r12
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	leal	(%r14,%r13), %esi
	addl	$41, %esi
	movq	-64(%rbp), %r8
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%rsp)
	leaq	l_.str(%rip), %rdx
	movq	%r12, %rdi
	movq	%r15, %rcx
	movl	-52(%rbp), %r9d                 ## 4-byte Reload
	xorl	%eax, %eax
	callq	__snwprintf
LBB0_3:
	movq	-64(%rbp), %rdi
	callq	_LocalFree
	jmp	LBB0_6
LBB0_4:
	xorl	%r12d, %r12d
	xorl	%eax, %eax
	callq	_GetProcessHeap
	leal	12(,%r13,4), %edx
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_HeapAlloc
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movq	%rax, %rbx
	addl	$3, %r13d
	leaq	l_.str.1(%rip), %rdx
	movq	%rax, %rdi
	movl	%r13d, %esi
	movq	%r15, %rcx
	xorl	%eax, %eax
	callq	__snwprintf
	movq	%rbx, %r12
LBB0_6:
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	movq	%r12, %rdi
	callq	_wcslen
	movl	%eax, %ebx
	cltq
	movq	_MAXDWORD@GOTPCREL(%rip), %rcx
	movslq	(%rcx), %rcx
	shrq	$2, %rcx
	cmpq	%rax, %rcx
	jae	LBB0_8
## %bb.7:
	movq	_EXCEPTION_INT_OVERFLOW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_RaiseException
LBB0_8:
	testq	%r12, %r12
	je	LBB0_18
## %bb.9:
	movq	_hLogFile@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	shll	$2, %ebx
	movq	_olWrite@GOTPCREL(%rip), %r15
	leaq	-48(%rbp), %rcx
	movq	%r12, %rsi
	movl	%ebx, %edx
	movq	%r15, %r8
	callq	_WriteFile
	testq	%rax, %rax
	jne	LBB0_14
## %bb.10:
	xorl	%eax, %eax
	callq	_GetLastError
	movq	_ERROR_IO_PENDING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_13
## %bb.11:
	movl	(%r15), %edi
	movq	_INFINITE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_WaitForSingleObject
	cmpl	$128, %eax
	jne	LBB0_13
## %bb.12:
	movl	(%r14), %edi
	movq	_FALSE@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	_olWrite@GOTPCREL(%rip), %rsi
	leaq	-48(%rbp), %rdx
	callq	_GetOverlappedResult
	jmp	LBB0_14
LBB0_13:
	movq	_FALSE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
LBB0_14:
	testq	%rax, %rax
	je	LBB0_16
## %bb.15:
	cmpl	$0, -48(%rbp)
	jne	LBB0_17
LBB0_16:
	xorl	%eax, %eax
	callq	_GetLastError
	movq	_LOG_EVENTLOG@GOTPCREL(%rip), %rdx
	movq	_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rdx), %ecx
	leaq	l_.str.2(%rip), %rdi
	movq	%rax, %rsi
	xorl	%edx, %edx
	callq	_LogToEventLog
LBB0_17:
	xorl	%eax, %eax
	callq	_GetProcessHeap
	movl	%eax, %edi
	xorl	%esi, %esi
	movq	%r12, %rdx
	callq	_HeapFree
LBB0_18:
	testl	%r13d, %r13d
	jle	LBB0_20
## %bb.19:
	movl	%r13d, %edi
	callq	_ExitProcess
LBB0_20:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LOG_ERROR,4,2                  ## @LOG_ERROR
	.comm	_FORMAT_MESSAGE_ALLOCATE_BUFFER,4,2 ## @FORMAT_MESSAGE_ALLOCATE_BUFFER
	.comm	_FORMAT_MESSAGE_FROM_SYSTEM,4,2 ## @FORMAT_MESSAGE_FROM_SYSTEM
	.comm	_LANG_NEUTRAL,4,2               ## @LANG_NEUTRAL
	.comm	_SUBLANG_DEFAULT,4,2            ## @SUBLANG_DEFAULT
	.section	__TEXT,__const
	.p2align	2                               ## @.str
l_.str:
	.long	37                              ## 0x25
	.long	115                             ## 0x73
	.long	32                              ## 0x20
	.long	58                              ## 0x3a
	.long	32                              ## 0x20
	.long	37                              ## 0x25
	.long	115                             ## 0x73
	.long	9                               ## 0x9
	.long	69                              ## 0x45
	.long	114                             ## 0x72
	.long	114                             ## 0x72
	.long	78                              ## 0x4e
	.long	117                             ## 0x75
	.long	109                             ## 0x6d
	.long	32                              ## 0x20
	.long	61                              ## 0x3d
	.long	32                              ## 0x20
	.long	37                              ## 0x25
	.long	108                             ## 0x6c
	.long	117                             ## 0x75
	.long	32                              ## 0x20
	.long	69                              ## 0x45
	.long	120                             ## 0x78
	.long	105                             ## 0x69
	.long	116                             ## 0x74
	.long	67                              ## 0x43
	.long	111                             ## 0x6f
	.long	100                             ## 0x64
	.long	101                             ## 0x65
	.long	32                              ## 0x20
	.long	61                              ## 0x3d
	.long	32                              ## 0x20
	.long	37                              ## 0x25
	.long	108                             ## 0x6c
	.long	117                             ## 0x75
	.long	13                              ## 0xd
	.long	10                              ## 0xa
	.long	0                               ## 0x0

	.p2align	2                               ## @.str.1
l_.str.1:
	.long	37                              ## 0x25
	.long	115                             ## 0x73
	.long	13                              ## 0xd
	.long	10                              ## 0xa
	.long	0                               ## 0x0

	.comm	_MAXDWORD,4,2                   ## @MAXDWORD
	.comm	_EXCEPTION_INT_OVERFLOW,4,2     ## @EXCEPTION_INT_OVERFLOW
	.comm	_hLogFile,4,2                   ## @hLogFile
	.comm	_olWrite,4,2                    ## @olWrite
	.comm	_ERROR_IO_PENDING,8,3           ## @ERROR_IO_PENDING
	.comm	_FALSE,8,3                      ## @FALSE
	.comm	_INFINITE,4,2                   ## @INFINITE
	.p2align	2                               ## @.str.2
l_.str.2:
	.long	70                              ## 0x46
	.long	97                              ## 0x61
	.long	105                             ## 0x69
	.long	108                             ## 0x6c
	.long	101                             ## 0x65
	.long	100                             ## 0x64
	.long	32                              ## 0x20
	.long	116                             ## 0x74
	.long	111                             ## 0x6f
	.long	32                              ## 0x20
	.long	119                             ## 0x77
	.long	114                             ## 0x72
	.long	105                             ## 0x69
	.long	116                             ## 0x74
	.long	101                             ## 0x65
	.long	32                              ## 0x20
	.long	116                             ## 0x74
	.long	111                             ## 0x6f
	.long	32                              ## 0x20
	.long	108                             ## 0x6c
	.long	111                             ## 0x6f
	.long	103                             ## 0x67
	.long	32                              ## 0x20
	.long	102                             ## 0x66
	.long	105                             ## 0x69
	.long	108                             ## 0x6c
	.long	101                             ## 0x65
	.long	0                               ## 0x0

	.comm	_LOG_EVENTLOG,4,2               ## @LOG_EVENTLOG
	.no_dead_strip	_LogToFile
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function LogToFile
_LogToFile:                             ; @LogToFile
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x23, x3
	mov	x19, x2
	mov	x22, x1
	mov	x21, x0
	bl	_wcslen
	mov	x20, x0
Lloh0:
	adrp	x24, _LOG_ERROR@GOTPAGE
Lloh1:
	ldr	x24, [x24, _LOG_ERROR@GOTPAGEOFF]
	ldr	w8, [x24]
	tst	w8, w23
	b.eq	LBB0_4
; %bb.1:
Lloh2:
	adrp	x8, _FORMAT_MESSAGE_ALLOCATE_BUFFER@GOTPAGE
Lloh3:
	ldr	x8, [x8, _FORMAT_MESSAGE_ALLOCATE_BUFFER@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _FORMAT_MESSAGE_FROM_SYSTEM@GOTPAGE
Lloh6:
	ldr	x9, [x9, _FORMAT_MESSAGE_FROM_SYSTEM@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w23, w9, w8
Lloh8:
	adrp	x8, _LANG_NEUTRAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _LANG_NEUTRAL@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
Lloh11:
	adrp	x8, _SUBLANG_DEFAULT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _SUBLANG_DEFAULT@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	bl	_MAKELANGID
	mov	x3, x0
	add	x4, sp, #40
	mov	x0, x23
	mov	x1, #0
	mov	x2, x22
	mov	w5, #0
	mov	x6, #0
	bl	_FormatMessageW
	add	w8, w20, w0
	add	w23, w8, #41
	bl	_GetProcessHeap
	lsl	w2, w23, #2
	mov	w1, #0
	bl	_HeapAlloc
	mov	x20, x0
	cbz	x0, LBB0_3
; %bb.2:
	ldr	x8, [sp, #40]
	stp	x22, x19, [sp, #8]
	str	x8, [sp]
Lloh14:
	adrp	x2, l_.str@PAGE
Lloh15:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	mov	x1, x23
	mov	x3, x21
	bl	__snwprintf
LBB0_3:
	ldr	x0, [sp, #40]
	bl	_LocalFree
	b	LBB0_6
LBB0_4:
	add	w22, w20, #3
	bl	_GetProcessHeap
	lsl	w2, w22, #2
	mov	w1, #0
	bl	_HeapAlloc
	mov	x20, x0
	cbz	x0, LBB0_6
; %bb.5:
Lloh16:
	adrp	x2, l_.str.1@PAGE
Lloh17:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	x1, x22
	mov	x3, x21
	bl	__snwprintf
LBB0_6:
	mov	x0, x20
	bl	_wcslen
	mov	x21, x0
	sxtw	x8, w21
Lloh18:
	adrp	x9, _MAXDWORD@GOTPAGE
Lloh19:
	ldr	x9, [x9, _MAXDWORD@GOTPAGEOFF]
Lloh20:
	ldrsw	x9, [x9]
	cmp	x8, x9, lsr #2
	b.ls	LBB0_8
; %bb.7:
Lloh21:
	adrp	x8, _EXCEPTION_INT_OVERFLOW@GOTPAGE
Lloh22:
	ldr	x8, [x8, _EXCEPTION_INT_OVERFLOW@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	mov	w1, #0
	mov	w2, #0
	mov	x3, #0
	bl	_RaiseException
LBB0_8:
	cbz	x20, LBB0_17
; %bb.9:
Lloh24:
	adrp	x22, _hLogFile@GOTPAGE
Lloh25:
	ldr	x22, [x22, _hLogFile@GOTPAGEOFF]
	ldr	w0, [x22]
	lsl	w2, w21, #2
Lloh26:
	adrp	x21, _olWrite@GOTPAGE
Lloh27:
	ldr	x21, [x21, _olWrite@GOTPAGEOFF]
	add	x3, sp, #36
	mov	x1, x20
	mov	x4, x21
	bl	_WriteFile
	cbnz	x0, LBB0_14
; %bb.10:
	bl	_GetLastError
Lloh28:
	adrp	x8, _ERROR_IO_PENDING@GOTPAGE
Lloh29:
	ldr	x8, [x8, _ERROR_IO_PENDING@GOTPAGEOFF]
Lloh30:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_13
; %bb.11:
	ldr	w0, [x21]
Lloh31:
	adrp	x8, _INFINITE@GOTPAGE
Lloh32:
	ldr	x8, [x8, _INFINITE@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x8]
	bl	_WaitForSingleObject
	cmp	w0, #128
	b.ne	LBB0_13
; %bb.12:
	ldr	w0, [x22]
Lloh34:
	adrp	x8, _FALSE@GOTPAGE
Lloh35:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh36:
	ldr	x3, [x8]
Lloh37:
	adrp	x1, _olWrite@GOTPAGE
Lloh38:
	ldr	x1, [x1, _olWrite@GOTPAGEOFF]
	add	x2, sp, #36
	bl	_GetOverlappedResult
	b	LBB0_14
LBB0_13:
Lloh39:
	adrp	x8, _FALSE@GOTPAGE
Lloh40:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh41:
	ldr	x0, [x8]
LBB0_14:
	ldr	w8, [sp, #36]
	cmp	x0, #0
	ccmp	w8, #0, #4, ne
	b.ne	LBB0_16
; %bb.15:
	bl	_GetLastError
	mov	x1, x0
Lloh42:
	adrp	x8, _LOG_EVENTLOG@GOTPAGE
Lloh43:
	ldr	x8, [x8, _LOG_EVENTLOG@GOTPAGEOFF]
Lloh44:
	ldr	w8, [x8]
	ldr	w9, [x24]
	orr	w3, w9, w8
Lloh45:
	adrp	x0, l_.str.2@PAGE
Lloh46:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	w2, #0
	bl	_LogToEventLog
LBB0_16:
	bl	_GetProcessHeap
	mov	w1, #0
	mov	x2, x20
	bl	_HeapFree
LBB0_17:
	cmp	w19, #1
	b.lt	LBB0_19
; %bb.18:
	mov	x0, x19
	bl	_ExitProcess
LBB0_19:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.cfi_endproc
                                        ; -- End function
	.comm	_LOG_ERROR,4,2                  ; @LOG_ERROR
	.comm	_FORMAT_MESSAGE_ALLOCATE_BUFFER,4,2 ; @FORMAT_MESSAGE_ALLOCATE_BUFFER
	.comm	_FORMAT_MESSAGE_FROM_SYSTEM,4,2 ; @FORMAT_MESSAGE_FROM_SYSTEM
	.comm	_LANG_NEUTRAL,4,2               ; @LANG_NEUTRAL
	.comm	_SUBLANG_DEFAULT,4,2            ; @SUBLANG_DEFAULT
	.section	__TEXT,__const
	.p2align	2                               ; @.str
l_.str:
	.long	37                              ; 0x25
	.long	115                             ; 0x73
	.long	32                              ; 0x20
	.long	58                              ; 0x3a
	.long	32                              ; 0x20
	.long	37                              ; 0x25
	.long	115                             ; 0x73
	.long	9                               ; 0x9
	.long	69                              ; 0x45
	.long	114                             ; 0x72
	.long	114                             ; 0x72
	.long	78                              ; 0x4e
	.long	117                             ; 0x75
	.long	109                             ; 0x6d
	.long	32                              ; 0x20
	.long	61                              ; 0x3d
	.long	32                              ; 0x20
	.long	37                              ; 0x25
	.long	108                             ; 0x6c
	.long	117                             ; 0x75
	.long	32                              ; 0x20
	.long	69                              ; 0x45
	.long	120                             ; 0x78
	.long	105                             ; 0x69
	.long	116                             ; 0x74
	.long	67                              ; 0x43
	.long	111                             ; 0x6f
	.long	100                             ; 0x64
	.long	101                             ; 0x65
	.long	32                              ; 0x20
	.long	61                              ; 0x3d
	.long	32                              ; 0x20
	.long	37                              ; 0x25
	.long	108                             ; 0x6c
	.long	117                             ; 0x75
	.long	13                              ; 0xd
	.long	10                              ; 0xa
	.long	0                               ; 0x0

	.p2align	2                               ; @.str.1
l_.str.1:
	.long	37                              ; 0x25
	.long	115                             ; 0x73
	.long	13                              ; 0xd
	.long	10                              ; 0xa
	.long	0                               ; 0x0

	.comm	_MAXDWORD,4,2                   ; @MAXDWORD
	.comm	_EXCEPTION_INT_OVERFLOW,4,2     ; @EXCEPTION_INT_OVERFLOW
	.comm	_hLogFile,4,2                   ; @hLogFile
	.comm	_olWrite,4,2                    ; @olWrite
	.comm	_ERROR_IO_PENDING,8,3           ; @ERROR_IO_PENDING
	.comm	_FALSE,8,3                      ; @FALSE
	.comm	_INFINITE,4,2                   ; @INFINITE
	.p2align	2                               ; @.str.2
l_.str.2:
	.long	70                              ; 0x46
	.long	97                              ; 0x61
	.long	105                             ; 0x69
	.long	108                             ; 0x6c
	.long	101                             ; 0x65
	.long	100                             ; 0x64
	.long	32                              ; 0x20
	.long	116                             ; 0x74
	.long	111                             ; 0x6f
	.long	32                              ; 0x20
	.long	119                             ; 0x77
	.long	114                             ; 0x72
	.long	105                             ; 0x69
	.long	116                             ; 0x74
	.long	101                             ; 0x65
	.long	32                              ; 0x20
	.long	116                             ; 0x74
	.long	111                             ; 0x6f
	.long	32                              ; 0x20
	.long	108                             ; 0x6c
	.long	111                             ; 0x6f
	.long	103                             ; 0x67
	.long	32                              ; 0x20
	.long	102                             ; 0x66
	.long	105                             ; 0x69
	.long	108                             ; 0x6c
	.long	101                             ; 0x65
	.long	0                               ; 0x0

	.comm	_LOG_EVENTLOG,4,2               ; @LOG_EVENTLOG
	.no_dead_strip	_LogToFile
.subsections_via_symbols
