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

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

Issue 1425013006: Using override keyword in ObjectVisitor class hierarchy. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 1 month 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 | « src/heap/heap.cc ('k') | src/heap/mark-compact.cc » ('j') | 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/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 331 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 } 342 }
343 }; 343 };
344 344
345 345
346 class IncrementalMarkingRootMarkingVisitor : public ObjectVisitor { 346 class IncrementalMarkingRootMarkingVisitor : public ObjectVisitor {
347 public: 347 public:
348 explicit IncrementalMarkingRootMarkingVisitor( 348 explicit IncrementalMarkingRootMarkingVisitor(
349 IncrementalMarking* incremental_marking) 349 IncrementalMarking* incremental_marking)
350 : heap_(incremental_marking->heap()) {} 350 : heap_(incremental_marking->heap()) {}
351 351
352 void VisitPointer(Object** p) { MarkObjectByPointer(p); } 352 void VisitPointer(Object** p) override { MarkObjectByPointer(p); }
353 353
354 void VisitPointers(Object** start, Object** end) { 354 void VisitPointers(Object** start, Object** end) override {
355 for (Object** p = start; p < end; p++) MarkObjectByPointer(p); 355 for (Object** p = start; p < end; p++) MarkObjectByPointer(p);
356 } 356 }
357 357
358 private: 358 private:
359 void MarkObjectByPointer(Object** p) { 359 void MarkObjectByPointer(Object** p) {
360 Object* obj = *p; 360 Object* obj = *p;
361 if (!obj->IsHeapObject()) return; 361 if (!obj->IsHeapObject()) return;
362 362
363 IncrementalMarking::MarkObject(heap_, HeapObject::cast(obj)); 363 IncrementalMarking::MarkObject(heap_, HeapObject::cast(obj));
364 } 364 }
(...skipping 786 matching lines...) Expand 10 before | Expand all | Expand 10 after
1151 void IncrementalMarking::IncrementIdleMarkingDelayCounter() { 1151 void IncrementalMarking::IncrementIdleMarkingDelayCounter() {
1152 idle_marking_delay_counter_++; 1152 idle_marking_delay_counter_++;
1153 } 1153 }
1154 1154
1155 1155
1156 void IncrementalMarking::ClearIdleMarkingDelayCounter() { 1156 void IncrementalMarking::ClearIdleMarkingDelayCounter() {
1157 idle_marking_delay_counter_ = 0; 1157 idle_marking_delay_counter_ = 0;
1158 } 1158 }
1159 } // namespace internal 1159 } // namespace internal
1160 } // namespace v8 1160 } // namespace v8
OLDNEW
« no previous file with comments | « src/heap/heap.cc ('k') | src/heap/mark-compact.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698