mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
Display code size in source file view window.
This commit is contained in:
@@ -26,6 +26,7 @@ SourceView::SourceView( ImFont* font )
|
||||
, m_targetLine( 0 )
|
||||
, m_selectedLine( 0 )
|
||||
, m_showAsm( false )
|
||||
, m_codeLen( 0 )
|
||||
{
|
||||
}
|
||||
|
||||
@@ -125,6 +126,7 @@ bool SourceView::Disassemble( uint64_t symAddr, const Worker& worker )
|
||||
cs_free( insn, cnt );
|
||||
}
|
||||
cs_close( &handle );
|
||||
m_codeLen = len;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -196,6 +198,10 @@ void SourceView::Render( const Worker& worker )
|
||||
ImGui::SameLine();
|
||||
ImGui::Spacing();
|
||||
ImGui::SameLine();
|
||||
TextFocused( "Code size:", MemSizeToString( m_codeLen ) );
|
||||
ImGui::SameLine();
|
||||
ImGui::Spacing();
|
||||
ImGui::SameLine();
|
||||
}
|
||||
TextFocused( "Samples:", RealToString( iptotal ) );
|
||||
ImGui::SameLine();
|
||||
|
||||
Reference in New Issue
Block a user