Nothing Special   »   [go: up one dir, main page]

skip to main content
article
Free access

Limitations of Graham-Glanville style code generation

Published: 01 February 1987 Publication History

Abstract

In recent years, the Graham-Glanville approach to code generation has become an increasingly important influence on new compiler writing projects. Initial enthusiasm prompted by the early research results has now fueled projects with more practical goals and requirements. This paper reports on the early results of a long-term project that is applying the Graham-Glanville method to the creation of an industrial-quality multi-language, multi-target compiler system. Much of the resulting code generation system deals with matters that are not fully handled by the Graham-Glanville method. We present a derailed list of the limitations encountered and, for each, the extension or modification that was invented to deal with it.Our conclusion is that the Graham-Glanville method does not always fulfill its early promise of generating locally-optimal code. Production-quality retargetable compiler generation still requires clever organization and many sophisticated algorithms to achieve this goal in the presence of register allocation and cost analysis.

References

[1]
[Aho 85] Aho, A. V., and Ganapathi, M. Efficient Tree Pattern Matching: an Aid to Code Generation. In Twelfth ACM Symposium on the Principles of Programming Languages (POPL), pages 334-340. ACM, January, 1985.
[2]
[Christopher 84] Christopher, T. W., Hatcher, P. J., and Kukuk, R. C. Using Dynamic programming to Generate Optimized Code in a Graham-Glanville Style Code Generator. In SIGPLAN '84 Symposium on Compiler Construction, pages 25-36. ACM, June, 1984.
[3]
[Crawford 82] Crawford, J. Engineering a Production Code Generator. In SIGPLAN '82 Symposium on Compiler Construction, pages 205-215. ACM, June, 1982.
[4]
[Ganapathi 80] Ganapathi, M. Retargetable Code Generation and Optimization Using Attribute Grammars. PhD thesis, University of Wisconsin - Madison, 1980.
[5]
[Glanville 77] Glanville, R. S. A Machine Independent Algorithm for Code Generation and Its Use in Retargetable Compilers. PhD thesis, University of California - Berkeley, 1977.
[6]
[Graham 80] Graham, S. L. Table-Driven Code Generation. IEEE Computer 13(8):25-33, August, 1980.
[7]
[Graham 84] Aigrain, P., Graham, S. L., Henry, R. R., McKusick, M. K., and Pelegri-Llopart, E. Experience with a Graham-Glanville Style Code Generator. In SIGPLAN '84 Symposium on Compiler Construction, pages 13-24. ACM, June, 1984.
[8]
[Henry 84] Henry, R. R. Graham-Glanville Code Generators. PhD thesis, University of California - Berkeley, 1984.
[9]
[Hoffman 82] Hoffman, C. M. and O'Donnell, M. J. Pattern Matching in Trees. J ACM 29(1):68-95, January, 1982.
[10]
[Kron 75] Kron, H. H. Tree Templates and Subtree Transformational Grammars. PhD thesis, University of California - Santa Cruz, 1975.

Recommendations

Comments

Please enable JavaScript to view thecomments powered by Disqus.

Information & Contributors

Information

Published In

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 01 February 1987
Published in SIGPLAN Volume 22, Issue 2

Check for updates

Qualifiers

  • Article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • 0
    Total Citations
  • 173
    Total Downloads
  • Downloads (Last 12 months)35
  • Downloads (Last 6 weeks)8
Reflects downloads up to 02 Oct 2024

Other Metrics

Citations

View Options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Get Access

Login options

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media