-   Programming (
-   -   VALGRIND-Query (

inramana 11-04-2008 04:26 PM

I need a tool by which I can look/ display all the memory accesses in a program in order to resolve race conditions. I have started using valgrind but cannot find an option where this could be done..
Could anyone help me out?

TheIndependentAquarius 04-08-2010 04:22 AM

Hello !

Did you try the following command ?

valgrind --tool=memcheck --leak-check=yes progrm_name
The following text is from this page !

The memcheck tool that we used also shows bad memory access. It reports situations when: you read uninitialized memory, read past the buffers, access freed memory etc. All with nice stack traces. This is really the primary use of Valgrind for me.

TimothyEBaldwin 04-12-2010 02:08 PM


Originally Posted by anishakaul (Post 3928304)
Hello !

Did you try the following command?

valgrind --tool=memcheck --leak-check=yes progrm_name

Did you read the question? That would check for memory leaks and use of uninitialised memory, not race conditions.

What is required is:

valgrind --tool=helgrind program_name
See the manual:

TheIndependentAquarius 04-13-2010 01:41 AM


Well that was enlightening ! Thanks !

May be I had not read the question properly:banghead:

All times are GMT -5. The time now is 08:02 PM.