Chromium Code Reviews| 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 f6ebddbfeca63fea2fd166576e6028f3a785378b..62338d88f1e56535b675b13f63711e121abb27bc 100644 |
| --- a/third_party/WebKit/Source/platform/heap/PersistentNode.h |
| +++ b/third_party/WebKit/Source/platform/heap/PersistentNode.h |
| @@ -143,7 +143,7 @@ public: |
| --m_persistentCount; |
| #endif |
| } |
| - void tracePersistentNodes(Visitor*); |
| + void tracePersistentNodes(Visitor*, bool (*shouldTrace)(Visitor*, PersistentNode*) = nullptr); |
|
haraken
2016/01/28 15:52:50
Use typedef for the function signature.
keishi
2016/02/29 06:02:33
Done.
|
| int numberOfPersistents(); |
| private: |
| @@ -177,11 +177,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 |