From 3dc4fc4796063f69b70d6678f6b8fc952c770d68 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sun, 1 Oct 2017 19:21:25 +0200 Subject: [PATCH] Display CPU id in zone tooltips. --- server/TracyView.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/server/TracyView.cpp b/server/TracyView.cpp index 35e3c423..e5b0cf57 100755 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -1566,6 +1566,17 @@ void View::ZoneTooltip( const Event& ev ) ImGui::Text( "%s:%i", filename, line ); ImGui::Text( "Execution time: %s", TimeToString( end - ev.start ) ); ImGui::Text( "Without profiling: %s", TimeToString( end - ev.start - m_delay * dmul ) ); + if( ev.cpu_start != -1 ) + { + if( ev.end == -1 || ev.cpu_start == ev.cpu_end ) + { + ImGui::Text( "CPU: %i", ev.cpu_start ); + } + else + { + ImGui::Text( "CPU: %i -> %i", ev.cpu_start, ev.cpu_end ); + } + } if( ev.text && ev.text->userText ) { ImGui::Text( "" );