ABSTRACT
A compiler is traditionally partitioned into a (mostly) machine independent Front End which performs lexical, syntactic, and semantic analysis, and a machine dependent Back End which performs optimization and code generation. In the Ada compiler being implemented at Carnegie-Mellon University in the PQCC project, it is useful to identify a set of phases occurring at the start of the Back End - i.e., “Middle End” - after semantic analysis but before optimization. These phases, known collectively as “CWVM” (an abbreviation for “Compiler Writer's Virtual Machine”) make basic representational choices and reflect these in an expanded program tree. This paper describes both TCOLAda - the intermediate language interface produced by the Front End - and the phases comprising CWVM. TCOLAda is a graph structured high level representation of the source program which includes both the symbol table and the program tree. The CWVM phases perform transformations of the TCOLAda graph which fall into three categories: language oriented (e.g., expansion of checking for constructs such as array indexing), virtual machine oriented (e.g., translation of up-level addressing into “display” vector accesses), and actual machine oriented (e.g., expansion of component selection into address arithmetic).
- 1.Proc. of SIGPLAN Symposium on the Ada Programming Language, December 1980.Google Scholar
- 2."Types and Type Resolution in Ada: an Implementation Report", in {ACM 80}.Google Scholar
- 3.B.M. Brosgol, J.M. Newcomer, D.A. Lamb, D.R. Levine, M.S. Van Deusen, W.A. Wulf. TCOLAda: Revised Report on an Intermediate Representation for the Preliminary Ada Language. Technical Report CMU-CS-80-105, Carnegie-Mellon University, February 1980.Google Scholar
- 4.M. Dausmann, S. Drossopoulou, G. Goos, G. Persch, G. Winterstein. AIDA-An Informal Introduction, University of Karlsruhe, Germany, February 1980.Google Scholar
- 5.Digital Equipment Corporation.VAX-11/780 Architecture Handbook, 1977.Google Scholar
- 6.U.S. Department of Defense. Reference Manual for the Ada Programming Language. Proposed Standard Document, July 1980.Google Scholar
- 7.B.W. Leverett. The Packing Problem in Optimizing Compilers, Ph.D. Thesis. Carnegie-Mellon University, to be published.Google Scholar
- 8.B.W. Leverett, R.G.G. Cattell, S.O. Hobbs, J.M. Newcomer, A.H. Reiner, B.R. Schatz, W.A. Wulf. "An Overview of the Production-Quality Compiler-Compiler Project", Computer, Vol. 13, No. 8, August 1980.Google Scholar
- 9.R.W. Scheifler. "An Analysis of Inline Substitution for a Structured Programming Language", Communications of the ACM 20(9): 647-654, Sept. 1977. Google ScholarDigital Library
- 10.M. Sherman, M. Borkan. "A Flexible Semantic Analyzer for Ada," in {ACM 80}.Google Scholar
- 11.C. Wetherell and A. Shannon. LR: Automatic Parser Generator and LR(1) Parser, Lawrence Livermore Laboratory, Preprint UCRL-82926, June 1979.Google Scholar
- 12.W. Wulf, P. Feiler, J. Zinnikas, R. Brender. "A Quantitative Technique for Comparing the Quality of Compiler Code Generation", Tech. Report, Carnegie-Mellon Univ. (to be published).Google Scholar
Index Terms
- TCOLAda and the “Middle End” of the PQCC Ada compiler
Recommendations
TCOLAda and the "middle end" of the PQCC Ada compiler
SIGPLAN '80: Proceedings of the ACM-SIGPLAN symposium on Ada programming languageA compiler is traditionally partitioned into a (mostly) machine independent Front End which performs lexical, syntactic, and semantic analysis, and a machine dependent Back End which performs optimization and code generation. In the Ada compiler being ...
TCOLAda and the "middle end" of the PQCC Ada compiler
Proceedings of the ACM-SIGPLAN symposium on the Ada programming languageA compiler is traditionally partitioned into a (mostly) machine independent Front End which performs lexical, syntactic, and semantic analysis, and a machine dependent Back End which performs optimization and code generation. In the Ada compiler being ...
The als Ada compiler front end architecture
AdaTEC '82: Proceedings of the AdaTEC Conference on AdaThis paper describes the architecture of the Ada Language System (ALS) Ada compiler front end. It examines the motivation for the architecture chosen and how this architecture has affected the implementation. The paper also examines the use of the ...
Comments