|
From: Ferosh J. <fj...@cr...> - 2012-03-17 03:53:32
|
Hi all I have an OpenMP program written in C and OpenMP, the program runs fine for some sizes of data, For bigger sizes it is throwing a segmentation fault, I tried setting the ulimit -s 10000, unlimited, G/K/O, MP_STACKSIZE, variables but all in vain. While running through valgrind this is not happening, the program ends normally. Below is the Valgrind summary. I believe if I can setup the execution environment as in the Valgrind, my program will execute normally. :) Anyone knows where I can find this information, like the value of variables set before executing a program in Valgrind. Please let me know if you need more information. ==4506== ==4506== HEAP SUMMARY: ==4506== in use at exit: 1,764 bytes in 4 blocks ==4506== total heap usage: 37,477 allocs, 37,473 frees, 7,095,680 bytes allocated ==4506== ==4506== LEAK SUMMARY: ==4506== definitely lost: 0 bytes in 0 blocks ==4506== indirectly lost: 0 bytes in 0 blocks ==4506== possibly lost: 152 bytes in 1 blocks ==4506== still reachable: 1,612 bytes in 3 blocks ==4506== suppressed: 0 bytes in 0 blocks ==4506== Rerun with --leak-check=full to see details of leaked memory ==4506== ==4506== For counts of detected and suppressed errors, rerun with: -v ==4506== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 19 from 6) Thanks Ferosh |
|
From: Dan K. <da...@ke...> - 2012-03-17 04:03:20
|
On Fri, Mar 16, 2012 at 7:22 PM, Ferosh Jacob <fj...@cr...> wrote: > While running through valgrind this is not happening, the program > ends normally. Below is the Valgrind summary. I believe if I can setup > the execution environment as in the Valgrind, my program will execute > normally. :) What about taskset -c 0 ./yourapp ? That would mimic the non-multicore valgrind environment. Otherwise you're probably out of luck, you're going to have to use other methods to find your problem. - Dan |
|
From: Ferosh J. <fj...@cr...> - 2012-03-17 08:51:58
|
Thanks Dan for the reply. I tried with taskset, the program is hanged :), similar to running in gdb. My guess is before running as a taskset, Valgrind should be setting some environment variables for stack memory and if any other settings for the session, which make the program run normally. May be I should check out their source code for this. Regards Ferosh On 12-03-16 11:03 PM, Dan Kegel wrote: > On Fri, Mar 16, 2012 at 7:22 PM, Ferosh Jacob<fj...@cr...> wrote: >> While running through valgrind this is not happening, the program >> ends normally. Below is the Valgrind summary. I believe if I can setup >> the execution environment as in the Valgrind, my program will execute >> normally. :) > What about > taskset -c 0 ./yourapp > ? > > That would mimic the non-multicore valgrind environment. > > Otherwise you're probably out of luck, you're going to have > to use other methods to find your problem. > - Dan |
|
From: Ferosh J. <fj...@cr...> - 2012-03-17 21:33:56
|
It worked without any complaints in ICC compiler Thanks Ferosh On 12-03-16 11:03 PM, Dan Kegel wrote: > On Fri, Mar 16, 2012 at 7:22 PM, Ferosh Jacob<fj...@cr...> wrote: >> While running through valgrind this is not happening, the program >> ends normally. Below is the Valgrind summary. I believe if I can setup >> the execution environment as in the Valgrind, my program will execute >> normally. :) > What about > taskset -c 0 ./yourapp > ? > > That would mimic the non-multicore valgrind environment. > > Otherwise you're probably out of luck, you're going to have > to use other methods to find your problem. > - Dan |
|
From: Josef W. <Jos...@gm...> - 2012-03-19 13:46:34
|
Am 17.03.2012 03:22, schrieb Ferosh Jacob: > Hi all > > I have an OpenMP program written in C and OpenMP, the program runs fine > for some sizes of data, > For bigger sizes it is throwing a segmentation fault, I tried setting > the ulimit -s 10000, unlimited, G/K/O, MP_STACKSIZE, variables but all > in vain. > > While running through valgrind this is not happening, the program > ends normally. Probably your program has problems with with data races/locking, which do not appear (by luck_) in valgrind, as VG is serializing threads. Trying to mimicking the VG environment is probably not what you want: Why to parallelize a program which later is run only on just one core? The easier way is not to use OpenMP ;-) You can check for races/locking problems with the VG tools DRD and helgrind. Josef Below is the Valgrind summary. I believe if I can setup > the execution environment as in the Valgrind, my program will execute > normally. :) > Anyone knows where I can find this information, like the value of > variables set before executing a program in Valgrind. Please let me > know if you need more information. > > ==4506== > ==4506== HEAP SUMMARY: > ==4506== in use at exit: 1,764 bytes in 4 blocks > ==4506== total heap usage: 37,477 allocs, 37,473 frees, 7,095,680 > bytes allocated > ==4506== > ==4506== LEAK SUMMARY: > ==4506== definitely lost: 0 bytes in 0 blocks > ==4506== indirectly lost: 0 bytes in 0 blocks > ==4506== possibly lost: 152 bytes in 1 blocks > ==4506== still reachable: 1,612 bytes in 3 blocks > ==4506== suppressed: 0 bytes in 0 blocks > ==4506== Rerun with --leak-check=full to see details of leaked memory > ==4506== > ==4506== For counts of detected and suppressed errors, rerun with: -v > ==4506== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 19 from 6) > > > Thanks > Ferosh > > > > ------------------------------------------------------------------------------ > This SF email is sponsosred by: > Try Windows Azure free for 90 days Click Here > http://p.sf.net/sfu/sfd2d-msazure > _______________________________________________ > Valgrind-users mailing list > Val...@li... > https://lists.sourceforge.net/lists/listinfo/valgrind-users > |