|
From: Bruce M. <bm...@gm...> - 2010-12-05 20:40:50
|
On 5 December 2010 19:12, Michal <kor...@gm...> wrote: > Hi, > I've cloned your repo at http://www.brucemerry.org.za/git/datagrind/, > but am unable to find anything about datagrind in it. Apologies, I forgot to mention that it is in a 'datagrind' git branch (the master branch is upstream Valgrind 3.6.0); the tool is called 'exp-datagrind'. > Anyway, at work I often deal with reference counted memory management, > which unfortunately is not well supported by valgrind. In order to > debug memory leaks I've created a similar, but weaker, tool to yours > (http://gitorious.org/watchgrind/watchgrind). As you can see on every > memory write to specified addresses (such as object's reference count) > I dump stack trace. Unfortunately I can't use gdb for that, as most of > the applications are threaded and gdb's watchpoints don't like that. I haven't downloaded your tool yet so I'm not sure if it's really the same thing, but datagrind does store stack-trace information and when one clicks on an access it shows the stack trace of both the accessing instruction and the malloc that allocated the memory (if it came from malloc). > If your tool would support such scenario easily that would be nice :), > especially if (as opposed to my tool) it would correctly support > atomic instructions. Currently it doesn't do anything special for atomics - instructions that modify memory are just represented as a read and a write. It also doesn't implement the hooks necessary to track inputs and outputs of system calls. Bruce -- Dr Bruce Merry bmerry <@> gmail <.> com http://www.brucemerry.org.za/ http://blog.brucemerry.org.za/ |