Help stabilising mini-gmp

Niels Möller nisse at lysator.liu.se
Wed Nov 16 19:45:28 UTC 2016


tg at gmplib.org (Torbjörn Granlund) writes:

> 5. The t-div test intermittently fails on at least
>    sky.gmplib.org-k10-dyn-clang-3.6-clang++-3.6:64 (note that it uses
>    clang, which means the likelihood of a compiler bug being the culprit
>    is perhaps high).

I've tracked this one down to incorrect results from mpn_invert_3by2.
I'll investigate, and in the process try to document how it works, and
maybe rewrite it (it's a bit too hairy for its own good).

It could also use some units test of its own; result is easy to
validate.

With some luck, this could be the root cause also for the gcd and powm
failures (the powm failure I've seen involved a negative exponent, and
hence an initial modular inversion).

Regards,
/Niels

-- 
Niels Möller. PGP-encrypted email is preferred. Keyid 368C6677.
Internet email is subject to wholesale government surveillance.


More information about the gmp-devel mailing list