Commit 9c951124 by Alexandre Oliva Committed by Alexandre Oliva

fp-bit.c (unpack_d): Handle pair of doubles with different signs correctly.

* config/fp-bit.c (unpack_d): Handle pair of doubles with
different signs correctly.

From-SVN: r65405
parent d1c9693e
2003-04-09 Alexandre Oliva <aoliva@redhat.com>
* config/fp-bit.c (unpack_d): Handle pair of doubles with
different signs correctly.
2003-04-09 Vladimir Makarov <vmakarov@redhat.com>
* sched-deps.c (reg_pending_barrier_mode): New enumeration.
......
......@@ -459,6 +459,7 @@ unpack_d (FLO_union_type * src, fp_number_type * dst)
if (exp != EXPMAX && exp != 0 && low != 0)
{
int lowexp = ((int)(low >> HALFFRACBITS)) & ((1 << EXPBITS) - 1);
int lowsign = ((int)(low >> (((HALFFRACBITS + EXPBITS))))) & 1;
int shift;
fractype xlow;
......@@ -472,7 +473,10 @@ unpack_d (FLO_union_type * src, fp_number_type * dst)
xlow <<= shift;
else if (shift < 0)
xlow >>= -shift;
fraction += xlow;
if (sign == lowsign)
fraction += xlow;
else
fraction -= xlow;
}
}
# else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment