| Index: runtime/vm/intermediate_language.cc
|
| ===================================================================
|
| --- runtime/vm/intermediate_language.cc (revision 17939)
|
| +++ runtime/vm/intermediate_language.cc (working copy)
|
| @@ -1362,6 +1362,15 @@
|
| }
|
|
|
|
|
| +bool BinarySmiOpInstr::RightIsPowerOfTwoConstant() const {
|
| + if (!right()->definition()->IsConstant()) return false;
|
| + const Object& constant = right()->definition()->AsConstant()->value();
|
| + if (!constant.IsSmi()) return false;
|
| + const intptr_t int_value = Smi::Cast(constant).Value();
|
| + return (int_value > 0) && Utils::IsPowerOfTwo(int_value);
|
| +}
|
| +
|
| +
|
| RawAbstractType* BinaryMintOpInstr::CompileType() const {
|
| return Type::IntType();
|
| }
|
|
|