Chromium Code Reviews| Index: Source/core/dom/NodeRareData.cpp |
| diff --git a/Source/core/dom/NodeRareData.cpp b/Source/core/dom/NodeRareData.cpp |
| index e3ee7e6d8a1190ad05ff54042d337417c73b0777..6eb0743b67621524102708398c2aa62ca23d71d3 100644 |
| --- a/Source/core/dom/NodeRareData.cpp |
| +++ b/Source/core/dom/NodeRareData.cpp |
| @@ -31,11 +31,17 @@ |
| #include "config.h" |
| #include "core/dom/NodeRareData.h" |
| #include "core/dom/Element.h" |
| +#include "platform/heap/Handle.h" |
| namespace WebCore { |
| struct SameSizeAsNodeRareData { |
| void* m_pointer[3]; |
| +#if ENABLE(OILPAN) |
| + // FIXME: Oilpan: when the persistent reference to NodeMutationObserverData goes, |
| + // this can be removed. |
| + void* m_extraOilpanPersistentPointers[sizeof(Persistent<NodeMutationObserverData>) / sizeof(void*) - 1]; |
| +#endif |
|
haraken
2014/04/15 02:33:25
Can you simple write:
OwnPtrWillBePersistent<No
sof
2014/04/15 22:00:53
That's a good suggestion.
And as m_nodeLists is a
|
| unsigned m_bitfields; |
| }; |
| @@ -55,6 +61,17 @@ void NodeListsNodeData::invalidateCaches(const QualifiedName* attrName) |
| it->value->invalidateCache(); |
| } |
| +#if ENABLE(OILPAN) |
| +void NodeRareData::dispose() |
| +{ |
| + if (m_mutationObserverData) { |
| + for (unsigned i = 0; i < m_mutationObserverData->registry.size(); i++) |
| + m_mutationObserverData->registry.at(i)->dispose(); |
| + m_mutationObserverData.clear(); |
| + } |
| +} |
| +#endif |
| + |
| // Ensure the 10 bits reserved for the m_connectedFrameCount cannot overflow |
| COMPILE_ASSERT(Page::maxNumberOfFrames < (1 << NodeRareData::ConnectedFrameCountBits), Frame_limit_should_fit_in_rare_data_count); |