Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/counters.h" | 5 #include "src/counters.h" |
| 6 | 6 |
| 7 #include <iomanip> | 7 #include <iomanip> |
| 8 | 8 |
| 9 #include "src/base/platform/platform.h" | 9 #include "src/base/platform/platform.h" |
| 10 #include "src/isolate.h" | 10 #include "src/isolate.h" |
| (...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 361 #undef RESET_COUNTER | 361 #undef RESET_COUNTER |
| 362 | 362 |
| 363 #define RESET_COUNTER(name) this->Handler_##name.Reset(); | 363 #define RESET_COUNTER(name) this->Handler_##name.Reset(); |
| 364 FOR_EACH_HANDLER_COUNTER(RESET_COUNTER) | 364 FOR_EACH_HANDLER_COUNTER(RESET_COUNTER) |
| 365 #undef RESET_COUNTER | 365 #undef RESET_COUNTER |
| 366 | 366 |
| 367 in_use_ = true; | 367 in_use_ = true; |
| 368 } | 368 } |
| 369 | 369 |
| 370 void RuntimeCallStats::Dump(v8::tracing::TracedValue* value) { | 370 void RuntimeCallStats::Dump(v8::tracing::TracedValue* value) { |
| 371 if (current_timer_ != NULL) { | |
| 372 current_timer_->Elapsed(); | |
| 373 } | |
|
Camillo Bruni
2016/10/27 09:00:58
Can you add the same call to RuntimeCallStats::Pri
lpy
2016/10/27 16:59:21
Done.
| |
| 371 #define DUMP_COUNTER(name) \ | 374 #define DUMP_COUNTER(name) \ |
| 372 if (this->name.count > 0) this->name.Dump(value); | 375 if (this->name.count > 0) this->name.Dump(value); |
| 373 FOR_EACH_MANUAL_COUNTER(DUMP_COUNTER) | 376 FOR_EACH_MANUAL_COUNTER(DUMP_COUNTER) |
| 374 #undef DUMP_COUNTER | 377 #undef DUMP_COUNTER |
| 375 | 378 |
| 376 #define DUMP_COUNTER(name, nargs, result_size) \ | 379 #define DUMP_COUNTER(name, nargs, result_size) \ |
| 377 if (this->Runtime_##name.count > 0) this->Runtime_##name.Dump(value); | 380 if (this->Runtime_##name.count > 0) this->Runtime_##name.Dump(value); |
| 378 FOR_EACH_INTRINSIC(DUMP_COUNTER) | 381 FOR_EACH_INTRINSIC(DUMP_COUNTER) |
| 379 #undef DUMP_COUNTER | 382 #undef DUMP_COUNTER |
| 380 | 383 |
| (...skipping 10 matching lines...) Expand all Loading... | |
| 391 #define DUMP_COUNTER(name) \ | 394 #define DUMP_COUNTER(name) \ |
| 392 if (this->Handler_##name.count > 0) this->Handler_##name.Dump(value); | 395 if (this->Handler_##name.count > 0) this->Handler_##name.Dump(value); |
| 393 FOR_EACH_HANDLER_COUNTER(DUMP_COUNTER) | 396 FOR_EACH_HANDLER_COUNTER(DUMP_COUNTER) |
| 394 #undef DUMP_COUNTER | 397 #undef DUMP_COUNTER |
| 395 | 398 |
| 396 in_use_ = false; | 399 in_use_ = false; |
| 397 } | 400 } |
| 398 | 401 |
| 399 } // namespace internal | 402 } // namespace internal |
| 400 } // namespace v8 | 403 } // namespace v8 |
| OLD | NEW |