|
From: Philippe W. <phi...@sk...> - 2009-05-06 20:38:52
|
The default value for leak-resolution is set to low. The default value for the nr of callers in a stack trace is 12 (so significantly higher than the 2 entries corresponding to the medium leak resolution). When a leak is reported, it is reported with a full stack trace (e.g. 12 callers) but this report "merges" the leaks created by various other stack traces only having the first 2 callers in common. At work, this has created confusion (and some doubts about the tool behaviour/quality) e.g. because "this stack trace is only called once and allocates only one block, how can it leak that much blocks ?" or "I fixed the only leak(s) reported, and now I have other leaks being reported in other stack traces." It looks to me that leak-resolution=high will be a better default as it will not confuse users. If a user really needs to combine various stack traces in one stack trace, then resolution low or medium can then be given. NB: due to this confusion, at work, we switched to leak-resolution=high, triggering a quadratic behaviour in the leak report code. This bug #191182 has been fixed in 3.5.0 SVN. To my knowledge, other leak search tools (purify, wdb) always report full stack traces for leaks (or at least according to the num-callers equivalent). => I believe default value high resolution is better. NB: I believe the valgrind user manual description of leak-resolution wrongly says the default value for the nr of callers is 4 (I think it is 12). |