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

Unified Diff: third_party/tcmalloc/chromium/src/memory_region_map.h

Issue 9666033: Experiment for updating the tcmalloc chromium branch to r144 (gperftools 2.0). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 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
Index: third_party/tcmalloc/chromium/src/memory_region_map.h
diff --git a/third_party/tcmalloc/chromium/src/memory_region_map.h b/third_party/tcmalloc/chromium/src/memory_region_map.h
index 09561ce1ac48ca6589db43a0e5e690266d5314c1..8c13fbceb9f257db16a3f86d29c441d6679d8ad9 100644
--- a/third_party/tcmalloc/chromium/src/memory_region_map.h
+++ b/third_party/tcmalloc/chromium/src/memory_region_map.h
@@ -252,6 +252,10 @@ class MemoryRegionMap {
static RegionIterator BeginRegionLocked();
static RegionIterator EndRegionLocked();
+ // Return the accumulated sizes of mapped and unmapped regions.
+ static int64 MapSize() { return map_size_; }
+ static int64 UnmapSize() { return unmap_size_; }
+
// Effectively private type from our .cc =================================
// public to let us declare global objects:
union RegionSetRep;
@@ -286,6 +290,11 @@ class MemoryRegionMap {
// The thread id of the thread that's inside the recursive lock.
static pthread_t lock_owner_tid_;
+ // Total size of all mapped pages so far
+ static int64 map_size_;
+ // Total size of all unmapped pages so far
+ static int64 unmap_size_;
+
// helpers ==================================================================
// Helper for FindRegion and FindAndMarkStackRegion:
« no previous file with comments | « third_party/tcmalloc/chromium/src/memfs_malloc.cc ('k') | third_party/tcmalloc/chromium/src/memory_region_map.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698