| Index: third_party/WebKit/Source/platform/heap/MarkingVisitorImpl.h
|
| diff --git a/third_party/WebKit/Source/platform/heap/MarkingVisitorImpl.h b/third_party/WebKit/Source/platform/heap/MarkingVisitorImpl.h
|
| index 99ac12e300c8915834446928196d9c6684a49882..9cd724cd0b6d962ffa48781836bf508bfce2fff6 100644
|
| --- a/third_party/WebKit/Source/platform/heap/MarkingVisitorImpl.h
|
| +++ b/third_party/WebKit/Source/platform/heap/MarkingVisitorImpl.h
|
| @@ -38,7 +38,8 @@ protected:
|
| if (header->isMarked())
|
| return;
|
|
|
| - ASSERT(ThreadState::current()->isInGC());
|
| + ASSERT(toDerived()->gcData()->threadState()->isInGC());
|
| + RELEASE_ASSERT(ThreadState::forObject(objectPointer)->gcGroup() == toDerived()->gcData()->threadState()->gcGroup());
|
| #if !defined(NDEBUG)
|
| ASSERT(Heap::findPageFromAddress(header));
|
| #endif
|
| @@ -47,7 +48,7 @@ protected:
|
| header->mark();
|
|
|
| if (callback)
|
| - Heap::pushTraceCallback(const_cast<void*>(objectPointer), callback);
|
| + Heap::pushTraceCallback(const_cast<void*>(objectPointer), callback, toDerived()->gcData());
|
| }
|
|
|
| inline void mark(const void* objectPointer, TraceCallback callback)
|
| @@ -61,7 +62,7 @@ protected:
|
| inline void registerDelayedMarkNoTracing(const void* objectPointer)
|
| {
|
| ASSERT(toDerived()->markingMode() != Visitor::WeakProcessing);
|
| - Heap::pushPostMarkingCallback(const_cast<void*>(objectPointer), &markNoTracingCallback);
|
| + Heap::pushPostMarkingCallback(const_cast<void*>(objectPointer), &markNoTracingCallback, toDerived()->gcData());
|
| }
|
|
|
| inline void registerWeakMembers(const void* closure, const void* objectPointer, WeakCallback callback)
|
| @@ -76,13 +77,13 @@ protected:
|
| inline void registerWeakTable(const void* closure, EphemeronCallback iterationCallback, EphemeronCallback iterationDoneCallback)
|
| {
|
| ASSERT(toDerived()->markingMode() != Visitor::WeakProcessing);
|
| - Heap::registerWeakTable(const_cast<void*>(closure), iterationCallback, iterationDoneCallback);
|
| + Heap::registerWeakTable(const_cast<void*>(closure), iterationCallback, iterationDoneCallback, toDerived()->gcData());
|
| }
|
|
|
| #if ENABLE(ASSERT)
|
| inline bool weakTableRegistered(const void* closure)
|
| {
|
| - return Heap::weakTableRegistered(closure);
|
| + return Heap::weakTableRegistered(closure, toDerived()->gcData());
|
| }
|
| #endif
|
|
|
| @@ -120,7 +121,7 @@ protected:
|
| // We don't want to run weak processings when taking a snapshot.
|
| if (toDerived()->markingMode() == Visitor::SnapshotMarking)
|
| return;
|
| - Heap::pushGlobalWeakCallback(cell, callback);
|
| + Heap::pushGlobalWeakCallback(cell, callback, toDerived()->gcData());
|
| }
|
|
|
| private:
|
|
|