diff --git a/Include/Aurora/Runtime.hpp b/Include/Aurora/Runtime.hpp index fab3bbc7..67028b9f 100644 --- a/Include/Aurora/Runtime.hpp +++ b/Include/Aurora/Runtime.hpp @@ -250,6 +250,11 @@ namespace Aurora AuString defaultBrand = "Aurora"; }; + struct DebugConfig + { + bool nonshipPrecachesSymbols {true}; + }; + struct RuntimeStartInfo { ConsoleConfig console; @@ -257,6 +262,7 @@ namespace Aurora TelemetryConfig telemetry; AsyncConfig async; FIOConfig fio; + DebugConfig debug; bool bFIODisableBatching {true}; }; diff --git a/Source/Console/ConsoleStd/ConsoleStd.cpp b/Source/Console/ConsoleStd/ConsoleStd.cpp index c80dd51d..9ef75b8d 100755 --- a/Source/Console/ConsoleStd/ConsoleStd.cpp +++ b/Source/Console/ConsoleStd/ConsoleStd.cpp @@ -103,7 +103,7 @@ namespace Aurora::Console::ConsoleStd static AuList gCanonicalBuffer; //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) diff --git a/Source/Debug/ExceptionWatcher.NT.cpp b/Source/Debug/ExceptionWatcher.NT.cpp index 4d84b5ff..61dde367 100644 --- a/Source/Debug/ExceptionWatcher.NT.cpp +++ b/Source/Debug/ExceptionWatcher.NT.cpp @@ -142,7 +142,7 @@ namespace Aurora::Debug { static bool handlingFatal = false; - #if defined(DEBUG) || defined(INTERNAL) + #if defined(AU_ENABLE_NATIVE_MINIDUMP) if (!fatal) { if (IsDebuggerPresent()) __debugbreak(); diff --git a/Source/Debug/ExceptionWatcher.Win32.cpp b/Source/Debug/ExceptionWatcher.Win32.cpp index c31eda52..5f90040b 100644 --- a/Source/Debug/ExceptionWatcher.Win32.cpp +++ b/Source/Debug/ExceptionWatcher.Win32.cpp @@ -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) { bool ok {}; @@ -409,7 +409,10 @@ namespace Aurora::Debug void InitWin32() { // ... - CacheInternalBuildSymbols(); + if (gRuntimeConfig.debug.nonshipPrecachesSymbols) + { + CacheInternalBuildSymbols(); + } // ... DisableWindowsErrorReporting(); diff --git a/Source/Debug/ExceptionWatcher.Win32.hpp b/Source/Debug/ExceptionWatcher.Win32.hpp index 894b5629..1e0973ba 100644 --- a/Source/Debug/ExceptionWatcher.Win32.hpp +++ b/Source/Debug/ExceptionWatcher.Win32.hpp @@ -11,8 +11,10 @@ namespace Aurora::Debug { 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); #endif + void BlackboxReport(_EXCEPTION_POINTERS *ExceptionInfo, bool isFatal); } \ No newline at end of file