Skip to content

Commit 8cd48e4

Browse files
authored
Merge branch 'main' into vk/ceed-vm-precomp
2 parents 74f274a + 44400aa commit 8cd48e4

Some content is hidden

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

58 files changed

+2470
-3138
lines changed

.github/workflows/rust.yml

Lines changed: 45 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,53 +2,85 @@ name: Rust
22

33
on:
44
push:
5-
branches: ["main"]
5+
branches: [ "main" ]
66
pull_request:
7-
branches: ["main"]
7+
branches: [ "main" ]
8+
workflow_dispatch:
9+
10+
permissions:
11+
contents: read
12+
13+
concurrency:
14+
group: rust-ci-${{ github.ref }}
15+
cancel-in-progress: true
816

917
env:
1018
CARGO_TERM_COLOR: always
19+
RUST_BACKTRACE: 1
1120

1221
jobs:
13-
build:
14-
runs-on: ubuntu-latest
15-
name: Build & Test
22+
build-test-matrix:
23+
name: Build & Test (${{ matrix.name }})
24+
runs-on: ${{ matrix.os }}
25+
strategy:
26+
fail-fast: false
27+
matrix:
28+
include:
29+
- name: x64-avx2
30+
os: ubuntu-latest
31+
rustflags: -C target-cpu=haswell
32+
run_tests: true
1633

34+
# TODO make arm64-neon work
35+
36+
# - name: arm64-neon
37+
# os: ubuntu-24.04-arm64
38+
# rustflags: -C target-feature=+neon
39+
# run_tests: true
1740
steps:
1841
- uses: actions/checkout@v4
1942
- name: Install nightly toolchain
2043
uses: actions-rust-lang/setup-rust-toolchain@v1
2144
with:
2245
toolchain: nightly
46+
- name: Cache cargo build
47+
uses: Swatinem/rust-cache@v2
2348
- name: Build
24-
run: cargo build --release --verbose
25-
- name: Run tests
26-
run: cargo test --release --verbose
49+
run: cargo build --release --all --verbose
50+
env:
51+
RUSTFLAGS: ${{ matrix.rustflags }}
52+
- name: Test
53+
if: ${{ matrix.run_tests == true }}
54+
run: cargo test --release --all --verbose
55+
env:
56+
RUSTFLAGS: ${{ matrix.rustflags }}
2757

2858
cargo-clippy:
2959
runs-on: ubuntu-latest
3060
name: Clippy
31-
3261
steps:
3362
- uses: actions/checkout@v4
3463
- name: Install nightly toolchain
3564
uses: actions-rust-lang/setup-rust-toolchain@v1
3665
with:
3766
toolchain: nightly
3867
components: clippy
68+
- name: Cache cargo build
69+
uses: Swatinem/rust-cache@v2
3970
- name: Clippy Check
4071
run: cargo clippy --workspace --all-targets -- -Dwarnings
4172

4273
cargo-fmt:
43-
name: Cargo fmt
4474
runs-on: ubuntu-latest
45-
75+
name: Rustfmt Check
4676
steps:
4777
- uses: actions/checkout@v4
4878
- name: Install nightly toolchain
4979
uses: actions-rust-lang/setup-rust-toolchain@v1
5080
with:
5181
toolchain: nightly
5282
components: rustfmt
53-
- name: Rustfmt Check
54-
run: cargo fmt --all --check
83+
- name: Cache cargo build
84+
uses: Swatinem/rust-cache@v2
85+
- name: Check formatting
86+
run: cargo fmt --all -- --check

0 commit comments

Comments
 (0)