Specify minimum length of subframe skip in one place.

This commit is contained in:
Bartosz Taudul 2021-06-09 02:13:00 +02:00
parent e1c3babf43
commit 9c2ea8a71f
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3
3 changed files with 4 additions and 2 deletions

View File

@ -529,7 +529,7 @@ static int CodeDataCb( void* data, uintptr_t pc, uintptr_t lowaddr, const char*
if( !fn ) return 1;
const auto fnsz = strlen( fn );
if( fnsz >= 19 ) // minimum length in s_tracySkipSubframes
if( fnsz >= s_tracySkipSubframesMinLen )
{
auto ptr = s_tracySkipSubframes;
do

View File

@ -15,6 +15,8 @@ struct StringMatch
extern const char** s_tracyStackFrames;
extern const StringMatch* s_tracySkipSubframes;
static constexpr int s_tracySkipSubframesMinLen = 19;
}
#endif

View File

@ -6002,7 +6002,7 @@ void Worker::ProcessCallstackFrame( const QueueCallstackFrame& ev, bool querySym
{
auto fstr = GetString( file );
auto flen = strlen( fstr );
if( flen >= 19 ) // minimum length in s_tracySkipSubframes
if( flen >= s_tracySkipSubframesMinLen )
{
auto ptr = s_tracySkipSubframes;
do