Skip to content
Prev 23778 / 63421 Next

SEXP i/o, .Call(), and garbage collection.

K. B. Udaya wrote:
[...]
If you can run your code on linux (x86, amd64, ppc32, or ppc64), then 
consider using valgrind for catching memory access problems. You would 
need to recompile R with debugging support (-g) and it would be best to 
compile without optimizations (although -O1 seems to be tolerated).

And running R within valgrind is as simple as:

R -d valgrind --vanilla < script.R

or even interactively with:

R -d valgrind

Best,

Jeff