mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-22 22:44:34 +00:00
Process call stack frames during failure dispatch.
This commit is contained in:
parent
641649143c
commit
9d392d2c90
@ -2989,10 +2989,18 @@ void Worker::DispatchFailure( const QueueItem& ev, const char*& ptr )
|
||||
switch( ev.hdr.type )
|
||||
{
|
||||
case QueueType::SingleStringData:
|
||||
ptr += sizeof( QueueHeader );
|
||||
memcpy( &sz, ptr, sizeof( sz ) );
|
||||
ptr += sizeof( sz );
|
||||
AddSingleStringFailure( ptr, sz );
|
||||
ptr += sz;
|
||||
break;
|
||||
case QueueType::SecondStringData:
|
||||
ptr += sizeof( QueueHeader );
|
||||
memcpy( &sz, ptr, sizeof( sz ) );
|
||||
ptr += sizeof( sz ) + sz;
|
||||
ptr += sizeof( sz );
|
||||
AddSecondString( ptr, sz );
|
||||
ptr += sz;
|
||||
break;
|
||||
default:
|
||||
ptr += QueueDataSize[ev.hdr.idx];
|
||||
@ -3003,6 +3011,12 @@ void Worker::DispatchFailure( const QueueItem& ev, const char*& ptr )
|
||||
m_serverQuerySpaceLeft++;
|
||||
break;
|
||||
case QueueType::CallstackFrameSize:
|
||||
ProcessCallstackFrameSize( ev.callstackFrameSize );
|
||||
m_serverQuerySpaceLeft++;
|
||||
break;
|
||||
case QueueType::CallstackFrame:
|
||||
ProcessCallstackFrame( ev.callstackFrame, false );
|
||||
break;
|
||||
case QueueType::SymbolInformation:
|
||||
case QueueType::ParamPingback:
|
||||
m_serverQuerySpaceLeft++;
|
||||
@ -3542,6 +3556,13 @@ void Worker::AddSingleString( const char* str, size_t sz )
|
||||
m_pendingSingleString = StoreString( str, sz );
|
||||
}
|
||||
|
||||
void Worker::AddSingleStringFailure( const char* str, size_t sz )
|
||||
{
|
||||
// During failure dispatch processing of most events is ignored, but string data
|
||||
// is still send. Just ignore anything that was already in the staging area.
|
||||
m_pendingSingleString = StoreString( str, sz );
|
||||
}
|
||||
|
||||
void Worker::AddSecondString( const char* str, size_t sz )
|
||||
{
|
||||
assert( m_pendingSecondString.ptr == nullptr );
|
||||
|
@ -736,6 +736,7 @@ private:
|
||||
void AddString( uint64_t ptr, const char* str, size_t sz );
|
||||
void AddThreadString( uint64_t id, const char* str, size_t sz );
|
||||
void AddSingleString( const char* str, size_t sz );
|
||||
void AddSingleStringFailure( const char* str, size_t sz );
|
||||
void AddSecondString( const char* str, size_t sz );
|
||||
void AddExternalName( uint64_t ptr, const char* str, size_t sz );
|
||||
void AddExternalThreadName( uint64_t ptr, const char* str, size_t sz );
|
||||
|
Loading…
Reference in New Issue
Block a user