NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: port-alpha/52520: Wrong double to uint64_t conversion



The following reply was made to PR port-alpha/52520; it has been noted by GNATS.

From: coypu%sdf.org@localhost
To: gnats-bugs%netbsd.org@localhost
Cc: 
Subject: Re: port-alpha/52520: Wrong double to uint64_t conversion
Date: Sun, 3 Sep 2017 10:42:51 +0000

 As for the cause of the bug, it's:
 
 .. -> cvt_tq_gq -> float64_to_int64 -> roundAndPackInt64:
 
   overflow:
          float_raise( float_flag_invalid );
          return
                zSign ? (sbits64) LIT64( 0x8000000000000000 )
              : LIT64( 0x7FFFFFFFFFFFFFFF );
 
 
 "float64_to_int64 does what the name says", whereas we needed
 _to_uint64.
 
 I would really like the opinion of someone who didn't hear about alpha
 FPU yesterday rather than make broad changes myself.
 


Home | Main Index | Thread Index | Old Index