]> Savannah Git Hosting - gnulib.git/commitdiff
expm1l: Fix configure test result with GCC 10 on powerpc64le.
authorBruno Haible <bruno@clisp.org>
Sun, 24 Jan 2021 08:03:05 +0000 (09:03 +0100)
committerBruno Haible <bruno@clisp.org>
Sun, 24 Jan 2021 08:03:05 +0000 (09:03 +0100)
* m4/expm1l.m4 (gl_FUNC_EXPM1L): Change test to avoid GCC optimization.

ChangeLog
m4/expm1l.m4

index 2cd75b4a4075d273e6c4f462ad2b2d4581c80ea9..e451f3368071bcb390d37fdcd312c36189de60c4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2021-01-24  Bruno Haible  <bruno@clisp.org>
+
+       expm1l: Fix configure test result with GCC 10 on powerpc64le.
+       * m4/expm1l.m4 (gl_FUNC_EXPM1L): Change test to avoid GCC optimization.
+
 2021-01-23  Bruno Haible  <bruno@clisp.org>
 
        utime: Fix configure test (regression 2020-12-04).
index 0eaaf844ba893cbbb78164a5bc394a1716ef6657..8fe31b574bd94f6efb03c3e6ab5a8470dbf6036c 100644 (file)
@@ -1,4 +1,4 @@
-# expm1l.m4 serial 7
+# expm1l.m4 serial 8
 dnl Copyright (C) 2010-2021 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -134,7 +134,8 @@ int main (int argc, char *argv[])
     long double x = 11.358L;
     long double y = my_expm1l (x);
     long double z = my_expm1l (- x);
-    long double err = (y + (1.0L + y) * z) * TWO_LDBL_MANT_DIG;
+    volatile long double t = (1.0L + y) * z;
+    long double err = (y + t) * TWO_LDBL_MANT_DIG;
     if (!(err >= -100.0L && err <= 100.0L))
       result |= 1;
   }