[TENT] Add QoS metrics baseline to tebench#2841
Conversation
…i#2792) Within a priority tier, when several flows contend for one NIC the bandwidth is split blindly/equally today, with no way to give a flow about to miss its deadline a larger share. This adds an opt-in, deadline-aware arbitration. The ordering acts at the per-NIC-path slice-post point: after slices are grouped by (local NIC -> remote NIC), they are sorted most-urgent-first by predicted MLU (predicted transfer time / remaining deadline window, reusing the MLU notion from kvcache-ai#2618) before submitSlices() hands them to the QP budget. That is the point where same-tier flows actually contend for the shared NIC; an earlier prototype that reordered at the priority-queue pop had no effect because the QP budget, not the tier queue, is the contention point. * bw_arbitration.h: pure OrderByUrgency() policy (unit-testable, no RDMA deps) + PredictedMlu(). bw<=0 or no-deadline degrade to original order. * workers.cpp: opt-in wiring via transports/rdma/deadline_bw_arbitration (default false = byte-identical FIFO / equal split). * transfer_engine_bench: --deadline_us / --deadline_tight_threads to tag N threads as tight-deadline flows + per-flow tight/loose throughput report. * bw_arbitration_test: 7 cases (tighter-first, no-deadline-last, past-due, FIFO ties, zero-bandwidth no-op, size-weighting). Measured (H20/ConnectX 200G RoCE, 2 nodes, 16 threads = 4 tight + 12 loose, 1 MB): tight flows 12.1 -> 44.6 GB/s (+269%), loose yield, total throughput unchanged (48.4 GB/s). At light load it is a no-op, as intended. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
# Conflicts: # mooncake-transfer-engine/tent/tests/CMakeLists.txt
There was a problem hiding this comment.
Code Review
This pull request introduces QoS metrics baseline support and deadline-aware NIC bandwidth arbitration within a priority tier for the transfer engine benchmark tool (tebench). It adds command-line options to configure QoS classes, calculate metrics (such as SLO attainment, Jain's fairness, and isolation leakage), and output versioned JSONL records. Additionally, it implements a deadline-aware scheduling policy for RDMA transport workers to prioritize urgent flows. The review feedback highlights a potential undefined behavior bug when parsing empty SLO fields and suggests avoiding hardcoded /tmp paths in unit tests to prevent permission conflicts in shared environments.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
Cluster validation update:
The cluster run also exposed and fixed two reporting issues: JSONL now retains |
|
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
|
Superseded by #2845. The fork branch was renamed to remove the disallowed |
Summary
--qos_classes=name:threads:slo_us:weight[:isolated_gbps],...workload contract totebenchnull/N/AMetric semantics
throughput / weight.max(0, 1 - mixed_throughput / isolated_throughput)and is only emitted when the caller supplies a matching isolated baseline.Validation
USE_TENT=ONtebenchtargets build successfully with GCC 13.3 in a clean Ubuntu 24.04 container.tebench_qos_metrics_testpasses in both builds, covering contract parsing, validation, metric math, JSON validity, and null semantics.sinian-public-1->sinian-platformpassed. With 64 KiB x batch 4 and four workers, the strict 1 ms foreground SLO attained 17.65%; Jain fairness was 0.8338, maximum isolation leakage 41.21%, and utilization 68.45%. All values were independently recomputed from the JSONL inputs.Dependency
This draft is stacked on #2794 because that PR introduces the reusable
tebenchdeadline workload and per-request deadline plumbing. Once #2794 merges, this branch will be rebased ontomainbefore review.