mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
One more place to check if srcloc zones are ready.
This commit is contained in:
parent
873d536845
commit
59632f0d37
@ -5386,9 +5386,12 @@ void View::DrawZoneInfoWindow()
|
|||||||
TextFocused( "Time from start of program:", TimeToString( ev.Start() ) );
|
TextFocused( "Time from start of program:", TimeToString( ev.Start() ) );
|
||||||
TextFocused( "Execution time:", TimeToString( ztime ) );
|
TextFocused( "Execution time:", TimeToString( ztime ) );
|
||||||
#ifndef TRACY_NO_STATISTICS
|
#ifndef TRACY_NO_STATISTICS
|
||||||
|
if( m_worker.AreSourceLocationZonesReady() )
|
||||||
|
{
|
||||||
auto& zoneData = m_worker.GetZonesForSourceLocation( ev.SrcLoc() );
|
auto& zoneData = m_worker.GetZonesForSourceLocation( ev.SrcLoc() );
|
||||||
ImGui::SameLine();
|
ImGui::SameLine();
|
||||||
ImGui::TextDisabled( "(%.2f%% of average time)", float( ztime ) / zoneData.total * zoneData.zones.size() * 100 );
|
ImGui::TextDisabled( "(%.2f%% of average time)", float( ztime ) / zoneData.total * zoneData.zones.size() * 100 );
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
TextFocused( "Self time:", TimeToString( selftime ) );
|
TextFocused( "Self time:", TimeToString( selftime ) );
|
||||||
if( ztime != 0 )
|
if( ztime != 0 )
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user