Have a personal or library account? Click to login
Equivalent Transformations and Regularization in Context-Free Grammars Cover

Equivalent Transformations and Regularization in Context-Free Grammars

Open Access
|Jan 2015

Abstract

Regularization of translational context-free grammar via equivalent transformations is a mandatory step in developing a reliable processor of a formal language defined by this grammar. In the 1970-ies, the multi-component oriented graphs with basic equivalent transformations were proposed to represent a formal grammar of ALGOL-68 in a compiler for IBM/360 compatibles. This paper describes a method of grammar regularization with the help of an algorithm of eliminating the left/right-hand side recursion of nonterminals which ultimately converts a context-free grammar into a regular one. The algorithm is based on special equivalent transformations of the grammar syntactic graph: elimination of recursions and insertion of iterations. When implemented in the system SynGT, it has demonstrated over 25% reduction of the memory size required to store the respective intermediate control tables, compared to the algorithm used in Flex/Bison parsers.

DOI: https://doi.org/10.1515/cait-2014-0003 | Journal eISSN: 1314-4081 | Journal ISSN: 1311-9702
Language: English
Page range: 29 - 44
Published on: Jan 31, 2015
Published by: Bulgarian Academy of Sciences, Institute of Information and Communication Technologies
In partnership with: Paradigm Publishing Services
Publication frequency: 4 issues per year

© 2015 Ludmila Fedorchenko, Sergey Baranov, published by Bulgarian Academy of Sciences, Institute of Information and Communication Technologies
This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 3.0 License.