[Rd] R valgrind question

Jeffrey Horner jeff.horner at vanderbilt.edu
Mon Feb 4 21:29:40 CET 2008


Daniel Oberski wrote on 02/04/2008 02:21 PM:
> Dear R developers
> 
> 
> I am running an instrumented build of R 2.6.1 on ubuntu, compiled with
> option configure --with-valgrind-instrumentation=3.
> 
> If run valgrind R then I get all sorts of warnings. I was wondering
> whether I should worry about them or not.

Don't worry about them. Those are benign issues with the system 
libraries.. insofar as you trust those libraries, which you should... in 
general.

Jeff

> 
> First, when I open R as follows:
> 
>   $R -d "valgrind --tool=memcheck --leak-check=full
> --show-reachable=yes" --vanilla
> 
>  I get a whole bunch of
> 
> 
> ==888== Invalid read of size 4
> ==888==    at 0x4014787: (within /lib/ld-2.5.so)
> ...
> ==888==  Address 0x50794A4 is 44 bytes inside a block of size 47 alloc'd
> ==888==    at 0x4021620: malloc (vg_replace_malloc.c:149)
> ==888==    by 0x4006EB4: (within /lib/ld-2.5.so)
> ...
> 
> Second, when I exit R I get memory leak reports:
> 
> ==888== LEAK SUMMARY:
> ==888==    definitely lost: 132 bytes in 17 blocks.
> ==888==    indirectly lost: 240 bytes in 20 blocks.
> ==888==      possibly lost: 0 bytes in 0 blocks.
> ==888==    still reachable: 13,110,032 bytes in 6,340 blocks.
> ==888==         suppressed: 0 bytes in 0 blocks.
> 
> 
> I am sorry if this is a stupid question, please be gentle. What should
> I make of this?
> 
> I was trying to check my own C program (as a standalone program it
> does not produce any valgrind warnings), but now I am not sure what is
> going on when using valgrind on R..
> 
> 
> Best regards,
>   daniel
> 
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel


-- 
http://biostat.mc.vanderbilt.edu/JeffreyHorner



More information about the R-devel mailing list