| Index: third_party/WebKit/Source/platform/heap/PersistentNode.h
|
| diff --git a/third_party/WebKit/Source/platform/heap/PersistentNode.h b/third_party/WebKit/Source/platform/heap/PersistentNode.h
|
| index 7b94bbe75cd648efd4afae60c592ced48c85b665..52b558084cb0772fac38b2915c8fc591c9e614d5 100644
|
| --- a/third_party/WebKit/Source/platform/heap/PersistentNode.h
|
| +++ b/third_party/WebKit/Source/platform/heap/PersistentNode.h
|
| @@ -150,8 +150,11 @@ public:
|
| #endif
|
| }
|
|
|
| + static bool shouldTracePersistentNode(Visitor*, PersistentNode*) { return true; }
|
| +
|
| void releasePersistentNode(PersistentNode*, ThreadState::PersistentClearCallback);
|
| - void tracePersistentNodes(Visitor*);
|
| + using ShouldTraceCallback = bool (*)(Visitor*, PersistentNode*);
|
| + void tracePersistentNodes(Visitor*, ShouldTraceCallback = PersistentRegion::shouldTracePersistentNode);
|
| int numberOfPersistents();
|
|
|
| private:
|
| @@ -186,11 +189,13 @@ public:
|
| void tracePersistentNodes(Visitor* visitor)
|
| {
|
| MutexLocker lock(m_mutex);
|
| - m_persistentRegion->tracePersistentNodes(visitor);
|
| + m_persistentRegion->tracePersistentNodes(visitor, CrossThreadPersistentRegion::shouldTracePersistentNode);
|
| }
|
|
|
| void prepareForThreadStateTermination(ThreadState*);
|
|
|
| + static bool shouldTracePersistentNode(Visitor*, PersistentNode*);
|
| +
|
| private:
|
| // We don't make CrossThreadPersistentRegion inherit from PersistentRegion
|
| // because we don't want to virtualize performance-sensitive methods
|
|
|