paperbot · PL 论文追踪

全部论文 待读 收藏

P2 Progressful Interpreters for Efficient WebAssembly Mechanisation

用于高效 WebAssembly 机器化的 Progressful 解释器
POPL 9(POPL)2025匹配度 3/10 · 论文属于编程语言形式语义与定理证明(Coq 机化 Wasm、progressful 解释器),虽涉及形式化验证,但完全不涉及 LLM/Agent、静态分析在 ML/Agent 中的应用、浮点程序分析或贝叶斯程序分析,与用户画像的核心交叉方向偏离。引用 3 inbox
Xiaojia Rao, Stefan Radziuk, Conrad Watt, Philippa Gardner
crossref: 2026-09-10

AI 速览

一句话:提出 progressful 解释器,用 Coq 依赖类型认证健全性与 progress,高效扩展 Wasm 2.0 机器化。

编程语言规范的机器化验证日益常见,但随规范演进难以维护。W3C WebAssembly 标准已全形式化,WasmCert-Coq 机器化此前尚能跟进,而 Wasm 2.0 的大规模扩展要求更高效地产出核心验证工件。论文研究两条策略:一是将 Kokke、Siek 与 Wadler 从构造性 progress 证明导出健全解释器的方法扩展到 Wasm 1.0,但在该设定下解释器效率低下;二是受内在类型语言启发,定义 progressful 解释器,用 Coq 依赖类型同时认证其健全性与 progress,并可在保持认证下实施性能优化,抽取后认证可完全擦除。据此,作者将 WasmCert-Coq 扩展到显著更大的 Wasm 2.0 特性集,并发现并修正扩展规范类型系统中的若干错误。

问题
如何在规范持续演进时高效维护 WebAssembly 的机器化验证工件,特别是为 Wasm 2.0 扩展生成类型系统、操作语义、类型健全性证明与健全解释器。现有 WasmCert-Coq 为这些部分分别定义,难以应对 Wasm 2.0 的大规模扩展。
方法
论文比较从构造性 progress 证明导出解释器的方案,并提出用 Coq 依赖类型定义的 progressful 解释器;该解释器将自身健全性和 progress 性质内建于类型中,并支持在保持认证的前提下实施可擦除的性能优化。
评估
将方法用于 WasmCert-Coq,扩展到 Wasm 2.0 特性集,评估解释器效率与认证抽取/擦除性,并在扩展规范的类型系统中发现并修正若干错误。
原文摘要(Abstract)

Mechanisations of programming language specifications are now increasingly common, providing machine-checked modelling of the specification and verification of desired properties such as type safety. However it is challenging to maintain these mechanisations, particularly in the face of an evolving specification. Existing mechanisations of the W3C WebAssembly (Wasm) standard have so far been able to keep pace as the standard evolves, helped enormously by the W3C Wasm standard’s choice to state the language’s semantics in terms of a fully formal specification. However a substantial incoming extension to Wasm, the 2.0 feature set, motivates the investigation of strategies for more efficient production of the core verification artefacts currently associated with the WasmCert-Coq mechanisation of Wasm. In the classic formalisation of a typed operational semantics as followed by the W3C Wasm standard, both the type system and runtime operational semantics are defined as inductive relations, with associated type soundness properties (progress and preservation) and an independent sound interpreter. We investigate two more efficient strategies for producing these artefacts, which are currently all separately defined by WasmCert-Coq. First, the approach of Kokke, Siek, and Wadler for deriving a sound interpreter from a constructive progress proof — we show that this approach scales to the W3C Wasm 1.0 standard, but results in an inefficient interpreter in our setting. Second, inspired by results from intrinsically-typed languages, we define a progressful interpreter which uses Coq’s dependent types to certify not only its own soundness, but also the progress property. We show that this interpreter can implement several performance optimisations while maintaining these certifications, which are fully erasable when the interpreter is extracted from Coq. Using this approach, we extend the WasmCert-Coq mechanisation to the significantly larger Wasm 2.0 feature set, discovering and correcting several errors in the expanded specification’s type system.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@article{paperbot3223,
  title = {Progressful Interpreters for Efficient WebAssembly Mechanisation},
  author = {Xiaojia Rao and Stefan Radziuk and Conrad Watt and Philippa Gardner},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {9},
  number = {POPL},
  year = {2025},
  doi = {10.1145/3704858}
}