At 05:14 PM 4/25/2001 -0500, David L. Nicol wrote:
>Dan Sugalski wrote:
>
> > >2) Anyway, even resizing vtables we would need some more indirection to
> > >determine in which position of the vtable is which operator.
> >
> > No. Each operator goes in a fixed position in the vtable, and it's the same
> > for each table. Anything else is nasty, error prone, and slow.
>
>What if the decision in-vtable or not-in-vtable is deferred? The size
>of the vtable could be chosen late in the compilation.  There could be
>hints.

That's doable, I think, though I can see some issues. It means that the 
bytecode compiler will need to do some reorganization and possibly emit 
different opcode streams. That's not a huge issue, but it does mean that 
we'll need to do extra processing of bytecode-compiled modules. (Especially 
ones loaded at runtime, unless we restrict the module compilation sequence 
to not use extra vtable entries, or spit out two streams of bytecode and 
choose which to use based on the number of remaining vtable entries) The 
logic could get potentially rather dodgy when twiddling code sequences from 
one way to the other.

I'd really just as soon not deal with the issue this way, though that 
doesn't mean it won't be the way we end up going.

                                        Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to