|
From: <sv...@va...> - 2006-01-19 03:52:23
|
Author: sewardj
Date: 2006-01-19 03:52:19 +0000 (Thu, 19 Jan 2006)
New Revision: 5558
Log:
Clever handling of partially defined equality does not work on
ppc32/64 at the moment. Make this test handle that whilst still
testing the facility on x86/amd64.
Added:
trunk/memcheck/tests/partiallydefinedeq.stderr.exp2
Modified:
trunk/memcheck/tests/partiallydefinedeq.c
Modified: trunk/memcheck/tests/partiallydefinedeq.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/memcheck/tests/partiallydefinedeq.c 2006-01-19 03:50:48 UTC (re=
v 5557)
+++ trunk/memcheck/tests/partiallydefinedeq.c 2006-01-19 03:52:19 UTC (re=
v 5558)
@@ -18,7 +18,7 @@
printf("bar\n");
}
=20
-
+static void bar ( void );
int main ( void )
{
=20
@@ -32,7 +32,7 @@
=20
int* pi1 =3D (int*)junk1;
int* pi2 =3D (int*)junk2;
-
+ bar();
// both words completely undefined. This should give an error.
foo(pi1,pi2, &hack);
=20
@@ -53,3 +53,13 @@
=20
return 0;
}
+
+// Note: on ppc32/64 the second call to foo() does give an error,
+// since the expensive EQ/NE scheme does not apply to the CmpORD
+// primops used by ppc.
+static void bar ( void )
+{
+#if defined(__powerpc__) || defined(__powerpc64__)
+ fprintf(stderr, "Currently running on ppc32/64: this test should give =
3 errors, not 2.\n");
+#endif
+}
Added: trunk/memcheck/tests/partiallydefinedeq.stderr.exp2
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/memcheck/tests/partiallydefinedeq.stderr.exp2 =
(rev 0)
+++ trunk/memcheck/tests/partiallydefinedeq.stderr.exp2 2006-01-19 03:52:=
19 UTC (rev 5558)
@@ -0,0 +1,19 @@
+
+Currently running on ppc32/64: this test should give 3 errors, not 2.
+Conditional jump or move depends on uninitialised value(s)
+ at 0x........: foo (partiallydefinedeq.c:15)
+ by 0x........: main (partiallydefinedeq.c:37)
+
+Conditional jump or move depends on uninitialised value(s)
+ at 0x........: foo (partiallydefinedeq.c:15)
+ by 0x........: main (partiallydefinedeq.c:45)
+
+Conditional jump or move depends on uninitialised value(s)
+ at 0x........: foo (partiallydefinedeq.c:15)
+ by 0x........: main (partiallydefinedeq.c:52)
+
+ERROR SUMMARY: 3 errors from 3 contexts (suppressed: 0 from 0)
+malloc/free: in use at exit: 8 bytes in 2 blocks.
+malloc/free: 2 allocs, 0 frees, 8 bytes allocated.
+For a detailed leak analysis, rerun with: --leak-check=3Dyes
+For counts of detected errors, rerun with: -v
|