mpz_probab_prime_p reproducibility

Torbjörn Granlund tg at gmplib.org
Wed Nov 16 16:20:49 UTC 2016


Pierre Chatelier <pierre at chachatelier.fr> writes:

  I have checked the source code, and so the answer (in GMP 6.1.1) about
  reproducibility is no. The miller rabbin tests are done under a
  gmp_randstate_t, and there is no seed deterministicallly hashed from the
  number n to test.

If your use of "reproducibility" is what I think it is, then you have
misread the source code: the fact is that two consecutive calls with the
exact same parameters will yield the same results.


-- 
Torbjörn
Please encrypt, key id 0xC8601622


More information about the gmp-discuss mailing list