mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-26 16:04:34 +00:00
Dispatch new zone, update zone events.
This commit is contained in:
parent
e3edd7e336
commit
c0dd0ef5bc
@ -162,16 +162,16 @@ void View::ProcessZoneBegin( uint64_t id, const QueueZoneBegin& ev )
|
|||||||
if( it == m_pendingEndZone.end() )
|
if( it == m_pendingEndZone.end() )
|
||||||
{
|
{
|
||||||
m_data.emplace_back( Event { ev.time, -1 } );
|
m_data.emplace_back( Event { ev.time, -1 } );
|
||||||
|
NewZone( idx );
|
||||||
lock.unlock();
|
lock.unlock();
|
||||||
|
|
||||||
m_openZones.emplace( id, idx );
|
m_openZones.emplace( id, idx );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
assert( ev.time <= it->second.time );
|
assert( ev.time <= it->second.time );
|
||||||
m_data.emplace_back( Event { ev.time, it->second.time } );
|
m_data.emplace_back( Event { ev.time, it->second.time } );
|
||||||
|
NewZone( idx );
|
||||||
lock.unlock();
|
lock.unlock();
|
||||||
|
|
||||||
m_pendingEndZone.erase( it );
|
m_pendingEndZone.erase( it );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -189,8 +189,8 @@ void View::ProcessZoneEnd( uint64_t id, const QueueZoneEnd& ev )
|
|||||||
std::unique_lock<std::mutex> lock( m_lock );
|
std::unique_lock<std::mutex> lock( m_lock );
|
||||||
assert( ev.time >= m_data[idx].start );
|
assert( ev.time >= m_data[idx].start );
|
||||||
m_data[idx].end = ev.time;
|
m_data[idx].end = ev.time;
|
||||||
|
UpdateZone( idx );
|
||||||
lock.unlock();
|
lock.unlock();
|
||||||
|
|
||||||
m_openZones.erase( it );
|
m_openZones.erase( it );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -214,4 +214,12 @@ void View::AddString( uint64_t ptr, std::string&& str )
|
|||||||
m_strings.emplace( ptr, std::move( str ) );
|
m_strings.emplace( ptr, std::move( str ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void View::NewZone( uint64_t idx )
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void View::UpdateZone( uint64_t idx )
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -40,6 +40,9 @@ private:
|
|||||||
void CheckString( uint64_t ptr );
|
void CheckString( uint64_t ptr );
|
||||||
void AddString( uint64_t ptr, std::string&& str );
|
void AddString( uint64_t ptr, std::string&& str );
|
||||||
|
|
||||||
|
void NewZone( uint64_t idx );
|
||||||
|
void UpdateZone( uint64_t idx );
|
||||||
|
|
||||||
std::string m_addr;
|
std::string m_addr;
|
||||||
|
|
||||||
Socket m_sock;
|
Socket m_sock;
|
||||||
|
Loading…
Reference in New Issue
Block a user