[Parrot] #549: Kill UnionVal
Martin D Kealey
martin at kurahaupo.gen.nz
Thu Jul 30 01:44:54 UTC 2009
On Wed, 29 Jul 2009, Andrew Whitworth wrote:
> > If you remove the UnionVal, you have
> > struct PMC { <*SNIP*> }
> > What specific structure definition would be "overlayed" *on *that?
>
> The only thing that the GC needs right now is enough storage for a
> single pointer, which can be used to arrange PObjs into a linked list
> of free items. See, for example, the structure GC_MS_PObj_Wrapper
> which is used in the MS GC right now for this exact purpose.
A few weeks ago there were some ideas tossed around on #parrot about the
prerequisites for implementing a *compacting* GC. One of the more
significant issues was having a compact way to represent a proxy PMC.
While there's restructuring of the fundamental P-whatever structure, could
some thought be given to overlaying something that looks (enough) like a PMC
regardless of whether it's a proxy for a PMC or a string or something else?
In particular it needs a reference to the "target object", and either a
vtable pointer or two flag bits.
Of course, I'm assuming it won't make the structure any larger, or any more
difficult to understand... feel free to ignore this suggestion if
implementing it would compromise other design objectives.
-Martin
More information about the parrot-dev
mailing list