Process memory name payload transfer.

This commit is contained in:
Bartosz Taudul 2020-09-23 15:15:39 +02:00
parent a9ce4f6454
commit 46f0853f1b
2 changed files with 11 additions and 0 deletions

View File

@ -4150,6 +4150,9 @@ bool Worker::Process( const QueueItem& ev )
case QueueType::CpuTopology:
ProcessCpuTopology( ev.cpuTopology );
break;
case QueueType::MemNamePayload:
ProcessMemNamePayload( ev.memName );
break;
default:
assert( false );
break;
@ -5834,6 +5837,12 @@ void Worker::ProcessCpuTopology( const QueueCpuTopology& ev )
m_data.cpuTopologyMap.emplace( ev.thread, CpuThreadTopology { ev.package, ev.core } );
}
void Worker::ProcessMemNamePayload( const QueueMemNamePayload& ev )
{
assert( m_memNamePayload == 0 );
m_memNamePayload = ev.name;
}
void Worker::MemAllocChanged( int64_t time )
{
const auto val = (double)m_data.memory.usage;

View File

@ -669,6 +669,7 @@ private:
tracy_force_inline void ProcessTidToPid( const QueueTidToPid& ev );
tracy_force_inline void ProcessParamSetup( const QueueParamSetup& ev );
tracy_force_inline void ProcessCpuTopology( const QueueCpuTopology& ev );
tracy_force_inline void ProcessMemNamePayload( const QueueMemNamePayload& ev );
tracy_force_inline ZoneEvent* AllocZoneEvent();
tracy_force_inline void ProcessZoneBeginImpl( ZoneEvent* zone, const QueueZoneBegin& ev );
@ -883,6 +884,7 @@ private:
uint64_t m_lastMemActionCallstack;
bool m_lastMemActionWasAlloc;
uint64_t m_memNamePayload = 0;
Slab<64*1024*1024> m_slab;