[Vm-dev] Works in SqueakVM but not Cog
Andreas Raab
andreas.raab at gmx.de
Mon Dec 13 20:01:29 UTC 2010
On 12/13/2010 11:52 AM, Igor Stasenko wrote:
> The problem i that we want to swap special objects array. And there
> are two approaches:
>
> 1 - create a full object memory , which is a copy of existing objects
> (but not everything, just selected pieces). This means that there will
> be two 'nils' and therefore need a working #become: for swapping.
>
> 2 - mark a set of objects for inclusion in 'new' image, and throw
> away the rest via stubbing. So, this approach avoids copying, but also
> it doesn't allows to hold two object memories in object memory at same
> time (host and baby one).
There are at least two more options:
(3) Write a primitive that replaces the special objects array and
includes a set of classes to be updated (this would include all the
literals).
(4) A variant on the above would make all these classes be compact and
have them switch implicitly by replacing the compact classes array in
the splObjs.
Cheers,
- Andreas
More information about the Vm-dev
mailing list