Compiling by Proving: Language-Agnostic Automatic Optimization from Formal Semantics
Zhao, Jianhong, Hildenbrandt, Everett, Conejero, Juan, Zhao, Yongwang
–arXiv.org Artificial Intelligence
Verification proofs encode complete program behavior, yet we discard them after checking correctness. We present compiling by proving, a paradigm that transforms these proofs into optimized execution rules. By constructing All-Path Reachability Proofs through symbolic execution and compiling their graph structure, we consolidate many semantic rewrites into single rules while preserving correctness by construction. We implement this as a language-agnostic extension to the K framework. Evaluation demonstrates performance improvements across different compilation scopes: opcode-level optimizations show consistent speedups, while whole-program compilation achieves orders of magnitude greater performance gains.
arXiv.org Artificial Intelligence
Sep-29-2025
- Country:
- Europe > United Kingdom > England > Cambridgeshire > Cambridge (0.04)
- Genre:
- Research Report (0.50)
- Industry:
- Banking & Finance (0.47)
- Information Technology > Security & Privacy (0.68)
- Technology: