Skip to content

WebAssembly backend#103

Merged
yforster merged 3 commits intoCertiRocq:masterfrom
womeier:upstream-pr
Nov 4, 2025
Merged

WebAssembly backend#103
yforster merged 3 commits intoCertiRocq:masterfrom
womeier:upstream-pr

Conversation

@womeier
Copy link
Copy Markdown
Contributor

@womeier womeier commented Nov 1, 2024

This PR adds our Wasm backend, as dicussed with Zoe.

We extended the plugin with CertiCoq Compile Wasm <definition>..
Benchmarks are in benchmarks/wasm.

Some considerations (before merge or follow-up):

  • Refactoring: use Disjoint and bound_var instead of NoDup in correctness statement (relevant for linking to earlier pipeline, to obtain an end-to-end statement at some point)
  • these helper lemmas are copied from the proof of the C backend (that doesn't compile currently) and belong somewhere else I think
  • The current Docker image has old versions, we need at least compcert 3.14, (see the temporary workaround in the GH actions config)
  • one of our benchmarks requires the coqprime package. We probably don't want this as a general dependency. It seems there is no way to specify development dependencies for opam? (The benchmark tests the 63-bit primitive integer operations.)

This PR has our backend in a single commit, we'll keep the full history at gh/womeier/certicoqwasm.

@womeier womeier marked this pull request as draft November 3, 2024 20:29
@spitters
Copy link
Copy Markdown

spitters commented Jul 1, 2025

Depends on #115

@womeier womeier changed the base branch from master to coq-8.20 July 1, 2025 10:28
@womeier womeier changed the base branch from coq-8.20 to master July 1, 2025 11:40
womeier and others added 2 commits July 1, 2025 16:44
see https://github.com/womeier/certicoqwasm for full history

Co-authored-by: Martin Karup Jensen <mkjensen@mailbox.org>
@womeier womeier marked this pull request as ready for review July 2, 2025 10:24
@womeier
Copy link
Copy Markdown
Contributor Author

womeier commented Jul 3, 2025

could someone trigger the CI? (and possibly take a look at the PR)

@spitters
Copy link
Copy Markdown

spitters commented Jul 3, 2025

@yforster @zoep ?

- fix wasmcert deprecations
- cleanup a bit
@womeier
Copy link
Copy Markdown
Contributor Author

womeier commented Sep 17, 2025

could someone take a look at this? @zoep maybe
(I also texted you on the CertiCoq slack a while back @zoep)

thanks!

@spitters
Copy link
Copy Markdown

@womeier what should be reviewed?
Is the PR ready to merge, or do you feedback before you can address the todos you list above?

@womeier
Copy link
Copy Markdown
Contributor Author

womeier commented Sep 23, 2025

The last three todos are really small things. I was just hoping for feedback/another opinion.
The first one about using Disjoint will take a bit of work, I thought it could make sense to merge the PR before that.
(the Wasm backend is fully usable as is now; the change will be necessary for the end-to-end statement)

The diff is already quite large, so I'm a little hesitant to include more changes...
It'd just be nice if so. could take a look first.

@yforster yforster merged commit 131494c into CertiRocq:master Nov 4, 2025
1 check passed
@womeier
Copy link
Copy Markdown
Contributor Author

womeier commented Nov 4, 2025

Thanks for the merge.
Unrelated to this, we also have a Nix-based setup for CertiCoq with the coq-nix-toolbox.
Would you care to have that @yforster?
If so I can open a PR.

@womeier womeier deleted the upstream-pr branch November 4, 2025 14:25
@mattam82
Copy link
Copy Markdown
Collaborator

mattam82 commented Nov 5, 2025

@womeier yes please, for the nix setup!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants