Related articles |
---|
Byte-Code compiler references sby@cs.usask.ca (S.Bharadwaj Yadavalli) (1995-07-20) |
Re: Byte-Code compiler references davis@wln.com (1995-07-27) |
Virtual Machines (was: Byte-Code compiler references) sdm7g@elvis.med.virginia.edu (Steven D. Majewski) (1995-08-04) |
Re: Virtual Machines (was: Byte-Code compiler references) will@ccs.neu.edu (1995-08-08) |
Newsgroups: | comp.compilers |
From: | will@ccs.neu.edu (William D Clinger) |
Keywords: | interpreter, architecture, bibliography |
Organization: | College of CS, Northeastern University |
References: | 95-07-138 95-08-010 95-08-062 |
Date: | Tue, 8 Aug 1995 15:05:38 GMT |
<sdm7g@elvis.med.virginia.edu> writes:
>If you're willing to poke around source code and look at
>*implementations* there's a lot of examples to look at:
> Python, Xlisp, several versions of Scheme all compile
>into byte code for a Virtual-Machine interpreter.
If you're willing to read refereed journal articles on byte-coded
virtual machines for Scheme, I recommend these articles on Scheme-48
and VLISP:
Richard A. Kelsey and Jonathan A. Rees. A tractable Scheme
implementation. Lisp and Symbolic Computation 7(44):315-335,
1994.
Joshua D. Gutman, John Ramsdell, and Mitchell Wand.
VLISP: a verified implementation of Scheme. Lisp and Symbolic
Computation 8(1/2):5-32, 1995.
Joshua D. Gutman, Vipin Swarup, and John Ramsdell.
The VLISP verified Scheme system. Lisp and Symbolic
Computation 8(1/2):33-110, 1995.
Dino P. Oliva, John D. Ramsdell, and Mitchell Wand.
The VLISP verified PreScheme compiler. Lisp and Symbolic
Computation 8(1/2):111-182, 1995.
> What I'm interested in is compiling to a byte-code that
>serves as both an Virtual Machine interpreter code, and
>as intermediate code for machine code generation. ( i.e.
>fast compilation to slow interpreter byte code, or slower
>compilation to fast machine code when optimization requested.)
>Any references on that?
Zillions of compilers have been based on P-code. On my Sage II,
which used the UCSD P-system, I could compile UCSD Pascal to
interpreted P-code, or run the P-code through a native code compiler.
As I recall, the native code occasionally ran up to five times as
fast as the interpreted code, but my Pascal programs had a lot of
procedure calls, which ran no faster in native than in interpreted
code, so the speedup was usually negligible.
For implementations of Scheme that can mix interpreted byte code
with native code generated from the byte code, I'll recommend my
conference papers on the compilers used in MacScheme and in Larceny:
William Clinger. The Scheme 311 compiler: an exercise in
denotational semantics. In Proceedings of the 1984 ACM
Conference on Lisp and Functional Programming, 356-364,
ACM, 1984.
William D Clinger and Lars Thomas Hansen. Lambda, the ultimate
label; or a simple optimizing compiler for Scheme. In Proceedings
of the 1994 ACM Conference on Lisp and Functional Programming,
128-139, ACM Lisp Pointers 7(3), July-September 1994.
I don't have the reference handy, but there was a paper circa 1986
by Peter Deutsch on dynamic compilation of Smalltalk byte codes to
native code. This technique has been used in several systems since
then, and is especially important for dynamically distributed programs
running on heterogenous networks.
William Clinger
--
Return to the
comp.compilers page.
Search the
comp.compilers archives again.