summaryrefslogtreecommitdiffstats
path: root/cc/scheduler/compositor_timing_history.h
diff options
context:
space:
mode:
Diffstat (limited to 'cc/scheduler/compositor_timing_history.h')
-rw-r--r--cc/scheduler/compositor_timing_history.h16
1 files changed, 12 insertions, 4 deletions
diff --git a/cc/scheduler/compositor_timing_history.h b/cc/scheduler/compositor_timing_history.h
index d64c38f..e580c5e 100644
--- a/cc/scheduler/compositor_timing_history.h
+++ b/cc/scheduler/compositor_timing_history.h
@@ -5,6 +5,7 @@
#ifndef CC_SCHEDULER_COMPOSITOR_TIMING_HISTORY_H_
#define CC_SCHEDULER_COMPOSITOR_TIMING_HISTORY_H_
+#include "base/memory/scoped_ptr.h"
#include "cc/base/rolling_time_delta_history.h"
namespace base {
@@ -19,7 +20,15 @@ class RenderingStatsInstrumentation;
class CC_EXPORT CompositorTimingHistory {
public:
- explicit CompositorTimingHistory(
+ enum UMACategory {
+ RENDERER_UMA,
+ BROWSER_UMA,
+ NULL_UMA,
+ };
+ class UMAReporter;
+
+ CompositorTimingHistory(
+ UMACategory uma_category,
RenderingStatsInstrumentation* rendering_stats_instrumentation);
virtual ~CompositorTimingHistory();
@@ -45,11 +54,9 @@ class CC_EXPORT CompositorTimingHistory {
void DidDraw();
protected:
+ static scoped_ptr<UMAReporter> CreateUMAReporter(UMACategory category);
virtual base::TimeTicks Now() const;
- void AddDrawDurationUMA(base::TimeDelta draw_duration,
- base::TimeDelta draw_duration_estimate);
-
bool enabled_;
RollingTimeDeltaHistory begin_main_frame_to_commit_duration_history_;
@@ -64,6 +71,7 @@ class CC_EXPORT CompositorTimingHistory {
base::TimeTicks start_activate_time_;
base::TimeTicks start_draw_time_;
+ scoped_ptr<UMAReporter> uma_reporter_;
RenderingStatsInstrumentation* rendering_stats_instrumentation_;
private: