Index: src/hydrogen-canonicalize.cc |
diff --git a/src/hydrogen-canonicalize.cc b/src/hydrogen-canonicalize.cc |
index 643234392d0ac942d719dc3cb71a87b29ab5cf7e..4d96415e6a8142b40a2e74ed6c17011bb18bf071 100644 |
--- a/src/hydrogen-canonicalize.cc |
+++ b/src/hydrogen-canonicalize.cc |
@@ -48,6 +48,10 @@ void HCanonicalizePhase::Run() { |
if (instr->HasAtLeastOneUseWithFlagAndNoneWithout( |
HInstruction::kTruncatingToSmi)) { |
instr->SetFlag(HInstruction::kAllUsesTruncatingToSmi); |
+ } else if (instr->HasAtLeastOneUseWithFlagAndNoneWithout( |
+ HInstruction::kTruncatingToInt32)) { |
+ // Avoid redundant minus zero check |
+ instr->SetFlag(HInstruction::kAllUsesTruncatingToInt32); |
} |
} |
} |