- Sort Score
- Result 10 results
- Languages All
Results 1 - 6 of 6 for lessThanBranchFree (0.15 sec)
-
guava-tests/benchmark/com/google/common/math/LessThanBenchmark.java
int tmp = 0; for (int i = 0; i < reps; i++) { int j = i & SAMPLE_MASK; int x = xInts[j]; int y = yInts[j]; int z = constant[j]; tmp += z + IntMath.lessThanBranchFree(x, y); } return tmp; } @Benchmark int ternaryLtIntAddOutsideTernary(int reps) { int tmp = 0; for (int i = 0; i < reps; i++) { int j = i & SAMPLE_MASK;
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Dec 04 17:37:03 UTC 2017 - 4K bytes - Viewed (0) -
guava/src/com/google/common/math/LongMath.java
case DOWN: return logFloor; case CEILING: case UP: return logFloor + lessThanBranchFree(floorPow, x); case HALF_DOWN: case HALF_UP: case HALF_EVEN: // sqrt(10) is irrational, so log10(x)-logFloor is never exactly 0.5 return logFloor + lessThanBranchFree(halfPowersOf10[logFloor], x); } throw new AssertionError(); } @GwtIncompatible // TODO
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 09 16:39:37 UTC 2024 - 45.2K bytes - Viewed (0) -
android/guava/src/com/google/common/math/LongMath.java
case DOWN: return logFloor; case CEILING: case UP: return logFloor + lessThanBranchFree(floorPow, x); case HALF_DOWN: case HALF_UP: case HALF_EVEN: // sqrt(10) is irrational, so log10(x)-logFloor is never exactly 0.5 return logFloor + lessThanBranchFree(halfPowersOf10[logFloor], x); } throw new AssertionError(); } @GwtIncompatible // TODO
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 09 16:39:37 UTC 2024 - 45.2K bytes - Viewed (0) -
guava-tests/test/com/google/common/math/IntMathTest.java
for (int x : ALL_INTEGER_CANDIDATES) { for (int y : ALL_INTEGER_CANDIDATES) { if (LongMath.fitsInInt((long) x - y)) { int expected = (x < y) ? 1 : 0; int actual = IntMath.lessThanBranchFree(x, y); assertEquals(expected, actual); } } } } @GwtIncompatible // java.math.BigInteger public void testIsPowerOfTwo() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:26:48 UTC 2024 - 23.1K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/math/IntMathTest.java
for (int x : ALL_INTEGER_CANDIDATES) { for (int y : ALL_INTEGER_CANDIDATES) { if (LongMath.fitsInInt((long) x - y)) { int expected = (x < y) ? 1 : 0; int actual = IntMath.lessThanBranchFree(x, y); assertEquals(expected, actual); } } } } @GwtIncompatible // java.math.BigInteger public void testIsPowerOfTwo() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:26:48 UTC 2024 - 23.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/math/LongMathTest.java
BigInteger difference = BigInteger.valueOf(x).subtract(BigInteger.valueOf(y)); if (fitsInLong(difference)) { int expected = (x < y) ? 1 : 0; int actual = LongMath.lessThanBranchFree(x, y); assertEquals(expected, actual); } } } } // Throws an ArithmeticException if "the simple implementation" of binomial coefficients overflows
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 15:00:32 UTC 2024 - 30.6K bytes - Viewed (0)