Index: src/hydrogen.cc |
diff --git a/src/hydrogen.cc b/src/hydrogen.cc |
index 75344bb513a0d13365ba32bff60330cd2a521301..66e69dc46bf3e102e4dd55e8f3dbbb15b7ee007b 100644 |
--- a/src/hydrogen.cc |
+++ b/src/hydrogen.cc |
@@ -3748,6 +3748,8 @@ static void DehoistArrayIndex(ArrayInstructionInterface* array_operation) { |
HValue* subexpression; |
int32_t sign; |
if (index->IsAdd()) { |
+ if (!index->representation().IsInteger32()) |
+ return; |
Jakob Kummerow
2012/09/11 13:16:24
{} please (or put it all on one line).
Again below
|
sign = 1; |
HAdd* add = HAdd::cast(index); |
if (add->left()->IsConstant()) { |
@@ -3760,6 +3762,8 @@ static void DehoistArrayIndex(ArrayInstructionInterface* array_operation) { |
return; |
} |
} else if (index->IsSub()) { |
+ if (!index->representation().IsInteger32()) |
+ return; |
sign = -1; |
HSub* sub = HSub::cast(index); |
if (sub->left()->IsConstant()) { |