Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Side by Side Diff: runtime/vm/flow_graph_inliner.cc

Issue 11092102: Avoid rediscovering blocks on each call to FlowGraph::InlineCall. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: comments Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/flow_graph.cc ('k') | runtime/vm/intermediate_language.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_inliner.h" 5 #include "vm/flow_graph_inliner.h"
6 6
7 #include "vm/compiler.h" 7 #include "vm/compiler.h"
8 #include "vm/flags.h" 8 #include "vm/flags.h"
9 #include "vm/flow_graph.h" 9 #include "vm/flow_graph.h"
10 #include "vm/flow_graph_builder.h" 10 #include "vm/flow_graph_builder.h"
(...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after
492 OS::Print("Before Inlining of %s\n", flow_graph_-> 492 OS::Print("Before Inlining of %s\n", flow_graph_->
493 parsed_function().function().ToFullyQualifiedCString()); 493 parsed_function().function().ToFullyQualifiedCString());
494 FlowGraphPrinter printer(*flow_graph_); 494 FlowGraphPrinter printer(*flow_graph_);
495 printer.PrintBlocks(); 495 printer.PrintBlocks();
496 } 496 }
497 497
498 CallSiteInliner inliner(flow_graph_); 498 CallSiteInliner inliner(flow_graph_);
499 inliner.InlineCalls(); 499 inliner.InlineCalls();
500 500
501 if (inliner.inlined()) { 501 if (inliner.inlined()) {
502 flow_graph_->RepairGraphAfterInlining();
502 if (FLAG_trace_inlining) { 503 if (FLAG_trace_inlining) {
503 OS::Print("Inlining growth factor: %f\n", inliner.GrowthFactor()); 504 OS::Print("Inlining growth factor: %f\n", inliner.GrowthFactor());
504 if (FLAG_print_flow_graph) { 505 if (FLAG_print_flow_graph) {
505 OS::Print("After Inlining of %s\n", flow_graph_-> 506 OS::Print("After Inlining of %s\n", flow_graph_->
506 parsed_function().function().ToFullyQualifiedCString()); 507 parsed_function().function().ToFullyQualifiedCString());
507 FlowGraphPrinter printer(*flow_graph_); 508 FlowGraphPrinter printer(*flow_graph_);
508 printer.PrintBlocks(); 509 printer.PrintBlocks();
509 } 510 }
510 } 511 }
511 } 512 }
512 } 513 }
513 514
514 } // namespace dart 515 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph.cc ('k') | runtime/vm/intermediate_language.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698