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

Side by Side Diff: src/heap/heap.cc

Issue 1493133003: [heap] Fix finalization of incremental marking race. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/heap/heap.h" 5 #include "src/heap/heap.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/api.h" 8 #include "src/api.h"
9 #include "src/ast/scopeinfo.h" 9 #include "src/ast/scopeinfo.h"
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 746 matching lines...) Expand 10 before | Expand all | Expand 10 after
757 757
758 758
759 void Heap::HandleGCRequest() { 759 void Heap::HandleGCRequest() {
760 if (incremental_marking()->request_type() == 760 if (incremental_marking()->request_type() ==
761 IncrementalMarking::COMPLETE_MARKING) { 761 IncrementalMarking::COMPLETE_MARKING) {
762 CollectAllGarbage(current_gc_flags_, "GC interrupt", 762 CollectAllGarbage(current_gc_flags_, "GC interrupt",
763 current_gc_callback_flags_); 763 current_gc_callback_flags_);
764 return; 764 return;
765 } 765 }
766 DCHECK(FLAG_finalize_marking_incrementally); 766 DCHECK(FLAG_finalize_marking_incrementally);
767 if (!incremental_marking()->finalize_marking_completed()) { 767 if (incremental_marking()->IsMarking() &&
768 !incremental_marking()->finalize_marking_completed()) {
768 FinalizeIncrementalMarking("GC interrupt: finalize incremental marking"); 769 FinalizeIncrementalMarking("GC interrupt: finalize incremental marking");
769 } 770 }
770 } 771 }
771 772
772 773
773 void Heap::ScheduleIdleScavengeIfNeeded(int bytes_allocated) { 774 void Heap::ScheduleIdleScavengeIfNeeded(int bytes_allocated) {
774 scavenge_job_->ScheduleIdleTaskIfNeeded(this, bytes_allocated); 775 scavenge_job_->ScheduleIdleTaskIfNeeded(this, bytes_allocated);
775 } 776 }
776 777
777 778
(...skipping 5321 matching lines...) Expand 10 before | Expand all | Expand 10 after
6099 } 6100 }
6100 6101
6101 6102
6102 // static 6103 // static
6103 int Heap::GetStaticVisitorIdForMap(Map* map) { 6104 int Heap::GetStaticVisitorIdForMap(Map* map) {
6104 return StaticVisitorBase::GetVisitorId(map); 6105 return StaticVisitorBase::GetVisitorId(map);
6105 } 6106 }
6106 6107
6107 } // namespace internal 6108 } // namespace internal
6108 } // namespace v8 6109 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698