Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Side by Side Diff: src/heap/incremental-marking.cc

Issue 871253005: Use weak cells in dependent code. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add comment Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/heap/incremental-marking.h" 7 #include "src/heap/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 532 matching lines...) Expand 10 before | Expand all | Expand 10 after
543 if (FLAG_cleanup_code_caches_at_gc) { 543 if (FLAG_cleanup_code_caches_at_gc) {
544 // We will mark cache black with a separate pass 544 // We will mark cache black with a separate pass
545 // when we finish marking. 545 // when we finish marking.
546 MarkObjectGreyDoNotEnqueue(heap_->polymorphic_code_cache()); 546 MarkObjectGreyDoNotEnqueue(heap_->polymorphic_code_cache());
547 } 547 }
548 548
549 // Mark strong roots grey. 549 // Mark strong roots grey.
550 IncrementalMarkingRootMarkingVisitor visitor(this); 550 IncrementalMarkingRootMarkingVisitor visitor(this);
551 heap_->IterateStrongRoots(&visitor, VISIT_ONLY_STRONG); 551 heap_->IterateStrongRoots(&visitor, VISIT_ONLY_STRONG);
552 552
553 heap_->mark_compact_collector()->MarkWeakObjectToCodeTable(); 553 heap_->mark_compact_collector()->MarkWeakObjectToCodeTable(&visitor);
554 554
555 // Ready to start incremental marking. 555 // Ready to start incremental marking.
556 if (FLAG_trace_incremental_marking) { 556 if (FLAG_trace_incremental_marking) {
557 PrintF("[IncrementalMarking] Running\n"); 557 PrintF("[IncrementalMarking] Running\n");
558 } 558 }
559 } 559 }
560 560
561 561
562 void IncrementalMarking::PrepareForScavenge() { 562 void IncrementalMarking::PrepareForScavenge() {
563 if (!IsMarking()) return; 563 if (!IsMarking()) return;
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after
981 void IncrementalMarking::IncrementIdleMarkingDelayCounter() { 981 void IncrementalMarking::IncrementIdleMarkingDelayCounter() {
982 idle_marking_delay_counter_++; 982 idle_marking_delay_counter_++;
983 } 983 }
984 984
985 985
986 void IncrementalMarking::ClearIdleMarkingDelayCounter() { 986 void IncrementalMarking::ClearIdleMarkingDelayCounter() {
987 idle_marking_delay_counter_ = 0; 987 idle_marking_delay_counter_ = 0;
988 } 988 }
989 } 989 }
990 } // namespace v8::internal 990 } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/compiler.cc ('k') | src/heap/mark-compact.h » ('j') | src/heap/mark-compact.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698