Commit Graph

64 Commits

Author SHA1 Message Date
Gerwin Klein feb1e56a49 github: add num_domains key to artifact upload
If we don't provide the additional name fragment, previous artifacts
would be overwritten, which leads to a failure with error message on
GitHub.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2024-01-22 09:37:07 +00:00
Gerwin Klein ee12ff5a99 github: add NUM_DOMAINS test matrix
This will now test with the following num_domains settings:

- PRs: default as in config file, no matrix
- push to master: with NUM_DOMAINS = 1 and default (= '')
- weekly test: with NUM_DOMAINS = 1, 7, and default

The default in the current config files is 16. 1 leads to structural
code changes is the setting most likely to break. 7 is for checking
that the proofs also work with a value that is not a power of 2.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2024-01-22 09:37:07 +00:00
Gerwin Klein 6d20b07581 github: docs for platform branch rebase workflow
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2024-01-22 09:37:07 +00:00
Gerwin Klein 722cd25c32 github: use correct secret
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-06-21 16:05:28 +10:00
Gerwin Klein dc093cab26 github: use explicit token to enable push triggers
The implicit GITHUB_TOKEN does not trigger further push actions in
the same repo, but in this case we do want the push action to happen
on the `-rebased` branches, so we use an explicit auth token instead.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-06-21 11:47:19 +10:00
Gerwin Klein 6f2ea86752 github: push to -rebased branch first
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-06-07 15:58:57 +10:00
Gerwin Klein 9fe16760b7 github: auto-rebase platform branches
The action will abort when no clean rebase is possible, and force-push
the rebased branch when the rebase over origin/master was clean.

The push will trigger proof runs on the rebased branches.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-06-07 15:58:57 +10:00
Gerwin Klein 443706fae8 github: distinguish proof PR checks from deployment run
Currently both workflows have the name "Proofs" which is confusing
in the GitHub UI.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-06-07 15:58:57 +10:00
Gerwin Klein 2545aa0e51 github: add manual triggers for testing
The worklow_dispatch trigger adds a button in the GitHub UI that lets
one trigger the workflow manually. Useful for testing the workflows.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-05-03 14:23:06 +10:00
Matthew Brecknell 59dd0452fe ci: Fix broken external workflow
A previous commit added a new job which depended on a job that didn't
exist. We rename the `all` job to `proofs` for consistency with other
workflows.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2023-03-16 14:17:05 +11:00
Matthew Brecknell f694aeb6fe ci bv: Use bv-trigger action
Use the bv-trigger action to trigger a binary verification run, rather
than a called workflow.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2023-03-05 16:09:39 +11:00
Matthew Brecknell 7225fb3989 ci: Move decompilation workflow to graph-refine repository
The decompilation process (part of binary verification) is more tightly
coupled to the graph-refine repository than l4v, so it makes more sense
to perform decompilation in graph-refine. (It was temporarily performed
here in l4v because the graph-refine branches needed some stabilisation
work.)

This also modifies proof workflows:
- All proof workflows now upload kernel build artifacts. These can be
  used as inputs to binary verification.
- Proof workflows other than the one for pull requests (proof.yml)
  automatically trigger a decompilation workflow. We can still manually
  initiate a decompilation workflow using the uploaded artifacts, but
  doint so automatically would consume too many parallel runners.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2023-03-04 08:38:33 +11:00
Gerwin Klein aa53e9a84c
github: provide nl-unescape script to BV trigger job
Need to check out the ci-actions repo first (where the nl-unescape.sh
script is located).

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-03-01 14:51:52 +11:00
Peter Chubb 5fcec5f56a
Unescape verification-manifest.xml before saving it (#583)
The current xmllint tools don't like %0A to mean newline
so are crashing.

Signed-off-by: Peter Chubb <peter.chubb@unsw.edu.au>
2023-02-22 15:32:28 +11:00
Gerwin Klein 6e11c9d000 github: replace obsolete access token
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2023-01-09 11:27:42 +11:00
Gerwin Klein 477a7c1016 github: bump github action dependencies
Upgrade to node16 actions to reduce warnings on CI.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-11-11 14:22:37 +11:00
Matthew Brecknell 81423c2200 ci: temporarily remove mcs-export from proof-deploy
This removes the mcs-export matrix job from the proof-deploy workflow,
as the first step towards solving seL4/l4v#497. This should unblock
verification manifest deployments.

The mcs-export job was added to the proof-deploy workflow to perform
SimplExportAndRefine for binary verification targets. It took a short
cut, using the master branch of l4v to perform SimplExportAndRefine for
MCS configurations, since there were no differences between rt and
master that were relevant to SimplExportAndRefine. This is no longer the
case, because MCS seL4 C code now contains C parser annotations that use
symbols only available in the rt branch of l4v.

We intend to add an equivalent job that uses the rt branch of l4v for
MCS SimplExportAndRefine, but are still working out the best way to do
that.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2022-07-06 18:58:04 +10:00
Gerwin Klein b1370585fe github: provide auth token for gitlint check
Missed one in c4fe1abb3d

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-04-20 09:16:19 +10:00
Gerwin Klein 0b023a4fc1 aarch64 github: provide repo token and cache
The repo token allows the action to work on a private repo, and
the S3 cache bucket name allows it to charge a different org.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-04-20 09:16:19 +10:00
Gerwin Klein d98d3ea703 github: enable standard checks on aarch64 branch
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-04-20 09:16:19 +10:00
Gerwin Klein c3900ced40 github: add AARCH64 to build matrix
This commit will only come into full effect when it is merged into
master, which is also the time AARCH64 tests should run regularly
in the main repository.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-04-20 09:16:19 +10:00
Gerwin Klein 8aefcddb37 github: separate workflow file for AARCH64
This is a separate workflow instead of being added to `proof.yml` so
that it can be switched on/off separately.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-04-20 09:16:19 +10:00
Gerwin Klein 82434f0d62 trivial: fix typo
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-04-08 10:59:05 +10:00
Matthew Brecknell d62eb31f9d ci binary: wait for artifacts
The previous version of the `binary` workflow assumed that its input
artifacts would be available for download before a `binary` workflow run
is started. However, the `binary` workflow typically wants to download
those artifacts from the same workflow run that triggered the `binary`
run via `repository_dispatch`.

It appears that GitHub Actions does not make artifacts available for
download from a workflow until *after* the relevant job has finished.
Hence, there's a race between the `binary` workflow and the workflow
that triggered it. We resolve this by making the `binary` workflow retry
its artifact download for up to 10 minutes.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2022-04-01 19:17:37 +11:00
Matthew Brecknell 2a173ba189 ci binary: download artifacts from correct repo
The previous version was erroneously downloading artifacts from the repo
in which the `binary` workflow was triggered, when it should have been
downloading from the repo identified by the payload of the trigger.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2022-04-01 19:17:37 +11:00
Gerwin Klein bf432bb631 github: changed AutoCorresSEL4 default
ci-actions/aws-proofs no longer excludes the AutoCorresSEL4 session by
default, so we no longer need to provide a fake argument to the session
parameter to not exclude it.

This is significant, because we now want the default to be non-verbose
since we're running multiple sessions in parallel.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-03-30 10:27:25 +11:00
Matthew Brecknell 590031439a ci: add binary verification workflow
- Add a new workflow to prepare graph-refine inputs and submit them to a
  back end over SSH. Intended to be triggered by the proof-deploy
  workflow. Fetches C graph-lang artifacts from the triggering workflow,
  and runs the decompiler to generate ASM graph-lang.
- Add a job to the l4v-proof workflow to trigger the decompilation
  workflow.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2022-03-23 11:53:28 +11:00
Matthew Brecknell bda2c35862 ci proof-deploy: reorganise c-graph-lang artifacts
Combine all C graph-lang outputs into a single artifact, to simplify
downstream workflows.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2022-03-23 11:53:28 +11:00
Matthew Brecknell 6673bf03d4 ci proof-deploy: add MCS C graph export
Add a second matrix job that runs SimplExportAndRefine for MCS C kernel
configurations that support it (currently ARM and RISCV64).

Note that this uses the master branch of l4v to generate the CSpec, and
to run SimplExportAndRefine, not the rt branch. This works because the
rt branch does not yet connect to the CSpec, and there are no meaningful
differences between rt and master in CSpec or SimplExportAndRefine. For
now, this simplifies workflows for binary verification. But when MCS
proofs connect to the CSpec, this will need to be refactored to use the
rt branch.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2022-03-14 11:13:47 +11:00
Matthew Brecknell da3c480cd4 ci proof-deploy: save C graph-lang
Upload an artifact for any C graph-lang generated by
SimplExportAndRefine during a proof-deploy workflow.

Signed-off-by: Matthew Brecknell <matt@kry10.com>
2022-03-14 11:13:47 +11:00
Gerwin Klein c4fe1abb3d github: provide auth tokens
These allow the test to run on private repos. If set to empty, they
have no effect.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-02-02 09:25:58 +11:00
Gerwin Klein a4c80a6887 github: use PR number to distinguish pull requests
${{github.ref}} will resolve to the base branch of the PR, not the
PR branch, so it is not useful for distinguishing PRs. The pull request
number will do the job.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-02-01 14:49:38 +11:00
Gerwin Klein d831ddea67 github: run AWS proofs only on most recent push
By default GitHub spawns a new test for each push event. To avoid
hitting the maximum number of AWS instances too quickly, we run the PR
and master proof tests only on the most recent push since the last test
finished.

The concurrency exclusion is per git ref, i.e. separate PRs and
separate branches still run tests concurrently.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2022-01-11 18:20:45 +11:00
Gerwin Klein 8678153429 github: explicit isa branch no longer necessary
The default test setup now uses the correct branch from devel.xml
in the verification-manifest repo.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-09-30 16:53:17 +10:00
Gerwin Klein 349309ebf5 github: trigger proof run on manifest update
The repository_dispatch event will be generated in the
verification-manifest repo when devel.xml is updated by anyone other
than the seL4-ci user.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-08-18 10:44:48 +10:00
Gerwin Klein 944df7055b github: no PR proof run for text file updates
Save some CI cycles by not running the full proofs for each
documentation update.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-08-16 21:55:00 +10:00
Gerwin Klein 100cf0c281 github: run push-checks on rt branch as well
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-08-14 15:59:10 +10:00
Gerwin Klein 3c1f9a8f58
github: deploy manifest after test on master (#323)
This refactors the proof runs into a separate run for the master branch
(which has deployment) and development branches (currently RT and PRs).

For the test on the master branch, we need to make sure that all tests
and the deployment action see the same revisions of all participating
repos.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-08-12 09:09:32 +10:00
Gerwin Klein bd844fbfff github: scheduled external + weekly clean proofs
External means default.xml and vanilla Isabelle instead of internal TS
Isabelle and devel.xml.

The weekly clean test runs without reading the proof image cache,
writing back a fresh cache state.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-07-31 08:57:50 +10:00
Gerwin Klein d8699b0222 github: provide pull request head
Easier to provide at the call site than trying to extract it from within
the GitHub action.

Signed-off-by: Gerwin Klein <kleing@unsw.edu.au>
2021-07-14 19:25:00 +10:00
Gerwin Klein 106cf5ac03 github: add artifact log upload
This makes the full low-level logs available in the "Artifacts" tab of
the "Actions" screen.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-07-13 21:28:21 +10:00
Gerwin Klein 90d5de3ea4 github: complete "switch proof runs to AWS"
This completes the previous commit to run all proof tests on reasonably
high-powered AWS VMs instead of GitHub runners. All tests run in one
go for efficiency.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-07-13 21:28:21 +10:00
Gerwin Klein d51908d195 github: switch proof runs to AWS
Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-07-12 15:18:04 +10:00
Gerwin Klein 5f0f373a0e auto-deploy CParser docker container
This action triggers docker container deployment in the repo
seL4/ci-actions when the C parser changes here.

Signed-off-by: Gerwin Klein <gerwin.klein@proofcraft.systems>
2021-07-08 09:23:32 +10:00
Gerwin Klein 9248a64b77 thylint: ignore annotation errors
The annotation action only works for in-repo pull requests. This flag
ignores any errors from this action so that forked pull requests don't
get spurious test failures.

Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
2021-01-13 17:05:31 +11:00
Gerwin Klein 66d03fec4d github: add thylint action
This github action checks PRs for unwanted outer syntax commands like
`sorry`, `sledgehammer`, or `thm`. The check is non-required, so can be
ignored for those cases where the command is wanted after all.

In addition to console output, the action annotates the sources in the
"changed files" tab. This only works for PRs from within the same repo,
unfortunately (forks have insufficient rights for annotations)

Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
2021-01-08 18:39:34 +11:00
Gerwin Klein 0c275ddad0 github: remove Refine sessions from github CI
With Isabelle2020 the Refine sessions are too close to memory
boundaries on github runners, the tests randomly fail with out-of-store
exceptions in polyml (but also randomly succeed without change).

Removing the session here until we have a better solution.

Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
2020-11-26 09:47:52 +11:00
Robert Sison 98c2889f1b lib: A tutorial and some 'modify' monad rules for Lib.EquivValid
Thanks to Toby Murray (@tobycmurray) for early feedback.

Signed-off-by: Robert Sison <robert.sison@unimelb.edu.au>
2020-11-17 06:06:03 +11:00
Gerwin Klein 69a8d9d6b2 github: session ASpecDoc is now merged with ASpec
Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
2020-10-27 15:52:31 +10:00
Gerwin Klein ee8c6a6404 github: fix Isabelle2020 version for now
This commit ignores the Isabelle version set in the repo manifest and fixes
Isabelle2020 instead for github CI checks. The main purpose is to test this
function and to make sure the test can remain working while the repo manifest
is being updated.

After that has happened, this commit can be reverted.

Signed-off-by: Gerwin Klein <gerwin.klein@data61.csiro.au>
2020-10-27 15:52:31 +10:00