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/gc-idle-time-handler.h" | 10 #include "src/heap/gc-idle-time-handler.h" |
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
368 | 368 |
369 | 369 |
370 void IncrementalMarking::SetNewSpacePageFlags(MemoryChunk* chunk, | 370 void IncrementalMarking::SetNewSpacePageFlags(MemoryChunk* chunk, |
371 bool is_marking) { | 371 bool is_marking) { |
372 chunk->SetFlag(MemoryChunk::POINTERS_TO_HERE_ARE_INTERESTING); | 372 chunk->SetFlag(MemoryChunk::POINTERS_TO_HERE_ARE_INTERESTING); |
373 if (is_marking) { | 373 if (is_marking) { |
374 chunk->SetFlag(MemoryChunk::POINTERS_FROM_HERE_ARE_INTERESTING); | 374 chunk->SetFlag(MemoryChunk::POINTERS_FROM_HERE_ARE_INTERESTING); |
375 } else { | 375 } else { |
376 chunk->ClearFlag(MemoryChunk::POINTERS_FROM_HERE_ARE_INTERESTING); | 376 chunk->ClearFlag(MemoryChunk::POINTERS_FROM_HERE_ARE_INTERESTING); |
377 } | 377 } |
378 chunk->SetFlag(MemoryChunk::SCAN_ON_SCAVENGE); | |
379 } | 378 } |
380 | 379 |
381 | 380 |
382 void IncrementalMarking::DeactivateIncrementalWriteBarrierForSpace( | 381 void IncrementalMarking::DeactivateIncrementalWriteBarrierForSpace( |
383 PagedSpace* space) { | 382 PagedSpace* space) { |
384 PageIterator it(space); | 383 PageIterator it(space); |
385 while (it.has_next()) { | 384 while (it.has_next()) { |
386 Page* p = it.next(); | 385 Page* p = it.next(); |
387 SetOldSpacePageFlags(p, false, false); | 386 SetOldSpacePageFlags(p, false, false); |
388 } | 387 } |
(...skipping 846 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1235 void IncrementalMarking::IncrementIdleMarkingDelayCounter() { | 1234 void IncrementalMarking::IncrementIdleMarkingDelayCounter() { |
1236 idle_marking_delay_counter_++; | 1235 idle_marking_delay_counter_++; |
1237 } | 1236 } |
1238 | 1237 |
1239 | 1238 |
1240 void IncrementalMarking::ClearIdleMarkingDelayCounter() { | 1239 void IncrementalMarking::ClearIdleMarkingDelayCounter() { |
1241 idle_marking_delay_counter_ = 0; | 1240 idle_marking_delay_counter_ = 0; |
1242 } | 1241 } |
1243 } // namespace internal | 1242 } // namespace internal |
1244 } // namespace v8 | 1243 } // namespace v8 |
OLD | NEW |