Chromium Code Reviews| Index: src/counters.cc |
| diff --git a/src/counters.cc b/src/counters.cc |
| index ec5d21d47c3a415846f9e5c5c7537ddf04972d82..63113a182c5e27688a020d051307640b44c48ed9 100644 |
| --- a/src/counters.cc |
| +++ b/src/counters.cc |
| @@ -47,8 +47,8 @@ void HistogramTimer::Start() { |
| // Stop the timer and record the results. |
| void HistogramTimer::Stop() { |
| if (Enabled()) { |
| - // Compute the delta between start and stop, in milliseconds. |
| - AddSample(static_cast<int>(timer_.Elapsed().InMilliseconds())); |
| + // Compute the delta between start and stop, in microseconds. |
| + AddSample(static_cast<int>(timer_.Elapsed().InMicroseconds())); |
| timer_.Stop(); |
| } |
| Logger::CallEventLogger(isolate(), name(), Logger::END, true); |
| @@ -61,13 +61,13 @@ Counters::Counters(Isolate* isolate) { |
| HISTOGRAM_RANGE_LIST(HR) |
| #undef HR |
| -#define HT(name, caption) \ |
| - name##_ = HistogramTimer(#caption, 0, 10000, 50, isolate); |
| +#define HT(name, caption, max) \ |
| + name##_ = HistogramTimer(#caption, 0, max, 50, isolate); |
| HISTOGRAM_TIMER_LIST(HT) |
| #undef HT |
| #define AHT(name, caption) \ |
| - name##_ = AggregatableHistogramTimer(#caption, 0, 10000, 50, isolate); |
| + name##_ = AggregatableHistogramTimer(#caption, 0, 1000000, 50, isolate); |
|
vogelheim
2015/01/26 14:46:50
One more '0' please. Compile times in single digit
Yang
2015/01/26 15:09:07
Done.
|
| AGGREGATABLE_HISTOGRAM_TIMER_LIST(AHT) |
| #undef AHT |
| @@ -157,7 +157,7 @@ void Counters::ResetHistograms() { |
| HISTOGRAM_RANGE_LIST(HR) |
| #undef HR |
| -#define HT(name, caption) name##_.Reset(); |
| +#define HT(name, caption, max) name##_.Reset(); |
| HISTOGRAM_TIMER_LIST(HT) |
| #undef HT |