[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bugs with count_leading_zeros and gmp-4.0
From: |
Torbjorn Granlund |
Subject: |
Re: bugs with count_leading_zeros and gmp-4.0 |
Date: |
21 Dec 2001 19:12:38 +0100 |
User-agent: |
Gnus/5.0807 (Gnus v5.8.7) Emacs/20.7 |
Nathalie Revol <address@hidden> writes:
Hello
we (me by chance and Paul by analyzing "my" bug) encountered a problem
with count_leading_zeros when applied to 42 (= 101010 in binary),
cf. C program below.
The result should be 26 = 32-6 and it is 27:
pastaga% gcc -I. -L.libs toto.c -lgmp (in the gmp-4.0 directory)
pastaga% ./a.out
k=27
I am unsable to reproduce. Using a 32-bit build, I get 26, and with a
64-bit build I get 58, as expected.
Perhaps your build was in 64-bit mode and then you're not using the
right compiler?
--
Torbjörn