Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(886)

Unified Diff: cc/scheduler/compositor_timing_history.h

Issue 1681393003: cc: Add MainAndImplFrameTimeDelta UMA. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: - active_tree_needs_first_draw_ = true Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | cc/scheduler/compositor_timing_history.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/scheduler/compositor_timing_history.h
diff --git a/cc/scheduler/compositor_timing_history.h b/cc/scheduler/compositor_timing_history.h
index 11dfc00d5e5d5c5e865be55cba3c3689da11c86b..a7c58dd567fba1077d7c9eabc80e960bf567d15f 100644
--- a/cc/scheduler/compositor_timing_history.h
+++ b/cc/scheduler/compositor_timing_history.h
@@ -29,6 +29,7 @@ class CC_EXPORT CompositorTimingHistory {
class UMAReporter;
CompositorTimingHistory(
+ bool using_synchronous_renderer_compositor,
UMACategory uma_category,
RenderingStatsInstrumentation* rendering_stats_instrumentation);
virtual ~CompositorTimingHistory();
@@ -49,12 +50,16 @@ class CC_EXPORT CompositorTimingHistory {
virtual base::TimeDelta ActivateDurationEstimate() const;
virtual base::TimeDelta DrawDurationEstimate() const;
+ // State that affects when events should be expected/recorded/reported.
void SetRecordingEnabled(bool enabled);
+ void DidCreateAndInitializeOutputSurface();
+ // Events to be timed.
void WillBeginImplFrame(bool new_active_tree_is_likely);
void WillFinishImplFrame(bool needs_redraw);
void BeginImplFrameNotExpectedSoon();
- void WillBeginMainFrame(bool on_critical_path);
+ void WillBeginMainFrame(bool on_critical_path,
+ base::TimeTicks main_frame_time);
void BeginMainFrameStarted(base::TimeTicks main_thread_start_time);
void BeginMainFrameAborted();
void DidCommit();
@@ -63,11 +68,13 @@ class CC_EXPORT CompositorTimingHistory {
void ReadyToActivate();
void WillActivate();
void DidActivate();
+ void DrawAborted();
void WillDraw();
- void DidDraw(bool used_new_active_tree);
+ void DidDraw(bool used_new_active_tree,
+ bool main_thread_missed_last_deadline,
+ base::TimeTicks impl_frame_time);
void DidSwapBuffers();
void DidSwapBuffersComplete();
- void DidSwapBuffersReset();
protected:
void DidBeginMainFrame();
@@ -79,6 +86,7 @@ class CC_EXPORT CompositorTimingHistory {
static scoped_ptr<UMAReporter> CreateUMAReporter(UMACategory category);
virtual base::TimeTicks Now() const;
+ bool using_synchronous_renderer_compositor_;
bool enabled_;
// Used to calculate frame rates of Main and Impl threads.
@@ -101,11 +109,14 @@ class CC_EXPORT CompositorTimingHistory {
RollingTimeDeltaHistory draw_duration_history_;
bool begin_main_frame_on_critical_path_;
+ base::TimeTicks begin_main_frame_frame_time_;
base::TimeTicks begin_main_frame_sent_time_;
base::TimeTicks begin_main_frame_start_time_;
base::TimeTicks begin_main_frame_end_time_;
+ base::TimeTicks pending_tree_main_frame_time_;
base::TimeTicks prepare_tiles_start_time_;
base::TimeTicks activate_start_time_;
+ base::TimeTicks active_tree_main_frame_time_;
base::TimeTicks draw_start_time_;
base::TimeTicks swap_start_time_;
« no previous file with comments | « no previous file | cc/scheduler/compositor_timing_history.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698