On 06/27/2013 12:48 AM, Camillo Bruni wrote:
On 2013-06-27, at 01:08, Paul DeBruicker <pdebruic@gmail.com> wrote:
Sven & Camillo,
Ok thanks. And using the PointerFinder is there a way to know which of the pointers points to the SystemDictionary or Object someObject or whereever the GC begins so one would not have to check every pointer for every stubborn object.
E.g. Lets say I've nil'ed the reference between the Navy and the ship so its ready to go but a few of the soldiers on the ship have references to other ships because their transfer papers weren't processed properly. Running #pointersTo on those soldiers gives a large collection of pointers.
How can I use the computer to filter that list to just those references back to the root object?
What do you mean by root object?
I'm sure my understanding is not completely accurate but by 'root object' I mean whichever object (memory space? pointer?) the VM always considers as part of the object-space-to-keep when it begins a full GC. So every object which is kept implicitly points to that object through a long chain (web?) of pointers.
In any case, if I'm not mistaken, this isn't that easy. Usually you have to manually track down and follow the objects in the PointerExplorer
=> Inspect an Object, right click, Explore Strong Pointers
OK. I can imagine a Roassal visualization of a rats nest of objects as nodes connected with edges made with #pointsTo: with just a few edges connecting the main blob (e.g. the navy) to objects (soldiers) in a smaller blob (the ship I want to GC). Kind of like the visualization Craig Latta uses as the header for his blog and describes here: https://thiscontext.wordpress.com/2012/10/22/a-detailed-description-of-spoon...