mirror of
https://github.com/wolfpld/tracy
synced 2025-04-30 20:53:52 +00:00
Extract single string idx retrieval.
This commit is contained in:
parent
06ca4e2d16
commit
e3dfa96055
@ -3826,6 +3826,14 @@ void Worker::HandlePostponedGhostZones()
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
uint32_t Worker::GetSingleStringIdx()
|
||||||
|
{
|
||||||
|
assert( m_pendingSingleString.ptr != nullptr );
|
||||||
|
const auto idx = m_pendingSingleString.idx;
|
||||||
|
m_pendingSingleString.ptr = nullptr;
|
||||||
|
return idx;
|
||||||
|
}
|
||||||
|
|
||||||
StringLocation Worker::StoreString( const char* str, size_t sz )
|
StringLocation Worker::StoreString( const char* str, size_t sz )
|
||||||
{
|
{
|
||||||
StringLocation ret;
|
StringLocation ret;
|
||||||
@ -5503,9 +5511,7 @@ void Worker::ProcessSymbolInformation( const QueueSymbolInformation& ev )
|
|||||||
auto it = m_pendingSymbols.find( ev.symAddr );
|
auto it = m_pendingSymbols.find( ev.symAddr );
|
||||||
assert( it != m_pendingSymbols.end() );
|
assert( it != m_pendingSymbols.end() );
|
||||||
|
|
||||||
assert( m_pendingSingleString.ptr != nullptr );
|
const auto idx = GetSingleStringIdx();
|
||||||
const auto idx = m_pendingSingleString.idx;
|
|
||||||
m_pendingSingleString.ptr = nullptr;
|
|
||||||
|
|
||||||
SymbolData sd;
|
SymbolData sd;
|
||||||
sd.name = it->second.name;
|
sd.name = it->second.name;
|
||||||
@ -5548,9 +5554,7 @@ void Worker::ProcessCodeInformation( const QueueCodeInformation& ev )
|
|||||||
assert( m_pendingCodeInformation > 0 );
|
assert( m_pendingCodeInformation > 0 );
|
||||||
m_pendingCodeInformation--;
|
m_pendingCodeInformation--;
|
||||||
|
|
||||||
assert( m_pendingSingleString.ptr != nullptr );
|
const auto idx = GetSingleStringIdx();
|
||||||
const auto idx = m_pendingSingleString.idx;
|
|
||||||
m_pendingSingleString.ptr = nullptr;
|
|
||||||
|
|
||||||
if( ev.line != 0 )
|
if( ev.line != 0 )
|
||||||
{
|
{
|
||||||
|
@ -761,6 +761,7 @@ private:
|
|||||||
void HandleFailure( const char* ptr, const char* end );
|
void HandleFailure( const char* ptr, const char* end );
|
||||||
void DispatchFailure( const QueueItem& ev, const char*& ptr );
|
void DispatchFailure( const QueueItem& ev, const char*& ptr );
|
||||||
|
|
||||||
|
uint32_t GetSingleStringIdx();
|
||||||
StringLocation StoreString( const char* str, size_t sz );
|
StringLocation StoreString( const char* str, size_t sz );
|
||||||
const ContextSwitch* const GetContextSwitchDataImpl( uint64_t thread );
|
const ContextSwitch* const GetContextSwitchDataImpl( uint64_t thread );
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user