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

Unified Diff: vm/intermediate_language.h

Issue 10635020: Add new files and data structures for the new register allocator. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 6 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: vm/intermediate_language.h
===================================================================
--- vm/intermediate_language.h (revision 9014)
+++ vm/intermediate_language.h (working copy)
@@ -9,6 +9,7 @@
#include "vm/ast.h"
#include "vm/growable_array.h"
#include "vm/handles_impl.h"
+#include "vm/locations.h"
#include "vm/object.h"
namespace dart {
@@ -46,7 +47,6 @@
class FlowGraphVisitor;
class Function;
class LocalVariable;
-class LocationSummary;
// M is a two argument macro. It is applied to each concrete value's
// typename and classname.
@@ -1706,6 +1706,7 @@
M(Throw) \
M(ReThrow) \
M(Branch) \
+ M(ParallelMove)
// Forward declarations for Instruction classes.
@@ -2363,6 +2364,38 @@
DISALLOW_COPY_AND_ASSIGN(BranchInstr);
};
+
+class MoveOperands : public ValueObject {
+ public:
+ MoveOperands(Location dest, Location src) : dest_(dest), src_(src) { }
+
+ Location src() const { return src_; }
+ Location dest() const { return dest_; }
+
+ private:
+ Location dest_;
+ Location src_;
+};
+
+
+class ParallelMoveInstr : public Instruction {
+ public:
+ ParallelMoveInstr() : moves_(1) { }
+
+ DECLARE_INSTRUCTION(ParallelMove)
+
+ void AddMove(Location dest, Location src) {
+ moves_.Add(MoveOperands(dest, src));
+ }
+
+ const GrowableArray<MoveOperands>& moves() { return moves_; }
+
+ private:
+ GrowableArray<MoveOperands> moves_;
+
+ DISALLOW_COPY_AND_ASSIGN(ParallelMoveInstr);
+};
+
#undef DECLARE_INSTRUCTION
« vm/flow_graph_allocator.h ('K') | « vm/il_printer.cc ('k') | vm/intermediate_language.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698