I’m trying to find objects that might be lingering around after they’re useful.
Is there a tool that helps you find these memory hogs?
I’m trying to find objects that might be lingering around after they’re useful.
Is there a tool that helps you find these memory hogs?
What do you mean with “linger around”?. If they are really lingering around with no way to access them then the GC will take care of it.
That wasn’t what he asked, he asked about objects lingering “after they’re useful”.
Objects linger around because there is some reference you weren’t aware of, keeping the GC from removing it. Also, I’m not sure how well the GC does if you have a circular reference.
Another issue is that objects allocated outside of Julia, where they may hold lots of resources (not just memory, but also things like open file handles), may not get freed quickly by the GC, because the GC only “sees” the size of objects allocated in Julia, and it may be quite a while before they are GC’ed and their finalize method called.
There’s whos()
, but I find it only moderately useful…