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

Unified Diff: runtime/vm/flow_graph.h

Issue 10893027: Inlining of static calls with trivial function bodies. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 months 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 side-by-side diff with in-line comments
Download patch
Index: runtime/vm/flow_graph.h
diff --git a/runtime/vm/flow_graph.h b/runtime/vm/flow_graph.h
index 3d7c51d12e2f90d7b0c58fd43ef695a2fe34d4cb..f1299a626686e22eb9bea6f9fb6b3ba8768af3ba 100644
--- a/runtime/vm/flow_graph.h
+++ b/runtime/vm/flow_graph.h
@@ -10,11 +10,15 @@
namespace dart {
+class BindInstr;
class BlockEntryInstr;
+class StaticCallComp;
class Definition;
class FlowGraphBuilder;
class GraphEntryInstr;
class PhiInstr;
+class ReturnInstr;
+class Value;
// Class to incapsulate the construction and manipulation of the flow graph.
class FlowGraph: public ZoneAllocated {
@@ -60,12 +64,20 @@ class FlowGraph: public ZoneAllocated {
return graph_entry_;
}
+ ZoneGrowableArray<ReturnInstr*>* exits() const { return exits_; }
+ void set_exits(ZoneGrowableArray<ReturnInstr*>* exits) { exits_ = exits; }
+
intptr_t alloc_ssa_temp_index() { return current_ssa_temp_index_++; }
// Operations on the flow graph.
void ComputeSSA();
+ void ComputeSSAForInlining(intptr_t callers_max_virtual_register_number);
Kevin Millikin (Google) 2012/08/29 14:01:04 I'd call this something like 'next_virtual_registe
zerny-google 2012/08/30 07:31:40 Done.
void ComputeUseLists();
+ void InlineCall(BindInstr* caller_instr,
+ StaticCallComp* caller_comp,
+ FlowGraph* callee_graph);
+
// TODO(zerny): Once the SSA is feature complete this should be removed.
void Bailout(const char* reason) const;
@@ -121,6 +133,7 @@ class FlowGraph: public ZoneAllocated {
GrowableArray<BlockEntryInstr*> preorder_;
GrowableArray<BlockEntryInstr*> postorder_;
GrowableArray<BlockEntryInstr*> reverse_postorder_;
+ ZoneGrowableArray<ReturnInstr*>* exits_;
};
} // namespace dart

Powered by Google App Engine
This is Rietveld 408576698