Java Reference
In-Depth Information
We focus on the traditional batch compilation approach in which an entire
source file is translated. However, many of the techniques we develop can be
reformulated into incremental form to support IDEs. For example, a parser
can reparse only those portions of a program that have been changed [GM80,
WG97], and a type checker can analyze only portions of an AST that are
a
ected by programmodification. An alternative is to write the compiler as a
sequence of passes over the source code, with its first pass su
ff
ciently fast to
provide an IDE its requisite information. Subsequent passes can complete the
compilation process and generate increasingly sophisticated code.
Summary In this topic, we concentrate on the translation of C, C
,andJava.
We use the JVM as a target in Chapter 11, and we address code generation
for RISC processors such as the MIPS R
++
and Sparc architectures in Chapter 13.
At the code-generation stage, a variety of current techniques designed to ex-
ploit a processor's capabilities are explored. Like so much else in crafting a
compiler, experience is the best guide. We begin with the translation of a very
simple language in Chapter 2 and work our way up to ever more challenging
translation tasks.
 
Search WWH ::




Custom Search