On Dec 8, 2009, at 12:08 , Mariano Martinez Peck wrote:

> On Fri, Dec 4, 2009 at 12:05 PM, Adrian Lienhard <[email protected]>  
> wrote:

> When you are creating your root of objects and you put symbols  
> inside, they
> are not put in ourPointers but in ByteArray.
> This is due to the fact that the only object who is pointing to that  
> symbol
> is inside the segment ?

To be precise, the symbols are also pointed to by the symbol table,  
but only by weak references. Since image segments use the GC mark  
logic, these pointers are not considered.

> What you do with this piece of code:
>
>    symbolHolder := Symbol allSymbols.
>
> is to hold those symbols there. So, when ImageSegment uses the GC  
> techniques
> to detect which objects are ONLY pointed from inside of the segment,  
> the
> symbols is not found (because it is accessible trough that test) and  
> thus,
> it goes to outPointers instead of ByteArray.
>
> And of course, if it is in outPointers instead of ByteArray when the  
> segment
> is loaded again, yo don't create a symbol again but use the same  
> object (the
> one of the oop).
>
> I am correct? or I understood anything ?

yes.

Cheers,
Adrian

_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

Reply via email to