OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 #include "vm/deopt_instructions.h" | 5 #include "vm/deopt_instructions.h" |
6 | 6 |
7 #include "vm/assembler.h" | 7 #include "vm/assembler.h" |
8 #include "vm/code_patcher.h" | 8 #include "vm/code_patcher.h" |
9 #include "vm/compiler.h" | 9 #include "vm/compiler.h" |
10 #include "vm/intermediate_language.h" | 10 #include "vm/intermediate_language.h" |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 } | 131 } |
132 dest_frame_ = NULL; | 132 dest_frame_ = NULL; |
133 | 133 |
134 // Delete all deferred objects. | 134 // Delete all deferred objects. |
135 for (intptr_t i = 0; i < deferred_objects_count_; i++) { | 135 for (intptr_t i = 0; i < deferred_objects_count_; i++) { |
136 delete deferred_objects_[i]; | 136 delete deferred_objects_[i]; |
137 } | 137 } |
138 delete[] deferred_objects_; | 138 delete[] deferred_objects_; |
139 deferred_objects_ = NULL; | 139 deferred_objects_ = NULL; |
140 deferred_objects_count_ = 0; | 140 deferred_objects_count_ = 0; |
141 if (deopt_start_micros_ != 0) { | 141 if (FLAG_support_timeline && (deopt_start_micros_ != 0)) { |
142 Isolate* isolate = Isolate::Current(); | 142 Isolate* isolate = Isolate::Current(); |
143 TimelineStream* compiler_stream = isolate->GetCompilerStream(); | 143 TimelineStream* compiler_stream = isolate->GetCompilerStream(); |
144 ASSERT(compiler_stream != NULL); | 144 ASSERT(compiler_stream != NULL); |
145 if (compiler_stream->Enabled()) { | 145 if (compiler_stream->Enabled()) { |
146 const Code& code = Code::Handle(zone(), code_); | 146 const Code& code = Code::Handle(zone(), code_); |
147 const Function& function = Function::Handle(zone(), code.function()); | 147 const Function& function = Function::Handle(zone(), code.function()); |
148 const char* function_name = function.QualifiedUserVisibleNameCString(); | 148 const char* function_name = function.QualifiedUserVisibleNameCString(); |
149 const char* reason = DeoptReasonToCString(deopt_reason()); | 149 const char* reason = DeoptReasonToCString(deopt_reason()); |
150 int counter = function.deoptimization_counter(); | 150 int counter = function.deoptimization_counter(); |
151 TimelineEvent* timeline_event = compiler_stream->StartEvent(); | 151 TimelineEvent* timeline_event = compiler_stream->StartEvent(); |
(...skipping 1155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1307 Smi* offset, | 1307 Smi* offset, |
1308 TypedData* info, | 1308 TypedData* info, |
1309 Smi* reason) { | 1309 Smi* reason) { |
1310 intptr_t i = index * kEntrySize; | 1310 intptr_t i = index * kEntrySize; |
1311 *offset ^= table.At(i); | 1311 *offset ^= table.At(i); |
1312 *info ^= table.At(i + 1); | 1312 *info ^= table.At(i + 1); |
1313 *reason ^= table.At(i + 2); | 1313 *reason ^= table.At(i + 2); |
1314 } | 1314 } |
1315 | 1315 |
1316 } // namespace dart | 1316 } // namespace dart |
OLD | NEW |