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

Side by Side Diff: Source/platform/heap/MarkingVisitorImpl.h

Issue 1179763005: Oilpan: Fix compile of GC_PROFILING build, and remove object graph dumper. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add EagerSweepHeap. Created 5 years, 6 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
« no previous file with comments | « Source/platform/heap/MarkingVisitor.h ('k') | Source/platform/heap/ThreadState.cpp » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium 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 #ifndef MarkingVisitorImpl_h 5 #ifndef MarkingVisitorImpl_h
6 #define MarkingVisitorImpl_h 6 #define MarkingVisitorImpl_h
7 7
8 #include "platform/heap/Heap.h" 8 #include "platform/heap/Heap.h"
9 #include "platform/heap/ThreadState.h" 9 #include "platform/heap/ThreadState.h"
10 #include "platform/heap/Visitor.h" 10 #include "platform/heap/Visitor.h"
(...skipping 27 matching lines...) Expand all
38 if (header->isMarked()) 38 if (header->isMarked())
39 return; 39 return;
40 40
41 #if ENABLE(ASSERT) 41 #if ENABLE(ASSERT)
42 ASSERT(ThreadState::current()->isInGC()); 42 ASSERT(ThreadState::current()->isInGC());
43 ASSERT(Heap::findPageFromAddress(header)); 43 ASSERT(Heap::findPageFromAddress(header));
44 ASSERT(toDerived()->markingMode() != Visitor::WeakProcessing); 44 ASSERT(toDerived()->markingMode() != Visitor::WeakProcessing);
45 #endif 45 #endif
46 header->mark(); 46 header->mark();
47 47
48 #if ENABLE(GC_PROFILING)
49 toDerived()->recordObjectGraphEdge(objectPointer);
50 #endif
51
52 if (callback) 48 if (callback)
53 Heap::pushTraceCallback(const_cast<void*>(objectPointer), callback); 49 Heap::pushTraceCallback(const_cast<void*>(objectPointer), callback);
54 } 50 }
55 51
56 inline void mark(const void* objectPointer, TraceCallback callback) 52 inline void mark(const void* objectPointer, TraceCallback callback)
57 { 53 {
58 if (!objectPointer) 54 if (!objectPointer)
59 return; 55 return;
60 HeapObjectHeader* header = HeapObjectHeader::fromPayload(objectPointer); 56 HeapObjectHeader* header = HeapObjectHeader::fromPayload(objectPointer);
61 markHeader(header, header->payload(), callback); 57 markHeader(header, header->payload(), callback);
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 private: 125 private:
130 static void markNoTracingCallback(Visitor* visitor, void* object) 126 static void markNoTracingCallback(Visitor* visitor, void* object)
131 { 127 {
132 visitor->markNoTracing(object); 128 visitor->markNoTracing(object);
133 } 129 }
134 }; 130 };
135 131
136 } // namespace blink 132 } // namespace blink
137 133
138 #endif 134 #endif
OLDNEW
« no previous file with comments | « Source/platform/heap/MarkingVisitor.h ('k') | Source/platform/heap/ThreadState.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698