• Home
  • Raw
  • Download

Lines Matching refs:Long

479     Assert.assertEquals(Math.abs(Long.MAX_VALUE), Long.MAX_VALUE);
480 Assert.assertEquals(Math.abs(Long.MIN_VALUE), Long.MIN_VALUE);
481 Assert.assertEquals(Math.abs(Long.MIN_VALUE - 1), Long.MAX_VALUE);
510 Assert.assertEquals(Math.min(0L, Long.MAX_VALUE), 0L);
511 Assert.assertEquals(Math.min(Long.MIN_VALUE, 0L), Long.MIN_VALUE);
512 Assert.assertEquals(Math.min(Long.MIN_VALUE, Long.MAX_VALUE), Long.MIN_VALUE);
520 Assert.assertEquals(Math.max(0L, Long.MAX_VALUE), Long.MAX_VALUE);
521 Assert.assertEquals(Math.max(Long.MIN_VALUE, 0L), 0L);
522 Assert.assertEquals(Math.max(Long.MIN_VALUE, Long.MAX_VALUE), Long.MAX_VALUE);
832 Assert.assertEquals(Math.round(Long.MAX_VALUE + 1.0d), Long.MAX_VALUE);
833 Assert.assertEquals(Math.round(Long.MIN_VALUE - 1.0d), Long.MIN_VALUE);
835 Long.MAX_VALUE); // 2^64
837 Long.MIN_VALUE); // -2^64
838 Assert.assertEquals(Math.round(Double.POSITIVE_INFINITY), Long.MAX_VALUE);
839 Assert.assertEquals(Math.round(Double.NEGATIVE_INFINITY), Long.MIN_VALUE);
995 Assert.assertEquals(StrictMath.abs(Long.MAX_VALUE), Long.MAX_VALUE);
996 Assert.assertEquals(StrictMath.abs(Long.MIN_VALUE), Long.MIN_VALUE);
997 Assert.assertEquals(StrictMath.abs(Long.MIN_VALUE - 1), Long.MAX_VALUE);
1025 Assert.assertEquals(StrictMath.min(0L, Long.MAX_VALUE), 0L);
1026 Assert.assertEquals(StrictMath.min(Long.MIN_VALUE, 0L), Long.MIN_VALUE);
1027 Assert.assertEquals(StrictMath.min(Long.MIN_VALUE, Long.MAX_VALUE), Long.MIN_VALUE);
1035 Assert.assertEquals(StrictMath.max(0L, Long.MAX_VALUE), Long.MAX_VALUE);
1036 Assert.assertEquals(StrictMath.max(Long.MIN_VALUE, 0L), 0L);
1037 Assert.assertEquals(StrictMath.max(Long.MIN_VALUE, Long.MAX_VALUE), Long.MAX_VALUE);
1191 Assert.assertEquals(StrictMath.round(Long.MAX_VALUE + 1.0d), Long.MAX_VALUE);
1192 Assert.assertEquals(StrictMath.round(Long.MIN_VALUE - 1.0d), Long.MIN_VALUE);
1194 Long.MAX_VALUE); // 2^64
1196 Long.MIN_VALUE); // -2^64
1197 Assert.assertEquals(StrictMath.round(Double.POSITIVE_INFINITY), Long.MAX_VALUE);
1198 Assert.assertEquals(StrictMath.round(Double.NEGATIVE_INFINITY), Long.MIN_VALUE);
1301 Long.reverseBytes(0x13579bdf2468ace0L);
1302 Assert.assertEquals(Long.reverseBytes(0x0000000000000000L), 0x0000000000000000L);
1303 Assert.assertEquals(Long.reverseBytes(0xffffffffffffffffL), 0xffffffffffffffffL);
1304 Assert.assertEquals(Long.reverseBytes(0x8000000000000000L), 0x0000000000000080L);
1305 Assert.assertEquals(Long.reverseBytes(0x0000000000000080L), 0x8000000000000000L);
1306 Assert.assertEquals(Long.reverseBytes(0x0123456789abcdefL), 0xefcdab8967452301L);
1321 Long.reverse(0x1234567812345678L);
1322 Assert.assertEquals(Long.reverse(1L), 0x8000000000000000L);
1323 Assert.assertEquals(Long.reverse(-1L), 0xffffffffffffffffL);
1324 Assert.assertEquals(Long.reverse(0L), 0L);
1325 Assert.assertEquals(Long.reverse(0x1234567812345678L), 0x1e6a2c481e6a2c48L);
1326 Assert.assertEquals(Long.reverse(0x8765432187654321L), 0x84c2a6e184c2a6e1L);
1327 Assert.assertEquals(Long.reverse(Long.MAX_VALUE), 0xfffffffffffffffeL);
1328 Assert.assertEquals(Long.reverse(Long.MIN_VALUE), 1L);
1350 long r1 = Long.reverse(l1);
1351 long r2 = Long.reverse(l2);
1399 Assert.assertEquals(Long.numberOfLeadingZeros(0L), Long.SIZE);
1400 Assert.assertEquals(Long.numberOfLeadingZeros(1L), Long.SIZE - 1);
1401 Assert.assertEquals(Long.numberOfLeadingZeros(1L << ((Long.SIZE/2)-1)), Long.SIZE/2);
1402 Assert.assertEquals(Long.numberOfLeadingZeros(1L << (Long.SIZE-1)), 0);
1403 Assert.assertEquals(Long.numberOfLeadingZeros($noinline$return_long_zero()), Long.SIZE);
1404 for (int i = 0; i < Long.SIZE; i++) {
1405 Assert.assertEquals(Long.numberOfLeadingZeros(1L << i), Long.SIZE - 1 - i);
1406 Assert.assertEquals(Long.numberOfLeadingZeros((1L << i) | 1L), Long.SIZE - 1 - i);
1407 Assert.assertEquals(Long.numberOfLeadingZeros(0xFFFFFFFFFFFFFFFFL >>> i), i);
1431 peek_byte = io_memory.getDeclaredMethod("peekByte", Long.TYPE);
1432 peek_int = io_memory.getDeclaredMethod("peekInt", Long.TYPE, Boolean.TYPE);
1433 peek_short = io_memory.getDeclaredMethod("peekShort", Long.TYPE, Boolean.TYPE);
1434 peek_long = io_memory.getDeclaredMethod("peekLong", Long.TYPE, Boolean.TYPE);
1435 poke_byte = io_memory.getDeclaredMethod("pokeByte", Long.TYPE, Byte.TYPE);
1436 poke_short = io_memory.getDeclaredMethod("pokeShort", Long.TYPE, Short.TYPE, Boolean.TYPE);
1437 poke_int = io_memory.getDeclaredMethod("pokeInt", Long.TYPE, Integer.TYPE, Boolean.TYPE);
1438 poke_long = io_memory.getDeclaredMethod("pokeLong", Long.TYPE, Long.TYPE, Boolean.TYPE);
1558 Assert.assertEquals(Long.numberOfTrailingZeros(0), Long.SIZE);
1559 for (int i = 0; i < Long.SIZE; i++) {
1561 Long.numberOfTrailingZeros(0x8000000000000000L >> i),
1562 Long.SIZE - 1 - i);
1564 Long.numberOfTrailingZeros((0x8000000000000000L >> i) | 0x8000000000000000L),
1565 Long.SIZE - 1 - i);
1566 Assert.assertEquals(Long.numberOfTrailingZeros(1L << i), i);
1593 Assert.assertEquals(Long.rotateRight(0x11, 0), 0x11);
1595 Assert.assertEquals(Long.rotateRight(0x11, 1), 0x8000000000000008L);
1596 Assert.assertEquals(Long.rotateRight(0x11, Long.SIZE - 1), 0x22);
1597 Assert.assertEquals(Long.rotateRight(0x11, Long.SIZE), 0x11);
1598 Assert.assertEquals(Long.rotateRight(0x11, Long.SIZE + 1), 0x8000000000000008L);
1600 Assert.assertEquals(Long.rotateRight(0x11, -1), 0x22);
1601 Assert.assertEquals(Long.rotateRight(0x11, -(Long.SIZE - 1)), 0x8000000000000008L);
1602 Assert.assertEquals(Long.rotateRight(0x11, -Long.SIZE), 0x11);
1603 Assert.assertEquals(Long.rotateRight(0x11, -(Long.SIZE + 1)), 0x22);
1605 Assert.assertEquals(Long.rotateRight(0x8000000000000000L, 1), 0x4000000000000000L);
1607 for (int i = 0; i < Long.SIZE; i++) {
1609 Long.rotateRight(0xBBAAAADDFF0000DDL, i),
1610 (0xBBAAAADDFF0000DDL >>> i) | (0xBBAAAADDFF0000DDL << (Long.SIZE - i)));
1637 Assert.assertEquals(Long.rotateLeft(0x11, 0), 0x11);
1639 Assert.assertEquals(Long.rotateLeft(0x11, 1), 0x22);
1640 Assert.assertEquals(Long.rotateLeft(0x11, Long.SIZE - 1), 0x8000000000000008L);
1641 Assert.assertEquals(Long.rotateLeft(0x11, Long.SIZE), 0x11);
1642 Assert.assertEquals(Long.rotateLeft(0x11, Long.SIZE + 1), 0x22);
1644 Assert.assertEquals(Long.rotateLeft(0x11, -1), 0x8000000000000008L);
1645 Assert.assertEquals(Long.rotateLeft(0x11, -(Long.SIZE - 1)), 0x22);
1646 Assert.assertEquals(Long.rotateLeft(0x11, -Long.SIZE), 0x11);
1647 Assert.assertEquals(Long.rotateLeft(0x11, -(Long.SIZE + 1)), 0x8000000000000008L);
1649 Assert.assertEquals(Long.rotateLeft(0xC000000000000000L, 1), 0x8000000000000001L);
1651 for (int i = 0; i < Long.SIZE; i++) {
1653 Long.rotateLeft(0xBBAAAADDFF0000DDL, i),
1654 (0xBBAAAADDFF0000DDL << i) | (0xBBAAAADDFF0000DDL >>> (Long.SIZE - i)));
1668 for (int i = 0; i < Long.SIZE * 2; i++) {
1669 Assert.assertEquals(Long.rotateLeft(0xBBAAAADDFF0000DDL, i),
1670 Long.rotateRight(0xBBAAAADDFF0000DDL, -i));
1671 Assert.assertEquals(Long.rotateLeft(0xBBAAAADDFF0000DDL, -i),
1672 Long.rotateRight(0xBBAAAADDFF0000DDL, i));