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
This commit is contained in:
parent
d1c9693eeb
commit
9c951124f3
2 changed files with 10 additions and 1 deletions
|
@ -1,3 +1,8 @@
|
|||
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
|
||||
|
|
Loading…
Add table
Reference in a new issue