Valgrind is an open-source suite of dynamic analysis tools used mainly on Linux. It runs a program on a synthetic CPU and observes its behavior, so it can analyze executables without recompiling them.
Its tools include Memcheck, which detects memory leaks and invalid memory access, and Callgrind and Cachegrind, which count executed instructions and model cache behavior. Because instruction counts barely change between runs, they are also used as a stable basis for performance comparisons.