From d9939362f578dd1b175bc6bcd7e765bff70e3759 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Tue, 16 Jun 2026 23:39:38 +0200 Subject: [PATCH] Add wait stack data to the LLM attachment. --- profiler/src/profiler/TracyView_Callstack.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/profiler/src/profiler/TracyView_Callstack.cpp b/profiler/src/profiler/TracyView_Callstack.cpp index f6d88f2a..24cd5b8e 100644 --- a/profiler/src/profiler/TracyView_Callstack.cpp +++ b/profiler/src/profiler/TracyView_Callstack.cpp @@ -113,7 +113,7 @@ void View::DrawCallstackTable( const CallstackFrameId* data, size_t size, uint64 } if( s_config.llm ) { - auto Attach = [this, data, size, hasCrashed, thread, callstack]() { + auto Attach = [this, data, size, wait, hasCrashed, thread, callstack]() { auto json = GetCallstackJson( data, size ); if( hasCrashed ) { @@ -131,6 +131,14 @@ void View::DrawCallstackTable( const CallstackFrameId* data, size_t size, uint64 json["thread_id"] = thread; } if( callstack >= 0 ) json["id"] = callstack; + if( wait.time > 0 ) + { + json["wait_time"] = TimeToString( wait.time ); + if( wait.reason ) json["wait_reason"] = wait.reasonCode; + if( wait.reasonCode ) json["wait_reason_hint"] = wait.reason; + if( wait.state ) json["wait_state"] = wait.stateCode; + if( wait.stateCode ) json["wait_state_hint"] = wait.state; + } AddLlmAttachment( json ); };