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

Unified Diff: src/v8-counters.cc

Issue 10854043: Add histograms for total allocated/live heap size, as well as allocated size and percentage of tota… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: updates Created 8 years, 4 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 | « src/v8-counters.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/v8-counters.cc
diff --git a/src/v8-counters.cc b/src/v8-counters.cc
index 36b45e2f8e8449d2a7d0636b88121ea924a4e697..3f83dffcae6fb7192056803171390d05cde9e36c 100644
--- a/src/v8-counters.cc
+++ b/src/v8-counters.cc
@@ -45,6 +45,12 @@ Counters::Counters() {
HISTOGRAM_PERCENTAGE_LIST(HP)
#undef HP
+#define HM(name, caption) \
+ Histogram name = { #caption, 1000, 500000, 50, NULL, false }; \
+ name##_ = name;
+ HISTOGRAM_MEMORY_LIST(HM)
+#undef HM
+
#define SC(name, caption) \
StatsCounter name = { "c:" #caption, NULL, false };\
name##_ = name;
@@ -101,6 +107,10 @@ void Counters::ResetHistograms() {
#define HP(name, caption) name##_.Reset();
HISTOGRAM_PERCENTAGE_LIST(HP)
#undef HP
+
+#define HM(name, caption) name##_.Reset();
+ HISTOGRAM_MEMORY_LIST(HM)
+#undef HM
}
} } // namespace v8::internal
« no previous file with comments | « src/v8-counters.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698