blob: f891f3ba8be88c0d897edb4f2e9483301c94eabd [file] [log] [blame]
sewardj14132a12007-11-22 01:07:57 +00001<?xml version="1.0"?> <!-- -*- sgml -*- -->
2<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
njnc46019e2009-08-07 04:07:20 +00003 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
4[ <!ENTITY % vg-entities SYSTEM "../../docs/xml/vg-entities.xml"> %vg-entities; ]>
sewardj14132a12007-11-22 01:07:57 +00005
6
njn8b68b642009-06-24 00:37:09 +00007<chapter id="design-impl"
sewardj14132a12007-11-22 01:07:57 +00008 xreflabel="The design and implementation of Valgrind">
9
10<title>The Design and Implementation of Valgrind</title>
11
12
13<para>A number of academic publications nicely describe many aspects
14of Valgrind's design and implementation. Online copies of all of
njnc46019e2009-08-07 04:07:20 +000015them, and others, are available on the <ulink url="&vg-pubs-url;">Valgrind
16publications page</ulink>.</para>
sewardj14132a12007-11-22 01:07:57 +000017
njnc46019e2009-08-07 04:07:20 +000018<para>The following paper gives a good overview of Valgrind, and explains
19how it differs from other dynamic binary instrumentation frameworks such as
20Pin and DynamoRIO.</para>
sewardj14132a12007-11-22 01:07:57 +000021
njnc46019e2009-08-07 04:07:20 +000022<itemizedlist>
23 <listitem>
24 <para>
25 <command>Valgrind: A Framework for Heavyweight Dynamic Binary
26 Instrumentation. Nicholas Nethercote and Julian Seward. Proceedings
27 of ACM SIGPLAN 2007 Conference on Programming Language Design and
28 Implementation (PLDI 2007), San Diego, California, USA, June
29 2007.</command>
30 </para>
31 </listitem>
32</itemizedlist>
sewardj14132a12007-11-22 01:07:57 +000033
34
njnc46019e2009-08-07 04:07:20 +000035<para>The following two papers together give a comprehensive description of
36how most of Memcheck works. The first paper describes in detail how
37Memcheck's undefined value error detection (a.k.a. V bits) works. The
38second paper describes in detail how Memcheck's shadow memory is
39implemented, and compares it to other alternative approaches.
40</para>
sewardj14132a12007-11-22 01:07:57 +000041
njnc46019e2009-08-07 04:07:20 +000042<itemizedlist>
43 <listitem>
44 <para><command>Using Valgrind to detect undefined value errors with
45 bit-precision. Julian Seward and Nicholas Nethercote. Proceedings
46 of the USENIX'05 Annual Technical Conference, Anaheim, California,
47 USA, April 2005.</command>
48 </para>
sewardj14132a12007-11-22 01:07:57 +000049
njnc46019e2009-08-07 04:07:20 +000050 <para><command>How to Shadow Every Byte of Memory Used by a Program.
51 Nicholas Nethercote and Julian Seward. Proceedings of the Third
52 International ACM SIGPLAN/SIGOPS Conference on Virtual Execution
53 Environments (VEE 2007), San Diego, California, USA, June
54 2007.</command>
55 </para>
56 </listitem>
57</itemizedlist>
sewardj14132a12007-11-22 01:07:57 +000058
59
njnc46019e2009-08-07 04:07:20 +000060<para>The following paper describes Callgrind.</para>
sewardj14132a12007-11-22 01:07:57 +000061
njnc46019e2009-08-07 04:07:20 +000062<itemizedlist>
63 <listitem>
64 <para><command>A Tool Suite for Simulation Based Analysis of Memory Access
65 Behavior. Josef Weidendorfer, Markus Kowarschik and Carsten
66 Trinitis. Proceedings of the 4th International Conference on
67 Computational Science (ICCS 2004), Krakow, Poland, June 2004.</command>
68 </para>
69 </listitem>
70</itemizedlist>
sewardj14132a12007-11-22 01:07:57 +000071
72<para>The following dissertation describes Valgrind in some detail
njnc46019e2009-08-07 04:07:20 +000073(many of these details are now out-of-date) as well as Cachegrind,
sewardj14132a12007-11-22 01:07:57 +000074Annelid and Redux. It also covers some underlying theory about
75dynamic binary analysis in general and what all these tools have in
njnc46019e2009-08-07 04:07:20 +000076common.</para>
sewardj14132a12007-11-22 01:07:57 +000077
njnc46019e2009-08-07 04:07:20 +000078<itemizedlist>
79 <listitem>
80 <para><command>Dynamic Binary Analysis and Instrumentation. Nicholas
81 Nethercote.</command> PhD Dissertation, University of Cambridge, November
82 2004.</para>
83 </listitem>
84</itemizedlist>
sewardj14132a12007-11-22 01:07:57 +000085
86
87</chapter>