Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 Jul 2017 16:21:22 +0000 (UTC)
From:      Ngie Cooper <ngie@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r321484 - head/lib/msun/tests
Message-ID:  <201707251621.v6PGLMmg070737@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ngie
Date: Tue Jul 25 16:21:22 2017
New Revision: 321484
URL: https://svnweb.freebsd.org/changeset/base/321484

Log:
  Only test ld_pi_odd with LDBL_MANT_DIG == 64 to fix the build
  
  The empty (unimplemented) test inputs for sparc64 trigger a -Wtype-limits build
  failure because nitems of an empty array is always false, i.e., deadcode.
  
  MFC after:	1 month
  MFC with:	r321455
  Reported by:	Jenkins (sparc64 job)

Modified:
  head/lib/msun/tests/trig_test.c

Modified: head/lib/msun/tests/trig_test.c
==============================================================================
--- head/lib/msun/tests/trig_test.c	Tue Jul 25 16:11:36 2017	(r321483)
+++ head/lib/msun/tests/trig_test.c	Tue Jul 25 16:21:22 2017	(r321484)
@@ -156,11 +156,6 @@ ATF_TC_BODY(reduction, tc)
 		9.8477555741888350649e+4314L,
 		1.6061597222105160737e+4326L,
 	};
-#elif LDBL_MANT_DIG == 113
-	static const long double ld_pi_odd[] = {
-		/* XXX */
-	};
-#endif
 
 #if defined(__clang__) && \
 	((__clang_major__ >= 5))
@@ -205,7 +200,7 @@ ATF_TC_BODY(reduction, tc)
 		ATF_CHECK(fabs(tan(-d_pi_odd[i] * 2)) < 2 * DBL_EPSILON);
 	}
 
-#if LDBL_MANT_DIG > 53
+#if LDBL_MANT_DIG == 64 /* XXX: || LDBL_MANT_DIG == 113 */
 	for (i = 0; i < nitems(ld_pi_odd); i++) {
 		ATF_CHECK(fabsl(sinl(ld_pi_odd[i])) < LDBL_EPSILON);
 		ATF_CHECK(cosl(ld_pi_odd[i]) == -1.0);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201707251621.v6PGLMmg070737>