|
From: Stefan K. <en...@ho...> - 2010-07-08 09:09:31
|
On 08.07.2010 11:34, Konstantin Serebryany wrote:
> --tool=helgrind
>
Nope. helgrind does not complain. Does it run cycle checks on-the-fly?
Or how would it detect that the app deadlocked. I was thinking of
writing a LD_PRELOAD based toy, there I would ctrl-c the app and then
run the cycle checks and dump the results. I have found no evidence in
the docs that I can signal helgrind to tell that the app has no deadlocked.
Stefan
> On Thu, Jul 8, 2010 at 12:30 PM, Stefan Kost <en...@ho...> wrote:
>
>> hi,
>>
>> is anyone aware of a valgrind tool that can help me to debug a deadlock
>> in a highly threaded program. The programm can easily create hundreds of
>> threads.
>> What I am locking for is a tool that tracks for each thread which
>> mutexes are locked (incl. the strackframe of the lock) and if it is
>> waiting on a mutex (also including the stackframe). When the app
>> deadlocks, the collected data can be represented as a directed graph
>> ("thread -> mutex" for a held lock and "mutex -> thread" for a pending
>> lock) and one could run Tarjan's strongly connected components algorithm
>> [1][2] to detect cycles. For each found cycle it could print the
>> involved threads with the backtraces.
>>
>> Stefan
>>
>>
>> [1]
>> http://en.wikipedia.org/wiki/Tarjan%E2%80%99s_strongly_connected_components_algorithm
>> [2] http://www.logarithmic.net/pfh/blog/01208083168
>>
>> ------------------------------------------------------------------------------
>> This SF.net email is sponsored by Sprint
>> What will you do first with EVO, the first 4G phone?
>> Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
>> _______________________________________________
>> Valgrind-users mailing list
>> Val...@li...
>> https://lists.sourceforge.net/lists/listinfo/valgrind-users
>>
>>
>>
>>
> ------------------------------------------------------------------------------
> This SF.net email is sponsored by Sprint
> What will you do first with EVO, the first 4G phone?
> Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
> _______________________________________________
> Valgrind-users mailing list
> Val...@li...
> https://lists.sourceforge.net/lists/listinfo/valgrind-users
>
|