A Systematic Approach to Static Analysis of Program Transformations

Sebastian Erdweg


Date: Tue, June 18, 2019
Time: 17:00
Room: Snijderszaal LB.01.010 (building 36)


Static analyses deduct information about programs at compile time, for example, to provide feedback to developers, to find bugs, or to enable compiler optimizations. While static analysis is generally well-understood, the static analysis of program transformations has not seen much attention. The main challenge in developing a static analysis for program transformations is designing good abstractions that capture relevant information about the generated code. However, a complete static analysis must handle many other aspects of the transformation language, such as backtracking and generic traversals, as well as analysis-specific concerns, such as interprocedurality and fixpoints. This deflects attention. We propose a systematic approach to design and implement static analyses for program transformations that isolates the abstraction for generated code from other analysis aspects. Using our approach, analysis developers can focus on the design of abstractions for generated code, while the rest of the analysis definition can be reused. We show that our approach is feasible and useful by developing three novel inter-procedural analyses for the Stratego transformation language: a singleton analysis for constant propagation, a sort analysis for type checking, and a locally-illsorted sort analysis that can additionally validate type changing generic traversals.


Previous: Ralf Lämmel |
Next: |