mirror of
https://github.com/wolfpld/tracy.git
synced 2025-03-20 07:40:02 +08:00
Optimize reading CPU data.
This commit is contained in:
parent
c03b8b72da
commit
232379c72c
@ -1542,10 +1542,13 @@ Worker::Worker( FileRead& f, EventType::Type eventMask, bool bgTasks )
|
|||||||
auto ptr = m_data.cpuData[i].cs.data();
|
auto ptr = m_data.cpuData[i].cs.data();
|
||||||
for( uint64_t j=0; j<sz; j++ )
|
for( uint64_t j=0; j<sz; j++ )
|
||||||
{
|
{
|
||||||
ptr->SetStart( ReadTimeOffset( f, refTime ) );
|
int64_t deltaStart, deltaEnd;
|
||||||
ptr->SetEnd( ReadTimeOffset( f, refTime ) );
|
|
||||||
uint16_t thread;
|
uint16_t thread;
|
||||||
f.Read( thread );
|
f.Read3( deltaStart, deltaEnd, thread );
|
||||||
|
refTime += deltaStart;
|
||||||
|
ptr->SetStart( refTime );
|
||||||
|
refTime += deltaEnd;
|
||||||
|
ptr->SetEnd( refTime );
|
||||||
ptr->SetThread( thread );
|
ptr->SetThread( thread );
|
||||||
ptr++;
|
ptr++;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user