Big note: I removed n_cbrt_newton_iteration, as I have no idea why this slower and very specific function should exist.
Inlined n_randint to enable remainders by limits known at compile time to be reduced to multiplications or and-operations.
Refactored a lot of test, and revised the number of iterations that had to be done. I think 10000 iterations is the maximum test coefficient we have to employ. More than this is just redundant for more test purposes.
Improved(?) fmpz_randprime and its test (the test doesn't have to be very thorough as it's based on n_randprime and fmpz_nextprime).
Changed every instance of __mpz_struct * to mpz_ptr.
Big note: I removed
n_cbrt_newton_iteration
, as I have no idea why this slower and very specific function should exist.Inlined
n_randint
to enable remainders by limits known at compile time to be reduced to multiplications or and-operations.Refactored a lot of test, and revised the number of iterations that had to be done. I think 10000 iterations is the maximum test coefficient we have to employ. More than this is just redundant for more test purposes.
Improved(?)
fmpz_randprime
and its test (the test doesn't have to be very thorough as it's based onn_randprime
andfmpz_nextprime
).Changed every instance of
__mpz_struct *
tompz_ptr
.