Commit 33a9145b by Ian Lance Taylor

libgo: Build math package with -ffp-contract=off on non-x86.

http://golang.org/issue/7074 shows that not using
-ffp-contract=off produces the wrong result for math.Log2(1)
on arm64.

From-SVN: r208505
parent 6c107fab
......@@ -14985,6 +14985,8 @@ $as_echo "$libgo_cv_c_fancymath" >&6; }
MATH_FLAG=
if test "$libgo_cv_c_fancymath" = yes; then
MATH_FLAG="-mfancy-math-387 -funsafe-math-optimizations"
else
MATH_FLAG="-ffp-contract=off"
fi
......
......@@ -620,6 +620,8 @@ CFLAGS=$CFLAGS_hold])
MATH_FLAG=
if test "$libgo_cv_c_fancymath" = yes; then
MATH_FLAG="-mfancy-math-387 -funsafe-math-optimizations"
else
MATH_FLAG="-ffp-contract=off"
fi
AC_SUBST(MATH_FLAG)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment