| 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/flow_graph.h" | 5 #include "vm/flow_graph.h" |
| 6 | 6 |
| 7 #include "vm/bit_vector.h" | 7 #include "vm/bit_vector.h" |
| 8 #include "vm/flow_graph_builder.h" | 8 #include "vm/flow_graph_builder.h" |
| 9 #include "vm/intermediate_language.h" | 9 #include "vm/intermediate_language.h" |
| 10 #include "vm/longjump.h" | 10 #include "vm/longjump.h" |
| (...skipping 737 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 748 } | 748 } |
| 749 RenameRecursive(entry, &env, live_phis, variable_liveness); | 749 RenameRecursive(entry, &env, live_phis, variable_liveness); |
| 750 } | 750 } |
| 751 | 751 |
| 752 | 752 |
| 753 void FlowGraph::AttachEnvironment(Instruction* instr, | 753 void FlowGraph::AttachEnvironment(Instruction* instr, |
| 754 GrowableArray<Definition*>* env) { | 754 GrowableArray<Definition*>* env) { |
| 755 Environment* deopt_env = | 755 Environment* deopt_env = |
| 756 Environment::From(*env, | 756 Environment::From(*env, |
| 757 num_non_copied_params_, | 757 num_non_copied_params_, |
| 758 parsed_function_.function()); | 758 Code::Handle(parsed_function_.code())); |
| 759 instr->SetEnvironment(deopt_env); | 759 instr->SetEnvironment(deopt_env); |
| 760 for (Environment::DeepIterator it(deopt_env); !it.Done(); it.Advance()) { | 760 for (Environment::DeepIterator it(deopt_env); !it.Done(); it.Advance()) { |
| 761 Value* use = it.CurrentValue(); | 761 Value* use = it.CurrentValue(); |
| 762 use->definition()->AddEnvUse(use); | 762 use->definition()->AddEnvUse(use); |
| 763 } | 763 } |
| 764 if (instr->CanDeoptimize()) { | 764 if (instr->CanDeoptimize()) { |
| 765 instr->env()->set_deopt_id(instr->deopt_id()); | 765 instr->env()->set_deopt_id(instr->deopt_id()); |
| 766 } | 766 } |
| 767 } | 767 } |
| 768 | 768 |
| (...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1198 } | 1198 } |
| 1199 | 1199 |
| 1200 | 1200 |
| 1201 bool BlockEffects::IsSideEffectFreePath(BlockEntryInstr* from, | 1201 bool BlockEffects::IsSideEffectFreePath(BlockEntryInstr* from, |
| 1202 BlockEntryInstr* to) const { | 1202 BlockEntryInstr* to) const { |
| 1203 return available_at_[to->postorder_number()]->Contains( | 1203 return available_at_[to->postorder_number()]->Contains( |
| 1204 from->postorder_number()); | 1204 from->postorder_number()); |
| 1205 } | 1205 } |
| 1206 | 1206 |
| 1207 } // namespace dart | 1207 } // namespace dart |
| OLD | NEW |