Hartmut Schirmer - Patch for Granlund's soft-fp lib (original) (raw)
This is the mail archive of the gcc@gcc.gnu.orgmailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] |
- From: "Hartmut Schirmer"
- To:
- Date: Mon, 30 Jun 2003 16:57:53 +0200
- Subject: Patch for Granlund's soft-fp lib
Hi,
Torbjorn Granlund published a soft-fp lib for GCC in 1999 (see http://gcc.gnu.org/ml/gcc/1999-07n/msg00553.html)
There's a bug in the float comparison routines. The patch below fixes this problem.
Hartmut
*** gieee/ieeelib.c Thu Mar 27 10:21:35 2003 --- ieeelib.c Mon Jun 30 12:41:16 2003
*** 116,122 ****
do {
union real_extract_1 di;
di.d = (dbl);
! (exp) = ((di.u >> (MANTISSA_BITS - 1)) & EXP_MASK) ^ (di.u >>
SIGN_POS);
(m) = (di.u & (((COMPUTE_TYPE) 1 << (MANTISSA_BITS - 1)) - 1)) <<
EXP_BITS;
} while (0)
--- 131,137 ----
do {
union real_extract_1 di;
di.d = (dbl);
! (exp) = ((di.u >> (MANTISSA_BITS - 1)) & EXP_MASK) ^
((COMPUTE_STYPE)di.u >> SIGN_POS);
(m) = (di.u & (((COMPUTE_TYPE) 1 << (MANTISSA_BITS - 1)) - 1)) <<
EXP_BITS;
} while (0)
- Follow-Ups:
- Re: Patch for Granlund's soft-fp lib
* From: Zack Weinberg
- Re: Patch for Granlund's soft-fp lib
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |