mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-10 02:31:48 +00:00
Add child samples data structure.
This commit is contained in:
parent
fa8c99fd74
commit
4dc6222ba1
@ -2196,6 +2196,14 @@ const Vector<SampleDataRange>* Worker::GetSamplesForSymbol( uint64_t symAddr ) c
|
||||
if( it == m_data.symbolSamples.end() ) return nullptr;
|
||||
return &it->second;
|
||||
}
|
||||
|
||||
const Vector<Int48>* Worker::GetChildSamples( uint64_t addr ) const
|
||||
{
|
||||
assert( m_data.symbolSamplesReady );
|
||||
auto it = m_data.childSamples.find( addr );
|
||||
if( it == m_data.childSamples.end() ) return nullptr;
|
||||
return &it->second;
|
||||
}
|
||||
#endif
|
||||
|
||||
const SymbolData* Worker::GetSymbolData( uint64_t sym ) const
|
||||
|
@ -294,6 +294,7 @@ private:
|
||||
unordered_flat_map<uint64_t, unordered_flat_map<CallstackFrameId, uint32_t, CallstackFrameIdHash, CallstackFrameIdCompare>> instructionPointersMap;
|
||||
unordered_flat_map<uint64_t, Vector<SampleDataRange>> symbolSamples;
|
||||
unordered_flat_map<CallstackFrameId, Vector<SampleDataRange>, CallstackFrameIdHash, CallstackFrameIdCompare> pendingSymbolSamples;
|
||||
unordered_flat_map<uint64_t, Vector<Int48>> childSamples;
|
||||
bool newFramesWereReceived = false;
|
||||
bool callstackSamplesReady = false;
|
||||
bool ghostZonesReady = false;
|
||||
@ -497,6 +498,7 @@ public:
|
||||
const VarArray<CallstackFrameId>& GetParentCallstack( uint32_t idx ) const { return *m_data.parentCallstackPayload[idx]; }
|
||||
const CallstackFrameData* GetParentCallstackFrame( const CallstackFrameId& ptr ) const;
|
||||
const Vector<SampleDataRange>* GetSamplesForSymbol( uint64_t symAddr ) const;
|
||||
const Vector<Int48>* GetChildSamples( uint64_t addr ) const;
|
||||
#endif
|
||||
|
||||
const CrashEvent& GetCrashEvent() const { return m_data.crashEvent; }
|
||||
|
Loading…
Reference in New Issue
Block a user