Skip to content

Commit

Permalink
run benchmarks on dedicated CI runner
Browse files Browse the repository at this point in the history
  • Loading branch information
arvidn committed Oct 7, 2022
1 parent 89d3122 commit 5bf66c4
Showing 1 changed file with 44 additions and 9 deletions.
53 changes: 44 additions & 9 deletions .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

name: Run benchmarks
name: Tests

on:
push:
Expand All @@ -12,8 +12,8 @@ on:
- '**'

jobs:
max-cost-checks:
name: Cost checks
tests:
name: Unit Tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
Expand Down Expand Up @@ -70,18 +70,53 @@ jobs:
run: |
pytest tests
benchmarks:
name: Generator performance
runs-on: benchmark
strategy:
fail-fast: false
matrix:
python-version: ['3.7', '3.8', '3.9', '3.10', '3.11']

steps:
- uses: actions/checkout@v2
with:
fetch-depth: 1

- uses: chia-network/actions/setup-python@main
name: Install Python ${{ matrix.python-version }}
with:
python-version: ${{ matrix.python-version }}

- name: Set up rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable

- name: setup venv
run: |
python -m venv venv
- uses: chia-network/actions/activate-venv@main

- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install maturin colorama clvm_tools
rustup target add x86_64-unknown-linux-musl
- name: Build
env:
CC: gcc
run: |
maturin develop --release -m wheel/Cargo.toml
- name: test generators
if: matrix.os == 'ubuntu-latest'
# TODO: This should happen everywhere but the benchmarking part is not passing
# on all platforms so this can be revisited separately.
run: |
cd tests
./test-generators.py
- name: Run cost checks
if: matrix.os == 'ubuntu-latest'
# TODO: This should happen everywhere but the benchmarking part is not passing
# on all platforms so this can be revisited separately.
run: |
cd tests
./generate-programs.py
Expand Down

0 comments on commit 5bf66c4

Please sign in to comment.