Okay, one of the first things we need to do to support multiple
segment bytecode is to be able to swap in constant tables. (Since we
access constants by offset from the table, and we don't want to go
fix up the offsets every time we load in bytecode--ick. Slow)
So...
setconstant ix
Takes the address *at* (not of) offset X and sticks it in the
interpreter structure as the address of the current constant table
pushconstanttable
Push the current constant table pointer onto the system stack
popconstanttable
Pop the constant table pointer from the system stack
This has an implication for bytecode generation--it means that at
least one pointer-sized word at the end of the bytecode will get
altered at load time. This is OK--we can use it as the bytecode fixup
section. (I expect we'll find other things we need to use as fixups
along the way)
--
Dan
--------------------------------------"it's like this"-------------------
Dan Sugalski even samurai
[EMAIL PROTECTED] have teddy bears and even
teddy bears get drunk