Abstract
It is common practice in compilers to use tables to represent data, and then automatically generate code based on those tables (often known as "table-driven code"). Many compilers use machine description tables from which is automatically generated parts of the code generator, and there are often small pieces of table-driven code within a compiler. Sometimes these tables are very useful, but other times the tables themselves can become a maintenance nightmare. This paper uses examples from several SGI compilers to try and enumerate some guidelines for designing good tables and table-driven code.
- C. A. R. Hoare. "Hints on programming language design". Technical Report CS-73-403, Stanford University Computer Science Department, December 1973. Google Scholar
Digital Library
- http://open64.sourceforge.net/.Google Scholar
- David L. Parnas. "On the Criteria To Be Used in Decomposing Systems into Modules". In Communications of the ACM, December 1972. Google Scholar
Digital Library
Index Terms
Some suggestions for the use of tables in compilers
Recommendations
Modular Compilers Based on Monad Transformers
ICCL '98: Proceedings of the 1998 International Conference on Computer LanguagesThe monadic style of language specification has the advantages of modularity and extensibility: it is simple to add or change features in an interpreter to reflect modifications in the source language. It has proven difficult to extend the method to ...
An open-source compiler and runtime implementation for Coarray Fortran
PGAS '10: Proceedings of the Fourth Conference on Partitioned Global Address Space Programming ModelCoarray Fortran (CAF) comprises a set of proposed language extensions to Fortran that are expected to be adopted as part of the Fortran 2008 standard. In contrast to prior open-source implementation efforts, our approach is to use a single, unified ...






Comments