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

Unified Diff: runtime/vm/flow_graph_optimizer.h

Issue 1679833002: VM: Move branch optimizations into a separate file. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 10 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
« no previous file with comments | « runtime/vm/flow_graph_inliner.cc ('k') | runtime/vm/flow_graph_optimizer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/flow_graph_optimizer.h
diff --git a/runtime/vm/flow_graph_optimizer.h b/runtime/vm/flow_graph_optimizer.h
index afbb455ce1a26e37819bd96f564487ae549696d3..95605784c12bc5055aebfc51210b99f1071b78fe 100644
--- a/runtime/vm/flow_graph_optimizer.h
+++ b/runtime/vm/flow_graph_optimizer.h
@@ -335,42 +335,6 @@ class DeadCodeElimination : public AllStatic {
};
-// Rewrite branches to eliminate materialization of boolean values after
-// inlining, and to expose other optimizations (e.g., constant folding of
-// branches, unreachable code elimination).
-class BranchSimplifier : public AllStatic {
- public:
- static void Simplify(FlowGraph* flow_graph);
-
- // Replace a target entry instruction with a join entry instruction. Does
- // not update the original target's predecessors to point to the new block
- // and does not replace the target in already computed block order lists.
- static JoinEntryInstr* ToJoinEntry(Zone* zone,
- TargetEntryInstr* target);
-
- private:
- // Match an instance of the pattern to rewrite. See the implementation
- // for the patterns that are handled by this pass.
- static bool Match(JoinEntryInstr* block);
-
- // Duplicate a branch while replacing its comparison's left and right
- // inputs.
- static BranchInstr* CloneBranch(Zone* zone,
- BranchInstr* branch,
- Value* new_left,
- Value* new_right);
-};
-
-
-// Rewrite diamond control flow patterns that materialize values to use more
-// efficient branchless code patterns if such are supported on the current
-// platform.
-class IfConverter : public AllStatic {
- public:
- static void Simplify(FlowGraph* flow_graph);
-};
-
-
class AllocationSinking : public ZoneAllocated {
public:
explicit AllocationSinking(FlowGraph* flow_graph)
« no previous file with comments | « runtime/vm/flow_graph_inliner.cc ('k') | runtime/vm/flow_graph_optimizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698