source: general/prog/valgrind.xml@ b112f043

11.3 12.0 12.1 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts lazarus lxqt plabs/newcss python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition trunk xry111/llvm18 xry111/xf86-video-removal
Last change on this file since b112f043 was 3f2db3a6, checked in by Pierre Labastie <pierre.labastie@…>, 18 months ago

Remove sect1info tags

They only contain a date tag that is nowhere used.

  • Property mode set to 100644
File size: 11.5 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY valgrind-download-http "https://sourceware.org/pub/valgrind/valgrind-&valgrind-version;.tar.bz2">
8 <!ENTITY valgrind-download-ftp "ftp://sourceware.org/pub/valgrind/valgrind-&valgrind-version;.tar.bz2">
9 <!ENTITY valgrind-md5sum "e3ca8e03c6c527e80e7da5135a1b6beb">
10 <!ENTITY valgrind-size "16 MB">
11 <!ENTITY valgrind-buildsize "381 MB (add 66 MB for tests)">
12 <!ENTITY valgrind-time "0.5 SBU (Using parallelism=4; add 8.1 SBU for tests)">
13]>
14
15<sect1 id="valgrind" xreflabel="Valgrind-&valgrind-version;">
16 <?dbhtml filename="valgrind.html"?>
17
18
19 <title>Valgrind-&valgrind-version;</title>
20
21 <indexterm zone="valgrind">
22 <primary sortas="a-Valgrind">Valgrind</primary>
23 </indexterm>
24
25 <sect2 role="package">
26 <title>Introduction to Valgrind</title>
27
28 <para>
29 <application>Valgrind</application> is an instrumentation framework for
30 building dynamic analysis tools. There are Valgrind tools that can
31 automatically detect many memory management and threading bugs, and
32 profile programs in detail. Valgrind can also be used to build new
33 tools.
34 </para>
35
36 &lfs112_checked;
37
38 <bridgehead renderas="sect3">Package Information</bridgehead>
39 <itemizedlist spacing="compact">
40 <listitem>
41 <para>
42 Download (HTTP): <ulink url="&valgrind-download-http;"/>
43 </para>
44 </listitem>
45 <listitem>
46 <para>
47 Download (FTP): <ulink url="&valgrind-download-ftp;"/>
48 </para>
49 </listitem>
50 <listitem>
51 <para>
52 Download MD5 sum: &valgrind-md5sum;
53 </para>
54 </listitem>
55 <listitem>
56 <para>
57 Download size: &valgrind-size;
58 </para>
59 </listitem>
60 <listitem>
61 <para>
62 Estimated disk space required: &valgrind-buildsize;
63 </para>
64 </listitem>
65 <listitem>
66 <para>
67 Estimated build time: &valgrind-time;
68 </para>
69 </listitem>
70 </itemizedlist>
71<!--
72 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
73 <itemizedlist spacing="compact">
74 <listitem>
75 <para>
76 Required patch:
77 <ulink url="&patch-root;/valgrind-&valgrind-version;-upstream_fixes-1.patch"/>
78 </para>
79 </listitem>
80 </itemizedlist>
81-->
82 <bridgehead renderas="sect3">Valgrind Dependencies</bridgehead>
83
84 <bridgehead renderas="sect4">Optional</bridgehead>
85 <para role="optional">
86 <xref linkend="gdb"/> (for tests),
87 <xref linkend="llvm"/> (with Clang), and
88 <xref linkend="which"/> (for tests)
89 </para>
90
91<!-- See "maintainer note", below
92 <bridgehead renderas="sect4">Optional for regenerating the documentation</bridgehead>
93 <para role="optional">
94 <xref linkend="libxslt"/> and
95 <xref linkend="texlive"/> (or <xref linkend="tl-installer"/>)
96 </para>
97-->
98 <para condition="html" role="usernotes">User Notes:
99 <ulink url="&blfs-wiki;/valgrind"/>
100 </para>
101 </sect2>
102
103 <sect2 role="installation">
104 <title>Installation of Valgrind</title>
105<!--
106 <para>
107 First, make several changes that are required for Valgrind to function on
108 systems with glibc-2.35 installed:
109 </para>
110
111<screen><userinput remap="pre">patch -Np1 -i ../valgrind-&valgrind-version;-upstream_fixes-1.patch</userinput></screen>
112-->
113
114 <para>
115 Install <application>Valgrind</application> by running the following
116 commands:
117 </para>
118
119<screen><userinput>sed -i 's|/doc/valgrind||' docs/Makefile.in &amp;&amp;
120
121./configure --prefix=/usr \
122 --datadir=/usr/share/doc/valgrind-&valgrind-version; &amp;&amp;
123make</userinput></screen>
124
125 <para>
126 To test the results, issue: <command>make regtest</command>. The tests
127 may hang forever if <xref linkend="gdb"/> is not installed. Some tests
128 are known to hang also, depending on the version of glibc. A few tests
129 can fail in various suites. Problematic
130 tests can be disabled by changing the <userinput>prereq:</userinput> line
131 in the corresponding <filename>.vgtest</filename> file to
132 <userinput>prereq: false</userinput>. For example:
133 </para>
134
135<screen role="nodump"><userinput>sed -e 's@prereq:.*@prereq: false@' \
136 -i {helgrind,drd}/tests/pth_cond_destroy_busy.vgtest</userinput></screen>
137
138 <!-- 731 tests, 6 stderr failures, 0 stdout failures, 1 stderrB failure,
139 0 stdoutB failures, 1 post failure -bdubbs Apr 13. 22
140 valgrind-3.19.0
141
142 732 tests, 4 stderr failures, 0 stdout failures, 1 stderrB failure,
143 0 stdoutB failures, 1 post failure - bdubbs Oct 26, 22
144 gdbserver_tests/hginfo (stderrB)
145 memcheck/tests/cdebug_zlib_gnu (stderr)
146 memcheck/tests/overlap (stderr)
147 helgrind/tests/tls_threads (stderr)
148 drd/tests/pth_mutex_signal (stderr) -->
149
150 <note>
151 <para>
152 The <application>OpenMP</application> tests are skipped if libgomp
153 has been compiled with <option>--enable-linux-futex</option> (the
154 default). If needed, just recompile the libgomp library from
155 the gcc build tree, passing <option>--disable-linux-futex</option>
156 to configure, storing the library to some place and changing the link
157 from <filename>/usr/lib/libgomp.so.1</filename> to point to the new
158 library.
159 </para>
160 </note>
161
162<!-- Note to maintainer: there is a long thread in ticket #5882 explaining
163 why we do not provide instructions to rebuild the documentation.
164 (still broken with TeXLive 2016) -->
165
166 <para>
167 Now, as the <systemitem class="username">root</systemitem> user:
168 </para>
169
170<screen role="root"><userinput>make install</userinput></screen>
171
172 </sect2>
173
174 <sect2 role="commands">
175 <title>Command Explanations</title>
176
177 <para>
178 <command>sed -i ... docs/Makefile.in </command>: This sed provides for
179 installing the documentation in a versioned directory.
180 </para>
181
182 <para>
183 <option>--enable-lto=yes</option>: This option allows building Valgrind
184 with LTO (link time optimization). This produces a smaller/faster
185 Valgrind (up to 10%), but build time increases to about 5.5 SBU.
186 </para>
187
188 </sect2>
189
190 <sect2 role="content">
191 <title>Contents</title>
192
193 <segmentedlist>
194 <segtitle>Installed Programs</segtitle>
195 <segtitle>Installed Libraries</segtitle>
196 <segtitle>Installed Directories</segtitle>
197
198 <seglistitem>
199 <seg>
200 callgrind_annotate,
201 callgrind_control,
202 cg_annotate,
203 cg_diff,
204 cg_merge,
205 ms_print,
206 valgrind,
207 valgrind-di-server,
208 valgrind-listener, and
209 vgdb
210 </seg>
211 <seg>
212 None
213 </seg>
214 <seg>
215 /usr/lib/valgrind,
216 /usr/libexec/valgrind,
217 /usr/include/valgrind, and
218 /usr/share/doc/valgrind-&valgrind-version;
219 </seg>
220 </seglistitem>
221 </segmentedlist>
222
223 <variablelist>
224 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
225 <?dbfo list-presentation="list"?>
226 <?dbhtml list-presentation="table"?>
227
228 <varlistentry id="valgrind-prog">
229 <term><command>valgrind</command></term>
230 <listitem>
231 <para>
232 is a program for debugging and profiling Linux executables
233 </para>
234 <indexterm zone="valgrind valgrind-prog">
235 <primary sortas="b-valgrind">valgrind</primary>
236 </indexterm>
237 </listitem>
238 </varlistentry>
239
240 <varlistentry id="callgrind_annotate">
241 <term><command>callgrind_annotate</command></term>
242 <listitem>
243 <para>
244 takes an output file produced by the
245 <application>Valgrind</application> tool Callgrind and prints the
246 information in an easy-to-read form
247 </para>
248 <indexterm zone="valgrind callgrind_annotate">
249 <primary sortas="b-callgrind_annotate">callgrind_annotate</primary>
250 </indexterm>
251 </listitem>
252 </varlistentry>
253
254 <varlistentry id="callgrind_control">
255 <term><command>callgrind_control</command></term>
256 <listitem>
257 <para>
258 controls programs being run by the <application>Valgrind</application>
259 tool Callgrind
260 </para>
261 <indexterm zone="valgrind callgrind_control">
262 <primary sortas="b-callgrind_control">callgrind_control</primary>
263 </indexterm>
264 </listitem>
265 </varlistentry>
266
267 <varlistentry id="cg_annotate">
268 <term><command>cg_annotate</command></term>
269 <listitem>
270 <para>
271 is a post-processing tool for the <application>Valgrind</application>
272 tool Cachegrind
273 </para>
274 <indexterm zone="valgrind cg_annotate">
275 <primary sortas="b-cg_annotate">cg_annotate</primary>
276 </indexterm>
277 </listitem>
278 </varlistentry>
279
280 <varlistentry id="cg_diff">
281 <term><command>cg_diff</command></term>
282 <listitem>
283 <para>
284 compares two Cachegrind output files
285 </para>
286 <indexterm zone="valgrind cg_diff">
287 <primary sortas="b-cg_diff">cg_diff</primary>
288 </indexterm>
289 </listitem>
290 </varlistentry>
291
292 <varlistentry id="cg_merge">
293 <term><command>cg_merge</command></term>
294 <listitem>
295 <para>
296 merges multiple Cachegrind output files into one
297 </para>
298 <indexterm zone="valgrind cg_merge">
299 <primary sortas="b-cg_merge">cg_merge</primary>
300 </indexterm>
301 </listitem>
302 </varlistentry>
303
304 <varlistentry id="ms_print">
305 <term><command>ms_print</command></term>
306 <listitem>
307 <para>
308 takes an output file produced by the <application>Valgrind</application>
309 tool Massif and prints the information in an easy-to-read form
310 </para>
311 <indexterm zone="valgrind ms_print">
312 <primary sortas="b-ms_print">ms_print</primary>
313 </indexterm>
314 </listitem>
315 </varlistentry>
316
317 <varlistentry id="valgrind-di-server">
318 <term><command>valgrind-di-server</command></term>
319 <listitem>
320 <para>
321 is a server that reads debuginfo from objects stored on a
322 different machine
323 </para>
324 <indexterm zone="valgrind valgrind-di-server">
325 <primary sortas="b-valgrind-di-server">valgrind-di-server</primary>
326 </indexterm>
327 </listitem>
328 </varlistentry>
329
330 <varlistentry id="valgrind-listener">
331 <term><command>valgrind-listener</command></term>
332 <listitem>
333 <para>
334 listens on a socket for Valgrind commentary
335 </para>
336 <indexterm zone="valgrind valgrind-listener">
337 <primary sortas="b-valgrind-listener">valgrind-listener</primary>
338 </indexterm>
339 </listitem>
340 </varlistentry>
341
342 <varlistentry id="vgdb">
343 <term><command>vgdb</command></term>
344 <listitem>
345 <para>
346 is an intermediary between Valgrind and GDB or a shell
347 </para>
348 <indexterm zone="valgrind vgdb">
349 <primary sortas="b-vgdb">vgdb</primary>
350 </indexterm>
351 </listitem>
352 </varlistentry>
353
354 </variablelist>
355
356 </sect2>
357
358</sect1>
Note: See TracBrowser for help on using the repository browser.