3.0.1 release?

David Bateman David.Bateman at motorola.com
Tue Apr 8 08:01:30 CDT 2008


Michael Goffioul wrote:
>   ***** assert(bitcmp(A,Amax),bitor(bitshift(1,Amax-1),bitshift(1,Amax-2)));
> !!!!! test failed
> error: assert (bitcmp (A, Amax),bitor (bitshift (1, Amax - 1),
> bitshift (1, Amax - 2))) expected
> 6.7554e+015
> but got
> 1.1259e+016
> values do not match
> shared variables {
>   Amax =  53
>   Bmax = 9.0072e+015
>   A = 2.2518e+015
> }
>   

I just looked at this issue a little bit and the failing part of the
code is

 Bmax = bitmax;
 A = bitshift(Bmax,-2);
 bitxor(cast(A,'uint64'),cast(Bmax,'uint64'))

Bmax is '2^53 - 1' and A is '2^51 - 1" and so bitxor of the above should
be '2^52 + 2^51' and is under linux. Under windows this appears to
return '2^53 + 2^51' which is of course a bug.. The equivalent in C++
would be

0x000FFFFFFFFFFFFFUL^ x0003FFFFFFFFFFFFUL

so what does this return when compiled with MSVC in C++ mode? If its not
'2^52 + 2^51' its time to file a bug report against MSVC..

D.

-- 
David Bateman                                David.Bateman at motorola.com
Motorola Labs - Paris                        +33 1 69 35 48 04 (Ph) 
Parc Les Algorithmes, Commune de St Aubin    +33 6 72 01 06 33 (Mob) 
91193 Gif-Sur-Yvette FRANCE                  +33 1 69 35 77 01 (Fax) 

The information contained in this communication has been classified as: 

[x] General Business Information 
[ ] Motorola Internal Use Only 
[ ] Motorola Confidential Proprietary



More information about the Octave-maintainers mailing list