Re: GMP 6.1.2 t-count_zeros failure on ARM with assertions

2017-12-26 Thread Vincent Lefevre
On 2017-12-26 11:51:28 +0100, Niels Möller wrote: > Hmm, I guess the problem is > > #define count_leading_zeros_gcc_clz(count,x)\ > do { \ > ASSERT ((x) != 0); \ > (count) = __builtin_clzll (x);

Re: GMP 6.1.2 t-count_zeros failure on ARM with assertions

2017-12-26 Thread Niels Möller
Vincent Lefevre writes: > #ifdef COUNT_LEADING_ZEROS_0 > check_clz (COUNT_LEADING_ZEROS_0, CNST_LIMB(0)); > #endif > > If GMP does a test with CNST_LIMB(0), I wonder why it has an > assertion (n) != 0. This is not consistent! The docs say: 5) count_leading_zeros(count,