CVSROOT:        /cvs
Module name:    src
Changes by:     [EMAIL PROTECTED]       2008/10/07 16:06:29

Modified files:
        sys/arch/alpha/alpha: fp_complete.c 
        sys/lib/libkern: softfloat.c softfloat.h 

Log message:
unbreak ieeefp emulation code wrt converting double to unsigned
long ints for alpha.  we've got only one instruction (cvttq) to
convert double-t to quadword, and float64_to_int64 did not take
into account the unsigned conversions
therefore, overflow always occured, and half of the unsigned range
(LONG_MAX .. ULONG_MAX) was broken
introduce roundAndPackInt64NoOverflow and float64_to_int64_no_overflow
for softfloat, that works with unsigned integers as well.  note
that this will return zero for nan/inf/oflow/uflow, raising exception
flag

perl is happy now
looked over by miod@
tested by naddy@, and by me on nick@'s alpha

Reply via email to