Index: third_party/WebKit/Source/platform/scheduler/child/worker_scheduler_impl.h |
diff --git a/third_party/WebKit/Source/platform/scheduler/child/worker_scheduler_impl.h b/third_party/WebKit/Source/platform/scheduler/child/worker_scheduler_impl.h |
index b6cf8d614f6ae1aa0a76d30b36a5998a6eea69d3..0c53b5d7e256e1094b8fd4c87b2faf22d956400b 100644 |
--- a/third_party/WebKit/Source/platform/scheduler/child/worker_scheduler_impl.h |
+++ b/third_party/WebKit/Source/platform/scheduler/child/worker_scheduler_impl.h |
@@ -6,9 +6,11 @@ |
#define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WORKER_SCHEDULER_IMPL_H_ |
#include "base/macros.h" |
+#include "platform/scheduler/base/thread_load_tracker.h" |
#include "platform/scheduler/child/idle_canceled_delayed_task_sweeper.h" |
#include "platform/scheduler/child/idle_helper.h" |
#include "platform/scheduler/child/scheduler_helper.h" |
+#include "public/platform/scheduler/base/task_time_observer.h" |
#include "public/platform/scheduler/child/worker_scheduler.h" |
namespace blink { |
@@ -17,7 +19,8 @@ namespace scheduler { |
class SchedulerTqmDelegate; |
class BLINK_PLATFORM_EXPORT WorkerSchedulerImpl : public WorkerScheduler, |
- public IdleHelper::Delegate { |
+ public IdleHelper::Delegate, |
+ TaskTimeObserver { |
nhiroki
2017/03/23 05:20:04
No public/protected/private. Is this intended?
kinuko
2017/04/03 13:01:20
Not really, made it public.
|
public: |
explicit WorkerSchedulerImpl( |
scoped_refptr<SchedulerTqmDelegate> main_task_runner); |
@@ -34,6 +37,12 @@ class BLINK_PLATFORM_EXPORT WorkerSchedulerImpl : public WorkerScheduler, |
void Init() override; |
void Shutdown() override; |
+ // TaskTimeObserver implementation: |
+ void willProcessTask(TaskQueue* task_queue, double start_time) override; |
+ void didProcessTask(TaskQueue* task_queue, |
+ double start_time, |
+ double end_time) override; |
+ |
SchedulerHelper* GetSchedulerHelperForTesting(); |
base::TimeTicks CurrentIdleTaskDeadlineForTesting() const; |
@@ -52,6 +61,7 @@ class BLINK_PLATFORM_EXPORT WorkerSchedulerImpl : public WorkerScheduler, |
SchedulerHelper helper_; |
IdleHelper idle_helper_; |
IdleCanceledDelayedTaskSweeper idle_canceled_delayed_task_sweeper_; |
+ ThreadLoadTracker load_tracker_; |
nhiroki
2017/03/23 05:20:04
Hm... it looks like this field name doesn't obey t
Sami
2017/03/24 10:48:10
This code originally lived in content/ and then mo
nhiroki
2017/04/04 03:13:06
I see. Thank you for the clarification
|
bool initialized_; |
DISALLOW_COPY_AND_ASSIGN(WorkerSchedulerImpl); |