mpn_sqrtrem{1,2} - patch for pure C implem

paul zimmermann Paul.Zimmermann at
Tue Jun 6 07:00:02 UTC 2017

       Dear Marco,

> I'll be happy to receive comments or critics :-)

I'd be happy to see a comparison with the code of [1]. According to [2],
slide 31, the slow branch of mpfr_sqrt takes 56 cycles for one 64-bit limb,
and 133 cycles for two limbs. This includes the computation of n = s^2 + r,
with s = floor(sqrt(n)), for s having 64 bits and 128 bits respectively.

Best regards,


More information about the gmp-devel mailing list