Philippe Waroquiers e2ba2f3671 add heuristics decreasing false possible "possible leaks" in c++ code.
The option --leak-check-heuristics=heur1,heur2,... can activate
various heuristics to decrease the number of false positive
"possible leaks" for C++ code. The available heuristics are
detecting valid interior pointers to std::stdstring, to new[] allocated
arrays with elements having destructors and to interior pointers pointing
to an inner part of a C++ object using multiple inheritance.

This fixes 280271 Valgrind reports possible memory leaks on still-reachable
std::string 

This has been tested on x86/amd64/ppc32/ppc64.

First performance measurements seems to show a neglectible impact on
the leak search.

More feedback welcome both on performance and functional aspects
(false positive 'possibly leaked' rate decrease and/or 
false negative 'possibly leaked' rate increase).

Note that the heuristic is not checking that the memory has been
allocated with "new" or "new[]", as it is expected that in some cases,
specific alloc fn are used for c++ objects instead of the standard new/new[].
If needed, we might add an option to check the alloc functions
to be new/new[].



git-svn-id: svn://svn.valgrind.org/valgrind/trunk@13582
2013-09-29 13:47:32 +00:00
..
2012-10-15 14:21:22 +00:00
2009-08-12 00:14:44 +00:00
2009-08-12 00:14:44 +00:00
2009-08-12 00:14:44 +00:00
2003-07-13 22:35:55 +00:00
2011-10-04 03:55:04 +00:00
2011-10-04 03:55:04 +00:00
2006-10-17 01:26:12 +00:00
2009-08-12 00:14:44 +00:00
2011-06-26 12:41:33 +00:00
2011-06-26 12:41:33 +00:00
2011-06-26 12:41:33 +00:00
2012-12-08 17:54:16 +00:00
2012-12-08 17:54:16 +00:00
2012-12-08 17:54:16 +00:00
2012-12-08 17:54:16 +00:00
2006-10-17 01:26:12 +00:00
2006-10-17 01:26:12 +00:00
2004-06-19 18:12:36 +00:00
2006-03-08 13:24:21 +00:00
2009-05-29 00:52:17 +00:00
2003-10-09 15:40:38 +00:00
2003-10-09 15:40:38 +00:00
2004-04-13 19:11:27 +00:00
2004-04-13 19:11:27 +00:00
2005-09-24 19:42:41 +00:00
2005-09-24 19:42:41 +00:00
2005-09-24 19:42:41 +00:00
2013-03-01 23:05:43 +00:00
2006-01-19 03:56:33 +00:00
2009-06-24 04:40:22 +00:00
2006-01-19 03:56:33 +00:00
2012-03-27 09:39:22 +00:00
2012-10-28 20:26:04 +00:00
2008-03-03 01:35:41 +00:00
2008-03-03 01:35:41 +00:00
2008-03-03 01:35:41 +00:00
2008-03-03 01:35:41 +00:00
2008-03-03 01:35:41 +00:00
2008-03-03 01:35:41 +00:00
2006-01-20 16:47:20 +00:00
2006-01-20 16:47:20 +00:00
2006-01-20 16:47:20 +00:00
2006-01-20 14:21:28 +00:00
2006-01-20 14:21:28 +00:00
2006-01-20 14:21:28 +00:00
2006-01-20 14:21:28 +00:00
2006-01-20 14:21:28 +00:00
2006-01-20 14:21:28 +00:00
2005-05-24 14:46:02 +00:00