[mpich-discuss] Questions about using valgrind

Yauheni Zelenko zelenko at cadence.com
Thu Feb 17 14:58:01 CST 2011


Hi, Saurabh!

Do you want to instrument your application or MPICH2 stuff?

For first, you need to run mpiexec valgrind --log-file=Valgrind.log.%p exec.

For second you could use:

valgrind --trace-children=yes --log-file=Valgrind.log.%p mpiexec exec

Please not how to separate log files for your processes.

Eugene.
________________________________________
From: mpich-discuss-bounces at mcs.anl.gov [mpich-discuss-bounces at mcs.anl.gov] On Behalf Of Saurabh T [saurabh at hotmail.com]
Sent: Thursday, February 17, 2011 12:46 PM
To: Mpich
Subject: [mpich-discuss] Questions about using valgrind

I was able to build mpich2 with valgrind using --enable-g=dbg,meminit as suggested on:
http://wiki.mcs.anl.gov/mpich2/index.php/Support_for_Debugging_Memory_Allocation.
I have a few questions about this:

1. How to actually run valgrind? Is it
valgrind mpiexec exec
or
mpiexec valgrind exec?

2. Assuming it is the latter, I noticed that it doesnt report errors from mpich2 itself. It does if mpich2 wasnt built with the --enable-g option. Is this the only benefit enable-g provides? In other words, apart from hiding MPICH2 errors, what are the pros of using enable-g vs using valgrind on the default MPICH2 installation? As you can imagine, there are excellent upsides to maintaining just one MPICH2 installation, so if hiding MPICH2 errors is the only upside of separate installs, I'd look at writing a valgrind suppression file. (Please note that the goal is for valgrind to report errors in the application rather than in MPICH2 itself).

Thank you.
saurabh



_______________________________________________
mpich-discuss mailing list
mpich-discuss at mcs.anl.gov
https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss


More information about the mpich-discuss mailing list