diff options
author | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-04-24 15:28:21 +0000 |
---|---|---|
committer | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-04-24 15:28:21 +0000 |
commit | d439f3efa283afa1d1cd0a03b7ea457a5faac06a (patch) | |
tree | 02de3c14605545c31467f9847eec2443b8c6117d /gcc/libgcc2.h | |
parent | 68ab21775fa850ca105606dab9ab4907fae311c0 (diff) | |
download | gcc-d439f3efa283afa1d1cd0a03b7ea457a5faac06a.tar.gz |
* libgcc2.h (AVOID_FP_TYPE_CONVERSION): Rename from
IS_IBM_EXTENDED. Also define in terms of WIDEST_HARDWARE_FP_SIZE.
* libgcc2.c (__floatdisf): Avoid double-word arithmetic when
looking for non-zero bits shifted out. Avoid a recursive call
when constructing the scalar.
(__floatundisf): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@124106 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/libgcc2.h')
-rw-r--r-- | gcc/libgcc2.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/gcc/libgcc2.h b/gcc/libgcc2.h index b1c749f0c99..c6084dc00fa 100644 --- a/gcc/libgcc2.h +++ b/gcc/libgcc2.h @@ -115,10 +115,16 @@ extern void __eprintf (const char *, const char *, unsigned int, const char *) /* FIXME: This #ifdef probably should be removed, ie. enable the test for mips too. */ +/* Don't use IBM Extended Double TFmode for TI->SF calculations. + The conversion from long double to float suffers from double + rounding, because we convert via double. In other cases, going + through the software fp routines is much slower than the fallback. */ #ifdef __powerpc__ -#define IS_IBM_EXTENDED(SIZE) (SIZE == 106) +#define AVOID_FP_TYPE_CONVERSION(SIZE) (SIZE == 106) +#elif defined(WIDEST_HARDWARE_FP_SIZE) +#define AVOID_FP_TYPE_CONVERSION(SIZE) (SIZE > WIDEST_HARDWARE_FP_SIZE) #else -#define IS_IBM_EXTENDED(SIZE) 0 +#define AVOID_FP_TYPE_CONVERSION(SIZE) 0 #endif /* In the first part of this file, we are interfacing to calls generated |