diff options
author | H.J. Lu <hongjiu.lu@intel.com> | 2016-01-12 00:30:30 +0000 |
---|---|---|
committer | H.J. Lu <hjl@gcc.gnu.org> | 2016-01-11 16:30:30 -0800 |
commit | cf4de6af251d35f7b5a416dca9a6642d89016abf (patch) | |
tree | cede8edeb57c09a0f2b04b27a70929bb4f3d117c /gcc/config/i386/i386.h | |
parent | 0f474f11b16c8c0bd8c1e9a9c0bcbaa358f59a8a (diff) | |
download | gcc-cf4de6af251d35f7b5a416dca9a6642d89016abf.zip gcc-cf4de6af251d35f7b5a416dca9a6642d89016abf.tar.gz gcc-cf4de6af251d35f7b5a416dca9a6642d89016abf.tar.bz2 |
Set FLT_EVAL_METHOD to 2 only if 387 FPU is used
When 387 FPU isn't used, there is no excess precision. We should set
FLT_EVAL_METHOD to 2 only if 387 FPU is used.
gcc/
PR target/69225
* config/i386/i386.h (TARGET_FLT_EVAL_METHOD): Set to 2 only if
TARGET_80387 is true.
gcc/testsuite
PR target/69225
* gcc.target/i386/pr69225-1.c: New test.
* gcc.target/i386/pr69225-2.c: Likewise.
* gcc.target/i386/pr69225-3.c: Likewise.
* gcc.target/i386/pr69225-4.c: Likewise.
* gcc.target/i386/pr69225-5.c: Likewise.
* gcc.target/i386/pr69225-6.c: Likewise.
From-SVN: r232249
Diffstat (limited to 'gcc/config/i386/i386.h')
-rw-r--r-- | gcc/config/i386/i386.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h index dcaa011..6c63871 100644 --- a/gcc/config/i386/i386.h +++ b/gcc/config/i386/i386.h @@ -694,7 +694,7 @@ extern const char *host_detect_local_cpu (int argc, const char **argv); the rounding precision is indeterminate, since either may be chosen apparently at random. */ #define TARGET_FLT_EVAL_METHOD \ - (TARGET_MIX_SSE_I387 ? -1 : TARGET_SSE_MATH ? 0 : 2) + (TARGET_MIX_SSE_I387 ? -1 : (TARGET_80387 && !TARGET_SSE_MATH) ? 2 : 0) /* Whether to allow x87 floating-point arithmetic on MODE (one of SFmode, DFmode and XFmode) in the current excess precision |