| 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/flow_graph_inliner.h" | 5 #include "vm/flow_graph_inliner.h" |
| 6 | 6 |
| 7 #include "vm/block_scheduler.h" | 7 #include "vm/block_scheduler.h" |
| 8 #include "vm/compiler.h" | 8 #include "vm/compiler.h" |
| 9 #include "vm/flags.h" | 9 #include "vm/flags.h" |
| 10 #include "vm/flow_graph.h" | 10 #include "vm/flow_graph.h" |
| (...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 590 // should have kept GC from detaching, but let's assert just to make sure. | 590 // should have kept GC from detaching, but let's assert just to make sure. |
| 591 ASSERT(function.HasCode()); | 591 ASSERT(function.HasCode()); |
| 592 ic_data_array = unoptimized_code.ExtractTypeFeedbackArray(); | 592 ic_data_array = unoptimized_code.ExtractTypeFeedbackArray(); |
| 593 | 593 |
| 594 // Build the callee graph. | 594 // Build the callee graph. |
| 595 InlineExitCollector* exit_collector = | 595 InlineExitCollector* exit_collector = |
| 596 new InlineExitCollector(caller_graph_, call); | 596 new InlineExitCollector(caller_graph_, call); |
| 597 FlowGraphBuilder builder(parsed_function, | 597 FlowGraphBuilder builder(parsed_function, |
| 598 ic_data_array, | 598 ic_data_array, |
| 599 exit_collector, | 599 exit_collector, |
| 600 Isolate::kNoDeoptId); | 600 Isolate::kNoDeoptId, |
| 601 true); |
| 601 builder.SetInitialBlockId(caller_graph_->max_block_id()); | 602 builder.SetInitialBlockId(caller_graph_->max_block_id()); |
| 602 FlowGraph* callee_graph; | 603 FlowGraph* callee_graph; |
| 603 { | 604 { |
| 604 TimerScope timer(FLAG_compiler_stats, | 605 TimerScope timer(FLAG_compiler_stats, |
| 605 &CompilerStats::graphinliner_build_timer, | 606 &CompilerStats::graphinliner_build_timer, |
| 606 isolate); | 607 isolate); |
| 607 callee_graph = builder.BuildGraph(); | 608 callee_graph = builder.BuildGraph(); |
| 608 } | 609 } |
| 609 | 610 |
| 610 // The parameter stubs are a copy of the actual arguments providing | 611 // The parameter stubs are a copy of the actual arguments providing |
| (...skipping 1047 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1658 OS::Print("After Inlining of %s\n", flow_graph_-> | 1659 OS::Print("After Inlining of %s\n", flow_graph_-> |
| 1659 parsed_function().function().ToFullyQualifiedCString()); | 1660 parsed_function().function().ToFullyQualifiedCString()); |
| 1660 FlowGraphPrinter printer(*flow_graph_); | 1661 FlowGraphPrinter printer(*flow_graph_); |
| 1661 printer.PrintBlocks(); | 1662 printer.PrintBlocks(); |
| 1662 } | 1663 } |
| 1663 } | 1664 } |
| 1664 } | 1665 } |
| 1665 } | 1666 } |
| 1666 | 1667 |
| 1667 } // namespace dart | 1668 } // namespace dart |
| OLD | NEW |