An efficient context-free parsing algorithm
Open Access
- 1 February 1970
- journal article
- research article
- Published by Association for Computing Machinery (ACM) in Communications of the ACM
- Vol. 13 (2), 94-102
- https://doi.org/10.1145/362007.362035
Abstract
A parsing algorithm which seems to be the most efficient general context-free algorithm known is described. It is similar to both Knuth's LR(k) algorithm and the familiar top-down algorithm. It has a time bound proportional to n3 (where n is the length of the string being parsed) in general; it has an n2 bound for unambiguous grammars; and it runs in linear time on a large class of grammars, which seems to include most practical context-free programming language grammars. In an empirical comparison it appears to be superior to the top-down and bottom-up algorithms studied by Griffiths and Petrick.Keywords
This publication has 5 references indexed in Scilit:
- A Syntax-Analysis Procedure for Unambiguous Context-Free GrammarsJournal of the ACM, 1969
- Translator writing systemsCommunications of the ACM, 1968
- Recognition and parsing of context-free languages in time n3Information and Control, 1967
- On the translation of languages from left to rightInformation and Control, 1965
- On the relative efficiencies of context-free grammarCommunications of the ACM, 1965