diff options
author | Bartosz Taudul <wolf@nereid.pl> | 2022-09-18 00:06:16 +0300 |
---|---|---|
committer | Bartosz Taudul <wolf@nereid.pl> | 2022-09-18 00:06:16 +0300 |
commit | 4cf096d883266092d325bcf5371bbf857bc4b88c (patch) | |
tree | 0ea61e712b820baaef5822c172be5d15d8732709 | |
parent | 4c086e94e4286beb4106488b1142b4cbeffb1f68 (diff) |
Mark privileged instructions in the tooltip.
-rw-r--r-- | server/TracySourceView.cpp | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/server/TracySourceView.cpp b/server/TracySourceView.cpp index 829e6662..83b71e79 100644 --- a/server/TracySourceView.cpp +++ b/server/TracySourceView.cpp @@ -3960,7 +3960,21 @@ void SourceView::RenderAsmLine( AsmLine& line, const AddrStat& ipcnt, const Addr ImGui::BeginTooltip(); if( jumpName || opdesc != 0 ) { - if( opdesc != 0 ) ImGui::TextUnformatted( OpDescList[opdesc] ); + if( opdesc != 0 ) + { + ImGui::TextUnformatted( OpDescList[opdesc] ); + if( line.opType == OpType::Privileged ) + { + ImGui::SameLine(); + ImGui::Spacing(); + ImGui::SameLine(); + TextColoredUnformatted( AsmOpTypeColors[(int)OpType::Privileged], "privileged" ); + } + } + else if( line.opType == OpType::Privileged ) + { + TextColoredUnformatted( AsmOpTypeColors[(int)OpType::Privileged], "Privileged" ); + } if( jumpName ) { if( jumpBase == m_baseAddr ) |