Grisette: Symbolic Compilation as a Functional Programming Library
Sirui Lu, Rastislav Bodík
Abstract
The development of constraint solvers simplified automated reasoning about programs and shifted the engineering burden to implementing symbolic compilation tools that translate programs into efficiently solvable constraints. We describe Grisette, a reusable symbolic evaluation framework for implementing domain-specific symbolic compilers. Grisette evaluates all execution paths and merges their states into a normal form that avoids making guards mutually exclusive. This ordered-guards representation reduces the constraint size 5-fold and the solving time more than 2-fold. Grisette is designed entirely as a library, which sidesteps the complications of lifting the host language into the symbolic domain. Grisette is purely functional, enabling memoization of symbolic compilation as well as monadic integration with host libraries. Grisette is statically typed, which allows catching programming errors at compile time rather than delaying their detection to the constraint solver. We implemented Grisette in Haskell and evaluated it on benchmarks that stress both the symbolic evaluation and constraint solving.
Ask about this paper
Ask your agent about it.
Lune has read the top-tier papers around this one, so every answer names the papers it rests on.
Cited by top-tier papers8
- TensorRight: Automated Verification of Tensor Graph RewritesJai Arora, Sirui Lu, Devansh Jain, Tianfan Xu et al.POPL 2025 · 6 citations
- Superfusion: Eliminating Intermediate Data Structures via Inductive SynthesisRuyi Ji, Yuwei Zhao, Nadia Polikarpova, Yingfei Xiong et al.PLDI 2024 · 4 citations
- Synthesizing DSLs for Few-Shot LearningPaul Krogmeier, P. MadhusudanOOPSLA 2025 · 1 citation
- HieraSynth: A Parallel Framework for Complete Super-Optimization with Hierarchical Space DecompositionSirui Lu, Rastislav BodíkOOPSLA 2025
- Soteria: Efficient Symbolic Execution as a Functional Library: Perhaps You Should Write Your Own Symbolic Execution Engine!Sacha-Élie Ayoun, Opale Sjöstedt, Azalea RaadPLDI 2026
Related papers
- A formal foundation for symbolic evaluation with mergingSorawee Porncharoenwase, Luke Nelson, Xi Wang, Emina TorlakPOPL 2022 · 13 citations
- State Merging with Quantifiers in Symbolic ExecutionDavid Trabish, Noam Rinetzky, Sharon Shoham, Vaibhav SharmaFSE 2023 · 5 citations
- Type Inference LogicsDenis Carnier, François Pottier, Steven KeuchelOOPSLA 2024 · 3 citations
- Engineering a Formally Verified Automated Bug FinderArthur Correnson, Dominic SteinhöfelFSE 2023 · 6 citations
- PureCake: A Verified Compiler for a Lazy Functional LanguageHrutvik Kanabar, Samuel Vivien, Oskar Abrahamsson, Magnus O. Myreen et al.PLDI 2023 · 7 citations
