| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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/compiler.h" | 5 #include "vm/compiler.h" |
| 6 | 6 |
| 7 #include "vm/assembler.h" | 7 #include "vm/assembler.h" |
| 8 #include "vm/ast_printer.h" | 8 #include "vm/ast_printer.h" |
| 9 #include "vm/code_generator.h" | 9 #include "vm/code_generator.h" |
| 10 #include "vm/code_patcher.h" | 10 #include "vm/code_patcher.h" |
| (...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 207 FLAG_common_subexpression_elimination) { | 207 FLAG_common_subexpression_elimination) { |
| 208 flow_graph->ComputeUseLists(); | 208 flow_graph->ComputeUseLists(); |
| 209 } | 209 } |
| 210 if (FLAG_constant_propagation) { | 210 if (FLAG_constant_propagation) { |
| 211 ConstantPropagator::Optimize(flow_graph); | 211 ConstantPropagator::Optimize(flow_graph); |
| 212 } | 212 } |
| 213 if (FLAG_common_subexpression_elimination) { | 213 if (FLAG_common_subexpression_elimination) { |
| 214 DominatorBasedCSE::Optimize(flow_graph); | 214 DominatorBasedCSE::Optimize(flow_graph); |
| 215 } | 215 } |
| 216 if (FLAG_loop_invariant_code_motion && | 216 if (FLAG_loop_invariant_code_motion && |
| 217 (parsed_function.function().deoptimization_counter() == | 217 (parsed_function.function().deoptimization_counter() < |
| 218 FLAG_deoptimization_counter_threshold - 1)) { | 218 (FLAG_deoptimization_counter_threshold - 1))) { |
| 219 LICM::Optimize(flow_graph); | 219 LICM::Optimize(flow_graph); |
| 220 } | 220 } |
| 221 | 221 |
| 222 if (FLAG_range_analysis) { | 222 if (FLAG_range_analysis) { |
| 223 // We have to perform range analysis after LICM because it | 223 // We have to perform range analysis after LICM because it |
| 224 // optimistically moves CheckSmi through phis into loop preheaders | 224 // optimistically moves CheckSmi through phis into loop preheaders |
| 225 // making some phis smi. | 225 // making some phis smi. |
| 226 flow_graph->ComputeUseLists(); | 226 flow_graph->ComputeUseLists(); |
| 227 optimizer.InferSmiRanges(); | 227 optimizer.InferSmiRanges(); |
| 228 } | 228 } |
| (...skipping 355 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 584 result = isolate->object_store()->sticky_error(); | 584 result = isolate->object_store()->sticky_error(); |
| 585 isolate->object_store()->clear_sticky_error(); | 585 isolate->object_store()->clear_sticky_error(); |
| 586 isolate->set_long_jump_base(base); | 586 isolate->set_long_jump_base(base); |
| 587 return result.raw(); | 587 return result.raw(); |
| 588 } | 588 } |
| 589 UNREACHABLE(); | 589 UNREACHABLE(); |
| 590 return Object::null(); | 590 return Object::null(); |
| 591 } | 591 } |
| 592 | 592 |
| 593 } // namespace dart | 593 } // namespace dart |
| OLD | NEW |