Module Name:    src
Committed By:   jruoho
Date:           Tue May 31 20:17:37 UTC 2011

Modified Files:
        src/tests/lib/libc/stdlib: t_strtod.c
        src/tests/lib/libm: t_infinity.c

Log Message:
Mark the following tests as expected failures on qemu/amd64: 'strtod_inf',
'strtod_round', and 'infinity_long_double'. None of these fail on any known
native host. Use the tracker PR misc/44767 as the reference point.


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/tests/lib/libc/stdlib/t_strtod.c
cvs rdiff -u -r1.1 -r1.2 src/tests/lib/libm/t_infinity.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/tests/lib/libc/stdlib/t_strtod.c
diff -u src/tests/lib/libc/stdlib/t_strtod.c:1.11 src/tests/lib/libc/stdlib/t_strtod.c:1.12
--- src/tests/lib/libc/stdlib/t_strtod.c:1.11	Fri May 20 21:42:49 2011
+++ src/tests/lib/libc/stdlib/t_strtod.c	Tue May 31 20:17:36 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: t_strtod.c,v 1.11 2011/05/20 21:42:49 nakayama Exp $ */
+/*	$NetBSD: t_strtod.c,v 1.12 2011/05/31 20:17:36 jruoho Exp $ */
 
 /*-
  * Copyright (c) 2011 The NetBSD Foundation, Inc.
@@ -32,7 +32,7 @@
 /* Public domain, Otto Moerbeek <o...@drijf.net>, 2006. */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: t_strtod.c,v 1.11 2011/05/20 21:42:49 nakayama Exp $");
+__RCSID("$NetBSD: t_strtod.c,v 1.12 2011/05/31 20:17:36 jruoho Exp $");
 
 #include <errno.h>
 #include <math.h>
@@ -115,8 +115,13 @@
 	float f;
 
 	/*
-	 * See old PR lib/33262.
+	 * See the closed PR lib/33262.
+	 *
+	 * This may also fail under QEMU; cf. PR misc/44767.
 	 */
+	if (system("cpuctl identify 0 | grep -q QEMU") == 0)
+		atf_tc_expect_fail("PR misc/44767");
+
 	d = strtod("INF", NULL);
 	ATF_REQUIRE(isinf(d) != 0);
 
@@ -143,9 +148,13 @@
 
 	/*
 	 * Test that strtod(3) honors the current rounding mode.
-	 *
 	 * The used value is somewhere near 1 + DBL_EPSILON + FLT_EPSILON.
+	 *
+	 * May fail under QEMU; cf. PR misc/44767.
 	 */
+	if (system("cpuctl identify 0 | grep -q QEMU") == 0)
+		atf_tc_expect_fail("PR misc/44767");
+
 	val = "1.00000011920928977282585492503130808472633361816406";
 
 	(void)fesetround(FE_UPWARD);

Index: src/tests/lib/libm/t_infinity.c
diff -u src/tests/lib/libm/t_infinity.c:1.1 src/tests/lib/libm/t_infinity.c:1.2
--- src/tests/lib/libm/t_infinity.c:1.1	Mon Apr 11 10:51:36 2011
+++ src/tests/lib/libm/t_infinity.c	Tue May 31 20:17:36 2011
@@ -1,4 +1,4 @@
-/* $NetBSD: t_infinity.c,v 1.1 2011/04/11 10:51:36 martin Exp $ */
+/* $NetBSD: t_infinity.c,v 1.2 2011/05/31 20:17:36 jruoho Exp $ */
 
 /*-
  * Copyright (c) 2002, 2008 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: t_infinity.c,v 1.1 2011/04/11 10:51:36 martin Exp $");
+__RCSID("$NetBSD: t_infinity.c,v 1.2 2011/05/31 20:17:36 jruoho Exp $");
 
 #include <atf-c.h>
 #include <math.h>
@@ -88,6 +88,14 @@
 
 ATF_TC_BODY(infinity_long_double, tc)
 {
+
+	/*
+	 * May fail under QEMU; cf. PR misc/44767.
+	 */
+	if (system("cpuctl identify 0 | grep -q QEMU") == 0)
+		atf_tc_expect_fail("PR misc/44767");
+
+
 #ifndef LDBL_MAX
 	atf_tc_skip("no long double support on this architecture");
 	return;

Reply via email to