Leopold Toetsch <[EMAIL PROTECTED]> writes:

> [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>> On 25/03/2004, at 9:01 PM, Leopold Toetsch wrote:
>
>>> All these generational collectors don't work with Parrot objects. We
>>> guarantee that objects don't move around.
>
>> Oh, I didn't see a mention of this in a PDD.  What's the reason for why
>> you provide such a guarantee?  Just curious.
>
> PMCs are passed on to (external) C code. When inmidst of C code the
> PMC moves around things break horribly--as they now break with the
> copying collector when you do:
>
>   char *c = string->strstart;
>   ...
>   <GC runs e.g. triggered by string_compare>
>   ...
>   do something with c

I know it's extra indirection, but maybe we should be passing pointers
to pointers rather than plain pointers to C functions. It could be a
win if that gets us faster GC...

Reply via email to