Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2287)

Unified Diff: Source/platform/heap/Heap.cpp

Issue 1210373002: Oilpan: Decrease m_promptlyFreedSize in makeConsistentForMutator (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/heap/Heap.cpp
diff --git a/Source/platform/heap/Heap.cpp b/Source/platform/heap/Heap.cpp
index c1dd9d315b3617088f4cc2d3e1f6b4d9a63d656c..e9a5964e3aab1e8918a1d57e92d63973b53db057 100644
--- a/Source/platform/heap/Heap.cpp
+++ b/Source/platform/heap/Heap.cpp
@@ -1318,8 +1318,8 @@ void NormalPage::makeConsistentForMutator()
for (Address headerAddress = payload(); headerAddress < payloadEnd();) {
HeapObjectHeader* header = reinterpret_cast<HeapObjectHeader*>(headerAddress);
ASSERT(header->size() < blinkPagePayloadSize());
- // Check if a free list entry first since we cannot call
- // isMarked on a free list entry.
+ if (header->isPromptlyFreed())
+ heapForNormalPage()->decreasePromptlyFreedSize(header->size());
if (header->isFree()) {
headerAddress += header->size();
continue;
@@ -1328,9 +1328,8 @@ void NormalPage::makeConsistentForMutator()
if (startOfGap != headerAddress)
heapForNormalPage()->addToFreeList(startOfGap, headerAddress - startOfGap);
- if (header->isMarked()) {
+ if (header->isMarked())
header->unmark();
- }
headerAddress += header->size();
startOfGap = headerAddress;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698