1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Display thread in GPU zone tooltip.

This commit is contained in:
Bartosz Taudul 2018-03-19 16:13:12 +01:00
parent 4d34ccc30c
commit d5e0858982

View File

@ -3461,6 +3461,7 @@ void View::ZoneTooltip( const ZoneEvent& ev )
void View::ZoneTooltip( const GpuEvent& ev )
{
const auto tid = GetZoneThread( ev );
const auto& srcloc = m_worker.GetSourceLocation( ev.srcloc );
const auto name = m_worker.GetString( srcloc.name );
@ -3475,6 +3476,9 @@ void View::ZoneTooltip( const GpuEvent& ev )
ImGui::Text( "%s", func );
ImGui::Separator();
ImGui::Text( "%s:%i", filename, line );
ImGui::Text( "Thread: %s", m_worker.GetThreadString( tid ) );
ImGui::SameLine();
ImGui::TextDisabled( "(0x%" PRIX64 ")", tid );
ImGui::Text( "GPU execution time: %s", TimeToString( end - ev.gpuStart ) );
ImGui::Text( "CPU command setup time: %s", TimeToString( ev.cpuEnd - ev.cpuStart ) );
ImGui::Text( "Delay to execution: %s", TimeToString( ev.gpuStart - ev.cpuStart ) );