| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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/incremental-marking.h" | 5 #include "src/heap/incremental-marking.h" |
| 6 | 6 |
| 7 #include "src/code-stubs.h" | 7 #include "src/code-stubs.h" |
| 8 #include "src/compilation-cache.h" | 8 #include "src/compilation-cache.h" |
| 9 #include "src/conversions.h" | 9 #include "src/conversions.h" |
| 10 #include "src/heap/concurrent-marking.h" | 10 #include "src/heap/concurrent-marking.h" |
| (...skipping 555 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 566 black_allocation_ = true; | 566 black_allocation_ = true; |
| 567 heap()->old_space()->MarkAllocationInfoBlack(); | 567 heap()->old_space()->MarkAllocationInfoBlack(); |
| 568 heap()->map_space()->MarkAllocationInfoBlack(); | 568 heap()->map_space()->MarkAllocationInfoBlack(); |
| 569 heap()->code_space()->MarkAllocationInfoBlack(); | 569 heap()->code_space()->MarkAllocationInfoBlack(); |
| 570 if (FLAG_trace_incremental_marking) { | 570 if (FLAG_trace_incremental_marking) { |
| 571 heap()->isolate()->PrintWithTimestamp( | 571 heap()->isolate()->PrintWithTimestamp( |
| 572 "[IncrementalMarking] Black allocation started\n"); | 572 "[IncrementalMarking] Black allocation started\n"); |
| 573 } | 573 } |
| 574 } | 574 } |
| 575 | 575 |
| 576 void IncrementalMarking::PauseBlackAllocation() { |
| 577 DCHECK(FLAG_black_allocation); |
| 578 DCHECK(IsMarking()); |
| 579 heap()->old_space()->UnmarkAllocationInfo(); |
| 580 heap()->map_space()->UnmarkAllocationInfo(); |
| 581 heap()->code_space()->UnmarkAllocationInfo(); |
| 582 if (FLAG_trace_incremental_marking) { |
| 583 heap()->isolate()->PrintWithTimestamp( |
| 584 "[IncrementalMarking] Black allocation paused\n"); |
| 585 } |
| 586 black_allocation_ = false; |
| 587 } |
| 588 |
| 576 void IncrementalMarking::FinishBlackAllocation() { | 589 void IncrementalMarking::FinishBlackAllocation() { |
| 577 if (black_allocation_) { | 590 if (black_allocation_) { |
| 578 black_allocation_ = false; | 591 black_allocation_ = false; |
| 579 if (FLAG_trace_incremental_marking) { | 592 if (FLAG_trace_incremental_marking) { |
| 580 heap()->isolate()->PrintWithTimestamp( | 593 heap()->isolate()->PrintWithTimestamp( |
| 581 "[IncrementalMarking] Black allocation finished\n"); | 594 "[IncrementalMarking] Black allocation finished\n"); |
| 582 } | 595 } |
| 583 } | 596 } |
| 584 } | 597 } |
| 585 | 598 |
| (...skipping 577 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1163 idle_marking_delay_counter_++; | 1176 idle_marking_delay_counter_++; |
| 1164 } | 1177 } |
| 1165 | 1178 |
| 1166 | 1179 |
| 1167 void IncrementalMarking::ClearIdleMarkingDelayCounter() { | 1180 void IncrementalMarking::ClearIdleMarkingDelayCounter() { |
| 1168 idle_marking_delay_counter_ = 0; | 1181 idle_marking_delay_counter_ = 0; |
| 1169 } | 1182 } |
| 1170 | 1183 |
| 1171 } // namespace internal | 1184 } // namespace internal |
| 1172 } // namespace v8 | 1185 } // namespace v8 |
| OLD | NEW |