Revision history for Perl extension Math::Prime::Util.
0.07 17 June 2012
- Fixed a bug in next_prime found by Lou Godio (thank you VERY much!).
Added more tests for this. This had been changed in another area but
hadn't been brought into next_prime.
0.06 14 June 2012
- Change to New/Safefree from malloc. Oops.
0.05 11 June 2012
- Speed up mulmod: asm for GCC + x86_64, native 64-bit for 32-bit Perl
is uint64_t is available, and range tests for others. This speeds up
some of the factoring as well as Miller-Rabin, which in turn speeds up
is_prime. is_prime is used quite commonly, so this is good.
- nth_prime routines should now all croak on overflow in the same way.
- Segmented prime_count, things like this are reasonably efficient:
say prime_count( 10**16, 10**16 + 2**20 )
- Add Ei(x), li(x), and R(x) functions.
- prime_count_approx uses R(x), making it vastly more accurate.
- Let user override rand for random_prime.
- Add many more tests with the help of Devel::Cover.
0.04 7 June 2012
- Didn't do tests on 32-bit machine before release. Test suite caught
problem with next_prime overflow.
- Try to use 64-bit modulo math even when Perl is 32-bit. It can make
is_prime run up to 10x faster (which impacts next_prime, factoring, etc.)
- replace all assert with croak indicating an internal error.
- Add random_prime and random_ndigit_prime
- renamed prime_free to prime_memfree.
0.03 6 June 2012
- Speed up factoring.
- fixed powmod routine, speedup for smaller numbers
- Add Miller-Rabin and deterministic probable prime functions. These
are now used for is_prime and factoring, giving a big speedup for
numbers > 32-bit.
- Add HOLF factoring (just for demo)
- Next prime returns 0 on overflow
0.02 5 June 2012
- Back off new_ok to new/isa_ok to keep Test::More requirements low.
- Some documentation updates.
- I accidently used long in SQUFOF, which breaks LLP64.
- Test for broken 64-bit Perl.
- Fix overflow issues in segmented sieving.
- Switch to using UVuf for croaks. What I should have done all along.
- prime_count uses a segment sieve with 256k chunks (~7.9M numbers).
Not memory intensive any more, and faster for large inputs. The time
growth is slightly over linear however, so expect to wait a long
time for 10^12 or more.
- nth_prime also transitioned to segmented sieve.
0.01 4 June 2012
- Initial release