CertiCoq-Wasm: A Verified WebAssembly Backend for CertiCoq
We contribute CertiCoq-Wasm, a verified WebAssembly backend for CertiCoq. CertiCoq-Wasm is implemented and verified in the Coq proof assistant, and is mechanised with respect to the WasmCert-Coq formalisation of the WebAssembly standard. CertiCoq-Wasm works from CertiCoq's minimal lambda calculus in administrative normal form (ANF), and produces WebAssembly programs with reasonable performance. It implements Coq's primitive integer operations as efficient WebAssembly instructions, identifying a corner case in their implementation that led to unsoundness. We compare CertiCoq-Wasm against other, partially verified extraction mechanisms from Coq to WebAssembly, benchmarking running time and program size. We demonstrate the practical usability of CertiCoq-Wasm with two case studies: we extract and run a Gallina program on the web, and a ConCert smart contract on the Concordium blockchain.
Authors
- Mikkel T. Jensen
- Jean Pichon-Pharabod (ORCID: https://orcid.org/0000-0002-4442-6543)
- Bas Spitters (ORCID: https://orcid.org/0000-0002-2802-0973)
- Wolfgang Meier
Institutions
- Aarhus University (DK)
Publication Details
- Published
- 2025-01-10
- DOI
- https://doi.org/10.1145/3703595.3705879
- Primary Topic
- Logic, programming, and type systems
- Type
- article
- Field-Weighted Citation Impact
- 0.00
Funders
- Aarhus Universitet