aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul E. Murphy <murphyp@linux.vnet.ibm.com>2016-05-27 12:05:47 -0500
committerPaul E. Murphy <murphyp@linux.vnet.ibm.com>2016-05-27 12:06:15 -0500
commitf64f68f53b2bd7c490f198b6da84f0ef41942aee (patch)
treec10e129cfacb73ece30930c9771b8d8b23d9a787
parent9513192bc7639d7d8d8b6a291b159f6b60782a43 (diff)
downloadglibc-f64f68f53b2bd7c490f198b6da84f0ef41942aee.tar
glibc-f64f68f53b2bd7c490f198b6da84f0ef41942aee.tar.gz
glibc-f64f68f53b2bd7c490f198b6da84f0ef41942aee.tar.bz2
glibc-f64f68f53b2bd7c490f198b6da84f0ef41942aee.zip
Replace M_El with lit_e in libm-test.inc
This is useful in situations where the long double type is less precise than the type under test.
-rw-r--r--ChangeLog5
-rw-r--r--math/libm-test.inc11
2 files changed, 13 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 39b2866a78..812f0a51ab 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2016-05-27 Paul E. Murphy <murphyp@linux.vnet.ibm.com>
+ * libm-test.inc: Replace usage of M_El with
+ (lit_e): New macro.
+
+2016-05-27 Paul E. Murphy <murphyp@linux.vnet.ibm.com>
+
* libm-test.inc: Replace usage of M_PI_4l with
(lit_pi_4_d): New macro.
diff --git a/math/libm-test.inc b/math/libm-test.inc
index 1e401a82bb..8c64c8e758 100644
--- a/math/libm-test.inc
+++ b/math/libm-test.inc
@@ -302,6 +302,11 @@ struct ulp_data
/* pi */
#define lit_pi LITM (M_PI)
+/* Other useful constants. */
+
+/* e */
+#define lit_e LITM (M_E)
+
#define ulps_file_name "ULPs" /* Name of the ULPs file. */
static FILE *ulps_file; /* File to document difference. */
static int output_ulps; /* Should ulps printed? */
@@ -7078,7 +7083,7 @@ static const struct test_f_f_data fabs_test_data[] =
TEST_f_f (fabs, -min_value, min_value, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
TEST_f_f (fabs, -max_value, max_value, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
TEST_f_f (fabs, 38.0, 38.0, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
- TEST_f_f (fabs, -M_El, M_El, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
+ TEST_f_f (fabs, -lit_e, lit_e, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
};
static void
@@ -7914,7 +7919,7 @@ hypot_test (void)
static const struct test_f_i_data ilogb_test_data[] =
{
TEST_f_i (ilogb, 1, 0, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
- TEST_f_i (ilogb, M_El, 1, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
+ TEST_f_i (ilogb, lit_e, 1, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
TEST_f_i (ilogb, 1024, 10, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
TEST_f_i (ilogb, -2000, 10, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
TEST_f_i (ilogb, 0.5, -1, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED);
@@ -9086,7 +9091,7 @@ static const struct test_f_f_data logb_test_data[] =
TEST_f_f (logb, -snan_value, qnan_value, NO_INEXACT_EXCEPTION|INVALID_EXCEPTION),
TEST_f_f (logb, 1, 0, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
- TEST_f_f (logb, M_El, 1, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
+ TEST_f_f (logb, lit_e, 1, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
TEST_f_f (logb, 1024, 10, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),
TEST_f_f (logb, -2000, 10, NO_INEXACT_EXCEPTION|ERRNO_UNCHANGED),