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

Side by Side Diff: third_party/WebKit/Source/platform/scheduler/base/task_queue_impl.h

Issue 2258133002: [scheduler] Implement time-based cpu throttling. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Renamed Enable/Disable to Enable/DisableThrottling. Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_BASE_TASK_QUEUE_IMPL_H_ 5 #ifndef THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_BASE_TASK_QUEUE_IMPL_H_
6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_BASE_TASK_QUEUE_IMPL_H_ 6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_BASE_TASK_QUEUE_IMPL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 base::TimeDelta delay) override; 142 base::TimeDelta delay) override;
143 TaskHandle PostCancellableDelayedTask( 143 TaskHandle PostCancellableDelayedTask(
144 const tracked_objects::Location& from_here, 144 const tracked_objects::Location& from_here,
145 const base::Closure& task, 145 const base::Closure& task,
146 base::TimeDelta delay) override; 146 base::TimeDelta delay) override;
147 bool CancelTask(const TaskHandle& handle) override; 147 bool CancelTask(const TaskHandle& handle) override;
148 void SetQueueEnabled(bool enabled) override; 148 void SetQueueEnabled(bool enabled) override;
149 bool IsQueueEnabled() const override; 149 bool IsQueueEnabled() const override;
150 bool IsEmpty() const override; 150 bool IsEmpty() const override;
151 bool HasPendingImmediateWork() const override; 151 bool HasPendingImmediateWork() const override;
152 base::Optional<base::TimeTicks> GetNextScheduledWakeUp() override;
152 void SetQueuePriority(QueuePriority priority) override; 153 void SetQueuePriority(QueuePriority priority) override;
153 QueuePriority GetQueuePriority() const override; 154 QueuePriority GetQueuePriority() const override;
154 void AddTaskObserver(base::MessageLoop::TaskObserver* task_observer) override; 155 void AddTaskObserver(base::MessageLoop::TaskObserver* task_observer) override;
155 void RemoveTaskObserver( 156 void RemoveTaskObserver(
156 base::MessageLoop::TaskObserver* task_observer) override; 157 base::MessageLoop::TaskObserver* task_observer) override;
157 void SetTimeDomain(TimeDomain* time_domain) override; 158 void SetTimeDomain(TimeDomain* time_domain) override;
158 TimeDomain* GetTimeDomain() const override; 159 TimeDomain* GetTimeDomain() const override;
159 void SetBlameContext(base::trace_event::BlameContext* blame_context) override; 160 void SetBlameContext(base::trace_event::BlameContext* blame_context) override;
160 void InsertFence() override; 161 void InsertFence() override;
161 void RemoveFence() override; 162 void RemoveFence() override;
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
326 const bool should_report_when_execution_blocked_; 327 const bool should_report_when_execution_blocked_;
327 328
328 DISALLOW_COPY_AND_ASSIGN(TaskQueueImpl); 329 DISALLOW_COPY_AND_ASSIGN(TaskQueueImpl);
329 }; 330 };
330 331
331 } // namespace internal 332 } // namespace internal
332 } // namespace scheduler 333 } // namespace scheduler
333 } // namespace blink 334 } // namespace blink
334 335
335 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_BASE_TASK_QUEUE_IMPL_H_ 336 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_BASE_TASK_QUEUE_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698