Valgrind and Welcome New Students: Difference between pages

From Computer Science at Indiana State University
(Difference between pages)
Jump to navigation Jump to search
m 1 revision imported
 
wiki_previous>Jkinne
 
Line 1: Line 1:
Note that <code>valgrind</code> is installed on cs.indstate.edu but not on all of the lab desktops, so make sure you are logged into cs in the terminal (e.g., <code>ssh username@cs.indstate.edu</code>).
#REDIRECT [[Welcome New Students (beginning of term)]]
 
First, you should make sure to compile your program with debugging information enabled.  See [[GNU Debugger]].  You can run the <code>valgrind</code> memory checker by running:
<pre>
valgrind program_file.o
</pre>
To see more detailed information about potential memory leaks, you can use the <code>--leak-check=full</code> option:
<pre>
valgrind --leak-check=full program_file.o
</pre>
 
More information about valgrind: https://valgrind.org/docs/manual/quick-start.html

Revision as of 01:25, 16 May 2022