This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Move csin, csinh tests to auto-libm-test-in [committed]


This patch moves most tests of csin and csinh with finite inputs from
libm-test.inc to auto-libm-test-in.  The remaining two tests of each
function with small arguments are not moved because moving them causes
the time required by gen-auto-libm-tests to go up from under 8 seconds
to over 11 minutes for me.  (The current development version of MPC
has had speed improvements for mpc_sin for some time, but there hasn't
been a release containing those improvements yet.)

Tested for x86_64 and x86.  Committed.

(auto-libm-test-out diffs omitted below.)

2015-06-24  Joseph Myers  <joseph@codesourcery.com>

	* math/auto-libm-test-in: Add more tests of csin and csinh.
	* math/auto-libm-test-out: Regenerated.
	* math/libm-test.inc (csin_test_data): Remove tests moved to
	auto-libm-test-in.
	(csinh_test_data): Likewise.

diff --git a/math/auto-libm-test-in b/math/auto-libm-test-in
index 2389c05..89a2684 100644
--- a/math/auto-libm-test-in
+++ b/math/auto-libm-test-in
@@ -955,16 +955,66 @@ cpow 0.75 1.25 1.0 1.0 xfail-rounding
 cpow 0.75 1.25 1.0 0.0
 cpow 0.75 1.25 0.0 1.0
 
+csin 0.0 0.0
+csin -0 0.0
+csin 0.0 -0
+csin -0 -0
+
+csin 0.75 1.25
+csin -2 -3
+
+csin 0.75 89.5
+csin 0.75 -89.5
+csin -0.75 89.5
+csin -0.75 -89.5
+csin 0.75 710.5
+csin 0.75 -710.5
+csin -0.75 710.5
+csin -0.75 -710.5
+csin 0.75 11357.25
+csin 0.75 -11357.25
+csin -0.75 11357.25
+csin -0.75 -11357.25
+
 csin 0.75 1e6
 csin 0.75 -1e6
 csin -0.75 1e6
 csin -0.75 -1e6
 
+csin 0x1p-149 180
+csin 0x1p-1074 1440
+csin 0x1p-16434 22730
+
+csinh 0.0 0.0
+csinh -0 0.0
+csinh 0.0 -0
+csinh -0 -0
+
+csinh 0.75 1.25
+csinh -2 -3
+
+csinh 89.5 0.75
+csinh -89.5 0.75
+csinh 89.5 -0.75
+csinh -89.5 -0.75
+csinh 710.5 0.75
+csinh -710.5 0.75
+csinh 710.5 -0.75
+csinh -710.5 -0.75
+csinh 11357.25 0.75
+csinh -11357.25 0.75
+csinh 11357.25 -0.75
+csinh -11357.25 -0.75
+
 csinh 1e6 0.75
 csinh -1e6 0.75
 csinh 1e6 -0.75
 csinh -1e6 -0.75
 
+csinh 180 0x1p-149
+csinh 1440 0x1p-1074
+csinh 22730 0x1p-16434
+
 csqrt 0 0
 csqrt 0 -0
 csqrt -0 0
diff --git a/math/libm-test.inc b/math/libm-test.inc
index ba8e8ff..cc86e3a 100644
--- a/math/libm-test.inc
+++ b/math/libm-test.inc
@@ -6382,11 +6382,6 @@ creal_test (void)
 
 static const struct test_c_c_data csin_test_data[] =
   {
-    TEST_c_c (csin, 0.0, 0.0, 0.0, 0.0),
-    TEST_c_c (csin, minus_zero, 0.0, minus_zero, 0.0),
-    TEST_c_c (csin, 0.0, minus_zero, 0, minus_zero),
-    TEST_c_c (csin, minus_zero, minus_zero, minus_zero, minus_zero),
-
     TEST_c_c (csin, 0.0, plus_infty, 0.0, plus_infty),
     TEST_c_c (csin, minus_zero, plus_infty, minus_zero, plus_infty),
     TEST_c_c (csin, 0.0, minus_infty, 0.0, minus_infty),
@@ -6432,40 +6427,6 @@ static const struct test_c_c_data csin_test_data[] =
 
     TEST_c_c (csin, qnan_value, qnan_value, qnan_value, qnan_value),
 
-    TEST_c_c (csin, 0.75L, 1.25L, 1.28722291002649188575873510790565441L, 1.17210635989270256101081285116138863L),
-    TEST_c_c (csin, -2, -3, -9.15449914691142957346729954460983256L, 4.16890695996656435075481305885375484L),
-
-    TEST_c_c (csin, 0.75, 89.5, 2.522786001038096774676288412995370563339e38L, 2.708024460708609732016532185663087200560e38L),
-    TEST_c_c (csin, 0.75, -89.5, 2.522786001038096774676288412995370563339e38L, -2.708024460708609732016532185663087200560e38L),
-    TEST_c_c (csin, -0.75, 89.5, -2.522786001038096774676288412995370563339e38L, 2.708024460708609732016532185663087200560e38L),
-    TEST_c_c (csin, -0.75, -89.5, -2.522786001038096774676288412995370563339e38L, -2.708024460708609732016532185663087200560e38L),
-
-#ifndef TEST_FLOAT
-    TEST_c_c (csin, 0.75, 710.5, 1.255317763348154410745082950806112487736e308L, 1.347490911916428129246890157395342279438e308L),
-    TEST_c_c (csin, 0.75, -710.5, 1.255317763348154410745082950806112487736e308L, -1.347490911916428129246890157395342279438e308L),
-    TEST_c_c (csin, -0.75, 710.5, -1.255317763348154410745082950806112487736e308L, 1.347490911916428129246890157395342279438e308L),
-    TEST_c_c (csin, -0.75, -710.5, -1.255317763348154410745082950806112487736e308L, -1.347490911916428129246890157395342279438e308L),
-#endif
-
-#if defined TEST_LDOUBLE && LDBL_MAX_EXP >= 16384
-    TEST_c_c (csin, 0.75, 11357.25, 8.385498349388321535962327491346664141020e4931L, 9.001213196851067077465606717616495588201e4931L),
-    TEST_c_c (csin, 0.75, -11357.25, 8.385498349388321535962327491346664141020e4931L, -9.001213196851067077465606717616495588201e4931L),
-    TEST_c_c (csin, -0.75, 11357.25, -8.385498349388321535962327491346664141020e4931L, 9.001213196851067077465606717616495588201e4931L),
-    TEST_c_c (csin, -0.75, -11357.25, -8.385498349388321535962327491346664141020e4931L, -9.001213196851067077465606717616495588201e4931L),
-#endif
-
-#ifdef TEST_FLOAT
-    TEST_c_c (csin, 0x1p-149, 180, 1.043535896672617552965983803453927655332e33L, plus_oflow, OVERFLOW_EXCEPTION),
-#endif
-
-#if defined TEST_DOUBLE || (defined TEST_LDOUBLE && LDBL_MAX_EXP == 1024)
-    TEST_c_c (csin, 0x1p-1074, 1440, 5.981479269486130556466515778180916082415e301L, plus_oflow, OVERFLOW_EXCEPTION),
-#endif
-
-#if defined TEST_LDOUBLE && LDBL_MAX_EXP >= 16384
-    TEST_c_c (csin, 0x1p-16434L, 22730, 1.217853148905605987081057582351152052687e4924L, plus_oflow, OVERFLOW_EXCEPTION),
-#endif
-
     AUTO_TESTS_c_c (csin),
 
     TEST_c_c (csin, min_subnorm_value, min_value, min_subnorm_value, min_value, UNDERFLOW_EXCEPTION),
@@ -6481,11 +6442,6 @@ csin_test (void)
 
 static const struct test_c_c_data csinh_test_data[] =
   {
-    TEST_c_c (csinh, 0.0, 0.0, 0.0, 0.0),
-    TEST_c_c (csinh, minus_zero, 0.0, minus_zero, 0.0),
-    TEST_c_c (csinh, 0.0, minus_zero, 0.0, minus_zero),
-    TEST_c_c (csinh, minus_zero, minus_zero, minus_zero, minus_zero),
-
     TEST_c_c (csinh, 0.0, plus_infty, 0.0, qnan_value, INVALID_EXCEPTION|IGNORE_ZERO_INF_SIGN),
     TEST_c_c (csinh, minus_zero, plus_infty, 0.0, qnan_value, INVALID_EXCEPTION|IGNORE_ZERO_INF_SIGN),
     TEST_c_c (csinh, 0.0, minus_infty, 0.0, qnan_value, INVALID_EXCEPTION|IGNORE_ZERO_INF_SIGN),
@@ -6531,40 +6487,6 @@ static const struct test_c_c_data csinh_test_data[] =
 
     TEST_c_c (csinh, qnan_value, qnan_value, qnan_value, qnan_value),
 
-    TEST_c_c (csinh, 0.75L, 1.25L, 0.259294854551162779153349830618433028L, 1.22863452409509552219214606515777594L),
-    TEST_c_c (csinh, -2, -3, 3.59056458998577995201256544779481679L, -0.530921086248519805267040090660676560L),
-
-    TEST_c_c (csinh, 89.5, 0.75, 2.708024460708609732016532185663087200560e38L, 2.522786001038096774676288412995370563339e38L),
-    TEST_c_c (csinh, -89.5, 0.75, -2.708024460708609732016532185663087200560e38L, 2.522786001038096774676288412995370563339e38L),
-    TEST_c_c (csinh, 89.5, -0.75, 2.708024460708609732016532185663087200560e38L, -2.522786001038096774676288412995370563339e38L),
-    TEST_c_c (csinh, -89.5, -0.75, -2.708024460708609732016532185663087200560e38L, -2.522786001038096774676288412995370563339e38L),
-
-#ifndef TEST_FLOAT
-    TEST_c_c (csinh, 710.5, 0.75, 1.347490911916428129246890157395342279438e308L, 1.255317763348154410745082950806112487736e308L),
-    TEST_c_c (csinh, -710.5, 0.75, -1.347490911916428129246890157395342279438e308L, 1.255317763348154410745082950806112487736e308L),
-    TEST_c_c (csinh, 710.5, -0.75, 1.347490911916428129246890157395342279438e308L, -1.255317763348154410745082950806112487736e308L),
-    TEST_c_c (csinh, -710.5, -0.75, -1.347490911916428129246890157395342279438e308L, -1.255317763348154410745082950806112487736e308L),
-#endif
-
-#if defined TEST_LDOUBLE && LDBL_MAX_EXP >= 16384
-    TEST_c_c (csinh, 11357.25, 0.75, 9.001213196851067077465606717616495588201e4931L, 8.385498349388321535962327491346664141020e4931L),
-    TEST_c_c (csinh, -11357.25, 0.75, -9.001213196851067077465606717616495588201e4931L, 8.385498349388321535962327491346664141020e4931L),
-    TEST_c_c (csinh, 11357.25, -0.75, 9.001213196851067077465606717616495588201e4931L, -8.385498349388321535962327491346664141020e4931L),
-    TEST_c_c (csinh, -11357.25, -0.75, -9.001213196851067077465606717616495588201e4931L, -8.385498349388321535962327491346664141020e4931L),
-#endif
-
-#ifdef TEST_FLOAT
-    TEST_c_c (csinh, 180, 0x1p-149, plus_oflow, 1.043535896672617552965983803453927655332e33L, OVERFLOW_EXCEPTION),
-#endif
-
-#if defined TEST_DOUBLE || (defined TEST_LDOUBLE && LDBL_MAX_EXP == 1024)
-    TEST_c_c (csinh, 1440, 0x1p-1074, plus_oflow, 5.981479269486130556466515778180916082415e301L, OVERFLOW_EXCEPTION),
-#endif
-
-#if defined TEST_LDOUBLE && LDBL_MAX_EXP >= 16384
-    TEST_c_c (csinh, 22730, 0x1p-16434L, plus_oflow, 1.217853148905605987081057582351152052687e4924L, OVERFLOW_EXCEPTION),
-#endif
-
     AUTO_TESTS_c_c (csinh),
 
     TEST_c_c (csinh, min_subnorm_value, min_value, min_subnorm_value, min_value, UNDERFLOW_EXCEPTION),

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]