diff options
| author | Dan Engelbrecht <[email protected]> | 2023-11-29 09:14:57 -0500 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-11-29 15:14:57 +0100 |
| commit | 68b3382ef7e0f7795b9a601aae73adc2f8ef9873 (patch) | |
| tree | a8460fa497195575505e14f7beef069ecee31ef7 /src/zencore/workthreadpool.cpp | |
| parent | fixed file logger pattern (#579) (diff) | |
| download | zen-68b3382ef7e0f7795b9a601aae73adc2f8ef9873.tar.xz zen-68b3382ef7e0f7795b9a601aae73adc2f8ef9873.zip | |
global thread worker pools (#577)
- Improvement: Use two global worker thread pools instead of ad-hoc creation of worker pools
Diffstat (limited to 'src/zencore/workthreadpool.cpp')
| -rw-r--r-- | src/zencore/workthreadpool.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/zencore/workthreadpool.cpp b/src/zencore/workthreadpool.cpp index e6a6b5c54..6ff6463dd 100644 --- a/src/zencore/workthreadpool.cpp +++ b/src/zencore/workthreadpool.cpp @@ -110,6 +110,7 @@ struct WorkerThreadPool::Impl m_WorkQueue.pop_front(); } + ZEN_TRACE_CPU_FLUSH("AsyncWork"); WorkFromQueue->Execute(); } }; @@ -178,6 +179,7 @@ WorkerThreadPool::Impl::WorkerThreadFunction(ThreadStartInfo Info) { try { + ZEN_TRACE_CPU_FLUSH("AsyncWork"); Work->Execute(); } catch (std::exception& e) @@ -225,6 +227,7 @@ WorkerThreadPool::ScheduleWork(Ref<IWork> Work) { try { + ZEN_TRACE_CPU_FLUSH("SyncWork"); Work->Execute(); } catch (std::exception& e) |