Build list of allocations in a given call stack tree entry.

This commit is contained in:
Bartosz Taudul 2018-09-27 23:05:46 +02:00
parent 9301986bae
commit 01e0bbb5f9
2 changed files with 15 additions and 0 deletions

View File

@ -7562,6 +7562,20 @@ void View::DrawFrameTreeLevel( std::vector<CallstackFrameTree>& tree, int& idx )
ImGui::PopID();
}
if( ImGui::IsItemClicked( 1 ) )
{
auto& mem = m_worker.GetMemData().data;
const auto sz = mem.size();
m_memInfo.allocList.clear();
for( size_t i=0; i<sz; i++ )
{
if( v.callstacks.find( mem[i].csAlloc ) != v.callstacks.end() )
{
m_memInfo.allocList.emplace_back( mem.data() + i );
}
}
}
if( io.KeyCtrl && ImGui::IsItemHovered() )
{
ImGui::BeginTooltip();

View File

@ -402,6 +402,7 @@ private:
char pattern[1024] = {};
uint64_t ptrFind = 0;
bool restrictTime = false;
std::vector<const MemEvent*> allocList;
} m_memInfo;
struct {