|
From: Leif W. <lei...@gm...> - 2012-08-14 18:55:16
|
I want to signal a pthread condition variable without holding the associated mutex. DRD (correctly) flags this as an error, but I want to suppress the error. I'd like to do it with a client request like DRD_IGNORE_VAR. I tried putting this on the cond and the mutex, and the error is still reported. Using --gen-suppressions won't work because there are lots of different stacks that trigger this, and the optimizer, especially with -flto, messes with the function names in a different way each time we build. Is there any other way to suppress this error? I see ANNOTATE_CONDVAR_* but they are all no-ops. -- Cheers, Leif |
|
From: Julian S. <js...@ac...> - 2012-08-14 19:06:49
|
On Tuesday, August 14, 2012, Leif Walsh wrote: > I want to signal a pthread condition variable without holding the > associated mutex. Hmm, you really really want to do that and 110% understand the possible races that could result? I looked at a situation like this in NSPR some time back and found it extremely difficult to convince myself that the code was really safe. J |
|
From: Leif W. <lei...@gm...> - 2012-08-14 19:21:18
|
On Tue, Aug 14, 2012 at 2:55 PM, Julian Seward <js...@ac...> wrote: > Hmm, you really really want to do that and 110% understand the possible > races that could result? Yep, I really do want to do that. I really do not care about the race. I suppose I could switch to a semaphore or something and hope that makes it go away, but I would rather tell valgrind what I want than change my code to fit valgrind. > I looked at a situation like this in NSPR some > time back and found it extremely difficult to convince myself that the > code was really safe. > > J -- Cheers, Leif |
|
From: Julian S. <js...@ac...> - 2012-08-14 19:57:27
|
On Tuesday, August 14, 2012, Leif Walsh wrote: > because there are lots of different stacks that trigger this, and the > optimizer, especially with -flto, messes with the function names in a > different way each time we build. Does it mess with the names so much that you can't use the * and ? wildcards, and the ... frame level wildcard, to reduce the number of suppressions to a manageable number? J |
|
From: Leif W. <lei...@gm...> - 2012-08-14 20:07:49
|
This may work, I forgot you could use wildcards in function names. I'll come back if it doesn't. On Tue, Aug 14, 2012 at 3:46 PM, Julian Seward <js...@ac...> wrote: > On Tuesday, August 14, 2012, Leif Walsh wrote: >> because there are lots of different stacks that trigger this, and the >> optimizer, especially with -flto, messes with the function names in a >> different way each time we build. > > Does it mess with the names so much that you can't use the * and ? > wildcards, and the ... frame level wildcard, to reduce the number of > suppressions to a manageable number? > > J -- Cheers, Leif |