Files in this item



application/pdfUIUCDCS-R-2008-3018.pdf (384kB)
(no description provided)PDF


Title:Staging Static Analyses for Program Generation (Extended Version)
Author(s):Aktemur, T. Baris; Kamin, Samuel; Katelman, Michael
Subject(s):Computer science
Abstract:Program generators are most naturally specified using a quote/antiquote facility; the programmer writes programs with holes which are filled in, at program generation time, by other program fragments. If the programs are generated at compile-time, analysis and compilation follow generation, and no changes in the compiler are needed. However, if program generation is done at run time, compilation and analysis need to be optimized so that they will not overwhelm overall execution time. In this paper, we give a compositional framework for defining program analyses which leads directly to a method of staging these analyses. The staging allows the analysis of incomplete programs to be started at compile time; the residual work to be done at run time may be much less costly than the full analysis. We give frameworks for forward and backward analyses, present several examples of specific analyses, and give timing results showing significant speed-ups for the run-time portion of the analysis relative to the full analysis. Our framework is defined on abstract syntax trees (AST), because program fragments appear as AST's. We give a translation from source-level code to an intermediate representation (IR) and show that our staging methodology is applicable at the IR-level, too.
Issue Date:2008-12
Date Available in IDEALS:2009-04-16

This item appears in the following Collection(s)

Item Statistics