| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project 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 "src/heap/scavenge-job.h" | 5 #include "src/heap/scavenge-job.h" |
| 6 | 6 |
| 7 #include "src/base/platform/time.h" | 7 #include "src/base/platform/time.h" |
| 8 #include "src/heap/heap-inl.h" | 8 #include "src/heap/heap-inl.h" |
| 9 #include "src/heap/heap.h" | 9 #include "src/heap/heap.h" |
| 10 #include "src/isolate.h" | 10 #include "src/isolate.h" |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 void ScavengeJob::ScheduleIdleTask(Heap* heap) { | 105 void ScavengeJob::ScheduleIdleTask(Heap* heap) { |
| 106 if (!idle_task_pending_) { | 106 if (!idle_task_pending_) { |
| 107 v8::Isolate* isolate = reinterpret_cast<v8::Isolate*>(heap->isolate()); | 107 v8::Isolate* isolate = reinterpret_cast<v8::Isolate*>(heap->isolate()); |
| 108 if (V8::GetCurrentPlatform()->IdleTasksEnabled(isolate)) { | 108 if (V8::GetCurrentPlatform()->IdleTasksEnabled(isolate)) { |
| 109 idle_task_pending_ = true; | 109 idle_task_pending_ = true; |
| 110 auto task = new IdleTask(heap->isolate(), this); | 110 auto task = new IdleTask(heap->isolate(), this); |
| 111 V8::GetCurrentPlatform()->CallIdleOnForegroundThread(isolate, task); | 111 V8::GetCurrentPlatform()->CallIdleOnForegroundThread(isolate, task); |
| 112 } | 112 } |
| 113 } | 113 } |
| 114 } | 114 } |
| 115 } | 115 } // namespace internal |
| 116 } // namespace v8::internal | 116 } // namespace v8 |
| OLD | NEW |