Skip to content

Compiler benchmark harness (Rust + moc phase timings)#6018

Draft
christoph-dfinity wants to merge 7 commits intomasterfrom
cursor/compiler-benchmark-harness
Draft

Compiler benchmark harness (Rust + moc phase timings)#6018
christoph-dfinity wants to merge 7 commits intomasterfrom
cursor/compiler-benchmark-harness

Conversation

@christoph-dfinity
Copy link
Copy Markdown
Contributor

@christoph-dfinity christoph-dfinity commented Apr 15, 2026

Summary

Adds a Motoko compiler benchmark harness and per-phase timing in moc.

moc

  • New --emit-compiler-timings <file> writes JSON phase durations on successful runs.
  • New compiler_timing library; pipeline phases wrapped for measurement.

motoko-compiler-bench (Rust)

  • Runs a TOML corpus (compiler-bench/corpus.toml): check and compile, wall time + parsed compiler timings.
  • Prefers bin/moc from the repo when present (RTS env).
  • Nix: compiler-bench package and dev shell.

Corpus

  • Sample entries from test/perf, test/bench, and compiler-bench/fixtures/.

Made with Cursor

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 15, 2026

Comparing from f816e6a to 10b9dd4:
The produced WebAssembly code seems to be completely unchanged.
In terms of gas, no changes are observed in 5 tests.
In terms of size, no changes are observed in 5 tests.

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.

1 participant