Skip to content

Commit

Permalink
Lock rust toolchain on v1.76.0 because higher versions segfaults duri…
Browse files Browse the repository at this point in the history
…ng PGO gather (#46)
  • Loading branch information
MarshalX authored Sep 7, 2024
1 parent 04ba564 commit 7ad062a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/codspeed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ jobs:
- name: Install python dependencies.
run: pip install -r pytests/requirements.txt

- name: Install rust stable.
- name: Install rust.
id: rust-toolchain
uses: dtolnay/rust-toolchain@stable
uses: dtolnay/rust-toolchain@1.76.0
with:
components: llvm-tools

Expand All @@ -40,7 +40,7 @@ jobs:
run: pytest . --benchmark-enable

- name: Prepare merged PGO data.
run: rustup run stable bash -c '$RUSTUP_HOME/toolchains/$RUSTUP_TOOLCHAIN/lib/rustlib/x86_64-unknown-linux-gnu/bin/llvm-profdata merge -o ${{ github.workspace }}/merged.profdata ${{ github.workspace }}/profdata'
run: rustup run 1.76.0 bash -c '$RUSTUP_HOME/toolchains/$RUSTUP_TOOLCHAIN/lib/rustlib/x86_64-unknown-linux-gnu/bin/llvm-profdata merge -o ${{ github.workspace }}/merged.profdata ${{ github.workspace }}/profdata'

- name: Compile with profile.
run: pip install -v -e .
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,9 @@ jobs:
python-version: '3.11'
architecture: ${{ matrix.python-architecture || 'x64' }}

- name: Install rust stable
- name: Install rust
id: rust-toolchain
uses: dtolnay/rust-toolchain@stable
uses: dtolnay/rust-toolchain@1.76.0
with:
components: llvm-tools

Expand All @@ -91,7 +91,7 @@ jobs:
manylinux: ${{ matrix.manylinux || 'auto' }}
container: ${{ matrix.container }}
args: --release --out dist --interpreter ${{ matrix.maturin-interpreter || matrix.interpreter || '3.7 3.8 3.9 3.10 3.11 3.12 pypy3.7 pypy3.8 pypy3.9 pypy3.10' }} ${{ matrix.extra-build-args }}
rust-toolchain: stable
rust-toolchain: 1.76.0
docker-options: -e CI

- name: List wheels.
Expand Down Expand Up @@ -131,9 +131,9 @@ jobs:
with:
python-version: ${{ matrix.interpreter }}

- name: Install rust stable.
- name: Install rust.
id: rust-toolchain
uses: dtolnay/rust-toolchain@stable
uses: dtolnay/rust-toolchain@1.76.0
with:
components: llvm-tools

Expand All @@ -146,7 +146,7 @@ jobs:
with:
manylinux: auto
args: --release --out pgo-wheel --interpreter ${{ matrix.interpreter }}
rust-toolchain: stable
rust-toolchain: 1.76.0
docker-options: -e CI
env:
RUSTFLAGS: "-Cprofile-generate=${{ github.workspace }}/profdata"
Expand All @@ -160,7 +160,7 @@ jobs:
pytest . --benchmark-enable
# we can't use github.workspace here because of Windows with backslashes
rustup run stable bash -c 'echo LLVM_PROFDATA=$RUSTUP_HOME/toolchains/$RUSTUP_TOOLCHAIN/lib/rustlib/${{ env.RUST_HOST }}/bin/llvm-profdata >> "$GITHUB_ENV"'
rustup run 1.76.0 bash -c 'echo LLVM_PROFDATA=$RUSTUP_HOME/toolchains/$RUSTUP_TOOLCHAIN/lib/rustlib/${{ env.RUST_HOST }}/bin/llvm-profdata >> "$GITHUB_ENV"'
- name: Prepare merged PGO data.
run: ${{ env.LLVM_PROFDATA }} merge -o ${{ github.workspace }}/merged.profdata ${{ github.workspace }}/profdata
Expand All @@ -170,7 +170,7 @@ jobs:
with:
manylinux: auto
args: --release --out dist --interpreter ${{ matrix.interpreter }}
rust-toolchain: stable
rust-toolchain: 1.76.0
docker-options: -e CI
env:
RUSTFLAGS: "-Cprofile-use=${{ github.workspace }}/merged.profdata"
Expand Down

0 comments on commit 7ad062a

Please sign in to comment.