Author:
MYREEN MAGNUS O.,OWENS SCOTT
Abstract
AbstractThe higher-order logic found in proof assistants such as Coq and various HOL systems provides a convenient setting for the development and verification of functional programs. However, to efficiently run these programs, they must be converted (or ‘extracted’) to functional programs in a programming language such as ML or Haskell. With current techniques, this step, which must be trusted, relates similar looking objects that have very different semantic definitions, such as the set-theoretic model of a logic and the operational semantics of a programming language. In this paper, we show how to increase the trustworthiness of this step with an automated technique. Given a functional program expressed in higher-order logic, our technique provides the corresponding program for a functional language defined with an operational semantics, and it provides a mechanically checked theorem relating the two. This theorem can then be used to transfer verified properties of the logical function to the program. We have implemented our technique in the HOL4 theorem prover, translating functions to a subset of Standard ML, and have applied the implementation to examples including functional data structures, a parser generator, cryptographic algorithms, a garbage collector and the 500-line kernel of the HOL light theorem prover. This paper extends our previous conference publication with new material that shows how functions defined in terms of a state-and-exception monad can be translated, with proofs, into stateful ML code. The HOL light example is also new.
Publisher
Cambridge University Press (CUP)
Cited by
33 articles.
订阅此论文施引文献
订阅此论文施引文献,注册后可以免费订阅5篇论文的施引文献,订阅后可以查看论文全部施引文献
1. Verified Extraction from Coq to OCaml;Proceedings of the ACM on Programming Languages;2024-06-20
2. Certified MaxSAT Preprocessing;Lecture Notes in Computer Science;2024
3. Cakes That Bake Cakes: Dynamic Computation in CakeML;Proceedings of the ACM on Programming Languages;2023-06-06
4. PureCake: A Verified Compiler for a Lazy Functional Language;Proceedings of the ACM on Programming Languages;2023-06-06
5. Verified Propagation Redundancy and Compositional UNSAT Checking in CakeML;International Journal on Software Tools for Technology Transfer;2023-02-27