| 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 741 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 752 RenameRecursive(entry, &env, live_phis, variable_liveness); | 752 RenameRecursive(entry, &env, live_phis, variable_liveness); |
| 753 } | 753 } |
| 754 | 754 |
| 755 | 755 |
| 756 void FlowGraph::AttachEnvironment(Instruction* instr, | 756 void FlowGraph::AttachEnvironment(Instruction* instr, |
| 757 GrowableArray<Definition*>* env) { | 757 GrowableArray<Definition*>* env) { |
| 758 Environment* deopt_env = | 758 Environment* deopt_env = |
| 759 Environment::From(isolate(), | 759 Environment::From(isolate(), |
| 760 *env, | 760 *env, |
| 761 num_non_copied_params_, | 761 num_non_copied_params_, |
| 762 Code::Handle(parsed_function_.code())); | 762 &parsed_function_); |
| 763 // TODO(fschneider): Add predicates CanEagerlyDeoptimize and | 763 // TODO(fschneider): Add predicates CanEagerlyDeoptimize and |
| 764 // CanLazilyDeoptimize to instructions to generally deal with instructions | 764 // CanLazilyDeoptimize to instructions to generally deal with instructions |
| 765 // that have pushed arguments and input operands. | 765 // that have pushed arguments and input operands. |
| 766 // Right now, closure calls are the only instructions that have both. They | 766 // Right now, closure calls are the only instructions that have both. They |
| 767 // also don't have an eager deoptimziation point, so the environment attached | 767 // also don't have an eager deoptimziation point, so the environment attached |
| 768 // here is only used for after the call. | 768 // here is only used for after the call. |
| 769 if (instr->IsClosureCall()) { | 769 if (instr->IsClosureCall()) { |
| 770 deopt_env = deopt_env->DeepCopy(isolate(), | 770 deopt_env = deopt_env->DeepCopy(isolate(), |
| 771 deopt_env->Length() - instr->InputCount()); | 771 deopt_env->Length() - instr->InputCount()); |
| 772 } | 772 } |
| (...skipping 461 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1234 } | 1234 } |
| 1235 | 1235 |
| 1236 | 1236 |
| 1237 bool BlockEffects::IsSideEffectFreePath(BlockEntryInstr* from, | 1237 bool BlockEffects::IsSideEffectFreePath(BlockEntryInstr* from, |
| 1238 BlockEntryInstr* to) const { | 1238 BlockEntryInstr* to) const { |
| 1239 return available_at_[to->postorder_number()]->Contains( | 1239 return available_at_[to->postorder_number()]->Contains( |
| 1240 from->postorder_number()); | 1240 from->postorder_number()); |
| 1241 } | 1241 } |
| 1242 | 1242 |
| 1243 } // namespace dart | 1243 } // namespace dart |
| OLD | NEW |