Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 3 additions & 20 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ jobs:
# cross-night history on the benchmark site stays informational.
nightly:
name: Nightly (${{ matrix.name }})
runs-on: ${{ matrix.runner || 'ubuntu-24.04-arm' }}
runs-on: ubuntu-24.04-arm
# Hosted `main` jobs write the Rust cache; see .github/actions/rust-cache.
environment: ${{ github.ref == 'refs/heads/main' && 'cache-write' || '' }}
timeout-minutes: 60
Expand All @@ -104,21 +104,9 @@ jobs:
strategy:
fail-fast: false
matrix:
# Unset keys default to the ARM runner, the plain dev shell, the Rust
# cache, no perf sampling, and nextest's default profile.
# Unset keys default to the plain dev shell, the Rust cache, and
# nextest's default profile.
include:
- name: Audio grouping relay benchmark
recipe: bench-audio
- name: Relay shard sweep
recipe: bench-shard
# Smoke-tests each capture path: exact off-CPU waits, CPU stacks, and
# heap snapshots, each refused without resolved relay stacks.
# x86: on the SVE-capable ARM runner, perf's DWARF unwinding asks for the SVE VG
# register, which the kernel refuses for the software context-switches event.
- name: Relay profiles
recipe: bench-profile "lock cpu heap" fanout-heavy 4
perf: true
runner: ubuntu-24.04
- name: Rust benchmark tests
recipe: gh nightly rust-test
- name: Binding benchmark runners
Expand Down Expand Up @@ -221,11 +209,6 @@ jobs:
access-key-id: ${{ secrets.MBX_R2_ACCESS_KEY_ID }}
secret-access-key: ${{ secrets.MBX_R2_SECRET_ACCESS_KEY }}

# perf samples the relay in kernel context into large buffers; bench-profile refuses without it.
- name: Allow perf kernel sampling
if: matrix.perf
run: sudo sysctl -w kernel.perf_event_paranoid=-1

- name: Run workload
id: workload
run: nix develop ${{ matrix.shell }} --command just ${{ matrix.recipe }}
Expand Down
9 changes: 6 additions & 3 deletions bench/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ nix develop --command just bench-audio

This sweeps room connections (16, 32) and subscriptions per connection (2, 8)
independently, plus one publisher serving 64 and 200 subscribers. It uses the
normal relay sampler and runs nightly. Each shape reports delivered frames,
normal relay sampler. Run it locally when changing grouping or relay load;
its measurements are not a nightly series. Each shape reports delivered frames,
p99 latency, relay CPU and RSS; the group-size suffix is the number of frames
after the keyframe (0, 4, 9), so each group carries 1, 5 or 10 frames. These
synthetic payloads measure group overhead; they do not measure codec loss
Expand Down Expand Up @@ -152,7 +153,8 @@ Zero shards is the shared runtime with one Tokio thread per usable CPU; any
other count is that many unpinned Tokio workers. The table reports CPU per
connection, so a steering, dispatch, or per-shard cost that grows with either
axis reads as a slope. Linux only, since nothing else steers a reuseport
group. It runs nightly.
group. Run the sweep locally when changing relay sharding; its measurements
are not a nightly series.

Profile the relay under a workload, in one or more capture modes: `lock`
(worker std mutex waits by stack), `cpu` (CPU stacks of every relay thread),
Expand All @@ -166,7 +168,8 @@ nix develop --command just bench-profile cpu chat 4 io-uring-workers origin/main
nix develop --command just bench-profile cpu chat 4 tokio-workers "" ws
```

This builds the relay with `[profile.profiling]` and frame pointers, then runs
This is an on-demand diagnostic, with captures kept in the local run directory.
It builds the relay with `[profile.profiling]` and frame pointers, then runs
the workload over the selected transport (`quic` by default, or `ws`, `wss`,
`tcp`, or `tls`) on the selected runtime (`tokio-workers` by default, or
`io-uring-workers`) at each count twice per mode: an unprofiled control, then a
Expand Down
1 change: 0 additions & 1 deletion quest/m1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ per-frame CPU growth since #5926.
- [Delete the tests that don't earn their cost](/quest/m1/prune-tests.md) - an off-cycle test cost sweep deletes tests whose cost outweighs their signal and makes the rest cheaper
- [Remove the dependencies that don't earn their weight](/quest/m1/prune-deps.md) - Rust, JS, and vendored dependencies that are trivial, duplicated, or serve features not worth keeping are removed
- [Remove what dominates build time](/quest/m1/prune-build-time.md) - the crates, features, and code that cost the most build time are removed or made cheaper
- [Delete the CI jobs that don't earn their cost](/quest/m1/prune-ci.md) - workflows and jobs that don't earn their runner time are deleted, and the rest made cheaper
- [Cluster routing](/quest/m1/cluster-routing/README.md) - prove shared routing contracts, implement per-origin routes, and connect outbound local clusters
- [Routing guide](/quest/m1/routing-guide.md) - concepts and practical outbound federation setup
- [moq-c at parity](/quest/m1/c/README.md) - the hand-written `moq-c` ships at the cut with every m1 binding feature moq-ffi gains
Expand Down
28 changes: 0 additions & 28 deletions quest/m1/prune-ci.md

This file was deleted.

2 changes: 1 addition & 1 deletion quest/m1/prune-tests.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Every test in the merge gate and in nightly is worth its cost. A test whose
wall time, CPU, or flakiness outweighs the regression it alone catches is
deleted. A costly test that earns its keep is made cheaper: fast at its
source, or moved to nightly. CI workflows and jobs belong to
[Delete the CI jobs that don't earn their cost](/quest/m1/prune-ci.md).
[CI workflow audit](/quest/m2/audit-ci.md).

## Plan

Expand Down
Loading