| 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_optimizer.h" | 5 #include "vm/flow_graph_optimizer.h" |
| 6 | 6 |
| 7 #include "vm/flow_graph_builder.h" | 7 #include "vm/flow_graph_builder.h" |
| 8 #include "vm/il_printer.h" | 8 #include "vm/il_printer.h" |
| 9 #include "vm/object_store.h" | 9 #include "vm/object_store.h" |
| 10 | 10 |
| (...skipping 586 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 597 // Replace binary checks with unary ones since EmitNative expects it. | 597 // Replace binary checks with unary ones since EmitNative expects it. |
| 598 ICData& unary_checks = | 598 ICData& unary_checks = |
| 599 ICData::Handle(ToUnaryClassChecks(*comp->ic_data())); | 599 ICData::Handle(ToUnaryClassChecks(*comp->ic_data())); |
| 600 comp->set_ic_data(&unary_checks); | 600 comp->set_ic_data(&unary_checks); |
| 601 } | 601 } |
| 602 | 602 |
| 603 TryFuseComparisonWithBranch(comp); | 603 TryFuseComparisonWithBranch(comp); |
| 604 } | 604 } |
| 605 | 605 |
| 606 | 606 |
| 607 void FlowGraphOptimizer::VisitDo(DoInstr* instr) { | |
| 608 instr->computation()->Accept(this); | |
| 609 } | |
| 610 | |
| 611 | |
| 612 void FlowGraphOptimizer::VisitBind(BindInstr* instr) { | 607 void FlowGraphOptimizer::VisitBind(BindInstr* instr) { |
| 613 instr->computation()->Accept(this); | 608 instr->computation()->Accept(this); |
| 614 } | 609 } |
| 615 | 610 |
| 616 | 611 |
| 617 | 612 |
| 618 FlowGraphAnalyzer::FlowGraphAnalyzer( | 613 FlowGraphAnalyzer::FlowGraphAnalyzer( |
| 619 const GrowableArray<BlockEntryInstr*>& blocks) | 614 const GrowableArray<BlockEntryInstr*>& blocks) |
| 620 :blocks_(blocks), is_leaf_(false) {} | 615 :blocks_(blocks), is_leaf_(false) {} |
| 621 | 616 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 632 is_leaf_ = false; | 627 is_leaf_ = false; |
| 633 return; | 628 return; |
| 634 } | 629 } |
| 635 } | 630 } |
| 636 instr = instr->successor(); | 631 instr = instr->successor(); |
| 637 } | 632 } |
| 638 } | 633 } |
| 639 } | 634 } |
| 640 | 635 |
| 641 } // namespace dart | 636 } // namespace dart |
| OLD | NEW |