| Index: src/compiler/machine-operator-reducer.cc
|
| diff --git a/src/compiler/machine-operator-reducer.cc b/src/compiler/machine-operator-reducer.cc
|
| index d1a275d56a07e4289934941122cac808c6cddd6d..2134c711ee581027690788e03c04e1dee11471eb 100644
|
| --- a/src/compiler/machine-operator-reducer.cc
|
| +++ b/src/compiler/machine-operator-reducer.cc
|
| @@ -638,13 +638,12 @@ Reduction MachineOperatorReducer::ReduceInt32Mod(Node* node) {
|
| if (base::bits::IsPowerOfTwo32(divisor)) {
|
| uint32_t const mask = divisor - 1;
|
| Node* const zero = Int32Constant(0);
|
| -
|
| - Node* check =
|
| - graph()->NewNode(machine()->Int32LessThan(), dividend, zero);
|
| - Diamond d(graph(), common(), check, BranchHint::kFalse);
|
| - Node* neg = Int32Sub(zero, Word32And(Int32Sub(zero, dividend), mask));
|
| - Node* pos = Word32And(dividend, mask);
|
| - d.OverwriteWithPhi(node, kMachInt32, neg, pos);
|
| + node->set_op(common()->Select(kMachInt32, BranchHint::kFalse));
|
| + node->ReplaceInput(
|
| + 0, graph()->NewNode(machine()->Int32LessThan(), dividend, zero));
|
| + node->ReplaceInput(
|
| + 1, Int32Sub(zero, Word32And(Int32Sub(zero, dividend), mask)));
|
| + node->ReplaceInput(2, Word32And(dividend, mask));
|
| } else {
|
| Node* quotient = Int32Div(dividend, divisor);
|
| node->set_op(machine()->Int32Sub());
|
|
|