-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org] On Behalf Of Sam Steingold
Sent: Tuesday, February 28, 2012 11:58 AM
To: r-help at r-project.org; Bert Gunter
Subject: Re: [R] memory management
My basic worry is that the GC does not work properly,
i.e., the unreachable data is never collected.
* Bert Gunter <thagre.oregba at trar.pbz> [2012-02-27 14:35:14 -0800]:
This appears to be the sort of query that (with apologies to other R
gurus) only Brian Ripley or Luke Tierney could figure out. R generally
passes by value into function calls (but not *always*), so often
multiple copies of objects are made during the course of calls. I
would speculate that this is what might be going on below -- maybe
even that's what you meant.
Just a guess on my part, of course, so treat accordingly.
-- Bert
On Mon, Feb 27, 2012 at 1:03 PM, Sam Steingold <sds at gnu.org> wrote:
It appears that the intermediate data in functions is never GCed even
after the return from the function call.
R's RSS is 4 Gb (after a gc()) and
sum(unlist(lapply(lapply(ls(),get),object.size)))
[1] 1009496520
(less than 1 GB)
how do I figure out where the 3GB of uncollected garbage is hiding?