Deriving with Derivatives: Optimizing Incremental Fixpoints for Higher-Order Flow Analysis
Attheheartofefficientprogramanalysisimplementationsareincrementalsolutionstofixpointproblems.These solutions can be interpreted as the derivative of the underlying analysis function. Methods that describe how to systematically derive higher-order analyses from program semantics, such as Abstracting Abstract Machines, don’t shed light on how to efficiently implement those analyses. In this paper, we explore complementary techniques to optimize the derivative computation towards deriving efficient implementations. In particular, we use static specializations (by partial evaluation and rewriting) and dynamic specializations (in the form of tracking dependencies during the fixpoint), yielding efficient incremental fixpoints. We present how these optimizations apply to an example analysis of continuation-passing-style 𝜆-calculus, and describe how they pair particularly well with tunable and optimized workset-based fixpoint methods. We demonstrate the efficacy of this approach on a flow analysis for the Standard ML language, yielding an average speed-up of 56x over an existing fixpoint method for higher-order analyses from the literature.
Authors
- Benjamin Quiring (ORCID: https://orcid.org/0000-0002-6922-9706)
- David Van Horn (ORCID: https://orcid.org/0000-0002-9201-6864)
Institutions
- University of Maryland, College Park (US)
Publication Details
- Journal
- Proceedings of the ACM on Programming Languages
- Published
- 2024-08-15
- DOI
- https://doi.org/10.1145/3674650
- Citations
- 2
- Primary Topic
- Data Stream Mining Techniques
- Type
- article
- Field-Weighted Citation Impact
- 0.69