feat: Implement RLC for iterators #164
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Creates a PR benchmark comment with a comparison to main | |
name: Benchmark pull requests | |
on: | |
issue_comment: | |
types: [created] | |
env: | |
CARGO_TERM_COLOR: always | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
jobs: | |
changes: | |
runs-on: ubuntu-latest | |
if: | |
github.event.issue.pull_request | |
&& github.event.issue.state == 'open' | |
&& contains(github.event.comment.body, '!benchmark') | |
&& (github.event.comment.author_association == 'MEMBER' || github.event.comment.author_association == 'OWNER') | |
# Set job outputs to values from filter step | |
outputs: | |
spartan: ${{ steps.filter.outputs.spartan }} | |
supernova: ${{ steps.filter.outputs.supernova }} | |
steps: | |
- uses: xt0rted/pull-request-comment-branch@v2 | |
id: comment-branch | |
- uses: actions/checkout@v4 | |
- uses: dorny/paths-filter@v2 | |
id: filter | |
with: | |
ref: ${{ steps.comment-branch.outputs.head_ref }} | |
filters: | | |
spartan: | |
- 'src/spartan/**' | |
supernova: | |
- 'src/supernova/**' | |
recursive-benchmark: | |
name: run benchmark | |
runs-on: buildjet-16vcpu-ubuntu-2204 | |
if: | |
github.event.issue.pull_request | |
&& github.event.issue.state == 'open' | |
&& contains(github.event.comment.body, '!benchmark') | |
&& (github.event.comment.author_association == 'MEMBER' || github.event.comment.author_association == 'OWNER') | |
steps: | |
- uses: xt0rted/pull-request-comment-branch@v2 | |
id: comment-branch | |
- uses: actions/checkout@v4 | |
if: success() | |
with: | |
ref: ${{ steps.comment-branch.outputs.head_ref }} | |
# Set the Rust env vars | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- uses: boa-dev/criterion-compare-action@v3 | |
with: | |
# Optional. Compare only this benchmark target | |
benchName: "recursive-snark" | |
# Needed. The name of the branch to compare with | |
branchName: ${{ github.ref_name }} | |
spartan-benchmark: | |
name: run benchmark | |
runs-on: buildjet-16vcpu-ubuntu-2204 | |
needs: changes | |
if: | |
github.event.issue.pull_request | |
&& github.event.issue.state == 'open' | |
&& contains(github.event.comment.body, '!benchmark') | |
&& (github.event.comment.author_association == 'MEMBER' || github.event.comment.author_association == 'OWNER') | |
&& ${{ needs.changes.outputs.spartan == 'true' }} | |
steps: | |
- uses: xt0rted/pull-request-comment-branch@v2 | |
id: comment-branch | |
- uses: actions/checkout@v4 | |
if: success() | |
with: | |
ref: ${{ steps.comment-branch.outputs.head_ref }} | |
# Set the Rust env vars | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- uses: boa-dev/criterion-compare-action@v3 | |
with: | |
# Optional. Compare only this benchmark target | |
benchName: "compressed-snark" | |
# Needed. The name of the branch to compare with | |
branchName: ${{ github.ref_name }} | |
supernova-benchmark: | |
name: run benchmark | |
runs-on: buildjet-16vcpu-ubuntu-2204 | |
needs: changes | |
if: | |
github.event.issue.pull_request | |
&& github.event.issue.state == 'open' | |
&& contains(github.event.comment.body, '!benchmark') | |
&& (github.event.comment.author_association == 'MEMBER' || github.event.comment.author_association == 'OWNER') | |
&& ${{ needs.changes.outputs.supernova == 'true' }} | |
steps: | |
- uses: xt0rted/pull-request-comment-branch@v2 | |
id: comment-branch | |
- uses: actions/checkout@v4 | |
if: success() | |
with: | |
ref: ${{ steps.comment-branch.outputs.head_ref }} | |
# Set the Rust env vars | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- uses: boa-dev/criterion-compare-action@v3 | |
with: | |
# Optional. Compare only this benchmark target | |
benchName: "recursive-snark-supernova" | |
# Needed. The name of the branch to compare with | |
branchName: ${{ github.ref_name }} |