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

Unified Diff: runtime/vm/flow_graph_optimizer.h

Issue 10431006: First step toward an optimizing compiler: (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 7 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_optimizer.h
===================================================================
--- runtime/vm/flow_graph_optimizer.h (revision 0)
+++ runtime/vm/flow_graph_optimizer.h (revision 0)
@@ -0,0 +1,35 @@
+// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+#ifndef VM_FLOW_GRAPH_OPTIMIZER_H_
+#define VM_FLOW_GRAPH_OPTIMIZER_H_
+
+#include "vm/intermediate_language.h"
+
+namespace dart {
+
+template <typename T> class GrowableArray;
+
+class FlowGraphOptimizer : public FlowGraphVisitor {
+ public:
+ explicit FlowGraphOptimizer(const GrowableArray<BlockEntryInstr*>& blocks)
+ : FlowGraphVisitor(blocks) {}
+ virtual ~FlowGraphOptimizer() {}
+
+ void ApplyICData();
+
+ virtual void VisitInstanceCall(InstanceCallComp* comp);
+
+ virtual void VisitDo(DoInstr* instr);
+ virtual void VisitBind(BindInstr* instr);
+
+ private:
+ void VisitBlocks();
+
+ DISALLOW_COPY_AND_ASSIGN(FlowGraphOptimizer);
+};
+
+} // namespace dart
+
+#endif // VM_FLOW_GRAPH_OPTIMIZER_H_

Powered by Google App Engine
This is Rietveld 408576698