|
From: venkat r. <ram...@ho...> - 2009-04-21 11:18:54
|
Hi, I am new to Valgrind. I configured, compiled and installed. But when I tried to check a small program I get the following error. My program name is memcheck.c. And I did a valgrind --tool=memcheck --leak-check=yes memcheck.c. Then I got the following error. valgrind: do_exec(./memcheck.c) failed: Exec format error How do I fix the above?. your help would be great. Temporarily I installed this in a local directory. But where do I need to install the Valgrind. Should it be in one of the root directories like /tmp or /usr etc? |
|
From: Konstantin S. <kon...@gm...> - 2009-04-21 11:33:58
|
valgrind runs on executables, not source code. do this: gcc -g memcheck.c valgrind ./a.out --kcc On Tue, Apr 21, 2009 at 3:18 PM, venkat ramana <ram...@ho...> wrote: > > Hi, > I am new to Valgrind. I configured, compiled and installed. But when I tried to check a small program I get the following error. > My program name is memcheck.c. And I did a valgrind --tool=memcheck --leak-check=yes memcheck.c. Then I got the following error. > valgrind: do_exec(./memcheck.c) failed: Exec format error > How do I fix the above?. your help would be great. > Temporarily I installed this in a local directory. But where do I need to install the Valgrind. Should it be in one of the root directories like /tmp or /usr etc? > > > > ------------------------------------------------------------------------------ > Stay on top of everything new and different, both inside and > around Java (TM) technology - register by April 22, and save > $200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco. > 300 plus technical and hands-on sessions. Register today. > Use priority code J9JMT32. http://p.sf.net/sfu/p > _______________________________________________ > Valgrind-users mailing list > Val...@li... > https://lists.sourceforge.net/lists/listinfo/valgrind-users > > > |