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

Unified Diff: components/scheduler/renderer/idle_time_estimator.h

Issue 1424053002: Adds a flag to support "Virtual Time" to the blink scheduler (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 5 years, 1 month 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 | « components/scheduler/renderer/DEPS ('k') | components/scheduler/renderer/idle_time_estimator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/scheduler/renderer/idle_time_estimator.h
diff --git a/components/scheduler/renderer/idle_time_estimator.h b/components/scheduler/renderer/idle_time_estimator.h
index eb9eee3d95e73c71f448c4df896115681e50385e..af00fbbeff35bd64c905d7bbf1799f0823101b68 100644
--- a/components/scheduler/renderer/idle_time_estimator.h
+++ b/components/scheduler/renderer/idle_time_estimator.h
@@ -18,6 +18,7 @@ class SCHEDULER_EXPORT IdleTimeEstimator
: public base::MessageLoop::TaskObserver {
public:
IdleTimeEstimator(const scoped_refptr<TaskQueue>& compositor_task_runner,
+ base::TickClock* time_source,
int sample_count,
double estimation_percentile);
@@ -36,12 +37,10 @@ class SCHEDULER_EXPORT IdleTimeEstimator
void WillProcessTask(const base::PendingTask& pending_task) override;
void DidProcessTask(const base::PendingTask& pending_task) override;
- void SetTimeSourceForTesting(scoped_ptr<base::TickClock> time_source);
-
private:
scoped_refptr<TaskQueue> compositor_task_runner_;
cc::RollingTimeDeltaHistory per_frame_compositor_task_runtime_;
- scoped_ptr<base::TickClock> time_source_;
+ base::TickClock* time_source_; // NOT OWNED
double estimation_percentile_;
base::TimeTicks task_start_time_;
« no previous file with comments | « components/scheduler/renderer/DEPS ('k') | components/scheduler/renderer/idle_time_estimator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698