Index: third_party/WebKit/Source/wtf/Partitions.h |
diff --git a/third_party/WebKit/Source/wtf/Partitions.h b/third_party/WebKit/Source/wtf/Partitions.h |
index 194003948a6d8e64a5835d4e96486857bffad164..dc9a4aad108ac626cbf8897f0f8fab7eed2aef40 100644 |
--- a/third_party/WebKit/Source/wtf/Partitions.h |
+++ b/third_party/WebKit/Source/wtf/Partitions.h |
@@ -62,13 +62,8 @@ public: |
ALWAYS_INLINE static PartitionRoot* nodePartition() |
{ |
-#if ENABLE(OILPAN) |
ASSERT_NOT_REACHED(); |
return nullptr; |
-#else |
- ASSERT(s_initialized); |
- return m_nodeAllocator.root(); |
-#endif |
} |
ALWAYS_INLINE static PartitionRoot* layoutPartition() |
{ |
@@ -79,12 +74,8 @@ public: |
static size_t currentDOMMemoryUsage() |
{ |
ASSERT(s_initialized); |
-#if ENABLE(OILPAN) |
ASSERT_NOT_REACHED(); |
return 0; |
-#else |
- return m_nodeAllocator.root()->totalSizeOfCommittedPages; |
-#endif |
} |
static size_t totalSizeOfCommittedPages() |
@@ -92,9 +83,6 @@ public: |
size_t totalSize = 0; |
totalSize += m_fastMallocAllocator.root()->totalSizeOfCommittedPages; |
totalSize += m_bufferAllocator.root()->totalSizeOfCommittedPages; |
-#if !ENABLE(OILPAN) |
- totalSize += m_nodeAllocator.root()->totalSizeOfCommittedPages; |
-#endif |
totalSize += m_layoutAllocator.root()->totalSizeOfCommittedPages; |
return totalSize; |
} |
@@ -143,14 +131,12 @@ private: |
static bool s_initialized; |
// We have the following four partitions. |
- // - Node partition: A partition to allocate Nodes. We prepare a |
- // dedicated partition for Nodes because Nodes are likely to be |
- // a source of use-after-frees. Another reason is for performance: |
- // Since Nodes are guaranteed to be used only by the main |
- // thread, we can bypass acquiring a lock. Also we can improve memory |
- // locality by putting Nodes together. |
- // - Layout object partition: A partition to allocate LayoutObjects. |
- // we prepare a dedicated partition for the same reason as Nodes. |
+ // - LayoutObject partition: A partition to allocate LayoutObjects. |
+ // We prepare a dedicated partition for LayoutObjects because they |
+ // are likely to be a source of use-after-frees. Another reason |
+ // is for performance: As LayoutObjects are guaranteed to only be used |
+ // by the main thread, we can bypass acquiring a lock. Also we can |
+ // improve memory locality by putting LayoutObjects together. |
// - Buffer partition: A partition to allocate objects that have a strong |
// risk where the length and/or the contents are exploited from user |
// scripts. Vectors, HashTables, ArrayBufferContents and Strings are |
@@ -158,9 +144,6 @@ private: |
// - Fast malloc partition: A partition to allocate all other objects. |
static PartitionAllocatorGeneric m_fastMallocAllocator; |
static PartitionAllocatorGeneric m_bufferAllocator; |
-#if !ENABLE(OILPAN) |
- static SizeSpecificPartitionAllocator<3328> m_nodeAllocator; |
-#endif |
static SizeSpecificPartitionAllocator<1024> m_layoutAllocator; |
static ReportPartitionAllocSizeFunction m_reportSizeFunction; |
}; |