|P-Code and virtual machines email@example.com (1994-03-23)|
|Threaded code (was Re: P-Code and virtual machines) mark@godzilla.Quotron.COM) (1994-03-26)|
|Threaded code firstname.lastname@example.org (1994-03-27)|
|Threaded code (was Re: P-Code and virtual machines) email@example.com (Stephen J Bevan) (1994-03-27)|
|Re: Threaded code (was Re: P-Code and virtual m firstname.lastname@example.org (1994-03-28)|
|Re: Threaded code (was Re: P-Code and virtual machines) email@example.com (1994-03-29)|
|Re: Threaded code (was Re: P-Code and virtual machines) firstname.lastname@example.org (Ulrich Hoffmann) (1994-03-30)|
|From:||mark@godzilla.Quotron.COM (Mark T. Price (sg))|
|Keywords:||interpreter, question, comment|
|Organization:||Quotron Systems, Inc.|
|Date:||Sat, 26 Mar 1994 04:47:43 GMT|
email@example.com (David Keppel) writes:
> Stack machines have the advantage that the code is compact, easy to
> decode and easy to convert to threaded code (for fast decode) and can be
> implemented with similar efficiency across a fair range of machines.
I've heard threaded code mentioned here before, but don't have any formal
exposure to the topic. Can someone provide some good references for threaded
code in general, as well as some specifics on the above mentioned conversion
of stack code to threaded code?
Mark T. Price (sg) mark@godzilla.Quotron.COM
[The point of threaded code is that in an interpreter, instead of having
a list of arbitrary byte codes, you have a list of addresses of interpretive
routines, and each routine does an indirect jump through the list to dispatch
directly to the next routine, cutting interpreter overhead close to zero.
This was very popular on the PDP-11, where the threaded jump was the single
instruction JMP @(R5)+ and was used in both the DEC and the Unix Fortran
compilers. I don't know where it originated, but wouldn't be surprised if
it was back in the 50's, like most other interesting software techniques.
Return to the
Search the comp.compilers archives again.