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

Preprocess CPU usage.

Things of note: Worker::GetCpuUsage() functionality was moved to
TimelineItemCpuData::PreprocessCpuUsage().
This commit is contained in:
Bartosz Taudul
2023-03-25 17:55:15 +01:00
parent dcf27f4989
commit 5eebc5d7cf
7 changed files with 194 additions and 149 deletions
+2 -3
View File
@@ -45,6 +45,7 @@ struct TimelineDraw;
struct ContextSwitchDraw;
struct SamplesDraw;
struct MessagesDraw;
struct CpuUsageDraw;
class View
{
@@ -131,7 +132,7 @@ public:
void DrawThreadMessagesList( const TimelineContext& ctx, const std::vector<MessagesDraw>& drawList, int offset, uint64_t tid );
void DrawThreadOverlays( const ThreadData& thread, const ImVec2& ul, const ImVec2& dr );
bool DrawGpu( const TimelineContext& ctx, const GpuCtxData& gpu, int& offset );
bool DrawCpuData( const TimelineContext& ctx, int& offset );
bool DrawCpuData( const TimelineContext& ctx, const std::vector<CpuUsageDraw>&, int& offset );
bool m_showRanges = false;
Range m_statRange;
@@ -841,8 +842,6 @@ private:
int64_t time;
} m_sendQueueWarning;
std::vector<std::pair<int, int>> m_cpuUsageBuf;
bool m_attnProtoMismatch = false;
bool m_attnNotAvailable = false;
bool m_attnDropped = false;