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/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/incremental-marking.h" | 7 #include "src/incremental-marking.h" |
8 | 8 |
9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
10 #include "src/compilation-cache.h" | 10 #include "src/compilation-cache.h" |
(...skipping 644 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
655 (obj->IsFiller() && Marking::IsWhite(mark_bit)) || | 655 (obj->IsFiller() && Marking::IsWhite(mark_bit)) || |
656 (chunk->IsFlagSet(MemoryChunk::HAS_PROGRESS_BAR) && | 656 (chunk->IsFlagSet(MemoryChunk::HAS_PROGRESS_BAR) && |
657 Marking::IsBlack(mark_bit))); | 657 Marking::IsBlack(mark_bit))); |
658 #endif | 658 #endif |
659 } | 659 } |
660 } | 660 } |
661 marking_deque_.set_top(new_top); | 661 marking_deque_.set_top(new_top); |
662 | 662 |
663 steps_took_since_last_gc_ = 0; | 663 steps_took_since_last_gc_ = 0; |
664 steps_count_since_last_gc_ = 0; | 664 steps_count_since_last_gc_ = 0; |
665 longest_step_ = 0.0; | |
666 } | 665 } |
667 | 666 |
668 | 667 |
669 void IncrementalMarking::VisitObject(Map* map, HeapObject* obj, int size) { | 668 void IncrementalMarking::VisitObject(Map* map, HeapObject* obj, int size) { |
670 MarkBit map_mark_bit = Marking::MarkBitFrom(map); | 669 MarkBit map_mark_bit = Marking::MarkBitFrom(map); |
671 if (Marking::IsWhite(map_mark_bit)) { | 670 if (Marking::IsWhite(map_mark_bit)) { |
672 WhiteToGreyAndPush(map, map_mark_bit); | 671 WhiteToGreyAndPush(map, map_mark_bit); |
673 } | 672 } |
674 | 673 |
675 IncrementalMarkingMarkingVisitor::IterateBody(map, obj); | 674 IncrementalMarkingMarkingVisitor::IterateBody(map, obj); |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
989 bytes_scanned_ = 0; | 988 bytes_scanned_ = 0; |
990 write_barriers_invoked_since_last_step_ = 0; | 989 write_barriers_invoked_since_last_step_ = 0; |
991 } | 990 } |
992 | 991 |
993 | 992 |
994 int64_t IncrementalMarking::SpaceLeftInOldSpace() { | 993 int64_t IncrementalMarking::SpaceLeftInOldSpace() { |
995 return heap_->MaxOldGenerationSize() - heap_->PromotedSpaceSizeOfObjects(); | 994 return heap_->MaxOldGenerationSize() - heap_->PromotedSpaceSizeOfObjects(); |
996 } | 995 } |
997 | 996 |
998 } } // namespace v8::internal | 997 } } // namespace v8::internal |
OLD | NEW |