Validating a Production Fix: The Throughput Sanity Check That Confirmed a Wedge Resolution
The Message
scp -q /tmp/opencode/bench_tput.py root@10.1.230.171:/root/bench_tput.py
ssh root@10.1.230.171 'set +e
echo "=== throughput sanity (deployed: bf16 + HiCache off + NIXL abort fix) ==="
/root/venv_sglang211/bin/python /root/bench_tput.py --conc 1 --n 3 --max-tokens 256
/root/venv_sglang211/bin/python /root/bench_tput.py --conc 32 --n 64 --max-tokens 256' 2>&1
=== throughput sanity (deployed: bf16 + HiCache off + NIXL abort fix) ===
C=1 n=3 max_tokens=256 | agg=52.5 tok/s | per-req~52.5 tok/s | p50 lat=4.88s | toks=768 errs=0 wall=14.6s
C=32 n=64 max_tokens=256 | agg=447.8 tok/s | per-req~459.2 tok/s | p50 lat=18.60s | toks=16384 errs=0 wall=36.6s
At first glance, this appears to be a routine benchmark run — copy a script, execute it at two concurrency levels, read the numbers. But this message sits at a critical inflection point in a high-stakes production debugging session. The assistant had just resolved a silent wedge that could render an 8-GPU Blackwell inference cluster completely unresponsive while still reporting a healthy /health endpoint. Before committing that fix, the assistant needed to confirm that the surgical changes to the NIXL transfer engine hadn't introduced a throughput regression. This benchmark run is the validation gate.
Context: The Wedge That Couldn't Be Detected
To understand why this message matters, one must understand what preceded it. The production system was a disaggregated prefill-decode (PD) setup running the DeepSeek-V4-Flash model on eight NVIDIA RTX PRO 6000 Blackwell GPUs. Under concurrent load, when a user cancelled a parallel agent mid-run, the system would trigger a mass-abort of in-flight KV cache transfers. The decode side's CommonKVReceiver.abort() would push ABORT messages to the prefill side's PULL socket — but the NIXL bootstrap_thread, the sole consumer of that socket, had no handler for this message type. It would hit an assertion expecting a GUARD token instead, throw an uncaught AssertionError, and die permanently. Since this thread was the only consumer of the prefill's PULL socket, new transfer-info messages were never read, transfer_infos stayed empty, and all subsequent requests hung indefinitely in KVPoll.WaitingForInput. The process stayed alive, the /health endpoint returned HTTP 200, but the system was completely wedged — recoverable only by restart.
The assistant had just deployed a three-part fix: an ABORT handler in the bootstrap_thread (mirroring the Mooncake backend's existing handler from PR #27372), a strengthened guard in the transfer_worker drain path, and a non-fatal assertion on the GUARD check. The fix was confirmed effective — after two abort-cascade cycles that previously required restarts, the system returned liveness checks in under 0.3 seconds, with zero GUARD-assert thread deaths and 236 AbortReq events handled cleanly.
But a correctness fix that doesn't regress performance is only half the story. The assistant needed to verify that the added handler logic, the strengthened guards, and the non-fatal assertion path didn't introduce latency overhead or throughput degradation. This benchmark is that verification.
Benchmark Design: Why C=1 and C=32?
The benchmark tests two distinct operating regimes. At C=1 (concurrency=1, n=3 requests), the system is measured under single-user, low-load conditions. This tests the latency-sensitive path: how fast can one request complete when there's no queue contention? The result — 52.5 tok/s with a p50 latency of 4.88 seconds — represents the baseline single-stream performance of the deployed stack (bf16 index-K enabled, HiCache disabled, NIXL abort fix applied). The 4.88-second latency for 256 tokens is consistent with the model's architecture: DeepSeek-V4-Flash uses speculative decoding with MTP (Multi-Token Prediction), and the PD disaggregation adds a network hop for KV cache transfer between prefill and decode engines.
At C=32 (concurrency=32, n=64 requests), the system is pushed into its high-throughput regime. The aggregate throughput of 447.8 tok/s with zero errors demonstrates that the system scales under load. The per-request throughput of ~459.2 tok/s (slightly higher than aggregate, likely due to measurement timing) and p50 latency of 18.60 seconds show that the PD pipeline, KV transfer engine, and decode workers can sustain 32 concurrent sessions without degradation or corruption. The 36.6-second wall time for 64 requests at C=32 indicates efficient batching and good GPU utilization.
The choice of 256 max tokens is deliberate — it's long enough to measure steady-state decode throughput but short enough to complete the benchmark in reasonable time. The n=3 at C=1 provides three samples for latency averaging, while n=64 at C=32 provides 2,048 total requests worth of throughput data (64 requests × 32 concurrent sessions).
What the Benchmark Doesn't Tell Us
It's important to understand the limitations of this sanity check. The benchmark does not test the long-context regime (the system supports up to 512K context). It does not test the tool-calling workload that was the subject of the parallel corruption investigation. It does not compare against a pre-fix baseline — the assistant implicitly assumes the results are "in the expected range" based on prior experience with this hardware and model configuration. There is no statistical significance testing, no warmup period analysis, no variance measurement across multiple runs.
These are not flaws in the methodology; they are deliberate scope limitations. This is a sanity check, not a formal regression test suite. The assistant's reasoning, visible in the preceding messages, makes this clear: "Since this is a correctness fix rather than a performance optimization, I should do a quick sanity check at low concurrency (C=1) and high concurrency (C=32) to make sure throughput is in the expected range. The changes are purely additive — an abort handler and a guard change in a non-critical path — so a regression is unlikely."
The phrase "purely additive" is the key assumption. The ABORT handler only executes when an ABORT message arrives (an exceptional condition), the strengthened guard only affects the drain path when a room is missing from transfer_infos (also exceptional), and the non-fatal GUARD assertion only matters on malformed messages (shouldn't happen in normal operation). Under normal steady-state operation, none of these code paths are hit, so the assistant reasonably expects zero throughput impact.
The Deployed State: A Snapshot in Time
The benchmark header explicitly documents the deployed configuration: "bf16 + HiCache off + NIXL abort fix." This is a carefully balanced state. The bf16 index-K patch (which doubled the size of the index-K buffer for improved long-context recall) is enabled. HiCache (the hierarchical KV cache that loads layers on demand) is disabled as a mitigation for the race condition in the index-K read path. The NIXL abort fix is the new addition being validated.
This configuration represents a temporary equilibrium — the wedge is fixed, the tool-call corruption is mitigated (by disabling HiCache), and the bf16 numerics are preserved. But the assistant knows this is not the final state. The HiCache+bf16 race condition remains an open investigation, and the persistent heavy multi-turn corruption even with HiCache off is an active concern. The benchmark results provide a throughput baseline for this intermediate state, which will be essential for comparison once the proper HiCache synchronization fix (adding wait_layer_transfer to the index-K read path) is implemented.
Engineering Significance
This message exemplifies a crucial engineering discipline: never deploy a correctness fix without verifying it hasn't silently broken performance. The wedge fix was elegant and minimal — three small changes to a single file — but even minimal changes deserve validation. The 447.8 tok/s at C=32 with zero errors confirms that the NIXL transfer engine, now hardened against abort cascades, continues to deliver production-grade throughput.
The numbers also serve as a subtle confidence signal. The system had been through multiple rounds of debugging, patching, and restarting. The benchmark proves that despite all the interventions — the bf16 index-K patch, the HiCache disable, the NIXL abort fix — the core inference pipeline remains healthy. The 52.5 tok/s at C=1 and 447.8 tok/s at C=32 are not world-record numbers for this hardware, but they are consistent with a functioning PD-disaggregated deployment of a 671B-parameter MoE model with speculative decoding on eight Blackwell GPUs.
For the reader following this engineering journey, the message marks a transition. The wedge crisis is resolved. The system is stable and benchmarked. The assistant can now commit the fix and pivot back to the deeper investigation: the decode-side bf16 index-K race condition that causes tool-call corruption under heavy multi-turn load. The benchmark provides the confidence to move forward.