Compilation principle is an important and professional course for computer majors, also one of the most difficult and challenging courses to learn. It aims at introducing the general principles and basic methods of compiler construction, and studying how to develop computer programs more efficiently so as to reduce the threshold of programming. In this age of highly developed IDEs, why should programmers learn the principles of compilation? In fact, the principle of compilation permeates every aspect of the daily programming work. Therefore, learning the principles of compilation can help you better understand computer programs and provide a solid foundation for your future development.

Compilers: Principles, Techniques, and Tools comprehensively and deeply probes into the important topics in compiler design, including lexical analysis, grammar analysis, syntax-directed definition, syntax-directed translation, runtime environment, target code generation, code optimization technology, parallelism detection, as well as process analysis technology, and provides a large number of examples in the relevant chapters. Compared to the first edition published in 1986, the second edition published in 2006 (20 years later) is a comprehensive revision, covering the latest developments in compiler development, and its each chapter provides a large number of systems and references.

To learn such a subject well, you must first have a good programming foundation, otherwise it will be pretty difficult to stick to it. The second chapter, for example, will make you so miserable that you'll start to hate studying the computer science. In short, for this abstract course about compiler principle, it still relies on the reader himself to slowly understand. The experience tells us that when you don't understand a book, just type down the code in the book, or write some along the lines of the book. In this process, you will find that the unclear things will become clear little by little, and slowly.

Topics Covered

  • Compiler structure
  • Lexical analysis (including regular expressions and finite automata)
  • Syntax analysis (including context-free grammars, LL parsers, bottom-up parsers, and LR parsers)
  • Syntax-directed translation
  • Type checking (including type conversions and polymorphism)
  • Run-time environment (including parameter passing, symbol tables and register allocation)
  • Code generation (including intermediate code generation)
  • Code optimization
  • Directed translation
  • New data flow analyses
  • Parallel machines
  • Garbage collection
  • New case studies

Table Of Contents

  • 1 Introduction
  • 2 A Simple Syntax-Directed Translator
  • 3 Lexical Analysis
  • 4 Syntax Analysis
  • 5 Syntax-Directed Translation
  • 6 Intermediate-Code Generation
  • 7 Run-Time Environments
  • 8 Code Generation
  • 9 Machine-Independent Optimizations
  • 10 Instruction-Level Parallelism
  • 11 Optimizing for Parallelism and Locality
  • 12 Interprocedural Analysis
  • A A Complete Front End
  • B Finding Linearly Independent Solutions

Book Example Codes

Download URLs

Format Download Size
Compilers: Principles, Techniques, and Tools, 2nd Edition
PDF 5.77 MB
Scanned PDF reserved 48.2 MB
(Homepage)