mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
Allow displaying instruction location.
This commit is contained in:
parent
7dd929a39e
commit
bc18862dc6
@ -11163,6 +11163,14 @@ void View::DrawStatistics()
|
|||||||
#else
|
#else
|
||||||
ImGui::Checkbox( "Exclusive", &m_statSelf );
|
ImGui::Checkbox( "Exclusive", &m_statSelf );
|
||||||
#endif
|
#endif
|
||||||
|
ImGui::SameLine();
|
||||||
|
ImGui::Spacing();
|
||||||
|
ImGui::SameLine();
|
||||||
|
ImGui::TextUnformatted( "Location:" );
|
||||||
|
ImGui::SameLine();
|
||||||
|
ImGui::RadioButton( "Function entry", &m_statSampleLocation, 0 );
|
||||||
|
ImGui::SameLine();
|
||||||
|
ImGui::RadioButton( "Instruction", &m_statSampleLocation, 1 );
|
||||||
ImGui::Separator();
|
ImGui::Separator();
|
||||||
ImGui::BeginChild( "##statisticsSampling" );
|
ImGui::BeginChild( "##statisticsSampling" );
|
||||||
|
|
||||||
@ -11241,9 +11249,17 @@ void View::DrawStatistics()
|
|||||||
if( sit != symMap.end() )
|
if( sit != symMap.end() )
|
||||||
{
|
{
|
||||||
name = m_worker.GetString( sit->second.name );
|
name = m_worker.GetString( sit->second.name );
|
||||||
file = m_worker.GetString( sit->second.file );
|
|
||||||
imageName = m_worker.GetString( sit->second.imageName );
|
imageName = m_worker.GetString( sit->second.imageName );
|
||||||
line = sit->second.line;
|
if( m_statSampleLocation == 0 )
|
||||||
|
{
|
||||||
|
file = m_worker.GetString( sit->second.file );
|
||||||
|
line = sit->second.line;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
file = m_worker.GetString( sit->second.callFile );
|
||||||
|
line = sit->second.callLine;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ImGui::TextUnformatted( name );
|
ImGui::TextUnformatted( name );
|
||||||
|
|||||||
@ -345,6 +345,7 @@ private:
|
|||||||
bool m_statSelf = true;
|
bool m_statSelf = true;
|
||||||
bool m_statSampleTime = true;
|
bool m_statSampleTime = true;
|
||||||
int m_statMode = 0;
|
int m_statMode = 0;
|
||||||
|
int m_statSampleLocation = 0;
|
||||||
int m_showCallstackFrameAddress = 0;
|
int m_showCallstackFrameAddress = 0;
|
||||||
bool m_showUnknownFrames = true;
|
bool m_showUnknownFrames = true;
|
||||||
bool m_groupChildrenLocations = false;
|
bool m_groupChildrenLocations = false;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user