| Index: src/hydrogen-instructions.cc
|
| diff --git a/src/hydrogen-instructions.cc b/src/hydrogen-instructions.cc
|
| index 60a6912654fe50b3533a470a1df8a540d145b37d..849c85d533d6c4e686e307af732e11cbe2b49393 100644
|
| --- a/src/hydrogen-instructions.cc
|
| +++ b/src/hydrogen-instructions.cc
|
| @@ -1436,6 +1436,16 @@ HValue* HSub::Canonicalize() {
|
| }
|
|
|
|
|
| +HValue* HMul::Canonicalize() {
|
| + if (left()->IsInteger32Constant() &&
|
| + HConstant::cast(left())->Integer32Value() == 1 &&
|
| + right()->representation().IsSpecialization()) {
|
| + return right();
|
| + }
|
| + return this;
|
| +}
|
| +
|
| +
|
| HValue* HChange::Canonicalize() {
|
| return (from().Equals(to())) ? value() : this;
|
| }
|
|
|