PD Yacc slows down

corbett@ernie.Berkeley.EDU (Robert Corbett)
13 Nov 89 06:24:16 GMT

          From comp.compilers

Related articles
PD Yacc slows down corbett@ernie.Berkeley.EDU (1989-11-13)
| List of all articles for this month |

From: corbett@ernie.Berkeley.EDU (Robert Corbett)
Newsgroups: comp.compilers
Date: 13 Nov 89 06:24:16 GMT
Distribution: usa
Organization: University of California, Berkeley

I have nearly completed the next version of Berkeley Yacc. Some of the
changes were to make error recovery more effective (though Yacc error recovery
is never very effective). If a state contains a reduction where the lookahead
is the error token, no default reduction is used in that state. For one of my
test grammars, this change has doubled the table size and the time required to
generate the tables. The bulk of the time (45%) was spent in fprintf.

I made this change in response to the footnote on page 71 of the book
Introduction to Compiler Construction with UNIX by Schreiner and Friedman.
I am beginning doubt if the resulting improvement is worth the cost.
I have devised a way of achieving the same effect without increasing the
size of the tables. However, my alternative will make parsing slower.

Yours truly,
Robert Paul Corbett
[From corbett@ernie.Berkeley.EDU (Robert Corbett)]

Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.