|
From: Philippe W. <phi...@sk...> - 2013-05-18 16:51:29
|
On Sat, 2013-05-18 at 12:05 +0200, Martin Richtarsky wrote: > Hi all, > > we use valgrind on some long-running tests consisting of many testcases. > Currently it is hard to find out what testcase caused a memory leak: A > developer who fixes a leak basically has to run the complete test to make > sure he fixed it. It would be helpful to see the allocation time for the > memory chunk that leaked so it can be corelated to the testcase that ran > at that time. At work, we have the same case : a big application, made of several processes, running several thousands of tests. To associate bugs and/or leaks to tests in each process, the test driver instructs each process to do a leak search at the end of each test. In our case, this is done using a shell script launching vgdb --pid=<processpid> leak_check full increased to see the delta of definite and possibleleaks caused by this test. (this is also doable from your program, using e.g. the client requests VALGRIND_DO_ADDED_LEAK_CHECK). > > Also, if this patch is welcome, how should I contribute it? A bug report in bugzilla, with an explanation about why this is needed (which I am not sure of, cfr approach above, which e.g. does not have a limitation of 5 allocations :) Philippe |