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

Implement transport of single string data.

In most cases only one string is sent per message and no pointer
tracking is needed.

This is only plumbing work, no changes to messages have been made yet.
This commit is contained in:
Bartosz Taudul
2020-07-25 23:13:01 +02:00
parent 7afdef3cdb
commit 81d5a8db5e
6 changed files with 39 additions and 2 deletions
+1 -1
View File
@@ -9,7 +9,7 @@ namespace tracy
constexpr unsigned Lz4CompressBound( unsigned isize ) { return isize + ( isize / 255 ) + 16; }
enum : uint32_t { ProtocolVersion = 37 };
enum : uint32_t { ProtocolVersion = 38 };
enum : uint32_t { BroadcastVersion = 1 };
using lz4sz_t = uint32_t;
+2
View File
@@ -83,6 +83,7 @@ enum class QueueType : uint8_t
ParamSetup,
ParamPingback,
CpuTopology,
SingleStringData,
StringData,
ThreadName,
CustomStringData,
@@ -613,6 +614,7 @@ static constexpr size_t QueueDataSize[] = {
sizeof( QueueHeader ) + sizeof( QueueParamSetup ),
sizeof( QueueHeader ), // param pingback
sizeof( QueueHeader ) + sizeof( QueueCpuTopology ),
sizeof( QueueHeader ), // single string data
// keep all QueueStringTransfer below
sizeof( QueueHeader ) + sizeof( QueueStringTransfer ), // string data
sizeof( QueueHeader ) + sizeof( QueueStringTransfer ), // thread name