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

Unified Diff: src/compiler/register-allocator-verifier.h

Issue 704193007: [turbofan] add gap move verifier (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: rebase Created 6 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 side-by-side diff with in-line comments
Download patch
Index: src/compiler/register-allocator-verifier.h
diff --git a/src/compiler/register-allocator-verifier.h b/src/compiler/register-allocator-verifier.h
index 10592e10f451fd40c1d70e868aa9c66272bcf45b..4e35dc2457342835ab538c5c401f65866042e30b 100644
--- a/src/compiler/register-allocator-verifier.h
+++ b/src/compiler/register-allocator-verifier.h
@@ -17,9 +17,11 @@ class InstructionSequence;
class RegisterAllocatorVerifier FINAL : public ZoneObject {
public:
- RegisterAllocatorVerifier(Zone* zone, const InstructionSequence* sequence);
+ RegisterAllocatorVerifier(Zone* zone, const RegisterConfiguration* config,
+ const InstructionSequence* sequence);
void VerifyAssignment();
+ void VerifyGapMoves();
private:
enum ConstraintType {
@@ -38,6 +40,7 @@ class RegisterAllocatorVerifier FINAL : public ZoneObject {
struct OperandConstraint {
ConstraintType type_;
int value_; // subkind index when relevant
+ int virtual_register_;
};
struct InstructionConstraint {
@@ -46,15 +49,30 @@ class RegisterAllocatorVerifier FINAL : public ZoneObject {
OperandConstraint* operand_constraints_;
};
+ class OutgoingMapping;
+
typedef ZoneVector<InstructionConstraint> Constraints;
+ typedef ZoneVector<OutgoingMapping*> OutgoingMappings;
+ Zone* zone() const { return zone_; }
+ const RegisterConfiguration* config() { return config_; }
const InstructionSequence* sequence() const { return sequence_; }
Constraints* constraints() { return &constraints_; }
+
+ static void VerifyInput(const OperandConstraint& constraint);
+ static void VerifyTemp(const OperandConstraint& constraint);
+ static void VerifyOutput(const OperandConstraint& constraint);
+
void BuildConstraint(const InstructionOperand* op,
OperandConstraint* constraint);
void CheckConstraint(const InstructionOperand* op,
const OperandConstraint* constraint);
+ void ConstructOutgoingMappings(OutgoingMappings* outgoing_mappings,
+ bool initial_pass);
+
+ Zone* const zone_;
+ const RegisterConfiguration* config_;
const InstructionSequence* const sequence_;
Constraints constraints_;

Powered by Google App Engine
This is Rietveld 408576698