Affiliation:
1. MIT CSAIL, Cambridge, USA
2. MIT CSAIL, Cambridge, MA, USA
Abstract
We present Fiat, a library for the Coq proof assistant supporting refinement of declarative specifications into efficient functional programs with a high degree of automation. Each refinement process leaves a proof trail, checkable by the normal Coq kernel, justifying its soundness. We focus on the synthesis of abstract data types that package methods with private data. We demonstrate the utility of our framework by applying it to the synthesis of query structures -- abstract data types with SQL-like query and insert operations. Fiat includes a library for writing specifications of query structures in SQL-inspired notation, expressing operations over relations (tables) in terms of mathematical sets. This library includes a suite of tactics for automating the refinement of specifications into efficient, correct-by-construction OCaml code. Using these tactics, a programmer can generate such an implementation completely automatically by only specifying the equivalent of SQL indexes, data structures capturing useful views of the abstract data. Throughout we speculate on the new programming modularity possibilities enabled by an automated refinement system with proved-correct rules.
Funder
Defense Advanced Research Projects Agency
Division of Computing and Communication Foundations
Publisher
Association for Computing Machinery (ACM)
Subject
Computer Graphics and Computer-Aided Design,Software
Cited by
14 articles.
订阅此论文施引文献
订阅此论文施引文献,注册后可以免费订阅5篇论文的施引文献,订阅后可以查看论文全部施引文献
1. Symbolic metaprogram search improves learning efficiency and explains rule learning in humans;Nature Communications;2024-08-10
2. UTC Time, Formally Verified;Proceedings of the 13th ACM SIGPLAN International Conference on Certified Programs and Proofs;2024-01-09
3. Cyclic program synthesis;Proceedings of the 42nd ACM SIGPLAN International Conference on Programming Language Design and Implementation;2021-06-18
4. Synthesizing data structure refinements from integrity constraints;Proceedings of the 42nd ACM SIGPLAN International Conference on Programming Language Design and Implementation;2021-06-18
5. Concise Read-Only Specifications for Better Synthesis of Programs with Pointers;Programming Languages and Systems;2020