Engineering a Compiler, 2nd Edition by Keith Cooper and Linda Torczon
September 9, 2010
![]() |
Morgan Kaufmann is excited to announce the forthcoming publication of Engineering a Compiler, 2nd Edition by Keith Cooper and Linda Torczon. The text is due out in February 2011. |
About the Book
This entirely updated second edition of Engineering a Compiler is full of technical updates and new material covering the latest developments in compiler technology. In this comprehensive text, students will learn important techniques for constructing a modern compiler. The authors, Keith Cooper and Linda Torczon, leading educators and researchers, have built several state-of-the-art compilers. They combine basic principles with pragmatic insights from their experience to help explain important techniques such as compilation of imperative and object-oriented languages, construction of static single-assignment form, instruction scheduling, and graph-coloring register allocation.
Key Features
- In-depth treatment of algorithms and techniques used in the front end of a modern compiler
- Focus on code optimization and code generation, the primary areas of recent research and development
- Improvements in presentation including conceptual overviews for each chapter, summaries and review questions for sections, and prominent placement of definitions for new terms
- Examples drawn from several different programming languages
Who should read this book?
This book is written for graduate and advanced undergraduate students in computer science. It’s also a great reference for professional compiler writers, system software developers, architects and computer system designers.
Table of Contents
CHAPTER 1 Overview of Compilation
1.1 Introduction
1.2 Why Study Compiler Construction?
1.3 The Fundamental Principles of Compilation
1.4 Compiler Structure
1.5 High-Level View of Translation
1.6 The Role of Engineering
1.7 Desirable Properties of a Compiler
1.8 Summary and Perspective
CHAPTER 2 Scanners
2.1 Introduction
2.2 Recognizing Words
2.3 Regular Expressions
2.4 From Regular Expression to Scanner
2.5 Implementing Scanners
2.6 Advanced Topics
2.7 Chapter Summary and Perspective
CHAPTER 3 Parsers
3.1 Introduction
3.2 Expressing Syntax
3.3 Top-Down Parsing
3.4 Bottom-Up Parsing
3.5 Practical Issues
3.6 Advanced Topics
3.7 Summary and Perspective
CHAPTER 4 Context-Sensitive Analysis
4.1 Introduction
4.2 An Introduction to Type Systems
4.3 The Attribute-Grammar Framework
4.4 Ad Hoc Syntax-Directed Translation
4.5 Advanced Topics
4.6 Summary and Perspective
CHAPTER 5 Intermediate Representations
5.1 Introduction
5.2 Graphical IRs
5.3 Linear IRs
5.4 Mapping Values to Names
5.5 Symbol Tables
5.6 Summary and Perspective
CHAPTER 6 The Procedure Abstraction
6.1 Introduction
6.2 Procedure Calls
6.3 Name Spaces
6.4 Communicating Values Between Procedures
6.5 Standardized Linkages
6.6 Advanced Topics
6.7 Summary and Perspective
CHAPTER 7 Code Shape
7.1 Introduction
7.2 Assigning Storage Locations
7.3 Arithmetic Operators
7.4 Boolean and Relational Operators
7.5 Storing and Accessing Arrays
7.6 Character Strings
7.7 Structure References
7.8 Control-Flow Constructs
7.9 Procedure Calls
7.10 Summary and Perspective
CHAPTER 8 Introduction to Code Optimization
8.1 Introduction
8.2 Background
8.3 Scope of Optimization
8.4 Local Optimization
8.5 Regional Optimization
8.6 Global Optimization
8.7 Interprocedural Optimization
8.8 Summary and Perspective
CHAPTER 9 Data-Flow Analysis
9.1 Introduction
9.2 Iterative Data-Flow Analysis
9.3 Static Single-Assignment Form
9.4 Interprocedural Analysis
9.5 Advanced Topics
9.6 Summary and Perspective
CHAPTER 10 Scalar Optimizations
10.1 Introduction
10.2 A Taxonomy for Transformations
10.3 Example Optimizations
10.4 Advanced Topics
10.5 Summary and Perspective
CHAPTER 11 Instruction Selection
11.1 Introduction
11.2 Code Generation
11.3 Extending the Simple Tree-Walk Scheme
11.4 Instruction Selection via Tree-Pattern Matching
11.5 Instruction Selection via Peephole Optimization
11.6 Advanced Topics
11.7 Summary and Perspective
CHAPTER 12 Instruction Scheduling
12.1 Introduction
12.2 The Instruction-Scheduling Problem
12.3 Local List Scheduling
12.4 Regional Scheduling
12.5 Advanced Topics
12.6 Summary and Perspective
CHAPTER 13 Register Allocation
13.1 Introduction
13.2 Background Issues
13.3 Local Register Allocation and Assignment
13.4 Moving Beyond Single Blocks
13.5 Global Register Allocation and Assignment
13.6 Advanced Topics
13.7 Summary and Perspective
CHAPTER A ILOC
A.1 Introduction
A.2 Naming Conventions
A.3 Individual Operations
A.4 An Example
A.5 Control-Flow Operations
A.6 Representing SSA Form
CHAPTER B Data Structures
B.1 Introduction
B.2 Representing Sets
B.3 Implementing Intermediate Representations
B.4 Implementing Hash Tables
B.5 A Flexible Symbol-Table Design
ISBN: 9780120884780 | View in bookstore
[MK] Andrea

My First Lexer (in Python)… « Coffee, Recliner, Action… said on November 23, 2010 at 4:24 am
[...] into the lexer implementation strategies in detail. So, I began with reading some stuff from “Engineering a Compiler”, and got something running. Here is the crude working code. Its immensely unproductive as far as [...]
it’s good