From c3238a496d2c9ba196cd81451ac2629b27961415 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sun, 24 Jun 2018 17:38:32 +0200 Subject: [PATCH] No need to check for frame function name match. Firstly, the match is not necessarily possible (e.g. on Linux the source location function names and callstack frame names are two completely different things). Secondly, the first current zone callstack frame (which is matched to some callstack frame of previous zone) is the frame in which a zone was captured, and it will already be present in the zone trace. The callstack frame omission should be therefore unconditional. --- server/TracyView.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/server/TracyView.cpp b/server/TracyView.cpp index fd73c804..d35b6783 100644 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -2774,8 +2774,8 @@ void DrawZoneTrace( T zone, const std::vector& trace, const Worker& worker, s auto& prevCs = worker.GetCallstack( prev->callstack ); auto& currCs = worker.GetCallstack( curr->callstack ); - const auto psz = prevCs.size(); - uint8_t idx; + const auto psz = int8_t( prevCs.size() ); + int8_t idx; for( idx=0; idx& trace, const Worker& worker, s { if( cf == pf ) { - auto frame = worker.GetCallstackFrame( prevCs[idx-1] ); - auto pname = worker.GetString( frame->name ); - auto cname = worker.GetString( worker.GetSourceLocation( curr->srcloc ).function ); - if( pname == cname ) idx--; + idx--; found = true; break; } } if( found ) break; } - for( uint8_t j=1; jname ) );