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

Delta-encode code information pointers.

This commit is contained in:
Bartosz Taudul
2021-10-16 16:29:06 +02:00
parent b099df75c2
commit a1511a39bd
4 changed files with 13 additions and 11 deletions
+2 -1
View File
@@ -3464,11 +3464,12 @@ void Profiler::SendCodeLocation( uint64_t ptr )
#ifdef TRACY_HAS_CALLSTACK
const auto sym = DecodeCodeAddress( ptr );
const uint64_t offset = ptr - sym.symAddr;
SendSingleString( sym.file );
QueueItem item;
MemWrite( &item.hdr.type, QueueType::CodeInformation );
MemWrite( &item.codeInformation.ptr, ptr );
MemWrite( &item.codeInformation.ptrOffset, offset );
MemWrite( &item.codeInformation.line, sym.line );
MemWrite( &item.codeInformation.symAddr, sym.symAddr );