|
From: Bjoern D. <bjo...@go...> - 2010-04-14 06:47:16
|
Ok. Can you add some kind of printf() to your app and see if you're running the right binary? As uninitialized value detection works for me, it might also help to post the code you're running. Bjoern 2010/4/14 ajit gunge <pea...@ya...> > No it didn't work.All I want is the exact line number in the source file > where actually we are using the value before initializing it. > > Ajit > > --- On *Wed, 4/14/10, Bjoern Doebel <bjo...@go...>* wrote: > > > From: Bjoern Doebel <bjo...@go...> > Subject: Re: [Valgrind-users] Problem with getting lie numbers of surce > file > To: "ajit gunge" <pea...@ya...> > Date: Wednesday, April 14, 2010, 2:19 AM > > > It might well be you are running your shell's builtin test command here > instead of the binary you're interested in. Try > > $> valgrind --tool=memcheck ./test > > instead. > > -- Bjoern > > 2010/4/13 ajit gunge <pea...@ya...<http://mc/compose?to=pea...@ya...> > > > >> Hi All, >> I am trying to run the sample program on RHEL given at >> http://www.valgrind.org/docs/manual/mc-manual.html under section 4.2.2. >> now this should give me error mentioned in the section >> as to surce file with line numbers but when I am running the same program >> I dont get the line number is source file. >> >> This is the output >> >> >> [root@kalpana tests]# valgrind --tool=memcheck test >> ==30057== Memcheck, a memory error detector >> ==30057== Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et al. >> ==30057== Using Valgrind-3.5.0 and LibVEX; rerun with -h for copyright >> info >> ==30057== Command: test >> ==30057== >> ==30057== >> ==30057== HEAP SUMMARY: >> ==30057== in use at exit: 0 bytes in 0 blocks >> ==30057== total heap usage: 2 allocs, 2 frees, 36 bytes allocated >> ==30057== >> ==30057== All heap blocks were freed -- no leaks are possible >> ==30057== >> ==30057== For counts of detected and suppressed errors, rerun with: -v >> ==30057== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 13 from 8) >> >> >> Please let me know why am I not getting the error along with the line >> numbers. >> >> Regards, >> Ajit >> >> >> >> ------------------------------------------------------------------------------ >> Download Intel® Parallel Studio Eval >> Try the new software tools for yourself. Speed compiling, find bugs >> proactively, and fine-tune applications for parallel performance. >> See why Intel Parallel Studio got high marks during beta. >> http://p.sf.net/sfu/intel-sw-dev >> _______________________________________________ >> Valgrind-users mailing list >> Val...@li...<http://mc/compose?to=Val...@li...> >> https://lists.sourceforge.net/lists/listinfo/valgrind-users >> >> > > |
|
From: jody <jod...@gm...> - 2010-04-14 07:42:09
|
Also make sure you compile with debug info (compiler option '-g' if you are using gcc) jody On Wed, Apr 14, 2010 at 8:47 AM, Bjoern Doebel <bjo...@go... > wrote: > Ok. Can you add some kind of printf() to your app and see if you're > running the right binary? As uninitialized value detection works for me, it > might also help to post the code you're running. > > Bjoern > > 2010/4/14 ajit gunge <pea...@ya...> > >> No it didn't work.All I want is the exact line number in the source file >> where actually we are using the value before initializing it. >> >> Ajit >> >> --- On *Wed, 4/14/10, Bjoern Doebel <bjo...@go...>*wrote: >> >> >> From: Bjoern Doebel <bjo...@go...> >> Subject: Re: [Valgrind-users] Problem with getting lie numbers of surce >> file >> To: "ajit gunge" <pea...@ya...> >> Date: Wednesday, April 14, 2010, 2:19 AM >> >> >> It might well be you are running your shell's builtin test command here >> instead of the binary you're interested in. Try >> >> $> valgrind --tool=memcheck ./test >> >> instead. >> >> -- Bjoern >> >> 2010/4/13 ajit gunge <pea...@ya...<http://mc/compose?to=pea...@ya...> >> > >> >>> Hi All, >>> I am trying to run the sample program on RHEL given at >>> http://www.valgrind.org/docs/manual/mc-manual.html under section 4.2.2. >>> now this should give me error mentioned in the section >>> as to surce file with line numbers but when I am running the same program >>> I dont get the line number is source file. >>> >>> This is the output >>> >>> >>> [root@kalpana tests]# valgrind --tool=memcheck test >>> ==30057== Memcheck, a memory error detector >>> ==30057== Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et al. >>> ==30057== Using Valgrind-3.5.0 and LibVEX; rerun with -h for copyright >>> info >>> ==30057== Command: test >>> ==30057== >>> ==30057== >>> ==30057== HEAP SUMMARY: >>> ==30057== in use at exit: 0 bytes in 0 blocks >>> ==30057== total heap usage: 2 allocs, 2 frees, 36 bytes allocated >>> ==30057== >>> ==30057== All heap blocks were freed -- no leaks are possible >>> ==30057== >>> ==30057== For counts of detected and suppressed errors, rerun with: -v >>> ==30057== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 13 from 8) >>> >>> >>> Please let me know why am I not getting the error along with the line >>> numbers. >>> >>> Regards, >>> Ajit >>> >>> >>> >>> ------------------------------------------------------------------------------ >>> Download Intel® Parallel Studio Eval >>> >>> Try the new software tools for yourself. Speed compiling, find bugs >>> proactively, and fine-tune applications for parallel performance. >>> See why Intel Parallel Studio got high marks during beta. >>> http://p.sf.net/sfu/intel-sw-dev >>> _______________________________________________ >>> Valgrind-users mailing list >>> Val...@li...<http://mc/compose?to=Val...@li...> >>> https://lists.sourceforge.net/lists/listinfo/valgrind-users >>> >>> >> >> > > > ------------------------------------------------------------------------------ > Download Intel® Parallel Studio Eval > Try the new software tools for yourself. Speed compiling, find bugs > proactively, and fine-tune applications for parallel performance. > See why Intel Parallel Studio got high marks during beta. > http://p.sf.net/sfu/intel-sw-dev > _______________________________________________ > Valgrind-users mailing list > Val...@li... > https://lists.sourceforge.net/lists/listinfo/valgrind-users > > |