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

Unified Diff: Source/platform/PartitionAllocMemoryDumpProvider.cpp

Issue 1161953003: [tracing] Change outer/inner size repr. in memory dumps (blink side) (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: WAR string + operator overload Created 5 years, 7 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 | Source/platform/heap/BlinkGCMemoryDumpProvider.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/PartitionAllocMemoryDumpProvider.cpp
diff --git a/Source/platform/PartitionAllocMemoryDumpProvider.cpp b/Source/platform/PartitionAllocMemoryDumpProvider.cpp
index 719b4944b65a97e3a0a43828c93d87abc0ab706c..9e5ac8f6ce5bf9401373c83b679829f0a385817c 100644
--- a/Source/platform/PartitionAllocMemoryDumpProvider.cpp
+++ b/Source/platform/PartitionAllocMemoryDumpProvider.cpp
@@ -34,22 +34,25 @@ private:
void PartitionStatsDumperImpl::partitionsDumpBucketStats(const char* partitionName, const PartitionBucketMemoryStats* memoryStats)
{
ASSERT(memoryStats->isValid);
- String format;
+ String dumpName;
if (memoryStats->isDirectMap)
- format = String::format("partition_alloc/%s/directMap_%zu", partitionName, ++m_uid);
+ dumpName = String::format("partition_alloc/%s/directMap_%zu", partitionName, ++m_uid);
else
- format = String::format("partition_alloc/%s/bucket_%zu", partitionName, static_cast<size_t>(memoryStats->bucketSlotSize));
+ dumpName = String::format("partition_alloc/%s/bucket_%zu", partitionName, static_cast<size_t>(memoryStats->bucketSlotSize));
- WebMemoryAllocatorDump* allocatorDump = m_memoryDump->createMemoryAllocatorDump(format);
- allocatorDump->AddScalar("partition_page_size", "bytes", memoryStats->allocatedPageSize);
+ WebMemoryAllocatorDump* allocatorDump = m_memoryDump->createMemoryAllocatorDump(dumpName);
+ allocatorDump->AddScalar("size", "bytes", memoryStats->residentBytes);
allocatorDump->AddScalar("waste_size", "bytes", memoryStats->pageWasteSize);
- allocatorDump->AddScalar("inner_size", "bytes", memoryStats->activeBytes);
- allocatorDump->AddScalar("outer_size", "bytes", memoryStats->residentBytes);
+ allocatorDump->AddScalar("partition_page_size", "bytes", memoryStats->allocatedPageSize);
allocatorDump->AddScalar("freeable_size", "bytes", memoryStats->freeableBytes);
allocatorDump->AddScalar("full_partition_pages", "objects", memoryStats->numFullPages);
allocatorDump->AddScalar("active_partition_pages", "objects", memoryStats->numActivePages);
allocatorDump->AddScalar("empty_partition_pages", "objects", memoryStats->numEmptyPages);
allocatorDump->AddScalar("decommitted_partition_pages", "objects", memoryStats->numDecommittedPages);
+
+ dumpName = dumpName + "/allocated_objects";
+ WebMemoryAllocatorDump* objectsDump = m_memoryDump->createMemoryAllocatorDump(dumpName);
+ objectsDump->AddScalar("size", "bytes", memoryStats->activeBytes);
}
} // namespace
« no previous file with comments | « no previous file | Source/platform/heap/BlinkGCMemoryDumpProvider.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698