1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Remove indirection in plot storage.

This commit is contained in:
Bartosz Taudul
2017-11-21 02:06:17 +01:00
parent 74cd22e655
commit 63c070228c
2 changed files with 7 additions and 8 deletions
+5 -6
View File
@@ -789,7 +789,7 @@ void View::ProcessPlotData( const QueuePlotData& ev )
}
else
{
plot = m_plots[it->second];
plot = it->second;
}
const auto time = int64_t( ev.time * m_timerMul );
@@ -1278,17 +1278,16 @@ void View::HandlePlotName( uint64_t name, char* str, size_t sz )
auto it = m_plotRev.find( sl.ptr );
if( it == m_plotRev.end() )
{
const auto idx = m_plots.size();
m_plotMap.emplace( name, idx );
m_plotRev.emplace( sl.ptr, idx );
m_plotMap.emplace( name, pit->second );
m_plotRev.emplace( sl.ptr, pit->second );
m_plots.push_back( pit->second );
m_strings.emplace( name, sl.ptr );
}
else
{
m_plotMap.emplace( name, it->second );
auto plot = it->second;
m_plotMap.emplace( name, plot );
const auto& pp = pit->second->data;
auto plot = m_plots[it->second];
for( auto& v : pp )
{
InsertPlot( plot, v );