From: Andrew T B. <And...@Co...> - 2007-05-04 14:59:32
|
I'm trying to use Valgrind to debug an MPI program. The user manual gives some instructions (section 2.16) and I follow them, and it says that if things are working I should get notices like this when I run my program: valgrind MPI wrappers 31901: Active for pid 31901 valgrind MPI wrappers 31901: Try MPIWRAP_DEBUG=help for possible options I do not get such notices, and Valgrind seems to be giving me lots of false positives from the MPI libraries. The configure script for Valgrind reports that it finds a usable mpicc. What am I missing? Thanks for any help. |
From: Julian S. <js...@ac...> - 2007-05-04 15:10:56
|
- Did it successfully build $prefix/lib/valgrind/<platform>/libmpiwrap.so ? - Did you point LD_PRELOAD at it ? - Is your executable statically linked? J On Friday 04 May 2007 15:59, Andrew T Barker wrote: > I'm trying to use Valgrind to debug an MPI program. The user manual gives > some instructions (section 2.16) and I follow them, and it says that if > things are working I should get notices like this when I run my program: > > valgrind MPI wrappers 31901: Active for pid 31901 > valgrind MPI wrappers 31901: Try MPIWRAP_DEBUG=help for possible options > > I do not get such notices, and Valgrind seems to be giving me lots of false > positives from the MPI libraries. The configure script for Valgrind > reports that it finds a usable mpicc. > > What am I missing? Thanks for any help. > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > Valgrind-users mailing list > Val...@li... > https://lists.sourceforge.net/lists/listinfo/valgrind-users |
From: Seán <sea...@gm...> - 2009-05-07 10:34:00
|
Bugzilla from js...@ac... wrote: > > > - Did it successfully build $prefix/lib/valgrind/<platform>/libmpiwrap.so > ? > > I seem to have the same problem. ./configure does find a usable mpicc (though the "secondary target" seems to fail ????) configure:8693: checking primary target for usable MPI2-compliant C compiler and mpi.h configure:8722: mpicc -o conftest -m32 conftest.c >&5 configure:8728: $? = 0 configure:8732: test -z || test ! -s conftest.err configure:8735: $? = 0 configure:8738: test -s conftest configure:8741: $? = 0 configure:8745: result: yes, mpicc configure:8778: checking secondary target for usable MPI2-compliant C compiler and mpi.h configure:8811: mpicc this will surely fail -o conftest conftest.c >&5 cc: this: No such file or directory cc: will: No such file or directory cc: surely: No such file or directory cc: fail: No such file or directory configure:8817: $? = 1 configure: failed program was: | /* confdefs.h. */ The directory /usr/lib/valgrind/ only contains 1 file, python.supp, and I cant find libmpiwrap.so anywhere on my system. Here is my http://www.nabble.com/file/p23424032/config.log config.log Any help greatly appreciated. Sorry if this is a double post. -- View this message in context: http://www.nabble.com/valgrind-and-MPI-wrappers-tp10324423p23424032.html Sent from the Valgrind - Users mailing list archive at Nabble.com. |
From: Seán <sea...@gm...> - 2009-05-07 14:06:12
|
Seán wrote: > > I seem to have the same problem. > I have solved my initial problem. It was caused by interference of another valgrind version already installed. I did a "complete remove" using synaptic, instead of the "remove" I had previously tried. I now have libmpiwrap.so installed in the directory /usr/local/lib/valgrind/x86-linux/libmpiwrap.so. I am trying to run an MPI HelloWorld program with valgrind. I am not getting the expected output "valgrind MPI wrappers 31901: Active for pid 31901" . Instead I get: sean@seanscomputer:~/CODE$ LD_PRELOAD=/usr/local/lib/valgrind/x86-linux/libmpiwrap.so mpirun -np 2 /usr/local/bin/valgrind ./main ==2869== Memcheck, a memory error detector. ==2869== Copyright (C) 2002-2008, and GNU GPL'd, by Julian Seward et al. ==2869== Using LibVEX rev 1884, a library for dynamic binary translation. ==2869== Copyright (C) 2004-2008, and GNU GPL'd, by OpenWorks LLP. ==2869== Using valgrind-3.4.1, a dynamic binary instrumentation framework. ==2869== Copyright (C) 2000-2008, and GNU GPL'd, by Julian Seward et al. ==2869== For more details, rerun with: -v ==2869== valgrind: seanscomputer: command not found p0_2869: p4_error: Child process exited while making connection to remote process on localhost: 0 ==2869== Conditional jump or move depends on uninitialised value(s) ...... Does anyone know what that "valgrind: hostname: command not found" error is? -- View this message in context: http://www.nabble.com/valgrind-and-MPI-wrappers-tp10324423p23427517.html Sent from the Valgrind - Users mailing list archive at Nabble.com. |
From: R. C. <rkc...@lb...> - 2009-05-14 21:49:27
|
Sean, I have encountered the same problem. The problem lies in how command-line arguments are parsed. Have a look at the following webpage https://csd.vpac.org/twiki/bin/view/Tech/ParallelDebugging#Using_valgrind_with_MPICH_to_che which gives instructions on getting valgrind to work with mpich. The upshot is that you will have to create a mpirun_dbg.valgrind shell script that parses the command line arguments correctly. This may require a little monkeying around with the script, like stripping of quotes and such. Hope this helps, Robert Seán wrote: > > > Seán wrote: >> >> I seem to have the same problem. >> > > I have solved my initial problem. It was caused by interference of another > valgrind version already installed. I did a "complete remove" using > synaptic, instead of the "remove" I had previously tried. I now have > libmpiwrap.so installed in the directory > /usr/local/lib/valgrind/x86-linux/libmpiwrap.so. > > I am trying to run an MPI HelloWorld program with valgrind. I am not > getting the expected output > "valgrind MPI wrappers 31901: Active for pid 31901" . > Instead I get: > > sean@seanscomputer:~/CODE$ > LD_PRELOAD=/usr/local/lib/valgrind/x86-linux/libmpiwrap.so mpirun -np 2 > /usr/local/bin/valgrind ./main > ==2869== Memcheck, a memory error detector. > ==2869== Copyright (C) 2002-2008, and GNU GPL'd, by Julian Seward et al. > ==2869== Using LibVEX rev 1884, a library for dynamic binary translation. > ==2869== Copyright (C) 2004-2008, and GNU GPL'd, by OpenWorks LLP. > ==2869== Using valgrind-3.4.1, a dynamic binary instrumentation framework. > ==2869== Copyright (C) 2000-2008, and GNU GPL'd, by Julian Seward et al. > ==2869== For more details, rerun with: -v > ==2869== > valgrind: seanscomputer: command not found > p0_2869: p4_error: Child process exited while making connection to remote > process on localhost: 0 > ==2869== Conditional jump or move depends on uninitialised value(s) > ...... > > Does anyone know what that "valgrind: hostname: command not found" error > is? > > ----- -- Robert Crockett Postdoctoral Fellow Applied Numerical Algorithms Group Lawrence Berkeley National Laboratory -- View this message in context: http://www.nabble.com/valgrind-and-MPI-wrappers-tp10324423p23512446.html Sent from the Valgrind - Users mailing list archive at Nabble.com. |
From: Seán <sea...@gm...> - 2009-05-13 09:54:44
|
Robert, Fantastic! Valgrind now running with mpich, and returning meaningful results. A simple suppression file gets rid of a few extra errors associated with things like MPI_Init. R. Crockett wrote: > > Sean, > > I have encountered the same problem. The problem lies in how command-line > arguments are parsed. > > Have a look at the following webpage > > https://csd.vpac.org/twiki/bin/view/Tech/ParallelDebugging#Using_valgrind_with_MPICH_to_che > > which gives instructions on getting valgrind to work with mpich. The > upshot is that you will have to create a mpirun_dbg.valgrind shell script > that parses the command line arguments correctly. This may require a > little monkeying around with the script, like stripping of quotes and > such. > > Hope this helps, > Robert > > -- View this message in context: http://www.nabble.com/valgrind-and-MPI-wrappers-tp10324423p23518788.html Sent from the Valgrind - Users mailing list archive at Nabble.com. |