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

Unified Diff: third_party/WebKit/Source/platform/scheduler/renderer/throttled_time_domain.h

Issue 2778123003: [scheduler] Add WakeupBudgetPool. (Closed)
Patch Set: Addressed comments Created 3 years, 7 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
Index: third_party/WebKit/Source/platform/scheduler/renderer/throttled_time_domain.h
diff --git a/third_party/WebKit/Source/platform/scheduler/renderer/throttled_time_domain.h b/third_party/WebKit/Source/platform/scheduler/renderer/throttled_time_domain.h
index 0cb0f87d40a70beaec6fb94666532117c756d129..3ddb0d2c383bcabfd0efa260abc0833d2379b15b 100644
--- a/third_party/WebKit/Source/platform/scheduler/renderer/throttled_time_domain.h
+++ b/third_party/WebKit/Source/platform/scheduler/renderer/throttled_time_domain.h
@@ -18,6 +18,8 @@ class PLATFORM_EXPORT ThrottledTimeDomain : public RealTimeDomain {
ThrottledTimeDomain();
~ThrottledTimeDomain() override;
+ void SetNextTaskRunTime(base::TimeTicks run_time);
+
// TimeDomain implementation:
const char* GetName() const override;
void RequestWakeUpAt(base::TimeTicks now, base::TimeTicks run_time) override;
@@ -27,6 +29,10 @@ class PLATFORM_EXPORT ThrottledTimeDomain : public RealTimeDomain {
using TimeDomain::WakeUpReadyDelayedQueues;
private:
+ // Next task run time provided by task queue throttler. Note that it does not
+ // get reset, so it is valid only when in the future.
+ base::Optional<base::TimeTicks> next_task_run_time_;
+
DISALLOW_COPY_AND_ASSIGN(ThrottledTimeDomain);
};

Powered by Google App Engine
This is Rietveld 408576698