| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_COMPILER_STATS_H_ | 5 #ifndef VM_COMPILER_STATS_H_ |
| 6 #define VM_COMPILER_STATS_H_ | 6 #define VM_COMPILER_STATS_H_ |
| 7 | 7 |
| 8 #include "vm/allocation.h" | 8 #include "vm/allocation.h" |
| 9 #include "vm/flags.h" | 9 #include "vm/flags.h" |
| 10 #include "vm/isolate.h" | 10 #include "vm/isolate.h" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 int64_t total_instr_size; // Total size of generated code in bytes. | 60 int64_t total_instr_size; // Total size of generated code in bytes. |
| 61 int64_t pc_desc_size; | 61 int64_t pc_desc_size; |
| 62 int64_t vardesc_size; | 62 int64_t vardesc_size; |
| 63 | 63 |
| 64 void Print(); | 64 void Print(); |
| 65 }; | 65 }; |
| 66 | 66 |
| 67 #define INC_STAT(isolate, counter, incr) \ | 67 #define INC_STAT(isolate, counter, incr) \ |
| 68 if (FLAG_compiler_stats) { (isolate)->compiler_stats()->counter += (incr); } | 68 if (FLAG_compiler_stats) { (isolate)->compiler_stats()->counter += (incr); } |
| 69 | 69 |
| 70 #define CSTAT_TIMER_SCOPE(iso, t) \ | 70 #define CSTAT_TIMER_SCOPE(thr, t) \ |
| 71 TimerScope timer(FLAG_compiler_stats, \ | 71 TimerScope timer(FLAG_compiler_stats, \ |
| 72 FLAG_compiler_stats ? &((iso)->compiler_stats()->t) : NULL, \ | 72 FLAG_compiler_stats ? &((thr)->isolate()->compiler_stats()->t) : NULL, \ |
| 73 iso); | 73 thr); |
| 74 | 74 |
| 75 } // namespace dart | 75 } // namespace dart |
| 76 | 76 |
| 77 #endif // VM_COMPILER_STATS_H_ | 77 #endif // VM_COMPILER_STATS_H_ |
| OLD | NEW |