mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-23 14:54:34 +00:00
Don't depend on callstack frames to match hw samples to source.
This commit is contained in:
parent
2f3ee594f0
commit
bc4016e97c
@ -4055,14 +4055,12 @@ void SourceView::GatherIpHwStats( AddrStat& iptotalSrc, AddrStat& iptotalAsm, un
|
|||||||
|
|
||||||
if( filename )
|
if( filename )
|
||||||
{
|
{
|
||||||
auto frame = worker.GetCallstackFrame( worker.PackPointer( addr ) );
|
uint32_t line;
|
||||||
if( frame )
|
const auto fref = worker.GetLocationForAddress( addr, line );
|
||||||
{
|
|
||||||
auto ffn = worker.GetString( frame->data[0].file );
|
|
||||||
if( strcmp( ffn, filename ) == 0 )
|
|
||||||
{
|
|
||||||
const auto line = frame->data[0].line;
|
|
||||||
if( line != 0 )
|
if( line != 0 )
|
||||||
|
{
|
||||||
|
auto ffn = worker.GetString( fref );
|
||||||
|
if( strcmp( ffn, filename ) == 0 )
|
||||||
{
|
{
|
||||||
auto it = ipcountSrc.find( line );
|
auto it = ipcountSrc.find( line );
|
||||||
if( it == ipcountSrc.end() )
|
if( it == ipcountSrc.end() )
|
||||||
@ -4082,7 +4080,6 @@ void SourceView::GatherIpHwStats( AddrStat& iptotalSrc, AddrStat& iptotalAsm, un
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
void SourceView::GatherIpStats( uint64_t baseAddr, AddrStat& iptotalSrc, AddrStat& iptotalAsm, unordered_flat_map<uint64_t, AddrStat>& ipcountSrc, unordered_flat_map<uint64_t, AddrStat>& ipcountAsm, AddrStat& ipmaxSrc, AddrStat& ipmaxAsm, const Worker& worker, bool limitView, const View& view )
|
void SourceView::GatherIpStats( uint64_t baseAddr, AddrStat& iptotalSrc, AddrStat& iptotalAsm, unordered_flat_map<uint64_t, AddrStat>& ipcountSrc, unordered_flat_map<uint64_t, AddrStat>& ipcountAsm, AddrStat& ipmaxSrc, AddrStat& ipmaxAsm, const Worker& worker, bool limitView, const View& view )
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user