[+] Internal void Aurora::Win32Terminate()
[+] Global NT-like Aurora::gUseFastFail
This commit is contained in:
parent
c0388144d0
commit
655f1839c5
@ -136,6 +136,12 @@ namespace Aurora
|
||||
(AuBuild::kCurrentPlatform != AuBuild::EPlatform::ePlatformWin32) ||
|
||||
(!gRuntimeConfig.threadingConfig.bEnableAggressiveScheduling &&
|
||||
AuSwInfo::IsWindows10OrGreater());
|
||||
|
||||
gUseFastFail = AuSwInfo::IsWindows8Point1OrGreater()
|
||||
#if defined(PF_FASTFAIL_AVAILABLE)
|
||||
&& ::IsProcessorFeaturePresent(PF_FASTFAIL_AVAILABLE)
|
||||
#endif
|
||||
;
|
||||
}
|
||||
|
||||
void Win32DropSchedulerResolution()
|
||||
@ -175,4 +181,16 @@ namespace Aurora
|
||||
|
||||
// ...SetProcessInformation?
|
||||
}
|
||||
|
||||
void Win32Terminate()
|
||||
{
|
||||
if (gUseFastFail)
|
||||
{
|
||||
__fastfail('fokd');
|
||||
}
|
||||
else
|
||||
{
|
||||
TerminateProcess(GetCurrentProcess(), 0);
|
||||
}
|
||||
}
|
||||
}
|
@ -200,6 +200,10 @@ namespace Aurora
|
||||
inline bool gUseNativeWaitCondvar {};
|
||||
inline bool gUseNativeWaitSemapahore {};
|
||||
|
||||
inline bool gUseFastFail {};
|
||||
|
||||
void Win32DropInit();
|
||||
void Win32DropSchedulerResolution();
|
||||
|
||||
void Win32Terminate();
|
||||
}
|
@ -421,14 +421,7 @@ namespace Aurora::Debug
|
||||
|
||||
}
|
||||
|
||||
if (AuSwInfo::IsWindows8Point1OrGreater())
|
||||
{
|
||||
__fastfail('fokd');
|
||||
}
|
||||
else
|
||||
{
|
||||
TerminateProcess(GetCurrentProcess(), 0);
|
||||
}
|
||||
Win32Terminate();
|
||||
}
|
||||
}
|
||||
#endif
|
||||
@ -499,14 +492,7 @@ namespace Aurora::Debug
|
||||
report.resource.type = Telemetry::ENewBlackBoxResourceType::eLocal;
|
||||
Telemetry::ReportDyingBreath(report);
|
||||
|
||||
if (AuSwInfo::IsWindows8Point1OrGreater())
|
||||
{
|
||||
__fastfail('fokd');
|
||||
}
|
||||
else
|
||||
{
|
||||
TerminateProcess(GetCurrentProcess(), 0);
|
||||
}
|
||||
Win32Terminate();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -116,14 +116,7 @@ namespace Aurora::Debug
|
||||
}
|
||||
|
||||
#if defined(AURORA_IS_MODERNNT_DERIVED)
|
||||
if (AuSwInfo::IsWindows8Point1OrGreater())
|
||||
{
|
||||
__fastfail('fokd');
|
||||
}
|
||||
else
|
||||
{
|
||||
TerminateProcess(GetCurrentProcess(), 0);
|
||||
}
|
||||
Win32Terminate();
|
||||
#else
|
||||
#if defined(AURORA_COMPILER_GCC) || defined(AURORA_COMPILER_CLANG)
|
||||
__builtin_trap();
|
||||
|
Loading…
Reference in New Issue
Block a user