Dieses Buch ist eine EinfUhrung in die Theorie der formalen Sprachen und ihrer Satzzerlegung, sowie in die Technik der Compiler-Konstruktion. Diese Themen sind aus zweierlei Grunden relevant. Erstens erleichtert und vertieft die Kenntnis der Grundprinzipien eines Compilers das Verstiindnis fUr korrekte Verwendung von Programmiersprachen ganz allgemein. Zweitens ist die Beherrschung dieser Themen Voraussetzung fUr die fachgerechte Erstellung vieler Computer-Systeme, denen eine einfache Befehlssprache zugrunde liegt. Die Anzahl derartiger Anwendungen nimmt rasch zu, sei es im Gebiet der Prozesssteuerung, der Datenverarbeitung, oder der Betriebssysteme. Beziiglich der Theorie der formalen Sprachen und der Methodik der syntaktischen Analyse beschriinken wir uns auf das fUr den Bau eines einfachen Compilers minimal notwendige. Hingegen wird die systematische Entwicklung eines vollstiindigen Compilers fur eine einfache Programmiersprache in ihren Einzelheiten dargelegt. Die Wahl der Quellsprache PLIO ist ein Kompromiss zwischen einer Sprache, die allzu trivial ware, urn als lehrreiches Beispiel zu gelten, und einer Sprache, deren Miichtigkeit und Komplexitiit den wirklichen Kern und seine Hauptprinzipien verschleiern wiirde. Fiir alle Programme wird die Sprache Pascal verwendet. Sie erlaubt eine transparente Darstellung komplexer Programme und Datenstrukturen, und sie eignet sich daher fur diesen Themenkreis besonders gut.
The book “Compilerbau” by Nikolaus Wirth managed to present the reader a valuable and broad overview of theoretical informatics, language theory and compiler creation. All theoretical approaches are well formulated and form the basis for today’s advancements in this topic. A huge recommendation for everyone interested.
Wow. Wirth manages to cover almost everything you want to know, in less space, and with less bullshit than any other compiler book I've ever read. What a gem! Had no idea this existed until a week ago and now it's pushed _Modern Compiler Construction_ by Appel out of first place for me.
First thing I want to mention is that this book is NOT from 1977. Per Niklaus Wirth: "The language Oberon, published in 1988, has a long history. It is a descendant of Algol 60 (1960), Pascal (1970), and Modula (1979)"
Per Wirth, the first edition of this book dates to 1996 and the book was slightly revised in 2005. I am currently reading the latter version. The book uses Oberon-0 a predecessor to Oberon.
Now as to the coverage of subject matter: This book is short, but it offered me the most precise, pragmatic and readable definitions of everything around compiler technology I have read so far. I am reading both versions of Aho (Lam), Sethi, Ullman 1989 and 2006 and although more thorough and very formal, they seem to me less precise than the formalisms and explanations that Wirth provides.
This book is written by someone that's been there, done that. A person that has lived through all the complexity then thrown it away, demystified and distilled it to its essential components.
Wirth's book is quite fascinating, in that it shows on relatively few pages how to write a complete compiler for small programming language (think of a simplified version of Pascal). The book is essentially a tutorial on how to step by step refine a parser from the point of building up a syntax tree, over checking the correctness of a program's structure to an actual compiler. There is very little theory here, only a few pages in the beginning that do not really explain anything, so do not expect to get a complete theoretical understanding of everything you are doing here (ideally, you would have acquired the theory before reading this book). But you get a very good idea of how a compiler works by following along the practical implementation, each part of which is preceded by a short but meaningful motivation by Wirth. This is the first book I have read on compiler construction, and I am keen to see how it will help me gaining a deeper understanding with other sources.
Despite it's age, this is still a pretty good introductory book on the principles of compiler construction. Don't get put off by the fact that it uses the language Oberon to build a compiler for a subset of the same, it's easy enough to understand even if you've never seen the language before. Being able to understand same basic Assembler won't hurt though.