Chromium Code Reviews| Index: src/v8-counters.h |
| diff --git a/src/v8-counters.h b/src/v8-counters.h |
| index dc55042b462ee08a86d7685ea4176fe050c3fb6d..fb372bdbb52cc9839e6105e5ec675a4650029368 100644 |
| --- a/src/v8-counters.h |
| +++ b/src/v8-counters.h |
| @@ -31,6 +31,7 @@ |
| #include "allocation.h" |
| #include "counters.h" |
| #include "v8globals.h" |
| +#include "objects.h" |
|
Michael Starzinger
2012/07/12 20:12:26
Is it possible to alpha-sort these includes or doe
danno
2012/07/12 21:18:16
Done.
|
| namespace v8 { |
| namespace internal { |
| @@ -286,6 +287,12 @@ class Counters { |
| STATS_COUNTER_LIST_2(SC) |
| #undef SC |
| +#define SC(name) \ |
| + StatsCounter* count_of_##name() { return &count_of_##name##_; } \ |
| + StatsCounter* size_of_##name() { return &size_of_##name##_; } |
| + INSTANCE_TYPE_LIST(SC) |
| +#undef SC |
| + |
| enum Id { |
| #define RATE_ID(name, caption) k_##name, |
| HISTOGRAM_TIMER_LIST(RATE_ID) |
| @@ -294,6 +301,9 @@ class Counters { |
| STATS_COUNTER_LIST_1(COUNTER_ID) |
| STATS_COUNTER_LIST_2(COUNTER_ID) |
| #undef COUNTER_ID |
| +#define COUNTER_ID(name) kCountOf##name, kSizeOf##name, |
| + INSTANCE_TYPE_LIST(COUNTER_ID) |
| +#undef COUNTER_ID |
| #define COUNTER_ID(name) k_##name, |
| STATE_TAG_LIST(COUNTER_ID) |
| #undef COUNTER_ID |
| @@ -316,6 +326,12 @@ class Counters { |
| STATS_COUNTER_LIST_2(SC) |
| #undef SC |
| +#define SC(name) \ |
| + StatsCounter size_of_##name##_; \ |
| + StatsCounter count_of_##name##_; |
| + INSTANCE_TYPE_LIST(SC) |
| +#undef SC |
| + |
| enum { |
| #define COUNTER_ID(name) __##name, |
| STATE_TAG_LIST(COUNTER_ID) |