|Stack, register, message based or hybrid for virtual machine? visionary25@_nospam_hotmail.com (Vis Mike) (2003-02-11)|
|Re: Stack, register, message based or hybrid for virtual machine? firstname.lastname@example.org (Ulrich Hobelmann) (2003-02-12)|
|Re: Stack, register, message based or hybrid for virtual machine? email@example.com (2003-02-21)|
|From:||firstname.lastname@example.org (Anton Ertl)|
|Date:||21 Feb 2003 00:54:26 -0500|
|Organization:||Institut fuer Computersprachen, Technische Universitaet Wien|
|Posted-Date:||21 Feb 2003 00:54:26 EST|
Ulrich Hobelmann <email@example.com> writes:
>Vis Mike wrote:
>> I was thinking of some kind of hybrid. Anybody have any thoughts?
>> I'll post the complete code if interested, just wanted to brush on the
>> subject first.
>Just add those registers you need for certain things, use the stack
>for everything else.
The typical hybrid for an Algol-style language is to have the stack
for values within expressions, and have directly accessible locals for
local variables; there are some implicit registers around (e.g., VM
instruction pointer, stack pointer). E.g., the JavaVM takes this
approach. Allocating locals on a non-indexable stack is hard (at
least if you are interested in efficiency).
M. Anton Ertl
Return to the
Search the comp.compilers archives again.