Monadic Abstract Interpreters

被引:18
|
作者
Sergey, Ilya
Devriese, Dominique [1 ]
Might, Matthew [2 ]
Midtgaard, Jan [3 ]
Darais, David [4 ]
Clarke, Dave [1 ]
Piessens, Frank [1 ]
机构
[1] Katholieke Univ Leuven, iMinds DistriNet, Louvain, Belgium
[2] Univ Utah, Salt Lake City, UT 84112 USA
[3] Aarhus Univ, DK-8000 Aarhus C, Denmark
[4] Harvard Univ, Cambridge, MA 02138 USA
关键词
Languages; Theory; abstract machines; abstract interpretation; monads; operational semantics; collecting semantics; abstract garbage collection; interpreters; MACHINES;
D O I
10.1145/2499370.2491979
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Recent developments in the systematic construction of abstract interpreters hinted at the possibility of a broad unification of concepts in static analysis. We deliver that unification by showing context-sensitivity, polyvariance, flow-sensitivity, reachability-pruning, heap-cloning and cardinality-bounding to be independent of any particular semantics. Monads become the unifying agent between these concepts and between semantics. For instance, by plugging the same "context-insensitivity monad" into a monadically-parameterized semantics for Java or for the lambda calculus, it yields the expected context-insensitive analysis. To achieve this unification, we develop a systematic method for transforming a concrete semantics into a monadically-parameterized abstract machine. Changing the monad changes the behavior of the machine. By changing the monad, we recover a spectrum of machines-from the original concrete semantics to a monovariant, flow- and context-insensitive static analysis with a singly-threaded heap and weak updates. The monadic parameterization also suggests an abstraction over the ubiquitous monotone fixed-point computation found in static analysis. This abstraction makes it straightforward to instrument an analysis with high-level strategies for improving precision and performance, such as abstract garbage collection and widening. While the paper itself runs the development for continuation-passing style, our generic implementation replays it for direct-style lambda-calculus and Featherweight Java to support generality.
引用
收藏
页码:399 / 409
页数:11
相关论文
共 50 条
  • [11] Refunctionalization of Abstract Abstract Machines Bridging the Gap between Abstract Abstract Machines and Abstract Definitional Interpreters (Functional Pearl)
    Wei, Guannan
    Decker, James
    Rompf, Tiark
    PROCEEDINGS OF THE ACM ON PROGRAMMING LANGUAGES, 2018,
  • [12] Lifting Abstract Interpreters to Quantified Logical Domains
    Gulwani, Sumit
    McCloskey, Bill
    Tiwari, Ashish
    POPL'08: PROCEEDINGS OF THE 35TH ANNUAL ACM SIGPLAN-SIGACT SYMPOSIUM ON PRINCIPLES OF PROGRAMMING LANGUAGES, 2008, : 235 - 246
  • [13] Monadic Interpreters for Concurrent Memory Models Executable Semantics of a Concurrent Subset of LLVM IR
    Chappe, Nicolas
    Henrio, Ludovic
    Zakowski, Yannick
    PROCEEDINGS OF THE 14TH ACM SIGPLAN INTERNATIONAL CONFERENCE ON CERTIFIED PROGRAMS AND PROOFS, CPP 2025, 2025, : 283 - 298
  • [14] Structuring Abstract Interpreters Through State and Value Abstractions
    Blazy, Sandrine
    Buehler, David
    Yakobowski, Boris
    VERIFICATION, MODEL CHECKING, AND ABSTRACT INTERPRETATION, VMCAI 2017, 2017, 10145 : 112 - 130
  • [15] Abstract Hidden Markov Models: a monadic account of quantitative information flow
    McIver, Annabelle
    Morgan, Carroll
    Rabehaja, Tahiry
    2015 30TH ANNUAL ACM/IEEE SYMPOSIUM ON LOGIC IN COMPUTER SCIENCE (LICS), 2015, : 597 - 608
  • [16] Understanding Convolutional Networks Using Linear Interpreters Extended Abstract
    Michelini, Pablo Navarrete
    Liu, Hanwen
    Lu, Yunhua
    Jiang, Xingqun
    2019 IEEE/CVF INTERNATIONAL CONFERENCE ON COMPUTER VISION WORKSHOPS (ICCVW), 2019, : 4186 - 4189
  • [17] ABSTRACT HIDDEN MARKOV MODELS: A MONADIC ACCOUNT OF QUANTITATIVE INFORMATION FLOW
    Mciver, Annabelle
    Morgan, Carroll
    Rabehaja, Tahiry
    LOGICAL METHODS IN COMPUTER SCIENCE, 2019, 15 (01) : 36:1 - 36:50
  • [18] A functional correspondence between monadic evaluators and abstract machines for languages with computational effects
    Ager, MS
    Danvy, O
    Midtgaard, J
    THEORETICAL COMPUTER SCIENCE, 2005, 342 (01) : 149 - 172
  • [19] Galois Transformers and Modular Abstract Interpreters Reusable Metatheory for Program Analysis
    Darais, David
    Might, Matthew
    Van Horn, David
    ACM SIGPLAN NOTICES, 2015, 50 (10) : 552 - 571
  • [20] Combinator-Based Fixpoint Algorithms for Big-Step Abstract Interpreters
    Keidel, Sven
    Erdweg, Sebastian
    Hombuecher, Tobias
    PROCEEDINGS OF THE ACM ON PROGRAMMING LANGUAGES-PACMPL, 2023, 7 (ICFP):