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_H_ | 5 #ifndef VM_FLOW_GRAPH_H_ |
6 #define VM_FLOW_GRAPH_H_ | 6 #define VM_FLOW_GRAPH_H_ |
7 | 7 |
8 #include "vm/growable_array.h" | 8 #include "vm/growable_array.h" |
9 #include "vm/parser.h" | 9 #include "vm/parser.h" |
10 | 10 |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 } | 91 } |
92 | 92 |
93 intptr_t max_block_id() const { | 93 intptr_t max_block_id() const { |
94 return max_block_id_; | 94 return max_block_id_; |
95 } | 95 } |
96 | 96 |
97 GraphEntryInstr* graph_entry() const { | 97 GraphEntryInstr* graph_entry() const { |
98 return graph_entry_; | 98 return graph_entry_; |
99 } | 99 } |
100 | 100 |
| 101 ConstantInstr* constant_null() const { |
| 102 return constant_null_; |
| 103 } |
| 104 |
101 ZoneGrowableArray<ReturnInstr*>* exits() const { return exits_; } | 105 ZoneGrowableArray<ReturnInstr*>* exits() const { return exits_; } |
102 void set_exits(ZoneGrowableArray<ReturnInstr*>* exits) { exits_ = exits; } | 106 void set_exits(ZoneGrowableArray<ReturnInstr*>* exits) { exits_ = exits; } |
103 | 107 |
104 intptr_t alloc_ssa_temp_index() { return current_ssa_temp_index_++; } | 108 intptr_t alloc_ssa_temp_index() { return current_ssa_temp_index_++; } |
105 | 109 |
106 intptr_t InstructionCount() const; | 110 intptr_t InstructionCount() const; |
107 | 111 |
108 ConstantInstr* AddConstantToInitialDefinitions(const Object& object); | 112 ConstantInstr* AddConstantToInitialDefinitions(const Object& object); |
109 void AddToInitialDefinitions(Definition* defn); | 113 void AddToInitialDefinitions(Definition* defn); |
110 | 114 |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 const ParsedFunction& parsed_function_; | 176 const ParsedFunction& parsed_function_; |
173 const intptr_t num_copied_params_; | 177 const intptr_t num_copied_params_; |
174 const intptr_t num_non_copied_params_; | 178 const intptr_t num_non_copied_params_; |
175 const intptr_t num_stack_locals_; | 179 const intptr_t num_stack_locals_; |
176 GraphEntryInstr* graph_entry_; | 180 GraphEntryInstr* graph_entry_; |
177 GrowableArray<BlockEntryInstr*> preorder_; | 181 GrowableArray<BlockEntryInstr*> preorder_; |
178 GrowableArray<BlockEntryInstr*> postorder_; | 182 GrowableArray<BlockEntryInstr*> postorder_; |
179 GrowableArray<BlockEntryInstr*> reverse_postorder_; | 183 GrowableArray<BlockEntryInstr*> reverse_postorder_; |
180 ZoneGrowableArray<ReturnInstr*>* exits_; | 184 ZoneGrowableArray<ReturnInstr*>* exits_; |
181 bool invalid_dominator_tree_; | 185 bool invalid_dominator_tree_; |
| 186 ConstantInstr* constant_null_; |
182 }; | 187 }; |
183 | 188 |
184 } // namespace dart | 189 } // namespace dart |
185 | 190 |
186 #endif // VM_FLOW_GRAPH_H_ | 191 #endif // VM_FLOW_GRAPH_H_ |
OLD | NEW |