From 0cd925896a986bece7c6a5b2255b2ee0f0b36560 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20G=C3=B6rgens?= Date: Thu, 12 Dec 2024 17:30:35 +0800 Subject: [PATCH] Remove unused and broken strategy matrix (#725) Extracted from https://github.com/scroll-tech/ceno/pull/719 for ease of review. Our strategy matrix only has one entry, so we might as well not use it. Also, using `riscv32im-unknown-none-elf` as the target anywhere actually fails. As an example you can try `TARGET=riscv32im-unknown-none-elf cargo make clippy` on current `master`. --- .github/workflows/integration.yml | 11 ++--------- .github/workflows/lints.yml | 8 -------- .github/workflows/tests.yml | 9 --------- Makefile.toml | 12 ------------ 4 files changed, 2 insertions(+), 38 deletions(-) diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index ec0de0b14..b882ca931 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -32,13 +32,6 @@ jobs: timeout-minutes: 30 runs-on: [self-hosted, Linux, X64] - strategy: - matrix: - target: [x86_64-unknown-linux-gnu, riscv32im-unknown-none-elf] - # Exclude the riscv32im-unknown-none-elf target - exclude: - - target: riscv32im-unknown-none-elf - steps: - uses: actions/checkout@v2 - name: Cargo cache @@ -57,11 +50,11 @@ jobs: env: RAYON_NUM_THREADS: 2 RUSTFLAGS: "-C opt-level=3" - run: cargo run --package ceno_zkvm --example riscv_opcodes --target ${{ matrix.target }} -- --start 10 --end 11 + run: cargo run --package ceno_zkvm --example riscv_opcodes -- --start 10 --end 11 - name: Run fibonacci env: RAYON_NUM_THREADS: 8 RUST_LOG: debug RUSTFLAGS: "-C opt-level=3" - run: cargo run --package ceno_zkvm --bin e2e --target ${{ matrix.target }} -- --platform=sp1 ceno_zkvm/examples/fibonacci.elf + run: cargo run --package ceno_zkvm --bin e2e -- --platform=sp1 ceno_zkvm/examples/fibonacci.elf diff --git a/.github/workflows/lints.yml b/.github/workflows/lints.yml index 1014ba9a1..fe7367a54 100644 --- a/.github/workflows/lints.yml +++ b/.github/workflows/lints.yml @@ -32,13 +32,6 @@ jobs: timeout-minutes: 30 runs-on: [self-hosted, Linux, X64] - strategy: - matrix: - target: [x86_64-unknown-linux-gnu, riscv32im-unknown-none-elf] - # Exclude the riscv32im-unknown-none-elf target - exclude: - - target: riscv32im-unknown-none-elf - steps: - uses: actions/checkout@v2 - uses: dtolnay/rust-toolchain@master @@ -67,7 +60,6 @@ jobs: - name: Run clippy env: - TARGET: ${{ matrix.target }} RUSTFLAGS: "-Dwarnings" run: | cargo check --workspace --all-targets --exclude ceno_rt diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 7bc6ef35a..da0784782 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -31,13 +31,6 @@ jobs: timeout-minutes: 30 runs-on: [self-hosted, Linux, X64] - strategy: - matrix: - target: [x86_64-unknown-linux-gnu, riscv32im-unknown-none-elf] - # Exclude the riscv32im-unknown-none-elf target - exclude: - - target: riscv32im-unknown-none-elf - steps: - uses: actions/checkout@v2 - uses: dtolnay/rust-toolchain@master @@ -61,6 +54,4 @@ jobs: run: | cargo make --version || cargo install cargo-make - name: run test - env: - TARGET: ${{ matrix.target }} run: cargo make tests diff --git a/Makefile.toml b/Makefile.toml index a62827fcc..4a5a93188 100644 --- a/Makefile.toml +++ b/Makefile.toml @@ -1,14 +1,6 @@ [env] CARGO_MAKE_EXTEND_WORKSPACE_MAKEFILE = true CORE = { script = ["nproc"] } -CUR_TARGET = { script = [''' - if [ -z "${TARGET}" ]; then - TARGET=$(rustc -vV | grep "host" | awk '{print $2}') - echo "${TARGET}" - else - echo "${TARGET}" - fi - '''] } RAYON_NUM_THREADS = "${CORE}" [tasks.tests] @@ -20,8 +12,6 @@ args = [ "--tests", "--examples", "--release", - "--target", - "${CUR_TARGET}", "--workspace", "--exclude", "ceno_rt", @@ -46,8 +36,6 @@ args = [ "--all-targets", "--exclude", "ceno_rt", - "--target", - "${CUR_TARGET}", "--", "-D", "warnings",