CI: run the Cranelift verifier. - #14207
Conversation
This PR adds a GitHub workflow that runs on pushes to main and on PRs. It restores the verifier's SMT query cache from the shared actions cache, runs 'verify.sh rebuild-cache' on top of it, and (on main) republishes the rebuilt cache as the isle-veri-cache.tar.gz asset on the rolling dev release plus a run artifact for use by local developers. It also adds a script, cranelift/isle/veri/setup/download-cache.sh, so a local user can download the current CI cache from the dev release and verify incrementally on top of it.
|
Let's see how long the run takes on the branch... |
|
Hmm, it seems that new workflows don't run until merge to main -- do I need to merge PRs as part of a debug loop?! That's awfully silly... (good security reasons for this I suppose but still) |
|
@cfallin it seems like you can manually trigger without merging to |
|
Unfortunately it seems there is no "Approve workflows to run" option, at least for me. I wonder if the set of workflows is somehow fixed based on what is in |
alexcrichton
left a comment
There was a problem hiding this comment.
If it works I'd recommend moving this to main.yml because otherwise we need to reconfigure repository settings to actually gate on this check where if it's in main.yml we can just manage it via the text configuration there.
Subscribe to Label ActionDetailsThis issue or pull request has been labeled: "cranelift", "isle"Thus the following users have been cc'd because of the following labels:
To subscribe or unsubscribe from this label, edit the |
1533989 to
9e2f162
Compare
- Move job into `main.yml` workflow. - Add branch spec to PR section.
9e2f162 to
7b3702c
Compare
|
Cool, the job finishes in 3h58m on a GitHub runner. That's definitely longer than I would have hoped for, but as long as the cache isn't dropped or mass-invalidated by some change it should be OK? (We should merge when the merge queue is otherwise quiet of course...) |
|
Woo! 🎉 A few things:
|
|
Oh, also, as-is this is going to run on every PR which while probably fine we perhaps want to tweak a bit to only run conditionally like we do for most other jobs. If you copy this configuration it'll only run with
I'll caution that this'll probably need an iteration or two of landing on main to fiddle with the logic around caching and the |
|
OK, switching to the |
|
I see the asset on the dev release so looks like that's going well, @cfallin wanna double-check the download script pulls that for local development? |
Yes, the download worked and verification from cache-only worked as well! $ cranelift/isle/veri/setup/download-cache.sh
############################################################################################################################################################################################################### 100.0%
Installed verifier cache to cranelift/isle/veri/cache/
You can now run ./cranelift/isle/veri/verify.sh (or cache-only / rebuild-cache).
$ time cranelift/isle/veri/verify.sh cache-only aarch64-fast
=== Verifying from cache (read-only, enforcing; no solver) ===
=== veri: cranelift/isle/veri/configs/aarch64-fast.args ===
Finished `release` profile [optimized] target(s) in 0.07s
Running `target/release/veri --config cranelift/isle/veri/configs/aarch64-fast.args --cache-source-dir cranelift/isle/veri/cache --cache-mode read-only-enforcing`
[ ... ]
Verification passed: 523
Verification failed: 0
Verification unknown: 0
===============================================================================
========================== Cache statistics ===========================
Mode: read-only-enforcing
Source: cranelift/isle/veri/cache
Destination: (none)
Hits: 1219 (100.0%)
Misses: 0 (0.0%)
New entries: 0
Retained: 0
========================================================================
=== Cache verification passed ===
cranelift/isle/veri/verify.sh cache-only aarch64-fast 6.28s user 1.08s system 324% cpu 2.264 total |
This PR adds a GitHub workflow that runs on pushes to main and on PRs. It restores the verifier's SMT query cache from the shared actions cache, runs 'verify.sh rebuild-cache' on top of it, and (on main) republishes the rebuilt cache as the isle-veri-cache.tar.gz asset on the rolling dev release plus a run artifact for use by local developers.
It also adds a script, cranelift/isle/veri/setup/download-cache.sh, so a local user can download the current CI cache from the dev release and verify incrementally on top of it.
Note that the cache needs a unique key per run on
main, because a cache entry is immutable oncecreated. Fortunately we can select the latest key by prefix.