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

Unified Diff: src/counters.cc

Issue 365153002: Remove a bunch of Isolate::UncheckedCurrent calls (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: updates Created 6 years, 5 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
« include/v8.h ('K') | « src/counters.h ('k') | src/d8.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/counters.cc
diff --git a/src/counters.cc b/src/counters.cc
index 7de25e98a3c10be9514de1ef484c1dbdc1f4c6e8..34e8467440554c5c9612b940657e9bb5f4cf9b12 100644
--- a/src/counters.cc
+++ b/src/counters.cc
@@ -109,6 +109,38 @@ Counters::Counters(Isolate* isolate) {
}
+void Counters::ResetCounters() {
+#define SC(name, caption) name##_.Reset();
+ STATS_COUNTER_LIST_1(SC)
+ STATS_COUNTER_LIST_2(SC)
+#undef SC
+
+#define SC(name) \
+ count_of_##name##_.Reset(); \
+ size_of_##name##_.Reset();
+ INSTANCE_TYPE_LIST(SC)
+#undef SC
+
+#define SC(name) \
+ count_of_CODE_TYPE_##name##_.Reset(); \
+ size_of_CODE_TYPE_##name##_.Reset();
+ CODE_KIND_LIST(SC)
+#undef SC
+
+#define SC(name) \
+ count_of_FIXED_ARRAY_##name##_.Reset(); \
+ size_of_FIXED_ARRAY_##name##_.Reset();
+ FIXED_ARRAY_SUB_INSTANCE_TYPE_LIST(SC)
+#undef SC
+
+#define SC(name) \
+ count_of_CODE_AGE_##name##_.Reset(); \
+ size_of_CODE_AGE_##name##_.Reset();
+ CODE_AGE_LIST_COMPLETE(SC)
+#undef SC
+}
+
+
void Counters::ResetHistograms() {
#define HT(name, caption) name##_.Reset();
HISTOGRAM_TIMER_LIST(HT)
« include/v8.h ('K') | « src/counters.h ('k') | src/d8.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698