|
From: Peter T. <pt...@li...> - 2011-11-24 17:06:49
|
On Thu, 24 Nov 2011 14:25:57 +0100, Julian Seward wrote: > On Thursday, November 24, 2011, Peter Toft wrote: >> Since my problem happens very seldom, one follow-up question is whether I can combine --tool=memtool and --tool=drd in one run? > No, you can't. But note: it might be that the problem occurs all the time (a race of some kind, for example) but that you only ever observe its effect via memcheck very seldom. So it might be that Helgrind or DRD can tell you something about it even in the 99.whatever% of cases that you think the problem does not occur in. (this is only a guess, btw ..) J He he - life is evil. I find that Helgrind and DRD reports the same - and I see the problems very very seldom (similar to memtool) , ==4698== drd, a thread error detector ==4698== Copyright (C) 2006-2010, and GNU GPL'd, by Bart Van Assche. ==4698== Using Valgrind-3.6.0 and LibVEX; rerun with -h for copyright info ==4698== Command: ./mem2 ==4698== ==4698== Destroying locked mutex: mutex 0x4fc0808, recursion count 1, owner 3. ==4698== at 0x490B014: pthread_mutex_destroy (drd_pthread_intercepts.c:569) ... ==4698== by 0x3F05C333A4: exit (in /lib64/libc-2.5.so) ==4698== by 0x3F05C1D99A: (below main) (in /lib64/libc-2.5.so) ==4698== mutex 0x4fc0808 was first observed at: ==4698== at 0x490AA8D: pthread_mutex_init (drd_pthread_intercepts.c:546) I must admit, that my insights to multi-threaded programming is too sloppy to tell how bad this is. Comments are welcome... -- Peter Toft, PhD http://petertoft.dk |