diff --git a/neo/framework/File_SaveGame.cpp b/neo/framework/File_SaveGame.cpp index 65e2e94b..b6ff7288 100644 --- a/neo/framework/File_SaveGame.cpp +++ b/neo/framework/File_SaveGame.cpp @@ -71,7 +71,9 @@ class idSGFcompressThread : public idSysThread public: virtual int Run() { +#if USE_OPTICK OPTICK_THREAD( "idSGFcompressThread" ); +#endif sgf->CompressBlock(); return 0; @@ -83,7 +85,9 @@ class idSGFdecompressThread : public idSysThread public: virtual int Run() { +#if USE_OPTICK OPTICK_THREAD( "idSGFdecompressThread" ); +#endif sgf->DecompressBlock(); return 0; @@ -95,7 +99,9 @@ class idSGFwriteThread : public idSysThread public: virtual int Run() { +#if USE_OPTICK OPTICK_THREAD( "idSGFwriteThread" ); +#endif sgf->WriteBlock(); return 0; @@ -107,7 +113,9 @@ class idSGFreadThread : public idSysThread public: virtual int Run() { +#if USE_OPTICK OPTICK_THREAD( "idSGFreadThread" ); +#endif sgf->ReadBlock(); return 0; diff --git a/neo/framework/common_frame.cpp b/neo/framework/common_frame.cpp index 36a3a5ec..da8dc167 100644 --- a/neo/framework/common_frame.cpp +++ b/neo/framework/common_frame.cpp @@ -90,7 +90,9 @@ be called directly in the foreground thread for comparison. */ int idGameThread::Run() { +#if USE_OPTICK OPTICK_THREAD( "idGameThread" ); +#endif commonLocal.frameTiming.startGameTime = Sys_Microseconds(); diff --git a/neo/idlib/ParallelJobList.cpp b/neo/idlib/ParallelJobList.cpp index 54b14c5d..16c31ec6 100644 --- a/neo/idlib/ParallelJobList.cpp +++ b/neo/idlib/ParallelJobList.cpp @@ -1145,7 +1145,9 @@ idJobThread::Run */ int idJobThread::Run() { +#if USE_OPTICK OPTICK_THREAD( GetName() ); +#endif threadJobListState_t threadJobListState[MAX_JOBLISTS]; int numJobLists = 0; diff --git a/neo/idlib/precompiled.h b/neo/idlib/precompiled.h index 3ac48bd2..012c878c 100644 --- a/neo/idlib/precompiled.h +++ b/neo/idlib/precompiled.h @@ -107,7 +107,7 @@ const int MAX_EXPRESSION_REGISTERS = 4096; #endif // RB: make Optick profiling available everywhere -#if defined( USE_OPTICK ) +#if USE_OPTICK #include "../libs/optick/optick.h" #endif diff --git a/neo/sys/common/savegame.cpp b/neo/sys/common/savegame.cpp index 65de9bb8..de47bef8 100644 --- a/neo/sys/common/savegame.cpp +++ b/neo/sys/common/savegame.cpp @@ -746,7 +746,9 @@ idSaveGameThread::Run */ int idSaveGameThread::Run() { +#if USE_OPTICK OPTICK_THREAD( "idSaveGameThread" ); +#endif int ret = ERROR_SUCCESS;