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/constant_propagator.h" | 5 #include "vm/constant_propagator.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/flow_graph_compiler.h" | 9 #include "vm/flow_graph_compiler.h" |
10 #include "vm/flow_graph_range_analysis.h" | 10 #include "vm/flow_graph_range_analysis.h" |
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
396 SetValue(instr, non_constant_); | 396 SetValue(instr, non_constant_); |
397 } | 397 } |
398 | 398 |
399 | 399 |
400 void ConstantPropagator::VisitLoadLocal(LoadLocalInstr* instr) { | 400 void ConstantPropagator::VisitLoadLocal(LoadLocalInstr* instr) { |
401 // Instruction is eliminated when translating to SSA. | 401 // Instruction is eliminated when translating to SSA. |
402 UNREACHABLE(); | 402 UNREACHABLE(); |
403 } | 403 } |
404 | 404 |
405 | 405 |
406 void ConstantPropagator::VisitPushTemp(PushTempInstr* instr) { | |
407 // Instruction is eliminated when translating to SSA. | |
408 UNREACHABLE(); | |
409 } | |
410 | |
411 | |
412 void ConstantPropagator::VisitDropTemps(DropTempsInstr* instr) { | 406 void ConstantPropagator::VisitDropTemps(DropTempsInstr* instr) { |
413 // Instruction is eliminated when translating to SSA. | 407 // Instruction is eliminated when translating to SSA. |
414 UNREACHABLE(); | 408 UNREACHABLE(); |
415 } | 409 } |
416 | 410 |
417 | 411 |
418 void ConstantPropagator::VisitStoreLocal(StoreLocalInstr* instr) { | 412 void ConstantPropagator::VisitStoreLocal(StoreLocalInstr* instr) { |
419 // Instruction is eliminated when translating to SSA. | 413 // Instruction is eliminated when translating to SSA. |
420 UNREACHABLE(); | 414 UNREACHABLE(); |
421 } | 415 } |
(...skipping 1264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1686 graph_->MergeBlocks(); | 1680 graph_->MergeBlocks(); |
1687 GrowableArray<BitVector*> dominance_frontier; | 1681 GrowableArray<BitVector*> dominance_frontier; |
1688 graph_->ComputeDominators(&dominance_frontier); | 1682 graph_->ComputeDominators(&dominance_frontier); |
1689 | 1683 |
1690 if (FLAG_trace_constant_propagation) { | 1684 if (FLAG_trace_constant_propagation) { |
1691 FlowGraphPrinter::PrintGraph("After CP", graph_); | 1685 FlowGraphPrinter::PrintGraph("After CP", graph_); |
1692 } | 1686 } |
1693 } | 1687 } |
1694 | 1688 |
1695 } // namespace dart | 1689 } // namespace dart |
OLD | NEW |