Jump to ratings and reviews
Rate this book

Modern Compiler Implementation in C

Rate this book
This new, expanded textbook describes all phases of a modern compiler: lexical analysis, parsing, abstract syntax, semantic actions, intermediate representations, instruction selection via tree matching, dataflow analysis, graph-coloring register allocation, and runtime systems. It includes good coverage of current techniques in code generation and register allocation, as well as functional and object-oriented languages, that are missing from most books. In addition, more advanced chapters are now included so that it can be used as the basis for a two-semester or graduate course. The most accepted and successful techniques are described in a concise way, rather than as an exhaustive catalog of every possible variant. Detailed descriptions of the interfaces between modules of a compiler are illustrated with actual C header files. The first part of the book, Fundamentals of Compilation, is suitable for a one-semester first course in compiler design. The second part, Advanced Topics, which includes the advanced chapters, covers the compilation of object-oriented and functional languages, garbage collection, loop optimizations, SSA form, loop scheduling, and optimization for cache-memory hierarchies.

554 pages, Hardcover

First published January 13, 1997

15 people are currently reading
144 people want to read

About the author

Andrew W. Appel

16 books6 followers
Andrew W. Appel, Ph.D. (Computer Science, Carnegie Mellon University, 1985; A.B., Princeton University, 1981) is the Eugene Higgins Professor of Computer Science at Princeton University, where he has been on the faculty since 1986. He served as department chair from 2009 to 2015. His research is in software verification, computer security, programming languages and compilers, and technology policy.

He has been editor-in-chief of ACM Transactions on Programming Languages and Systems and is a fellow of the ACM (Association for Computing Machinery). He has worked on fast N-body algorithms (1980s), Standard ML of New Jersey (1990s), Foundational Proof-Carrying Code (2000s), and the Verified Software Toolchain (2010s). He is the author of several scientific papers on voting machines and election technology, served as an expert witness on two voting-related court cases in New Jersey, and has taught a course at Princeton on election machinery.

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
12 (29%)
4 stars
8 (19%)
3 stars
16 (39%)
2 stars
5 (12%)
1 star
0 (0%)
Displaying 1 - 3 of 3 reviews
Profile Image for Serdar.
Author 13 books33 followers
March 5, 2018
The first few sections focus on parsing and context-free grammars and the like, and so might be rough going for all of us who nearly flunked algebra (like me, cough). After that, there's a wealth of detail on everything from abstract syntax trees to garbage collected memory management. I found out after the fact that there's other editions of this book that use Java and ML instead of C, and that the original (using ML) is less painful to read because the code examples aren't cluttered with the kinds of memory management details that tend to litter C code. At first I regretted this, but in truth it isn't that big an obstacle, especially since I'm using LLVM by way of Python, and therefore relying on the book mostly for theory and not specific code examples.
Profile Image for Oliver Erxleben.
5 reviews4 followers
June 16, 2013
Good book and introduction to the compiler build phases. Helped me a lot during the semester course. But, unfortunately, some times too much related to the tiger programing language. Chapter tasks are not all clear to understand.
Profile Image for Cedric.
43 reviews9 followers
June 5, 2013
Ok for the topics covered, but too much emphasis on implementational details.
Displaying 1 - 3 of 3 reviews

Can't find what you're looking for?

Get help and learn more about the design.