<div dir="ltr">unless you're on an OS X machine, in which case you should use libgmalloc: <a href="http://developer.apple.com/documentation/Darwin/Reference/ManPages/man3/libgmalloc.3.html">http://developer.apple.com/documentation/Darwin/Reference/ManPages/man3/libgmalloc.3.html</a><br>
<br>~A<br><br><div class="gmail_quote">On Wed, Jul 23, 2008 at 2:25 PM, Barry Smith <<a href="mailto:bsmith@mcs.anl.gov">bsmith@mcs.anl.gov</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
To emphasis Satish's point you should definitely use <a href="http://www.valgrind.org" target="_blank">www.valgrind.org</a> to remove<br>
all the memory bugs before starting to use it with PETSc.<br>
<br>
valgrind is the closest thing to a magic bullet I have ever seen in computing.<br><font color="#888888">
<br>
Barry</font><div><div></div><div class="Wj3C7c"><br>
<br>
<br>
On Jul 23, 2008, at 1:04 PM, Satish Balay wrote:<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
On Wed, 23 Jul 2008, Paul T. Bauman wrote:<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hello,<br>
<br>
Quick (and probably stupid) question: Does CHKMEMQ check *all* of memory used<br>
by the program for corruption or just the memory PETSc allocated? I have a<br>
code that I'm assigned to work on that doesn't use PETSc (yet), but I was<br>
hoping to use this macro to track down what I think is a memory corruption<br>
bug.<br>
</blockquote>
<br>
CHKMEMQ checks memory allocated by PetscMalloc() - for<br>
out-of-bounds-write errors.<br>
<br>
Valgrind is a general tool for detecting many more types of memory<br>
corruption.<br>
<br>
Satish<br>
<br>
</blockquote>
<br>
</div></div></blockquote></div><br></div>