| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "platform/scheduler/renderer/renderer_scheduler_impl.h" | 5 #include "platform/scheduler/renderer/renderer_scheduler_impl.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/debug/stack_trace.h" | 8 #include "base/debug/stack_trace.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 213 | 213 |
| 214 RendererSchedulerImpl::CompositorThreadOnly::~CompositorThreadOnly() {} | 214 RendererSchedulerImpl::CompositorThreadOnly::~CompositorThreadOnly() {} |
| 215 | 215 |
| 216 void RendererSchedulerImpl::Shutdown() { | 216 void RendererSchedulerImpl::Shutdown() { |
| 217 base::TimeTicks now = tick_clock()->NowTicks(); | 217 base::TimeTicks now = tick_clock()->NowTicks(); |
| 218 MainThreadOnly().background_main_thread_load_tracker.RecordIdle(now); | 218 MainThreadOnly().background_main_thread_load_tracker.RecordIdle(now); |
| 219 MainThreadOnly().foreground_main_thread_load_tracker.RecordIdle(now); | 219 MainThreadOnly().foreground_main_thread_load_tracker.RecordIdle(now); |
| 220 | 220 |
| 221 task_queue_throttler_.reset(); | 221 task_queue_throttler_.reset(); |
| 222 helper_.Shutdown(); | 222 helper_.Shutdown(); |
| 223 idle_helper_.Shutdown(); |
| 223 MainThreadOnly().was_shutdown = true; | 224 MainThreadOnly().was_shutdown = true; |
| 224 MainThreadOnly().rail_mode_observer = nullptr; | 225 MainThreadOnly().rail_mode_observer = nullptr; |
| 225 } | 226 } |
| 226 | 227 |
| 227 std::unique_ptr<blink::WebThread> RendererSchedulerImpl::CreateMainThread() { | 228 std::unique_ptr<blink::WebThread> RendererSchedulerImpl::CreateMainThread() { |
| 228 return base::MakeUnique<WebThreadImplForRendererScheduler>(this); | 229 return base::MakeUnique<WebThreadImplForRendererScheduler>(this); |
| 229 } | 230 } |
| 230 | 231 |
| 231 scoped_refptr<TaskQueue> RendererSchedulerImpl::DefaultTaskRunner() { | 232 scoped_refptr<TaskQueue> RendererSchedulerImpl::DefaultTaskRunner() { |
| 232 return helper_.DefaultTaskRunner(); | 233 return helper_.DefaultTaskRunner(); |
| (...skipping 1461 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1694 case v8::PERFORMANCE_LOAD: | 1695 case v8::PERFORMANCE_LOAD: |
| 1695 return "load"; | 1696 return "load"; |
| 1696 default: | 1697 default: |
| 1697 NOTREACHED(); | 1698 NOTREACHED(); |
| 1698 return nullptr; | 1699 return nullptr; |
| 1699 } | 1700 } |
| 1700 } | 1701 } |
| 1701 | 1702 |
| 1702 } // namespace scheduler | 1703 } // namespace scheduler |
| 1703 } // namespace blink | 1704 } // namespace blink |
| OLD | NEW |