mirror of
https://github.com/postgres/postgres.git
synced 2025-07-30 11:03:19 +03:00
Disable excessive FP optimization by recent versions of gcc.
Suggested solution from Tom Lane. Problem discovered, probably not for the first time, while testing the mingw-w64 32 bit compiler. Backpatched to all live branches.
This commit is contained in:
@ -433,6 +433,8 @@ if test "$GCC" = yes -a "$ICC" = no; then
|
||||
PGAC_PROG_CC_CFLAGS_OPT([-fno-strict-aliasing])
|
||||
# Disable optimizations that assume no overflow; needed for gcc 4.3+
|
||||
PGAC_PROG_CC_CFLAGS_OPT([-fwrapv])
|
||||
# Disable FP optimizations that cause various errors on gcc 4.5+ or maybe 4.6+
|
||||
PGAC_PROG_CC_CFLAGS_OPT([-fexcess-precision=standard])
|
||||
elif test "$ICC" = yes; then
|
||||
# Intel's compiler has a bug/misoptimization in checking for
|
||||
# division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
|
||||
|
Reference in New Issue
Block a user