Skip to content

Commit

Permalink
Merge branch 'main' into fix-smaller-bench-sizes
Browse files Browse the repository at this point in the history
  • Loading branch information
larseggert authored Feb 5, 2025
2 parents 5b9bf31 + 9dec573 commit 4f91a73
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
9 changes: 5 additions & 4 deletions .github/actions/rust/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ runs:
if [ "$(apt-cache search --names-only '^mold$' | wc -l)" -ge 1 ]; then
[ "$APT_UPDATED" ] || sudo apt-get update && echo "APT_UPDATED=1" >> "$GITHUB_ENV"
sudo apt-get install -y --no-install-recommends mold
echo "RUSTFLAGS=-C link-arg=-fuse-ld=mold $RUSTFLAGS" >> "$GITHUB_ENV"
fi
# See https://corrode.dev/blog/tips-for-faster-ci-builds/
Expand All @@ -57,9 +56,11 @@ runs:
{
echo "CARGO_PROFILE_RELEASE_LTO=true"
echo "CARGO_PROFILE_RELEASE_CODEGEN_UNITS=1"
if [ "${{ runner.os }}" == "Windows"]; then
echo "RUSTFLAGS=-C link-arg=-fuse-ld=lld $RUSTFLAGS"
fi
if [[ "${{ runner.os }}" == "Linux" && "$(command -v mold)" ]]; then
echo "RUSTFLAGS=-C linker=clang -C link-arg=-fuse-ld=mold $RUSTFLAGS"
elif [[ "${{ runner.os }}" == "Windows" ]]; then
echo "RUSTFLAGS=-C link-arg=-fuse-ld=lld $RUSTFLAGS"
fi
} >> "$GITHUB_ENV"
- name: Enable sscache
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/bench.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ env:
PERF_OPT: record -F997 --call-graph fp -g
SCCACHE_CACHE_SIZE: 128G
SCCACHE_DIRECT: true
MTU: 1504
MTU: 1504 # https://github.com/microsoft/msquic/issues/4618

permissions:
contents: read
Expand Down Expand Up @@ -52,8 +52,6 @@ jobs:
- name: Set PATH and environment
run: |
echo "/home/bench/.cargo/bin" >> "${GITHUB_PATH}"
# Append to RUSTFLAGS, which may already be set by the Rust action.
echo "RUSTFLAGS=-C link-arg=-Wl,--no-rosegment, -C force-frame-pointers=yes $RUSTFLAGS" >> "$GITHUB_ENV"
- name: Install Rust
uses: ./.github/actions/rust
Expand All @@ -75,6 +73,8 @@ jobs:
- name: Build neqo
run: |
cargo "+$TOOLCHAIN" bench --workspace --features bench --no-run
# See https://github.com/flamegraph-rs/flamegraph for why we append to RUSTFLAGS here.
export RUSTFLAGS="-C link-arg=-Wl,--no-rosegment, -C force-frame-pointers=yes $RUSTFLAGS"
cargo "+$TOOLCHAIN" build --locked --release --bin neqo-client --bin neqo-server
- name: Build msquic
Expand Down

0 comments on commit 4f91a73

Please sign in to comment.