Skip to content

Commit

Permalink
Minor: Fixing build workflow CI process (#187)
Browse files Browse the repository at this point in the history
  • Loading branch information
tonyfloatersu authored Jan 24, 2025
1 parent 1bb744a commit 88c5584
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 33 deletions.
33 changes: 15 additions & 18 deletions .github/workflows/build._yml → .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,35 +21,32 @@ jobs:
- os: 7950x3d
feature: avx512f
binary_name: expander-linux-avx512

runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4

- name: Setup Dependencies
run: |
if [ "${{ matrix.os }}" == "macos-latest" ]; then
brew install gcc make
else
sudo apt-get install -y build-essential
fi
shell: bash


- name: Setup Dependencies for MacOS workflow
if: matrix.os == 'macos-latest'
run: brew install gcc make openmpi

- uses: dtolnay/rust-toolchain@stable

- uses: Swatinem/rust-cache@v2
with:
prefix-key: "mpi-v5.0.6"

- name: Install MPI

- name: Install MPI for MacOS workflow
if: matrix.os == 'macos-latest'
run: python3 ./scripts/install.py

- name: Set RUSTFLAGS for AVX
if: matrix.feature != ''
if: matrix.feature != 'macos-latest'
run: echo "RUSTFLAGS=$RUSTFLAGS -C target-feature=+${{ matrix.feature }}" >> $GITHUB_ENV

- name: Prepare binary
run: cargo build --release --bin expander-exec

- name: Upload release asset
uses: actions/github-script@v6
with:
Expand All @@ -61,4 +58,4 @@ jobs:
release_id: ${{ github.event.release.id }},
name: '${{ matrix.binary_name }}',
data: await fs.readFile('target/release/expander-exec')
});
});
20 changes: 5 additions & 15 deletions .github/workflows/nightly_e2e._yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
schedule:
# This will run the workflow every day at 2:00 AM UTC
- cron: '0 2 * * *'

pull_request:
branches:
# not to be run on DEV branch to save resources
Expand All @@ -21,30 +21,20 @@ on:
jobs:
build-and-test:
runs-on: 7950x3d

steps:
- uses: actions/checkout@v4 # Updated to v4

- name: Setup Dependencies
run: |
sudo apt-get update
sudo apt-get install -y build-essential

- name: Set up Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly-2024-09-01
components: rustfmt, clippy

- uses: Swatinem/rust-cache@v2
with:
# The prefix cache key, this can be changed to start a new cache manually.
prefix-key: "mpi-v5.0.6" # update me if brew formula changes to a new version

- name: Set up Go
uses: actions/setup-go@v5 # Updated to v5
with:
go-version: '^1.16'

- name: Run tests
run: |
Expand All @@ -53,7 +43,7 @@ jobs:

# ECC part
git clone https://github.com/PolyhedraZK/ExpanderCompilerCollection.git
cd ExpanderCompilerCollection
cd ExpanderCompilerCollection
git switch dev
cargo test --release
cp expander_compiler/*.txt ../data
Expand All @@ -76,4 +66,4 @@ jobs:
RUSTFLAGS="-C target-cpu=native -C target-feature=+avx512f" cargo +nightly run --release --bin=gkr -- -s keccak -f gf2ext128 -t 16
RUSTFLAGS="-C target-cpu=native -C target-feature=+avx512f" cargo +nightly run --release --bin=gkr -- -s keccak -f m31ext3 -t 16
RUSTFLAGS="-C target-cpu=native -C target-feature=+avx512f" cargo +nightly run --release --bin=gkr -- -s keccak -f fr -t 16
RUSTFLAGS="-C target-cpu=native -C target-feature=+avx512f" cargo +nightly run --release --bin=gkr -- -s poseidon -f m31ext3 -t 16
RUSTFLAGS="-C target-cpu=native -C target-feature=+avx512f" cargo +nightly run --release --bin=gkr -- -s poseidon -f m31ext3 -t 16

0 comments on commit 88c5584

Please sign in to comment.