Proof-Producing Synthesis of CakeML from Monadic HOL Functions

Saved in:
Bibliographic Details
Title: Proof-Producing Synthesis of CakeML from Monadic HOL Functions
Authors: Abrahamsson, Oskar, 1986, Ho, Son, Kanabar, Hrutvik, Kumar, Ramana, Myreen, Magnus, 1983, Norrish, Michael, Tan, Yong Kiam
Source: Journal of Automated Reasoning. 64(7):1287-1306
Subject Terms: ML, Interactive theorem proving, Program synthesis, Higher-order logic
Description: We introduce an automatic method for producing stateful ML programs together with proofs of correctness from monadic functions in HOL. Our mechanism supports references, exceptions, and I/O operations, and can generate functions manipulating local state, which can then be encapsulated for use in a pure context. We apply this approach to several non-trivial examples, including the instruction encoder and register allocator of the otherwise pure CakeML compiler, which now benefits from better runtime performance. This development has been carried out in the HOL4 theorem prover.
File Description: electronic
Access URL: https://research.chalmers.se/publication/517619
https://research.chalmers.se/publication/518990
https://research.chalmers.se/publication/518990/file/518990_Fulltext.pdf
Database: SwePub
Description
Abstract:We introduce an automatic method for producing stateful ML programs together with proofs of correctness from monadic functions in HOL. Our mechanism supports references, exceptions, and I/O operations, and can generate functions manipulating local state, which can then be encapsulated for use in a pure context. We apply this approach to several non-trivial examples, including the instruction encoder and register allocator of the otherwise pure CakeML compiler, which now benefits from better runtime performance. This development has been carried out in the HOL4 theorem prover.
ISSN:01687433
15730670
DOI:10.1007/s10817-020-09559-8