FreeBSD 9.0: Valgrind leaks memory

Slawa Olhovchenkov slw at zxy.spb.ru
Fri Mar 16 17:15:03 UTC 2012


On Fri, Mar 16, 2012 at 01:23:48PM +0200, Ina J. wrote:

> Hi,
> 
> I tried to find a thread about this, but I didn't and in this
> thread<http://forums.freebsd.org/showthread.php?t=16468>trasz
> suggested to send message to the mailing list.


http://valgrind.org/docs/manual/dist.readme-packagers.html

-- Do not ship your Linux distro with a completely stripped
   /lib/ld.so.  At least leave the debugging symbol names on -- line
   number info isn't necessary.  If you don't want to leave symbols on
   ld.so, alternatively you can have your distro install ld.so's
   debuginfo package by default, or make ld.so.debuginfo be a
   requirement of your Valgrind RPM/DEB/whatever.

   Reason for this is that Valgrind's Memcheck tool needs to intercept
   calls to, and provide replacements for, some symbols in ld.so at
   startup (most importantly strlen).  If it cannot do that, Memcheck
   shows a large number of false positives due to the highly optimised
   strlen (etc) routines in ld.so.  This has caused some trouble in
   the past.  As of version 3.3.0, on some targets (ppc32-linux,
   ppc64-linux), Memcheck will simply stop at startup (and print an
   error message) if such symbols are not present, because it is
   infeasible to continue.

   It's not like this is going to cost you much space.  We only need
   the symbols for ld.so (a few K at most).  Not the debug info and
   not any debuginfo or extra symbols for any other libraries.


More information about the freebsd-stable mailing list