|
From: <sv...@va...> - 2012-09-19 12:48:22
|
petarj 2012-09-19 13:48:09 +0100 (Wed, 19 Sep 2012)
New Revision: 13001
Log:
Another exp file for tc23_bogus_condwait.c.
struct pthread_mutex_t is different on MIPS32 and x86_64, and thus passing a
bogus mutex pthread_cond_wait (line 72) will corrupt memory in a different way
on two platforms. This causes the subsequent call to pthread_cond_wait to fail
on MIPS and i386 but not on x86_64.
This change fixes helgrind/tests/tc23_bogus_condwait on MIPS and i386.
Added files:
trunk/helgrind/tests/tc23_bogus_condwait.stderr.exp-mips32
Modified files:
trunk/helgrind/tests/Makefile.am
Modified: trunk/helgrind/tests/Makefile.am (+1 -0)
===================================================================
--- trunk/helgrind/tests/Makefile.am 2012-09-19 12:51:31 +01:00 (rev 13000)
+++ trunk/helgrind/tests/Makefile.am 2012-09-19 13:48:09 +01:00 (rev 13001)
@@ -91,6 +91,7 @@
tc22_exit_w_lock.stderr.exp-kfail-x86 \
tc23_bogus_condwait.vgtest tc23_bogus_condwait.stdout.exp \
tc23_bogus_condwait.stderr.exp \
+ tc23_bogus_condwait.stderr.exp-mips32 \
tc24_nonzero_sem.vgtest tc24_nonzero_sem.stdout.exp \
tc24_nonzero_sem.stderr.exp
Added: trunk/helgrind/tests/tc23_bogus_condwait.stderr.exp-mips32 (+64 -0)
===================================================================
--- trunk/helgrind/tests/tc23_bogus_condwait.stderr.exp-mips32 2012-09-19 12:51:31 +01:00 (rev 13000)
+++ trunk/helgrind/tests/tc23_bogus_condwait.stderr.exp-mips32 2012-09-19 13:48:09 +01:00 (rev 13001)
@@ -0,0 +1,64 @@
+
+---Thread-Announcement------------------------------------------
+
+Thread #x is the program's root thread
+
+----------------------------------------------------------------
+
+Thread #x: pthread_cond_{timed}wait called with invalid mutex
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:69)
+
+----------------------------------------------------------------
+
+Thread #x: pthread_cond_{timed}wait called with un-held mutex
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:72)
+
+----------------------------------------------------------------
+
+Thread #x: pthread_cond_{timed}wait: cond is associated with a different mutex
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:72)
+
+----------------------------------------------------------------
+
+Thread #x's call to pthread_cond_wait failed
+ with error code 22 (EINVAL: Invalid argument)
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:72)
+
+----------------------------------------------------------------
+
+Thread #x: pthread_cond_{timed}wait called with mutex of type pthread_rwlock_t*
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:75)
+
+----------------------------------------------------------------
+
+Thread #x: pthread_cond_{timed}wait: cond is associated with a different mutex
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:75)
+
+----------------------------------------------------------------
+
+Thread #x: pthread_cond_{timed}wait called with mutex held by a different thread
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:78)
+
+----------------------------------------------------------------
+
+Thread #x: pthread_cond_{timed}wait: cond is associated with a different mutex
+ at 0x........: pthread_cond_wait_WRK (hg_intercepts.c:...)
+ by 0x........: pthread_cond_wait@* (hg_intercepts.c:...)
+ by 0x........: main (tc23_bogus_condwait.c:78)
+
+
+ERROR SUMMARY: 8 errors from 8 contexts (suppressed: 0 from 0)
|