Skip to content
Prev 25185 / 63424 Next

R scripts slowing down after repeated called to compiled code

I work with images with a lot of processing done in C code. Quite often 
I allocate memory there up to several gigs in chunks of 10-15 Mb each 
plus hundreds of protected dims, names etc. I had a similar problem only 
once when due to some erroneous use of an external library, internally 
created objects were not freed correctly. Otherwise, after correcting 
this, I never have seen any slow down on large number of objects created 
and manipulated. And then, it was so difficult to track the memory leak 
that I would really suggest to double and triple check all the memory 
allocations. Your code does not use any temp files? This could be a real 
pain. Oleg
Dirk Eddelbuettel wrote: