Abstract
Implementing an optimizing compiler for a new target architecture has traditionally been a complex design/development effort requiring a large time scale. Existing machine descriptions and approaches based on pre-existing internal representations (IR) are not sufficient to build truly modular and extensible compilers. This paper describes the features of the Extensible Compiler Interface (ECI) implemented in the PROMIS compiler, which tackles several major problems concerning the reuse of compiler components, retargeting as well as extending existing compilers with new functionality. One of the main design issues is maintaining analysis information calculated by one module after another potentially unknown module modifies the IR. Another problem is expanding existing modules (or passes) to work with processor-specific instructions and data types added by the compiler developers. Our approach to compiler extensibility through the proposed ECI tackles and solves the above problems, and provides a simple yet powerful API for adding arbitrary functionality or entirely new optimizations to existing compilers. A case study is presented in which the components of a parallelizing compiler are reused to build a compiler for a vector architecture, thereby demonstrating the utility and convenience of ECI.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
A. Appel, J. Davidson, and N. Ramsey. The Zephyr compiler infrastructure, 1998.
W.E. Cohen. Automatic Construction of Optimizing, Parallelizing Compilers from Specifications. PhD thesis, Purdue University, December 1994.
CSRD. PROMIS Manual ( http://promis.csrd.uiuc.edu/ ). Urbana, Illinois.
C. Fraser, R. Henry, and T. Proebsting. BURG — Fast Optimal Instruction Selection and Tree Parsing, April 1992.
Edison Design Group. http://www.edg.com/.
L.J. Hendren, C. Donawa, M. Emami, G. R. Gao, Justiani, and B. Sridharan. Designing the McCAT Compiler Based on a Family of Structured Intermediate Representations. In Proceedings of the 5th International Workshop on Languages and Compilers for Parallel Computing, pages 406–420. Springer-Verlag, LNCS 757, 1993.
G. Holloway and M.D. Smith. An Extender’s Guide to the Optimization Programming Interface and Target Descriptions. Harvard University, 2000.
S. C. Johnson. Yacc: Yet another compiler compiler. In UNIX Programmer’s Manual, volume 2, pages 353–387. Holt, Rinehart, and Winston, New York, NY, USA, 1979.
W. Ko. The Promis Universal Machine Descriptor: Concepts, Design, and Implementation. Master’s thesis, University of Illinois, Urbana, Illinois, 2001.
M. E. Lesk. Lex — A lexical analyzer generator. Technical Report No. 39, AT&T Bell Laboratories, Murray Hill, N.J., 1975.
H. Saito, N. Stavrakos, Steve Carroll, Constantine Polychronopoulos, and Alex Nicolau. The design of the PROMIS compiler. In Proceedings of the International Conference on Compiler Construction (CC), March 1999. Also available in Lecture Notes in Computer Science No. 1575 (Springer-Verlag) and as CSRD Technical Report No. 1539 (rev.1).
H. Saito, N. Stavrakos, C. Polychronopoulos, and A. Nicolau. The Design of the PROMIS Compiler — Towards Multi-Level Parallelization. International Journal of Parallel Programming, 28(2), 2000.
M. Smith. Extending SUIF for Machine-dependent Optimizations. In Proc. First SUIF Compiler Workshop, January 1996.
M.D. Smith and G. Holloway. An Introduction to Machine SUIF and Its Portable Libraries for Analysis and Optimization. Harvard University, 2000.
N. Stavrakos, S. Carroll, H. Saito, C. Polychronopoulos, and A. Nicolau. Symbolic analysis in the PROMIS compiler. In Proceedings of the International Workshop on Languages and Compilers for Parallel Computing (LCPC), August 1999. Also available in Lecture Notes in Computer Science (Springer-Verlag). Extended version available as CSRD Technical Report No. 1564.
D. Whitfield and M.L. Soffa. An approach to ordering optimizing transformations. In Proceedings of ACM SIGPLAN Symposium on Principles and Practices of Parallel Programming (PPoPP), March 1990.
R. Wilson, R. French, C. Wilson, S. Amarasinghe, J. Anderson, S. Tjiang, S. Liao, C. Tseng, M. Hall, M. Lam, and J. Hennessy. The SUIF compiler system: a parallelizing and optimizing research compiler. Technical Report CSL-TR-94-620, Stanford University, May 1994.
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2003 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Carroll, S., Ko, W., Yankelevsky, M., Polychronopoulos, C. (2003). Optimizing Compiler Design for Modularity and Extensibility. In: Dietz, H.G. (eds) Languages and Compilers for Parallel Computing. LCPC 2001. Lecture Notes in Computer Science, vol 2624. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-35767-X_1
Download citation
DOI: https://doi.org/10.1007/3-540-35767-X_1
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-04029-3
Online ISBN: 978-3-540-35767-4
eBook Packages: Springer Book Archive