[+] Debug config

[*] Update legacy macros to modern pipeline under debug
This commit is contained in:
Reece Wilson 2022-06-01 15:25:32 +01:00
parent db3f41233b
commit b500c0bd5f
5 changed files with 16 additions and 5 deletions

View File

@ -250,6 +250,11 @@ namespace Aurora
AuString defaultBrand = "Aurora"; AuString defaultBrand = "Aurora";
}; };
struct DebugConfig
{
bool nonshipPrecachesSymbols {true};
};
struct RuntimeStartInfo struct RuntimeStartInfo
{ {
ConsoleConfig console; ConsoleConfig console;
@ -257,6 +262,7 @@ namespace Aurora
TelemetryConfig telemetry; TelemetryConfig telemetry;
AsyncConfig async; AsyncConfig async;
FIOConfig fio; FIOConfig fio;
DebugConfig debug;
bool bFIODisableBatching {true}; bool bFIODisableBatching {true};
}; };

View File

@ -103,7 +103,7 @@ namespace Aurora::Console::ConsoleStd
static AuList<NoncanonicalInput> gCanonicalBuffer; static AuList<NoncanonicalInput> gCanonicalBuffer;
//static AuThreadPrimitives::MutexUnique_t gRingLock = AuThreadPrimitives::MutexUnique(); //static AuThreadPrimitives::MutexUnique_t gRingLock = AuThreadPrimitives::MutexUnique();
static AuThreadPrimitives::SpinLock gRingLock {};// = AuThreadPrimitives::MutexUnique(); static AuThreadPrimitives::SpinLock gRingLock;// = AuThreadPrimitives::MutexUnique();
#if defined(AURORA_IS_MODERNNT_DERIVED) #if defined(AURORA_IS_MODERNNT_DERIVED)

View File

@ -142,7 +142,7 @@ namespace Aurora::Debug
{ {
static bool handlingFatal = false; static bool handlingFatal = false;
#if defined(DEBUG) || defined(INTERNAL) #if defined(AU_ENABLE_NATIVE_MINIDUMP)
if (!fatal) if (!fatal)
{ {
if (IsDebuggerPresent()) __debugbreak(); if (IsDebuggerPresent()) __debugbreak();

View File

@ -244,7 +244,7 @@ namespace Aurora::Debug
} }
} }
#if defined(DEBUG) || defined(INTERNAL) #if defined(AU_ENABLE_NATIVE_MINIDUMP)
void SaveMinidump(_EXCEPTION_POINTERS *ExceptionInfo, bool isFatal) void SaveMinidump(_EXCEPTION_POINTERS *ExceptionInfo, bool isFatal)
{ {
bool ok {}; bool ok {};
@ -409,7 +409,10 @@ namespace Aurora::Debug
void InitWin32() void InitWin32()
{ {
// ... // ...
CacheInternalBuildSymbols(); if (gRuntimeConfig.debug.nonshipPrecachesSymbols)
{
CacheInternalBuildSymbols();
}
// ... // ...
DisableWindowsErrorReporting(); DisableWindowsErrorReporting();

View File

@ -11,8 +11,10 @@ namespace Aurora::Debug
{ {
void InitWin32(); void InitWin32();
#if defined(DEBUG) || defined(INTERNAL) #if defined(AU_CFG_ID_DEBUG) || defined(AU_CFG_ID_INTERNAL)
#define AU_ENABLE_NATIVE_MINIDUMP
void SaveMinidump(_EXCEPTION_POINTERS *ExceptionInfo, bool isFatal); void SaveMinidump(_EXCEPTION_POINTERS *ExceptionInfo, bool isFatal);
#endif #endif
void BlackboxReport(_EXCEPTION_POINTERS *ExceptionInfo, bool isFatal); void BlackboxReport(_EXCEPTION_POINTERS *ExceptionInfo, bool isFatal);
} }