| 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/globals.h" // Needed here to get TARGET_ARCH_XXX. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_XXX. |
| 6 | 6 |
| 7 #include "vm/flow_graph_compiler.h" | 7 #include "vm/flow_graph_compiler.h" |
| 8 | 8 |
| 9 #include "vm/cha.h" | 9 #include "vm/cha.h" |
| 10 #include "vm/dart_entry.h" | 10 #include "vm/dart_entry.h" |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 MaterializeObjectInstr* mat = | 57 MaterializeObjectInstr* mat = |
| 58 it.CurrentValue()->definition()->AsMaterializeObject(); | 58 it.CurrentValue()->definition()->AsMaterializeObject(); |
| 59 ASSERT(mat != NULL); | 59 ASSERT(mat != NULL); |
| 60 builder->AddMaterialization(mat); | 60 builder->AddMaterialization(mat); |
| 61 } | 61 } |
| 62 } | 62 } |
| 63 } | 63 } |
| 64 | 64 |
| 65 | 65 |
| 66 FlowGraphCompiler::FlowGraphCompiler(Assembler* assembler, | 66 FlowGraphCompiler::FlowGraphCompiler(Assembler* assembler, |
| 67 const FlowGraph& flow_graph, | 67 FlowGraph* flow_graph, |
| 68 bool is_optimizing) | 68 bool is_optimizing) |
| 69 : assembler_(assembler), | 69 : assembler_(assembler), |
| 70 parsed_function_(flow_graph.parsed_function()), | 70 parsed_function_(flow_graph->parsed_function()), |
| 71 flow_graph_(flow_graph), | 71 flow_graph_(*flow_graph), |
| 72 block_order_(flow_graph.reverse_postorder()), | 72 block_order_(*flow_graph->codegen_block_order(is_optimizing)), |
| 73 current_block_(NULL), | 73 current_block_(NULL), |
| 74 exception_handlers_list_(NULL), | 74 exception_handlers_list_(NULL), |
| 75 pc_descriptors_list_(NULL), | 75 pc_descriptors_list_(NULL), |
| 76 stackmap_table_builder_( | 76 stackmap_table_builder_( |
| 77 is_optimizing ? new StackmapTableBuilder() : NULL), | 77 is_optimizing ? new StackmapTableBuilder() : NULL), |
| 78 block_info_(block_order_.length()), | 78 block_info_(block_order_.length()), |
| 79 deopt_infos_(), | 79 deopt_infos_(), |
| 80 static_calls_target_table_(GrowableObjectArray::ZoneHandle( | 80 static_calls_target_table_(GrowableObjectArray::ZoneHandle( |
| 81 GrowableObjectArray::New())), | 81 GrowableObjectArray::New())), |
| 82 is_optimizing_(is_optimizing), | 82 is_optimizing_(is_optimizing), |
| (...skipping 1010 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1093 | 1093 |
| 1094 for (int i = 0; i < len; i++) { | 1094 for (int i = 0; i < len; i++) { |
| 1095 sorted->Add(CidTarget(ic_data.GetReceiverClassIdAt(i), | 1095 sorted->Add(CidTarget(ic_data.GetReceiverClassIdAt(i), |
| 1096 &Function::ZoneHandle(ic_data.GetTargetAt(i)), | 1096 &Function::ZoneHandle(ic_data.GetTargetAt(i)), |
| 1097 ic_data.GetCountAt(i))); | 1097 ic_data.GetCountAt(i))); |
| 1098 } | 1098 } |
| 1099 sorted->Sort(HighestCountFirst); | 1099 sorted->Sort(HighestCountFirst); |
| 1100 } | 1100 } |
| 1101 | 1101 |
| 1102 } // namespace dart | 1102 } // namespace dart |
| OLD | NEW |