Skip to content

Commit 5d5921f

Browse files
committed
0 parents  commit 5d5921f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+2539
-0
lines changed

.cargo/config.toml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[alias]
2+
xtask = "run --package xtask --"
3+
4+
[profile.show-asm]
5+
inherits = "release"
6+
# more determinism
7+
codegen-units=1
8+
# Values other than "thin" and "fat" cause the assembly to change in an undesirable way. It makes functions that have the same assembly link to eachother via ".set".
9+
lto = "thin"

.github/workflows/check.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
on:
2+
push:
3+
branches: [ "master" ]
4+
pull_request:
5+
branches: [ "master" ]
6+
7+
jobs:
8+
# We intentionally hardcode the stable/current version for the following reasons:
9+
#
10+
# - It makes it less likely that CI starts failing in the future despite the project not changing.
11+
# - It makes us independent of the default Rust version that the Github runner comes with.
12+
check_stable:
13+
runs-on: ubuntu-24.04
14+
steps:
15+
- run: sudo apt-get -qq install gcc-multilib qemu-user
16+
- run: cargo install --quiet cargo-show-asm
17+
- run: |
18+
rustup --quiet toolchain uninstall stable
19+
rustup --quiet toolchain install 1.82 --profile=default
20+
rustup --quiet default 1.82
21+
- uses: actions/checkout@v4
22+
- run: cargo fmt --check
23+
- run: cargo fetch --quiet --locked
24+
- run: cargo clippy --quiet --workspace --all-targets -- --D=warnings
25+
- run: cargo test --quiet --workspace
26+
- run: cargo build --quiet --package xtask
27+
- run: target/debug/xtask all
28+
- run: git diff --exit-code -- "generated assembly"
29+
30+
# For the MSRV we only care about the code compiling.
31+
check_minimum_supported_rust_version:
32+
runs-on: ubuntu-24.04
33+
steps:
34+
- run: sudo apt-get -qq install gcc-multilib
35+
- run: |
36+
rustup --quiet toolchain uninstall stable
37+
rustup --quiet toolchain install 1.82 --profile=default
38+
rustup --quiet toolchain install 1.71 --profile=minimal
39+
rustup --quiet default 1.71
40+
- uses: actions/checkout@v4
41+
- run: cargo fetch --quiet --locked
42+
# xtask does not use MSRV because we don't publish it. xtask's internal cargo calls use the default rustup pipeline, which is the MSRV. Note that we cannot run xtask through cargo because that forces the toolchain version for building xtask to be the same as the toolchain version for xtask's internal cargo calls through the RUSTUP_TOOLCHAIN environment variable.
43+
- run: cargo +1.82 build --quiet --package xtask
44+
- run: target/debug/xtask check

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/target

0 commit comments

Comments
 (0)