mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
Allocation times may be displayed relative to zone start.
This commit is contained in:
parent
d2cca5dc3f
commit
b6ccb9d686
@ -4453,6 +4453,8 @@ void View::DrawZoneInfoWindow()
|
|||||||
|
|
||||||
if( ImGui::TreeNode( "Allocations list" ) )
|
if( ImGui::TreeNode( "Allocations list" ) )
|
||||||
{
|
{
|
||||||
|
SmallCheckbox( "Allocation times relative to zone start", &m_allocTimeRelativeToZone );
|
||||||
|
|
||||||
std::vector<const MemEvent*> v;
|
std::vector<const MemEvent*> v;
|
||||||
v.reserve( nAlloc + nFree );
|
v.reserve( nAlloc + nFree );
|
||||||
|
|
||||||
@ -4480,7 +4482,7 @@ void View::DrawZoneInfoWindow()
|
|||||||
|
|
||||||
ListMemData<decltype( v.begin() )>( v.begin(), v.end(), []( auto& v ) {
|
ListMemData<decltype( v.begin() )>( v.begin(), v.end(), []( auto& v ) {
|
||||||
ImGui::Text( "0x%" PRIx64, (*v)->ptr );
|
ImGui::Text( "0x%" PRIx64, (*v)->ptr );
|
||||||
} );
|
}, nullptr, m_allocTimeRelativeToZone ? ev.start : -1 );
|
||||||
ImGui::TreePop();
|
ImGui::TreePop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -268,6 +268,7 @@ private:
|
|||||||
bool m_showCallstackFrameAddress = false;
|
bool m_showCallstackFrameAddress = false;
|
||||||
bool m_showUnknownFrames = true;
|
bool m_showUnknownFrames = true;
|
||||||
bool m_groupChildrenLocations = false;
|
bool m_groupChildrenLocations = false;
|
||||||
|
bool m_allocTimeRelativeToZone = true;
|
||||||
|
|
||||||
ShortcutAction m_shortcut = ShortcutAction::None;
|
ShortcutAction m_shortcut = ShortcutAction::None;
|
||||||
Namespace m_namespace = Namespace::Full;
|
Namespace m_namespace = Namespace::Full;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user