18 of 18 people found the following review helpful:
5.0 out of 5 stars
I taught from this book, May 6, 2003
This review is from: Compiler Construction: Principles and Practice (Paperback)
This is an excellent basic book on compilers. Its strength is its strong practical approach combined with using YACC/LEX technology. It hand holds you through the development of a simple compiler. If I wanted to learn about compilers I would read this first. Its weakness is it is too narrow. There are plenty of features of languages that are not addressed but in passing. Its goal is to get a compiler built. For a compilers 101 class there is no better book.
Help other customers find the most helpful reviews
Was this review helpful to you? Yes
No
13 of 13 people found the following review helpful:
5.0 out of 5 stars
Great book on a tough subject, August 21, 2005
This review is from: Compiler Construction: Principles and Practice (Paperback)
I am studying for an M.S in software construction/engineering and this book was used for a compiler course. This review is written from my perspective as a student required to understand the information.
The language: The book is written in a clear and frindly "student"-friendly tone. It is actually like the author understands that I am a student and seeing this subject for the first time. The language is straightforward and not over-complex as I have seen it in other books used by instructors.
The structure: As a student i liked the content of the exercises a great deal. They kept focus on things which had been discussed earlier and this is always a good thing. I was able to keep pace with the reading and to follow the course at the same time - this is quite a feat (though maybe i just pulled myself together this time).
Content: It should be no problem for any instructor to plan the teaching using this book. The first chapters introduces compilers and the idea of simple text-recognition using regular expressions and finite automatas and moves on from there by introducing the BNF notation to write context-free grammers. Three chapters explains the essence of CF grammers and top-down and bottom-up parsers in a clear and friendly way.
The book uses the C language to show programming examples. Personally i had not problems but some might feel that the use of pseudo-code would be more appropiate. The book describes the construction of a simple compiler (written in C) for a simple programming language. C or pseudo-code - i like this way of doing a real example which is followed all the way through the book. The entire C source-code for this compiler is presented in the back of the book and used as reference through the chapters.
But - have you never seen the C programming language before, perhaps another book was better. It tries to keep focus on the clean understanding on the theory of parsers, semantic analysis and also later on code optimization. How to program compilers in an object oriented manner is not described, which i believe is okay since it would move the focus away from what is important here. There are books with focus on implementation of compilers in Java for instance, which could be a better choice if you are not a C programmer.
All in all - a good compiler book for students if the instructor teaches by the structure of the book and uses the exercises in class. But it can also be used for self-study.
Help other customers find the most helpful reviews
Was this review helpful to you? Yes
No
16 of 17 people found the following review helpful:
4.0 out of 5 stars
Nice book for self-paced hands-on approach, September 7, 2001
By A Customer
This review is from: Compiler Construction: Principles and Practice (Paperback)
Unlike some of the classic compiler texts (ex: Aho), this one has the benefit of coming with a hands-on project, in which you take a working codebase for a tiny language (without even functions in it) and turn it into a compiler for "C-", a fairly minimal subset of C (no pointers, for instance, but function calls and a number of other elements are added: it'll keep you busy). Personally I found it useful to have something concrete to work on while learning material that is otherwise quite abstract: actually writing a scanner and parser for a language makes it all soak in a lot better. Note that the target of the compiler you build is an interpreter, so you target an intermediate language rather than actual machine code. But that's interesting in itself, and you can always change it to crank out machine code if you've got a nice chunk of extra time on your hands.
The book is also shorter than Aho, which can either be good or bad, depending on what you're looking for. It reads fairly well, though there are a few typos that can be confusing, and it seems to be fairly rigorous in the topics it covers.
Help other customers find the most helpful reviews
Was this review helpful to you? Yes
No