johnl@ima.UUCP (07/15/87)
I'm not an expert on all this, but... Its strong points are the
description of LR parsing and the more machine-independent aspects of
code optimization. The parsing stuff is very helpful, because Yacc
(or one of its clones) is really the only sensible way to build a
parser anymore.
Its weak point is the lack of discussion about the really hairy
aspects of run-time storage and stack handling. I much prefered
Gries' "Compiler Construction for Digital Computers". (But don't
bother reading the chapters on parsing -- they're all precedence
techniques.) I attribute this to the Gries' coming from the Algol
(European) tradition, where these things have to be attended to
carefully; whereas AHU come from a more Fortran/C (American)
background, where you don't even have nested procedures, fer
chrissake.
Dale
[I always thought that the lack of attention to LR parsers was a social
phemonenon. Lots of people had programs that turned a BNF grammar into LR
state changes, but it was always up to you to wrap a parser and semantic
routines around them. Yacc was the first to create a usable language in which
you could write an LR parser. At that point, everybody started to use
bottom-up parsers, because they were made so easy to write. But the reason I
really hated Gries' book is that it was reproduced from ugly 1403 line printer
output. -John]
--
Send compilers articles to ima!compilers or, in a pinch, to Levine@YALE.ARPA
Plausible paths are { ihnp4 | decvax | cbosgd | harvard | yale | cca}!ima
Please send responses to the originator of the message -- I cannot forward
mail accidentally sent back to compilers. Meta-mail to ima!compilers-requeststeve@hubcap.clemson.edu (Steve (D.E.) Stevenson) (07/16/87)
Is there any plan to redo and update Gries' book? It seems to be a closet
favorite. In particular, it seems to be the only book that really gets into
the nitty-gritty.
I also agree that LR is a social phenomenon. I also contend that YACC has
done as much to hurt parsing as help it.
Steve
--
Send compilers articles to ima!compilers or, in a pinch, to Levine@YALE.ARPA
Plausible paths are { ihnp4 | decvax | cbosgd | harvard | yale | cca}!ima
Please send responses to the originator of the message -- I cannot forward
mail accidentally sent back to compilers. Meta-mail to ima!compilers-request