#include <stdlib.h>
#include <unistd.h> // confstr()
#include "config.h"
+#include "drd_basics.h"
#include "drd_clientreq.h"
#include "pub_tool_redir.h"
tid, joinable, 0, 0, 0);
}
-static void* vg_thread_wrapper(void* arg)
+static void* DRD_(thread_wrapper)(void* arg)
{
int res;
/* Suppress NPTL-specific conflicts between creator and created thread. */
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__DRD_STOP_RECORDING,
0, 0, 0, 0, 0);
- CALL_FN_W_WWWW(ret, fn, thread, attr, vg_thread_wrapper, &vgargs);
+ CALL_FN_W_WWWW(ret, fn, thread, attr, DRD_(thread_wrapper), &vgargs);
VALGRIND_DO_CLIENT_REQUEST(res, -1, VG_USERREQ__DRD_START_RECORDING,
0, 0, 0, 0, 0);
#if 0
Thread 2:
Conflicting load by thread 2/3 at 0x........ size 4
at 0x........: thread_func_2 (atomic_var.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "s_y"
Thread 3:
Conflicting load by thread 3/3 at 0x........ size 4
at 0x........: thread_func_2 (atomic_var.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "s_y"
Thread 3:
Conflicting store by thread 3/3 at 0x........ size 4
at 0x........: t2 (hg03_inherit.c:28)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside shared[1],
Conflicting store by thread 3/3 at 0x........ size 4
at 0x........: t2 (hg03_inherit.c:29)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside shared[1],
Thread 2:
Conflicting load by thread 2/3 at 0x........ size 4
at 0x........: th (hg04_race.c:10)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "shared"
Conflicting store by thread 2/3 at 0x........ size 4
at 0x........: th (hg04_race.c:10)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "shared"
Thread 2:
Conflicting load by thread 2/3 at 0x........ size 4
at 0x........: th (hg05_race2.c:17)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside foo.poot[5].plop[11],
Conflicting store by thread 2/3 at 0x........ size 4
at 0x........: th (hg05_race2.c:17)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside foo.poot[5].plop[11],
Thread 2:
Conflicting load by thread 2/3 at 0x........ size 4
at 0x........: th (hg05_race2.c:17)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Allocation context: unknown.
Conflicting store by thread 2/3 at 0x........ size 4
at 0x........: th (hg05_race2.c:17)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Allocation context: unknown.
Probably a race condition: condition variable 0x........ has been signaled but the associated mutex 0x........ is not locked by the signalling thread.
at 0x........: pthread_cond_signal* (drd_pthread_intercepts.c:?)
by 0x........: thread_func (pth_cond_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
cond 0x........ was first observed at:
Emulation fatal error -- Valgrind cannot continue:
PPC64 function redirection stack overflow
at 0x........: ???
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Inconsistent association of condition variable and mutex: condition variable 0x........, mutexes 0x........ and 0x........
at 0x........: pthread_cond_wait* (drd_pthread_intercepts.c:?)
by 0x........: thread2 (pth_inconsistent_cond_wait.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
cond 0x........ was first observed at:
Inconsistent association of condition variable and mutex: condition variable 0x........, mutexes 0x........ and 0x........
at 0x........: pthread_cond_wait* (drd_pthread_intercepts.c:?)
by 0x........: thread1 (pth_inconsistent_cond_wait.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
cond 0x........ was first observed at:
Thread 3:
Conflicting load by thread 3/3 at 0x........ size 4
at 0x........: thread_func (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "s_racy"
Other segment start (thread 2/2)
at 0x........: pthread_rwlock_rdlock* (drd_pthread_intercepts.c:?)
by 0x........: thread_func (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Other segment end (thread 2/2)
at 0x........: pthread_rwlock_unlock* (drd_pthread_intercepts.c:?)
by 0x........: thread_func (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Conflicting store by thread 3/3 at 0x........ size 4
at 0x........: thread_func (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "s_racy"
Other segment start (thread 2/2)
at 0x........: pthread_rwlock_rdlock* (drd_pthread_intercepts.c:?)
by 0x........: thread_func (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Other segment end (thread 2/2)
at 0x........: pthread_rwlock_unlock* (drd_pthread_intercepts.c:?)
by 0x........: thread_func (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Result: 2
Thread 3:
Conflicting load by thread 3/3 at 0x........ size 4
at 0x........: thread (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "s_racy"
Conflicting store by thread 3/3 at 0x........ size 4
at 0x........: thread (rwlock_race.c:?)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Location 0x........ is 0 bytes inside local var "s_racy"
Mutex not locked by calling thread: mutex 0x........, recursion count 1, owner 1.
at 0x........: pthread_mutex_unlock (drd_pthread_intercepts.c:?)
by 0x........: child_fn (tc09_bad_unlock.c:11)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
mutex 0x........ was first observed at:
Mutex not locked by calling thread: mutex 0x........, recursion count 1, owner 1.
at 0x........: pthread_mutex_unlock (drd_pthread_intercepts.c:?)
by 0x........: child_fn (tc09_bad_unlock.c:11)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
mutex 0x........ was first observed at:
Mutex not locked by calling thread: mutex 0x........, recursion count 1, owner 1.
at 0x........: pthread_mutex_unlock (drd_pthread_intercepts.c:?)
by 0x........: child_fn (tc09_bad_unlock.c:11)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
mutex 0x........ was first observed at:
Mutex not locked by calling thread: mutex 0x........, recursion count 1, owner 1.
at 0x........: pthread_mutex_unlock (drd_pthread_intercepts.c:?)
by 0x........: child_fn (tc09_bad_unlock.c:11)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
mutex 0x........ was first observed at:
mutex 0x........ was first observed at:
at 0x........: pthread_mutex_lock (drd_pthread_intercepts.c:?)
by 0x........: child_fn1 (tc22_exit_w_lock.c:18)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
Probably a race condition: condition variable 0x........ has been signaled but the associated mutex 0x........ is not locked by the signalling thread.
at 0x........: pthread_cond_signal* (drd_pthread_intercepts.c:?)
by 0x........: rescue_me (tc23_bogus_condwait.c:20)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
cond 0x........ was first observed at:
Probably a race condition: condition variable 0x........ has been signaled but the associated mutex 0x........ is not locked by the signalling thread.
at 0x........: pthread_cond_signal* (drd_pthread_intercepts.c:?)
by 0x........: rescue_me (tc23_bogus_condwait.c:24)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
cond 0x........ was first observed at:
Probably a race condition: condition variable 0x........ has been signaled but the associated mutex 0x........ is not locked by the signalling thread.
at 0x........: pthread_cond_signal* (drd_pthread_intercepts.c:?)
by 0x........: rescue_me (tc23_bogus_condwait.c:28)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
cond 0x........ was first observed at:
Probably a race condition: condition variable 0x........ has been signaled but the associated mutex 0x........ is not locked by the signalling thread.
at 0x........: pthread_cond_signal* (drd_pthread_intercepts.c:?)
by 0x........: rescue_me (tc23_bogus_condwait.c:32)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
cond 0x........ was first observed at:
Mutex not locked by calling thread: mutex 0x........, recursion count 2, owner 1.
at 0x........: pthread_mutex_unlock (drd_pthread_intercepts.c:?)
by 0x........: grab_the_lock (tc23_bogus_condwait.c:42)
- by 0x........: vg_thread_wrapper (drd_pthread_intercepts.c:?)
+ by 0x........: vgDrd_thread_wrapper (drd_pthread_intercepts.c:?)
by 0x........: (within libpthread-?.?.so)
by 0x........: clone (in /...libc...)
mutex 0x........ was first observed at: