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

Send lean allocated source locations.

This commit is contained in:
Bartosz Taudul
2020-05-10 19:20:59 +02:00
parent 94d0232ed3
commit 2dc07fca0b
4 changed files with 33 additions and 23 deletions
+12 -3
View File
@@ -16,7 +16,9 @@ enum class QueueType : uint8_t
MessageColorCallstack,
MessageAppInfo,
ZoneBeginAllocSrcLoc,
ZoneBeginAllocSrcLocLean,
ZoneBeginAllocSrcLocCallstack,
ZoneBeginAllocSrcLocCallstackLean,
CallstackMemory,
Callstack,
CallstackAlloc,
@@ -96,9 +98,13 @@ struct QueueThreadContext
uint64_t thread;
};
struct QueueZoneBegin
struct QueueZoneBeginLean
{
int64_t time;
};
struct QueueZoneBegin : public QueueZoneBeginLean
{
uint64_t srcloc; // ptr
};
@@ -417,6 +423,7 @@ struct QueueItem
{
QueueThreadContext threadCtx;
QueueZoneBegin zoneBegin;
QueueZoneBeginLean zoneBeginLean;
QueueZoneEnd zoneEnd;
QueueZoneValidation zoneValidation;
QueueStringTransfer stringTransfer;
@@ -471,8 +478,10 @@ static constexpr size_t QueueDataSize[] = {
sizeof( QueueHeader ) + sizeof( QueueMessage ), // callstack
sizeof( QueueHeader ) + sizeof( QueueMessageColor ), // callstack
sizeof( QueueHeader ) + sizeof( QueueMessage ), // app info
sizeof( QueueHeader ) + sizeof( QueueZoneBegin ), // allocated source location
sizeof( QueueHeader ) + sizeof( QueueZoneBegin ), // allocated source location, callstack
sizeof( QueueHeader ) + sizeof( QueueZoneBegin ), // allocated source location, not for network transfer
sizeof( QueueHeader ) + sizeof( QueueZoneBeginLean ), // lean allocated source location
sizeof( QueueHeader ) + sizeof( QueueZoneBegin ), // allocated source location, callstack, not for network transfer
sizeof( QueueHeader ) + sizeof( QueueZoneBeginLean ), // lean allocated source location, callstack
sizeof( QueueHeader ) + sizeof( QueueCallstackMemory ),
sizeof( QueueHeader ) + sizeof( QueueCallstack ),
sizeof( QueueHeader ) + sizeof( QueueCallstackAlloc ),