At 06:37 PM 1/7/2004 -0700, Luke Palmer wrote:
Leopold Toetsch writes:
> Jeff Clites <[EMAIL PROTECTED]> wrote:
> > On Jan 7, 2004, at 1:46 AM, Leopold Toetsch wrote:
> >> That part is already answered: create a buffer_like structure.
> >> *But* again register backing stacks are *not* in the interpreter
> >> context.
>
> > I don't understand what you are getting at. They are not physically
> > part of Parrot_Interp.ctx, but it holds pointers to them, right?
>
> No, they were in the context but aren't any more.
>
> > ... So,
> > they need to be copied when the context is being duplicated. Is that
> > your point, or are you trying to say that they are not _logically_ part
> > of the context, or are not supposed to be?
>
> Exactly the latter:
> That was AFAIK a design decision, when Dan did introduce CPS. At this
> time register backing stacks went out of the continuation or whatelse
> context - IIRC did Dan commit that to CVS himself.

In which case I feel obliged to contest that decision.  The register
backing stacks are as much a part of the current state as the program
counter is.

I tend to agree, but maybe Dan can explain. I looked back at the CVS history and when I put continuations in, I did originally have register stacks in the Parrot_Context (although they weren't yet garbage collected). Dan since reverted that and put them back to the top level interpreter object.

It seems to me they should be part of the context structure or
continuations become very messy and make save/restoring of
register pads almost useless in combination.

-Melvin




Reply via email to