Merge pull request #611 from Geod24/tracy_demangle_fix

Fix and test TRACY_DEMANGLE for TracyClient
This commit is contained in:
Bartosz Taudul 2023-09-06 10:51:44 +02:00 committed by GitHub
commit 4e83aa3818
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 0 deletions

View File

@ -42,3 +42,4 @@ jobs:
make -j`nproc` -C test TRACYFLAGS=-DTRACY_ON_DEMAND make -j`nproc` -C test TRACYFLAGS=-DTRACY_ON_DEMAND
make -j`nproc` -C test clean make -j`nproc` -C test clean
make -j`nproc` -C test TRACYFLAGS="-DTRACY_DELAYED_INIT -DTRACY_MANUAL_LIFETIME" make -j`nproc` -C test TRACYFLAGS="-DTRACY_DELAYED_INIT -DTRACY_MANUAL_LIFETIME"
make -C test -B ../public/TracyClient.o DEFINES='-DTRACY_DEMANGLE'

View File

@ -686,7 +686,9 @@ void InitCallstackCritical()
void InitCallstack() void InitCallstack()
{ {
cb_bts = backtrace_create_state( nullptr, 0, nullptr, nullptr ); cb_bts = backtrace_create_state( nullptr, 0, nullptr, nullptr );
#ifndef TRACY_DEMANGLE
___tracy_init_demangle_buffer(); ___tracy_init_demangle_buffer();
#endif
#ifdef __linux #ifdef __linux
InitKernelSymbols(); InitKernelSymbols();
@ -761,7 +763,9 @@ debuginfod_client* GetDebuginfodClient()
void EndCallstack() void EndCallstack()
{ {
#ifndef TRACY_DEMANGLE
___tracy_free_demangle_buffer(); ___tracy_free_demangle_buffer();
#endif
#ifdef TRACY_DEBUGINFOD #ifdef TRACY_DEBUGINFOD
ClearDebugInfoVector( s_di_known ); ClearDebugInfoVector( s_di_known );
debuginfod_end( s_debuginfod ); debuginfod_end( s_debuginfod );