| 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 #ifndef VM_FLOW_GRAPH_OPTIMIZER_H_ | 5 #ifndef VM_FLOW_GRAPH_OPTIMIZER_H_ |
| 6 #define VM_FLOW_GRAPH_OPTIMIZER_H_ | 6 #define VM_FLOW_GRAPH_OPTIMIZER_H_ |
| 7 | 7 |
| 8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
| 9 #include "vm/flow_graph.h" | 9 #include "vm/flow_graph.h" |
| 10 | 10 |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 MethodRecognizer::Kind recognized_kind); | 145 MethodRecognizer::Kind recognized_kind); |
| 146 | 146 |
| 147 void HandleRelationalOp(RelationalOpInstr* comp); | 147 void HandleRelationalOp(RelationalOpInstr* comp); |
| 148 | 148 |
| 149 // Visit an equality compare. The current instruction can be the | 149 // Visit an equality compare. The current instruction can be the |
| 150 // comparison itself or a branch on the comparison. | 150 // comparison itself or a branch on the comparison. |
| 151 template <typename T> | 151 template <typename T> |
| 152 void HandleEqualityCompare(EqualityCompareInstr* comp, | 152 void HandleEqualityCompare(EqualityCompareInstr* comp, |
| 153 T current_instruction); | 153 T current_instruction); |
| 154 | 154 |
| 155 void HandleStrictCompare(StrictCompareInstr* comp, BranchInstr* instr); |
| 156 |
| 155 void OptimizeLeftShiftBitAndSmiOp(Definition* bit_and_instr, | 157 void OptimizeLeftShiftBitAndSmiOp(Definition* bit_and_instr, |
| 156 Definition* left_instr, | 158 Definition* left_instr, |
| 157 Definition* right_instr); | 159 Definition* right_instr); |
| 158 | 160 |
| 159 FlowGraph* flow_graph_; | 161 FlowGraph* flow_graph_; |
| 160 | 162 |
| 161 DISALLOW_COPY_AND_ASSIGN(FlowGraphOptimizer); | 163 DISALLOW_COPY_AND_ASSIGN(FlowGraphOptimizer); |
| 162 }; | 164 }; |
| 163 | 165 |
| 164 | 166 |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 289 // inputs. | 291 // inputs. |
| 290 static BranchInstr* CloneBranch(BranchInstr* branch, | 292 static BranchInstr* CloneBranch(BranchInstr* branch, |
| 291 Value* left, | 293 Value* left, |
| 292 Value* right); | 294 Value* right); |
| 293 }; | 295 }; |
| 294 | 296 |
| 295 | 297 |
| 296 } // namespace dart | 298 } // namespace dart |
| 297 | 299 |
| 298 #endif // VM_FLOW_GRAPH_OPTIMIZER_H_ | 300 #endif // VM_FLOW_GRAPH_OPTIMIZER_H_ |
| OLD | NEW |