Index: src/compiler/simplified-lowering.cc |
diff --git a/src/compiler/simplified-lowering.cc b/src/compiler/simplified-lowering.cc |
index e7aaf43535a54e0bf27a1361265758a28c9d7532..1e54015335bf09ecbd304923a1837e347cdc6fc9 100644 |
--- a/src/compiler/simplified-lowering.cc |
+++ b/src/compiler/simplified-lowering.cc |
@@ -1667,22 +1667,15 @@ class RepresentationSelector { |
} |
BinaryOperationHints::Hint hint = BinaryOperationHintOf(node->op()); |
if (hint == BinaryOperationHints::kSignedSmall || |
- hint == BinaryOperationHints::kSigned32) { |
+ hint == BinaryOperationHints::kSigned32 || |
Benedikt Meurer
2016/07/27 03:34:36
This if is redundant. Drop it completely, or phras
Jarin
2016/07/27 05:34:01
+1 for the DCHECK.
epertoso
2016/07/27 08:26:36
As per offline discussion, I'll just remove this.
|
+ hint == BinaryOperationHints::kNumberOrOddball) { |
Type* rhs_type = GetUpperBound(node->InputAt(1)); |
- if (truncation.IsUsedAsWord32()) { |
- VisitBinop(node, UseInfo::CheckedSigned32AsWord32(), |
- MachineRepresentation::kWord32); |
- if (lower()) { |
- lowering->DoShift(node, lowering->machine()->Word32Shl(), |
- rhs_type); |
- } |
- } else { |
- VisitBinop(node, UseInfo::CheckedSigned32AsWord32(), |
- MachineRepresentation::kWord32, Type::Signed32()); |
- if (lower()) { |
- lowering->DoShift(node, lowering->machine()->Word32Shl(), |
- rhs_type); |
- } |
+ VisitBinop(node, hint == BinaryOperationHints::kNumberOrOddball |
+ ? UseInfo::CheckedNumberOrOddballAsWord32() |
+ : UseInfo::CheckedSigned32AsWord32(), |
+ MachineRepresentation::kWord32, Type::Signed32()); |
+ if (lower()) { |
+ lowering->DoShift(node, lowering->machine()->Word32Shl(), rhs_type); |
} |
return; |
} |