[Vm-dev] Detecting objects that point to an object

stephane ducasse stephane.ducasse at gmail.com
Wed Jul 21 15:51:29 UTC 2010


Thanks for the pointer.
What mariano is trying to do is to get a roboust mechanism to manage large chunk of memory.
And we were thinking that also having an object which contains (opaquely: without outpointers) 
could also another alternative. So we will look at Island.

Stef

On Jul 20, 2010, at 11:51 PM, Andreas Raab wrote:

> On 7/20/2010 11:20 AM, Bert Freudenberg wrote:
>> On 20.07.2010, at 04:47, Mariano Martinez Peck wrote:
>>> Thanks for the answers. Maybe I should have explained why I needed
>>> that. What I had in mind, is to be able to detect subgraphs. But not
>>> any kind of subgraphs, but only those on which ALL objects are ONLY
>>> reachable from the root of the subgraph. This means, that there are no
>>> objects outside the graph, pointing to objects inside the graph. In
>>> ImageSegment word, would mean to detect subgraphs that don't have
>>> outPointers.
>> 
>> So why not simply use an ImageSegment? IIRC that's how Croquet islands
>> are checked for closedness.
> 
> No, it's the other way around. Croquet can use ImageSegments because it can prove (constructively) that it tracks all the pointers into the object graph of an island. Since Mariano hasn't said what he's trying to do other than "detecting subgraphs" it's difficult to give any advice here but if the goal is to use ImageSegments for something similar to Croquet (i.e., dumping the bits of a well-defined set of objects) then the only way I know to do that is constructively, via message passing. And I'd recommend to check out [T]FarRef in Croquet and [T]IslandArgumentCopier to get an idea of how that can work. In addition, I'd recommend having a look at [T]IslandReader and [T]IslandWriter which do the actual checkpointing and instantiation for an island using ImageSegments (there are some interesting subtleties in this code :-)
> 
> Cheers,
>  - Andreas



More information about the Vm-dev mailing list