Linux Tools Project - Valgrind Support

Overview

Valgrind Launch Configuration Dialog

The Linux Tools Project Valgrind plugin aims to provide simple and effective profiling for the C/C++ Development Tools. There is an abundance of Valgrind functionality to expose in Eclipse. Valgrind itself is very component based and this relates well to Eclipse plugins. The main architectural goal is to have a common Valgrind user interface and underlying launch framework, while the Valgrind tools themselves are contributed via extension points. As with most tools in this project, the aim is to provide not just a user interface for the underlying tool. Instead, this project will attempt to exploit every opportunity to integrate into the Eclipse workbench to provide a unique and formidable user experience.


Extensibility


Memcheck

Memcheck is a tool that detects memory management problems. It is Valgrind's most popular tool and seemingly the most mature. Memcheck's output is rather straight forward - it is a series of errors along with stack trace information.
Using the Memcheck tool

Massif

Using the Massif tool Massif is a heap profiling tool. It takes several "snapshots" during execution of your program detailing the various heap allocations throughout. It's output for each snapshot primarily consists the time of the snapshot, how many bytes were allocated that can be used, and how much extra was allocated than was asked. The unit of time can be configured to be instructions, milliseconds or bytes. At specified intervals, "detailed" snapshots are produced. These detailed snapshots contain a tree of heap allocations that comprise that snapshot. Unlike Memcheck, Massif does not yet support XML output. Massif's output is complex and as such requires creative ways of displaying it. Valgrind includes the ms_print program that is used to display Massif's output in a visually appealing manner. ms_print was used as a template for how to display this output.

Cachegrind

Cachegrind performs cache and branching profiling. A Cachegrind profile run measures the number of cache misses and branch mispredictions performed by an application. The results of a Cachegrind profile run are displayed in the Valgrind view. These results show Cachegrind's cache/branch data in different levels of granularity.
Using the Cachegrind tool

Future Plans


Try it out

Please use our update site as described here.

Check out the source code from our Github repository