Abstract interfaces for compiler generating tools
The main tasks in compiler construction are solved by systematic algorithms. Tools are available which generate compiler modules from specifications. They are often developed as closed stand-alone systems difficult to combine with other tools. Integration of their products requires considerable engineering work and may loose efficiency because the tools fix all implementation decisions.
In order to improve the applicability of generating tools we suggest in this paper a modular tool structure: The central part of the generator translates an abstract representation of a specification into an abstract algorithm. These interfaces are open to meet the requirements of the tools environment by variations of the frontends and backends. Especially the implementation decisions for the generated products are separated from the generation of the abstract algorithm. We demonstrated this design principle applied to the development of a CFG toolset and an attribute evaluator generator.
Further work should be devoted to the development of other compiler tools on that base and to increase the variants of the existing tools. Furthermore we believe that the design principle is as well applicable to tools of areas different from compiler construction.
KeywordsFinite State Machine Abstract Representation Tool Integration Attribute Evaluator Attribute Grammar
- ASU 86.Aho, A.V., R. Sethi and J.D. Ullman, “Compilers”, Addison Wesley, Reading MA, 1986Google Scholar
- Bu 88.Budde, V., “Werkzeuge zur Grammatik-Transformation und LL-Parsergenerierung auf der COMAR-Datenbasis, Diplomarbeit, FB 17, Universität-GH Paderborn, 1988Google Scholar
- Cl 88.Clemm, G.M., “The Odin Specification Language”, in International Workshop on Software Version and Configuration Control '88, Teubner, Stuttgart, 1988, 144–158Google Scholar
- De 77.Dencker, P. “Ein neues LALR-System”, Institut für Informatik, Universität Karlsruhe, Diplomarbeit, 1977Google Scholar
- Ha 87.Hall, M.L., “The Optimization of Automatically Generated Compilers”, Ph.D. Thesis, Dept. of Computer Science, University of Colorado, Boulder, CO. 1987Google Scholar
- HKPW 87.Heuring, V.P., Kastens, U., Plummer, R.G., Waite, W.M., “COMAR: A Data Format for Integration of CFG-Tools”, University of Colorado, Boulder, ECE-Report 87/124, 1987, to appear in The Computer JournalGoogle Scholar
- Jo 75.Johnson, S.C., “YACC — Yet Another Compiler-Compiler”, Computer Science Technical Report 32, Bell Telephone Laboratories, Murray Hill, NJ, July 1975Google Scholar
- Ka 80.Kastens, U. “Ordered Attributed Grammars”, Acta Informatica 13, 229–256, 1980Google Scholar
- Ka 87.Kastens, U. “Lifetime Analysis for Attributes”, Acta Informatica 24, 633–651, 1987Google Scholar
- KHZ 82.Kastens, U., Hutt, B., Zimmermann, E. “GAG — A Practical Compiler Generator”, Lecture Notes in Computer Science 141, Springer, 1982Google Scholar
- La 87.Lamb, D.A., “IDL: Sharing Intermediate Representations”, TOPLAS, vol. 9, no. 3, 1987, 297–318Google Scholar
- Le 75.Lesk, M.E., “LEX — A Lexical Analyzer Generator”, Computer Science Technical Report 39, Bell Telephone Laboratories, Murray Hill, NJ, 1975Google Scholar
- SS 86.Snodgrass, R., Shannon, K., “Supporting flexible and efficient tool integration”, SoftLab Document No. 25, Computer Science Department, University of North Carolina, Chapel Hill, N.C., May 1986Google Scholar
- WG 84.Waite, W.M., G. Goos, “Compiler Construction”, Springer Verlag, New York, NY, 1984Google Scholar
- WHK 88.Waite, W.M., Heuring, V.P., Kastens, U. “Configuration Control in Compiler Construction”, Int'l Workshop on Software Version and Configuration Controll SVCC, Grassau, Januar 88Google Scholar