Lines Matching refs:rotateRightShort
258 private static int rotateRightShort(short value, int distance) { in rotateRightShort() method in Main
491 expectEqualsInt(0xFFFF8000, rotateRightShort((short)0x8000, 0)); in testRotateRightShort()
492 expectEqualsInt(0x7FFFC000, rotateRightShort((short)0x8000, 1)); in testRotateRightShort()
493 expectEqualsInt(0xFFFF0001, rotateRightShort((short)0x8000, 31)); in testRotateRightShort()
494 expectEqualsInt(0xFFFF8000, rotateRightShort((short)0x8000, 32)); // overshoot in testRotateRightShort()
495 expectEqualsInt(0xFFFFC000, rotateRightShort((short)0x8001, 1)); in testRotateRightShort()
496 expectEqualsInt(0x7FFFE000, rotateRightShort((short)0x8001, 2)); in testRotateRightShort()
497 expectEqualsInt(0x40000123, rotateRightShort((short)0x1234, 4)); in testRotateRightShort()
498 expectEqualsInt(0xBCFFFF9A, rotateRightShort((short)0x9ABC, 8)); in testRotateRightShort()
501 expectEqualsInt(0x00000000, rotateRightShort((short)0x0000, i)); in testRotateRightShort()
502 expectEqualsInt(0xFFFFFFFF, rotateRightShort((short)0xFFFF, i)); in testRotateRightShort()
503 expectEqualsInt(1 << (32 - j), rotateRightShort((short)0x0001, i)); in testRotateRightShort()
504 expectEqualsInt((0x1234 >>> j) | (0x1234 << -j), rotateRightShort((short)0x1234, i)); in testRotateRightShort()