| Index: src/ia32/lithium-ia32.cc
|
| ===================================================================
|
| --- src/ia32/lithium-ia32.cc (revision 13175)
|
| +++ src/ia32/lithium-ia32.cc (working copy)
|
| @@ -1264,6 +1264,13 @@
|
| if (instr->representation().IsDouble()) {
|
| return DoArithmeticD(Token::DIV, instr);
|
| } else if (instr->representation().IsInteger32()) {
|
| + if (instr->HasPowerOf2Divisor()) {
|
| + ASSERT(!instr->CheckFlag(HValue::kCanBeDivByZero));
|
| + LOperand* value = UseRegisterAtStart(instr->left());
|
| + LDivI* div =
|
| + new(zone()) LDivI(value, UseOrConstant(instr->right()), NULL);
|
| + return AssignEnvironment(DefineSameAsFirst(div));
|
| + }
|
| // The temporary operand is necessary to ensure that right is not allocated
|
| // into edx.
|
| LOperand* temp = FixedTemp(edx);
|
|
|