diff options
author | Bartosz Taudul <wolf.pld@gmail.com> | 2019-08-02 21:18:08 +0300 |
---|---|---|
committer | Bartosz Taudul <wolf.pld@gmail.com> | 2019-08-02 21:18:08 +0300 |
commit | 12969ee4972c335c0845ff608d7a846938b663c8 (patch) | |
tree | 60ca1ec97119ee6a68952c695b3439e8d2132e3d /server/TracyWorker.hpp | |
parent | 9b6c4054857a93682e39c4db60c44d24ab3328d5 (diff) |
Track thread context.
This change exploits the fact that events are processed in batches
originating from a single thread. A single message changing thread
context is enough to handle multiple messages, as opposed to inclusion
of thread identifier in each message.
Diffstat (limited to 'server/TracyWorker.hpp')
-rw-r--r-- | server/TracyWorker.hpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/server/TracyWorker.hpp b/server/TracyWorker.hpp index 4b1e44ef..2915c0de 100644 --- a/server/TracyWorker.hpp +++ b/server/TracyWorker.hpp @@ -361,6 +361,7 @@ private: tracy_force_inline bool DispatchProcess( const QueueItem& ev, char*& ptr ); tracy_force_inline bool Process( const QueueItem& ev ); + tracy_force_inline void ProcessThreadContext( const QueueThreadContext& ev ); tracy_force_inline void ProcessZoneBegin( const QueueZoneBegin& ev ); tracy_force_inline void ProcessZoneBeginCallstack( const QueueZoneBegin& ev ); tracy_force_inline void ProcessZoneBeginAllocSrcLoc( const QueueZoneBegin& ev ); @@ -551,6 +552,8 @@ private: flat_hash_map<uint64_t, int32_t> m_frameImageStaging; char* m_frameImageBuffer = nullptr; size_t m_frameImageBufferSize = 0; + + uint64_t m_threadCtx = 0; }; } |