Index: runtime/lib/integers.cc |
=================================================================== |
--- runtime/lib/integers.cc (revision 3170) |
+++ runtime/lib/integers.cc (working copy) |
@@ -478,7 +478,11 @@ |
result = left.Value() << right.Value(); |
break; |
case Token::kSAR: { |
+#if defined(TARGET_ARCH_X64) // TODO(regis): Revisit. |
+ int shift_amount = (right.Value() > 0x3F) ? 0x3F : right.Value(); |
+#else |
int shift_amount = (right.Value() > 0x1F) ? 0x1F : right.Value(); |
+#endif |
result = left.Value() >> shift_amount; |
break; |
} |