From da75d9b2f6e18679a43474c2c8e1f8bae5d42b59 Mon Sep 17 00:00:00 2001 From: Erik Griese Date: Thu, 7 Mar 2024 17:26:08 +0100 Subject: [PATCH] Changes logic for only (in)active allocations frame tree: - Swaps logic to: - skip active allocations if only inactive should be displayed - skip inactive allocations if only active should be displayed --- server/TracyView_FrameTree.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/TracyView_FrameTree.cpp b/server/TracyView_FrameTree.cpp index b9a5cb7f..e0f76ba3 100644 --- a/server/TracyView_FrameTree.cpp +++ b/server/TracyView_FrameTree.cpp @@ -70,7 +70,7 @@ unordered_flat_map View::GetCallstackPaths( const M { auto& ev = *it++; if( ev.CsAlloc() == 0 ) continue; - if( ( memRange == MemRange::Inactive ) == ( ev.TimeFree() >= 0 && ev.TimeFree() < m_memInfo.range.max ) ) continue; + if( ( memRange == MemRange::Inactive ) != ( ev.TimeFree() >= 0 && ev.TimeFree() < m_memInfo.range.max ) ) continue; auto pit = pathSum.find( ev.CsAlloc() ); if( pit == pathSum.end() ) { @@ -110,7 +110,7 @@ unordered_flat_map View::GetCallstackPaths( const M for( auto& ev : mem.data ) { if( ev.CsAlloc() == 0 ) continue; - if( ( memRange == MemRange::Inactive ) == ( ev.TimeFree() >= 0 ) ) continue; + if( ( memRange == MemRange::Inactive ) != ( ev.TimeFree() >= 0 ) ) continue; auto it = pathSum.find( ev.CsAlloc() ); if( it == pathSum.end() ) {