src/share/classes/java/math/BigInteger.java

Print this page

        

*** 3595,3605 **** /** * Converts the specified BigInteger to a string and appends to * {@code sb}. This implements the recursive Schoenhage algorithm * for base conversions. ! * <p/> * See Knuth, Donald, _The Art of Computer Programming_, Vol. 2, * Answers to Exercises (4.4) Question 14. * * @param u The number to convert to a string. * @param sb The StringBuilder that will be appended to in place. --- 3595,3605 ---- /** * Converts the specified BigInteger to a string and appends to * {@code sb}. This implements the recursive Schoenhage algorithm * for base conversions. ! * <p> * See Knuth, Donald, _The Art of Computer Programming_, Vol. 2, * Answers to Exercises (4.4) Question 14. * * @param u The number to convert to a string. * @param sb The StringBuilder that will be appended to in place.
*** 3644,3654 **** } /** * Returns the value radix^(2^exponent) from the cache. * If this value doesn't already exist in the cache, it is added. ! * <p/> * This could be changed to a more complicated caching method using * {@code Future}. */ private static BigInteger getRadixConversionCache(int radix, int exponent) { BigInteger[] cacheLine = powerCache[radix]; // volatile read --- 3644,3654 ---- } /** * Returns the value radix^(2^exponent) from the cache. * If this value doesn't already exist in the cache, it is added. ! * <p> * This could be changed to a more complicated caching method using * {@code Future}. */ private static BigInteger getRadixConversionCache(int radix, int exponent) { BigInteger[] cacheLine = powerCache[radix]; // volatile read