Installing Valgrind

Prerequisites

Building valgrind requires the following ports to be installed:

Obtaining the Valgrind source

The current version of the Valgrind FreeBSD is maintained in a mercurial repository on bitbucket.org: https://bitbucket.org/stass/valgrind-freebsd

To check out the source:

hg clone https://bitbucket.org/stass/valgrind-freebsd

The old version is also available in the FreeBSD ports collection in devel/valgrind.

Building

sh autogen.sh
./configure
gmake
gmake install

TODO

FreeBSD tree

Task

HEAD

RELENG_7

RELENG_6

END() macros in src

done

r192760 needed

needed

kern.proc sysctls

done

done

needed

Valgrind src

  1. Exit with a suitable error message if the procfs sysctl aren't available. Valgrind currently exits with an obscure message.
  2. Test more syscalls which are disabled and implement the missing ones (rfork mainly, others to come).
  3. Push FreeBSD changes to upstream valgrind
  4. Fix exp-ptrcheck.
    • Details?
  5. Fix support for FreeBSD TLS
  6. Growable stack / SIGSEGV / kqueue signal delivery issue.
  7. ptrace handlers

Done

  1. Tested by Sandvine Incorporated: SYS_sched_get_priority_max, SYS_sched_get_priority_min, SYS_sched_rr_get_interval
  2. libVex doesn't know about atomic instructions, which are used heavilly in userland by threading primitives (libthr in primis) in order to implement locking mechanism. While a direct fix to libVex seems pretty much difficult, a short-circuit of atomic operations may be implemented and got in place for main libraries. Apparently 3.5.0 has atomic support

Valgrind (last edited 2013-10-24 05:52:23 by HirenPanchasara)