Skip to content

[Test] cpu: prune mirror and tautology cases from the per-commit CPU suite - #45672

Merged
hnyls2002 merged 6 commits into
mainfrom
lsyin/cpu-test-prune
Oct 21, 2026
Merged

hnyls2002 merged 6 commits into
mainfrom
lsyin/cpu-test-prune

Conversation

@hnyls2002

@hnyls2002 hnyls2002 commented Oct 21, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

The per-commit CPU suite (base-a-test-cpu) grew to 860+ registered files. A full audit of every file against the unit-test admission rule (.claude/rules/unit-test-admission.md: each case must name a future diff that turns it red) found a large share of cases whose assertions restate the implementation: wire-format round trips asserted against the decoder's own output, one-predicate-per-case rejection truth tables, mock call-count blocks, and happy-path tautologies.

This PR removes them in three commits: 177 files changed, ~14.2k lines deleted, no production code touched.

Changes

  • Whole-file deletions (21+5): files whose every case is a mirror or is fully subsumed by a sibling suite — e.g. test_uno_token_accounting.py (re-computes the one-line get_num_generated_tokens), test_radix_cache_slru_accuracy.py (no external oracle; test_evict_policy.py pins the SLRU priority tuple directly), ROCm-only leaf-predicate tables, and test_http_server_auth.py (subset of test_auth.py).
  • Disaggregation case pruning (~200 cases): wire round trips on from_zmq / pack / transfer-indices helpers, test_pd_role_switch.py's 14-case test_rejected_* truth table, test_encode_server.py's 50-case TestEncoderDelivery mock-permutation class. Kept: protocol ordering, failure injection, negative branches, cross-process contracts.
  • Case pruning across managers / spec / mem_cache / observability (~120 cases): accessor mirrors, dict-semantics tautologies, constructor read-backs, and one 540-subtest sweep whose oracle re-implemented the rule it tested. Two cases that were unconditional CUDA skips in the CPU suite (dead coverage) are also removed.

Verification

  • py_compile on all touched files; pytest --collect-only clean on touched directories.
  • Executed the pruned suites locally: disaggregation 672 -> 309 collected cases, all passing; managers 334 passed; spec/layers 203 passed; mem_cache 253 passed; observability/misc 229 passed. The remaining failures reproduce identically on main (missing native extensions in the local env).
  • Every deletion was checked against the current file contents, not just the audit snapshot; a handful of audit-flagged cases that had since become load-bearing were kept (listed per-commit).

CI States

Latest PR Test (Base): 🚫 Run #39689952033
Latest PR Test (Extra): ❌ Run #39689950780
Latest PR Test (AMD ROCm 10): ⏳ Run #39689950812

@github-actions github-actions Bot added quant LLM Quantization lora Multi-modal multi-modal language model speculative-decoding hicache Hierarchical Caching for SGLang blackwell SM100/SM120 npu labels Oct 21, 2026
@hnyls2002

Copy link
Copy Markdown
Collaborator Author

/tag-and-rerun-ci

@github-actions github-actions Bot added the run-ci CI: run the baseline test suite on this PR label Oct 21, 2026
@hnyls2002
hnyls2002 merged commit 3438ed6 into main Oct 21, 2026
89 of 104 checks passed
@hnyls2002
hnyls2002 deleted the lsyin/cpu-test-prune branch October 21, 2026 23:02
EricKing626 added a commit to EricKing626/sglang that referenced this pull request Oct 22, 2026
… the merge

sgl-project#45672 pruned `test_ascend_packed_state_roundtrip_uses_buffer_descriptors`
from this file, along with the `torch`, `MambaStateBufferInfo` and
`MambaPoolHost` imports it was the only user of. Resolving the merge in favour
of this branch brought the test body back but not the imports, so lint failed
with seven F821 on `torch`.

Take upstream's deletion and re-apply only what this branch adds: the
`DSATokenToKVPool` import and the two DCP draft-layout cases.
jeynmann pushed a commit to jeynmann/sglang that referenced this pull request Oct 22, 2026
The merge restored six cases that sgl-project#45672 had just pruned from the
per-commit CPU suite; drop them again to match upstream:

- test_alloc_mmap / test_alloc_shm / test_shm_host_tensor_allocator /
  test_alloc_shm_unlinked: tautologies (shape/dtype/data_ptr asserts);
  the alloc paths stay covered by the hugepage mode/marking tests and
  the shm hugepage-warning test.
- test_page_first_direct_mla/mha_uses_page_registration_granularity:
  mirror pair; page registration granularity stays covered by the
  mamba, k-only MHA and DSA granularity tests.
At1a8 pushed a commit to At1a8/sglang that referenced this pull request Oct 22, 2026
Main deleted test_scheduler_batch_is_full_latch.py when pruning mirror
cases from the CPU suite (sgl-project#45672); the two HiSparse V2 latch cases sgl-project#32314
added to it go with the file.

Co-authored-by: Cursor <[email protected]>
ShangmingCai added a commit to aurickq/sglang that referenced this pull request Oct 22, 2026
Main (sgl-project#45672) pruned the mirror from_zmq and worker tests this PR had
extended. Keep only the PR's own cases on top of main's versions of
test_disaggregation_wire.py, test_nixl_backend_basic.py and
test_prefill_abort_result_cleanup.py.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
ShangmingCai added a commit to ShangmingCai/sglang that referenced this pull request Oct 22, 2026
Resolve conflict with sgl-project#45672 (deleted test_scheduler_prefill_decode_interval.py):
keep only the min-bs cases. Append prefill_decode_interval_min_bs to
POSITIONAL_FIELD_ORDER required by sgl-project#44991.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
ShangmingCai added a commit to KrishnanPrash/sglang that referenced this pull request Oct 22, 2026
main sgl-project#45672 deleted test_encode_receiver.py. Keep only this PR's
bug-regression case there (fails on main, passes with the fix).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
detain added a commit to detain/sglang that referenced this pull request Oct 29, 2026
…20 commits since 12dc623 @ merge-sgl-project#4)

Conflicts: 167 files (149 content / 14 add/add / 4 modify/delete) at the settled
309 tip d28e7cd -- dossier predicted 146 +/-25; the +21 shift is entries
275-309 landing qsa-ring/hicache-ctrl/gdn/moe/llguard deltas into the conflict
zone. By class: A 13 (auto-takes-upstream, dedupe-verified), B 80, C 56, D 18.
102 TODO(merge5) re-plant/fold markers planted: B1 x15, B2 x29, B3 x12, B4 x23,
B5 x23. Re-plant stock: 117 files under /tmp/opencode/merge5-dossier/replant/
(76 fork-hunks patches, 19 upstream-side patches, 14 AA fork copies, 8
preremove snapshots) -- sessions 2/3 re-plant from real code, not memory.

D-list outcomes (must-not-auto-resolve, handled personally):
- sgl-project#45289-vs-sgl-project#44858 (entry 301): VERIFIED, not re-resolved -- the gate/up-order
  final form is in origin/main (5b1dbc2 in range); scales test taken as
  upstream oracle, fork 191-line version saved to replant/ for B5 diffing.
  sgl-project#44858's call-site shape CANNOT survive (our base never had it).
- entry-230 dispatcher vs sgl-project#44993/sgl-project#44994: took upstream structure in
  token_dispatcher/standard.py; published-value CONTRACT lives upstream via
  get_moe_runner_backend() in the LoRA-EP guard; fork's warn-once mismatch
  diagnostic re-plants (B5 marker). UNION GATE: standard_dispatcher 16P (was
  12P, suite grew), model_overrides 121P/1S/210sub (was 112P/1S/181sub),
  fold probe 6P/2F (upstream added a runner_backend arg to the predicate --
  B5 re-pins the probe).
- entry-219 gauge names vs sgl-project#43727 return + sgl-project#44968: PER-POOL NAMES KEPT as the
  serving schema -- hicache_host_pool_{used,total}_tokens{pool} dataclass
  fields, Gauge registrations and labels(pool=) emission re-restored over the
  #4697x structure; hicache_host_pool_evicted_tokens_total already survived
  auto-merge; producer dict restored by union in metrics_reporter. ANTI-NEEDLE
  SATISFIED: old mamba-only gauges are NOT the serving schema.
- entry-221 eager-direct add/add: DEDUPED to upstream (bodies identical except
  est_time 15->9); MEASUREMENT DEBT RECORDED: prefill t/s must be re-measured
  post-B4 before trusting the est_time.
- entry-168 D2H fence vs sgl-project#44800: the fence is ALREADY UPSTREAM (both
  load_fence_stream + write_fence_stream with the load-thread-corruption
  comment in origin/main's cache_controller.py) -- nothing re-planted; the two
  real regions resolved as import-union + comment wording (merge sgl-project#4 stale-tail
  pattern avoided). Fork hunks still saved to replant/ (belt).
- entry-209 clamp + 216/218 ordering + 288-295 hicache-ctrl-era vs #46970x KV
  rewrite: ADOPTED-UPSTREAM across unified_radix_cache/hicache_storage/
  hybrid_cache_controller/memory_pool/kv_cache_builder; EVERY fork hunk
  extracted to replant/*.fork-hunks.patch; B3 re-plant markers planted.
  sgl-project#45703's short-full-match seam arrives with upstream.
- sgl-project#45090 SGLANG_ENABLE_UNIFIED_RADIX_TREE: REMOVAL TAKEN (fork had already
  moved it to _DeprecatedEnv; now gone). grep: ZERO .py readers repo-wide;
  2 upstream-owned docs jsx snippets still export it (deepseek-v4, glm-5.2 --
  upstream's own debt). OPERATOR-OWED CHECK: confirm no /root harness exports
  it (unreadable from this seat).
- sgl-project#39727 unified L3 key: VERIFIED OPT-IN -- merged hicache_storage.py keeps
  the DEFAULT legacy suffix composition _<model>_<tp_rank>_<tp_size>
  (content-anchor: HiCacheFile._init_config_suffix, raise-guarded when
  _unified_chunk_spans is set). ANTI-NEEDLE: no silent key-scheme switch;
  warm /root/hicache_store contents stay addressable.

Modify/delete (4, all victims of upstream sgl-project#45672 test prune + URC split):
- test_unified_radix_cache_unittest.py: REMOVED (adopted split) -- its bare
  unified_tree_core_inspector imports are unreachable post-sgl-project#45236 re-home;
  fork source + hunks saved; B2 marker planted in the new core test.
- test_fused_moe_triton_config.py: REMOVED -- imports common_utils, absent
  from both sides post-sgl-project#45672; the 2 live entry-3/235 tests re-plant in B2.
- test_scheduler_batch_is_full_latch.py: REMOVED -- fork delta was 3 stub-attr
  lines documenting sgl-project#46643's absorbed arms; upstream deletion correct.
- test_qsa_kv_pool.py: KEPT -- fork's 147 added lines are entry-187/200
  sharding + 285-287 QSA-ring tests with NO upstream replacement;
  qsa_kv_pool.py sides converged byte-identical; collects clean. B2 marker.

Cascading silent-auto-merge repairs (classes not in the conflict set but
broken by auto-merge + union splices -- all found by gates, now fixed):
kernels/ops/activation/__init__.py (dead _CUDA registration dup), kernels/ops/
diffusion/__init__.py (5-tuple _SPECS entry), kernels ops embeddings/moe/
attention/mamba __init__ (KernelSpec fields removed upstream: description/
format_signature stripped, CapabilityRequirement->CUDA_ONLY), base_runner/
eager_runner cp_extend + shared_read_event imports retargeted per upstream's
"no imports in runner_utils/__init__" contract, and 4 fork helpers grafted
back onto their take-upstream homes because merged code/tests still import
them (memory_pool.spec_intermediate_bytes_per_req, kv_cache_builder.
_adjust_hicache_size_for_draft + _device_pool_size_per_token,
hybrid_cache_controller.local_restorable_mask, validation_hook.
validate_replayssm_spec_algorithm, arg_groups/moe_hook b12x validator).
flashinfer_cutlass.py flipped to FORK-OWNED (b12x route is fork-only, 760 vs
95 lines; upstream sgl-project#44993 hunks = B5 fold patch saved).

Silent-semantics notes: sgl-project#46127/sgl-project#44912 riders arrived via per-PR picks (union);
sgl-project#45520 (entry 302) is STILL OPEN upstream -- entry-230 fail-safe layer stays
as entry 303 records; if a future sync brings it, re-apply the fail-safe reads.
qwen4_exp holder-contract fused (ctor takes optional batch).

Gates at commit: import sglang OK (CVD=9, prod venv); check_registered_tests/
check_no_bare_pytest_main/check_no_registered_tests_in_package rc=0; ruff F821
+E9+format clean on the resolution set; collect-only over unit/{mem_cache,
model_executor,distributed,layers/moe} = 4337 nodes, 3 ERRORS: 2x cargo/torch-
sys libtorch probe (REPRODUCED IDENTICALLY AT THE PRE-MERGE TIP -- env issue,
not merge damage) + test_hicache_async_ready_sync.py (entry-253-era attribute
gone with the URC rewrite -- EXPECTED pre-B3).

sessions 2/3 owed: B2 test re-home, B3 mem_cache+rust re-plant (+hicache-ctrl
re-ports), B4 scheduler/admission, B5 moe/quant/dispatcher, B6 environ+C0a+
CAVEATS re-pin. PROD BOOT FORBIDDEN until B3 completes (209 clamp + 218
ordering re-plant).
detain added a commit to detain/sglang that referenced this pull request Oct 30, 2026
…entries 122,198,200,211,215,220,267,268,305

Re-plants the scheduler.py fork-hunks (replant/...managers__scheduler.py.fork-hunks.patch)
onto the post-sgl-project#46977 admission structure. tp_worker marker consumed (15/23 B4 markers
still on the tree; per-file counts, damage-state from entry 310's map).

PER-HUNK DECISIONS (all VERIFIED against the merged tree, not taken on faith):
- entry 122 (sgl-project#40458): grammar-sync overlap disable RE-PLANTED for mixed mode
  (is_decode() OR is_mixed()) + the fork's trimmed comments; upstream's
  host-draft-only arm was the pre-sgl-project#40458 form (origin/main verified: absent).
- entry 220 (sgl-project#39765, OPEN port): _has_pending_mamba_cache_update + the early
  pop_and_process/short-circuited disable-overlap RE-PLANTED into
  event_loop_overlap; the require_mlp_sync/disable/extra-buffer gate verbatim.
- entry 198 (sgl-project#37612): THE CATCHER — B3-5 landed the raiser; the
  try/except MambaCowAllocError around init_next_round_input (res=NO_TOKEN,
  request stays queued; the revert block + unconditional alloc_group_end were
  already in the merged tree = the no-leak halves VERIFIED PRESENT) RE-PLANTED
  with the import. COW component test re-anchored to the #46970x kv_storage
  seam the B3-5 replant moved _state() behind (stub was the pre-split
  mamba_allocator shape).
- entry 268 (sgl-project#46643, OPEN port -- VERIFIED NEVER MERGED: git log
  12dc623..2a6c204 --grep 46643 = ZERO; only sgl-project#45491/sgl-project#45435/sgl-project#45472/sgl-project#45670
  of the briefed merged-list arrived in-range): the UNCONDITIONAL batch_is_full
  clear RE-PLANTED on the scheduler side, subsuming the entry-198 hybrid-SSM
  arm and the priority-preemption/is_empty arms (policy side lands in B4-3).
- entry 267 (sgl-project#46496): retract_decode new_token_ratio FLOOR clamp RE-PLANTED.
- entry 211: triton_load_watch.prewarm_device_loads(self.model_worker) line
  RE-PLANTED between install() and mark_serving_started (the utils-side
  function survived the merge; only the call site was dropped).
- entry 200 (sgl-project#43527) CAPACITY PAIR RE-PLANTED: model_runner
  .logical_max_total_num_tokens passes allocator= again (the configurator's
  PageInterleavePoolAllocator -> allocator.size branch SURVIVED the merge
  byte-identical, so the merged tree had the fork predicate with upstream's
  consumer-side multiplications = DOUBLE-COUNT); the three scheduler
  * kv_shard_widening multipliers back to the fork form (pool-stats shape,
  load_inquirer, and the init_req one-page-per-shard subtraction);
  tp_worker drops page_interleave_shard_size x + import. Upstream's
  invariant-checker hunk: OBSOLETE (the constructor no longer takes
  max_total_num_tokens -- absorbed by refactor).
- entry 215 (sgl-project#44351/sgl-project#44401/sgl-project#44420): VERIFIED ALREADY PRESENT at the merge
  (filter_batch-every-step + reset ride, num_held_rows, budget_state FIRST
  statement, PD-gate deletion all byte-compare to the fork form) -- DEDUPED,
  no edit. Entry 107's local early-revision of sgl-project#40940 stays superseded
  (entry 215 rule), and its re-plant here would double-count.
- entry 220's/305's pause-window busy accounting + write_fence_stream +
  is_empty arm: VERIFIED PRESENT (entry 305 landed patch-identical via
  sgl-project#46127; the fence assignment is the B3-2 controller half) -- DEDUPED.

TEST FIXTURE RE-ANCHORS (not B2's: no markers, pure new-upstream-contract
drift, per the entry-198 fixture-adaptation precedent): the two hybrid-ssm
admission stubs gain disagg_prefill_bootstrap_queue=None (upstream's
routing-key bootstrap_queue arg in calc_priority arrived in-range).

PRUNE vs BREAKAGE (managers −523sub audit): the three managers test files
vanished in-range (test_schedule_policy_dfs_weight, test_scheduler_batch_is
_full_latch, test_uno_token_accounting) were ALL deleted by upstream's OWN
sgl-project#45672 prune (3438ed6). Two are byte-identical upstream copies = zero
fork delta. The third carried a 3-line fork comment/stub delta whose
SEMANTICS the re-planted unconditional clear pins: its case was the
is_empty-arm mirror of test_scheduler_hybrid_ssm_admission_latch (present,
green, hybrid_swa/non-hybrid arms included) -- NOT re-homed, recorded.

ACTUALS (damage -> after, CVD=9, prod venv, PYTHONPATH=python, per-file):
  test_scheduler_hybrid_ssm_admission_retry   4F -> ** 4P **
  test_scheduler_hybrid_ssm_admission_latch   3F -> ** 4P **
  test_mamba_prefill_cache_boundary  2F/12subF -> ** 5P/12sub EXACT (220 pin) **
  test_scheduler_retract_ratio                1F -> ** 2P EXACT (267 pin) **
  test_scheduler_init_req_max_new_tokens      1F -> ** 10P/6sub **
  test_scheduler_grammar_mixed_tail_sync      1F -> ** 4P **
  adjacent scheduler-stub files (held_row, running_batch_finished,
  pause_generation, disagg_idle, dp_converted, hicache_events) 56P/64sub
  UNMOVED -- no regression from the clear/catcher/capacity edits.
Lint: ruff format + F821/E9 clean on all five files; imports OK (no GPU
execution, no push).

Co-Authored-By: OpenCode <[email protected]>
detain added a commit to detain/sglang that referenced this pull request Oct 30, 2026
…re-plant) SESSION 2B COMPLETE

Entry 312 records: the 5 cluster commits (9bd9007..5cde7a5) with per-
cluster batteries; THE sgl-project#46977 RECONCILIATION DECISION TABLE (per-hunk
survive-as-is / re-adapt / supersede, incl. the git-log proof that the
spec-mamba four arrived in-range while the admission six NEVER merged --
correcting the briefing's dedupe list, and sgl-project#46643 fix(1)'s reconcile as
already-merged base-PrefillBudget form = the reason prefill_budget.py got
ZERO B4 edits); the entry-200 CAPACITY-PAIR restoration (our configurator's
allocator.size branch survived -> upstream's consumer-side multiplications
double-counted -> model_runner allocator= kwarg + tp_worker/scheduler
subtractive forms re-planted; invariant-checker hunk OBSOLETE by upstream
refactor); the io_struct NEEDS-ATTENTION VERDICT (upstream's own
pointer_head guard vs stale fork stub -- test-side one-field re-anchor,
matching sibling stubs); the -523sub PRUNE-vs-BREAKAGE audit (all three
vanished managers files died to upstream's OWN sgl-project#45672 prune, two byte-
identical to origin/main, the third's fork delta subsumed by sgl-project#46643 --
recorded, not re-homed); the B3 cross-note closures (MambaCowAllocError
CATCHER landed; 216/217 admission interplay VERIFIED absorbed); the 2err
population correction (replayssm_ring_fold pruned by sgl-project#44690, gdn cutedsl
probe lives in the kernels zone, the spec dir's real err was merge damage,
now 0err); the runner-zone finds the damage map missed (_init_model_hooks
BOOT-INTEGRITY loss -- real decode-runner builds AttributeError, and
component_manager's dropped residency half that parallel_executor already
CALLS: both re-planted, 7F+crash-class closed); the true marker census (23
tree-carried, NOT the briefing's 20 -- B3 lesson applied; ALL consumed,
B4=0, B1/B2/B5 diff-audited intact).

GATES: trailing_endpoint ** 17P = 17P ** re-verified post-B4 (DoD-d, B3's
gate unmoved). DoD(e) diff audit: ZERO mem_cache/ files changed, ZERO in
qsa/moe-quant zones (moe_hook diff is marker-removal-only).

NEW PINS: unit/managers 1009P/81F/9S/412sub/2err -> 1056P/2F/9S/474sub (2F
= the two documented order-dependent mm_process_config ENV F's; the dir's
2err never reproduced -- population is the spec row's); unit/spec
363P/20F/21S/238sub/2err -> 388P/0F/21S/238sub/0err EXACT over 7
consecutive full-dir runs. OWED RESTART-WATCH REAFFIRMED: sgl-project#45472's
sync-free planning (verified present, upstream form) + sgl-project#46643's
unconditional per-round admission re-runs (re-planted) ride the entry-201
restart; entry-198's TTFT/starvation measure STILL OWED.

Header: STACK -> qwennext-stack-312+merge5-b4-2026-10-29; +merge5-b4 wave
tag; tip -> 5cde7a5; entries 1-312; INTEGRATION OWED annotated B4
LANDED (boot ban STAYS). wanted_stack: UNTOUCHED (no S-item changed by B4
findings -- recorded here). ENV debts recorded NOT-fixed: pcie_vocab_gather
GPU suite (27F identical at the merge commit), openai 2.6.1<2.8.0
serving_responses import (upstream's own beam.py), imageio (whole diffusion
import chain). NOTHING PUSHED; tree clean; zero GPU execution; zero prod
boots all session.

Co-Authored-By: OpenCode <[email protected]>
detain added a commit to detain/sglang that referenced this pull request Oct 30, 2026
…ome + hybrid_pool_assembler 5-class re-home + fused_moe_triton_config 2-case restore -- entries 73,91,114,199,218,219,222,241,3/235

THE KITS GATE (the 1056F storm): B3 proved the post-merge mem_cache
residue is URC-split kits calling get_device() at build_fixture on CPU
(upstream's split ships the topic files CUDA/AMD-registered -- register_cuda_ci
stage-b -- and its kits assume an accelerator; our dir battery runs CPU).
Fix at the kits' SINGLE device choke point: fixtures.build_fixture now
pytest.skip's when torch.cuda is unavailable (mirrors the sibling
kernels/qsa module CUDA gates), so the CPU run reports HONEST SKIPS while
the device-free surfaces (40 in the URC dir alone) keep RUNNING. No test
deleted, no coverage narrowed; a GPU seat still executes every case.

357-LINE URC-UNITTEST FORK BODY re-homed from the preremove snapshot
(the monolith died to upstream's split; markers in the topic files pointed
here; two of the ten cases were ALREADY re-homed by the merge work --
verified and left in place):
  (a) TestUnifiedRadixCacheBatchedWriteThrough (6 tests, entry-218 family,
      incl. the ONE-fence writing_check discipline B3-3 planted) ->
      test_unified_radix_cache_hicache.py; imports + kits name translations
      (drop_hicache_atexit_pin, node_* helpers, ExtraPool naming).
  (b) test_buffer_only_split_pool_sidecar_storage_roundtrip (entry-222
      sidecar draft-budget family) -> test_unified_radix_cache_storage.py
      INSIDE UnifiedRadixCacheStorageSuite (kits _init_buffer_hicache /
      _buffer_backup_and_wait / mixin helpers verified present);
      register_host_pool_entry + sidecar_pool_specs verified live
      (controller :395, decode.py consumers).
  (c) test_batched_backup_reuses_the_on_path_h_leaf -> insert_walk topic:
      the shared _build_host_full_on_path_h_leaf(batched=) helper EXTRACTED
      from the tip verbatim (renamed to the kit helpers), the already
      re-homed twin test rewritten onto it byte-equivalently, and the
      batched twin added -- pair stays a matched pair.

test_hybrid_pool_assembler.py: the five fork classes RE-PLANTED verbatim
from the 309 tip (_Pool/_DevicePool/_fake_mamba_pool/_glm_mamba_pool
helpers + TestHicacheMambaSizeKnob + TestMambaHostCoverageLine +
TestBuildPoolEntryCallSites + TestMambaHostShare incl. the entry-263/295
host_capacity_bytes CHECKPOINT-ONLY pin B3-8 recorded) -- the merge took
upstream's file wholesale; TestDeviceAllocEviction/TestSplitHicacheSize
NOT re-homed: BYTE-IDENTICAL to the pre-merge upstream copies (verified
by diff) = upstream's own prune, B4-audit precedent. The appended tip
stubs that shadowed re-homed current-file fixtures (stale
_build_unified_swa_pool vs the fused_draft-aware builder, the duplicate
TestUnifiedPageEnvelopeHostPool) were stripped; call-sites ride the
current seams. The :1716 B2 marker is consumed.

test_fused_moe_triton_config.py RESTORED slim (2 cases, entry-3 tuner-
filename contract + entry-235 RTX PRO 6000 tuned-config fleet pin):
upstream's sgl-project#45672 prune deleted the monolith file, but these two are fork
artifacts (8 config JSONs under configs/triton_3_7_1 for
NVIDIA_RTX_PRO_6000_Blackwell_Server_Edition) -- re-register_cpu_ci,
CI lint trio (check_registered_tests / no_bare_pytest_main /
no_registered_tests_in_package) ALL rc=0.

python/-zone B2 markers: the two kits inspection files' get_parent_node_id
+ _build_backup_kv_action surfaces VERIFIED PRESENT (stale placeholder
markers consumed; the entry-199 parent-id API is live in
unified_tree_core_interface:226 + adapter:1082 + kits :32/:34).

Battery ACTUALS (CVD=9, prod venv, PYTHONPATH=python, import sglang OK):
  unit/mem_cache dir: 1861P/1209F/364S/4514sub/2err (B3 pin) ->
    ** 1861P/153F/1420S/4514sub/2err ** (run mid-cluster; 153F == the
    PURE ENV decomposition: cargo/torch-sys 130F+2err + no-CUDA ~23F;
    the 1056F kits block is now honest skips; P EXACTLY preserved)
  unified_radix_cache topic dir: 40P/1255S/0F standalone
  test_hybrid_pool_assembler: 44P/36sub -> **52P/0F/36sub** (>= 295-era
    53P/31sub on the P axis net of upstream's own prune; subtests +5)
  test_fused_moe_triton_config (restored): 2P/0F
  ruff F821+E9 + format + CI trio: clean
  B5 CLOSURE (definitive battery-3, final tree): 650P/683S/195F/560sub
    vs damage 637P/683S/201F/558sub and pre-merge 573P/682S/195F/444sub:
    F back to PRE-MERGE PARITY, every F env-documented (trtllm-gen 8,
    fused_gate 52 CUDA-gated, triton_fused 96 CUDA, round_robin 38
    CUDA[+1 upstream case], mega_moe 1 [B2 marker :905, test-side]);
    named gates: dispatcher 21P/45sub, runner_backend 16P, smallm
    28P/66sub, b12x 67P/46sub EXACT, kernels_namespace 107P, overrides
    121P/1S/210sub EXACT, fold probe 9P, mem_pool_ep 49P/0F (1F closed),
    scales 20P/44sub, fp4_gemm 12P. B5 MARKER CENSUS: ZERO.
detain added a commit to detain/sglang that referenced this pull request Oct 30, 2026
…t a LIVE production regression (sharded-QSA decode) -- entries 200,125/200-era + 285-287 ring KEEP audit + pp_sync_drain recovered -- entries 217-era, 285-287

(test_page_interleave_shard.py): upstream grew the file 58->80 in-range
while the merge took their side and DROPPED the fork's 9 entry-200 cases
(4 TestClassedAllocator decode tests + 5 module-level sharding/
localization/configurator functions). Re-homed VERBATIM (helpers
_make_allocator/_alloc_extend byte-identical; imports extended: pytest +
QSACompressedBlockSharding/QSARawKVSharding/QSATokenToKVPool +
localize_compressed_page_table). TestDeviceAllocEviction/
TestSplitHicacheSize NOT restored: byte-IDENTICAL to the pre-merge
upstream copies (verified by diff) = upstream's own prune, B4-audit
precedent. The decode-helper stub rides the post-#46970x storage seam.

THE CATCH (production, not test): test_decode_helper_forwards_request_
rotation_bases went RED for a REAL reason -- the merged StaticKVStorage.
take_decode calls allocator.alloc_decode WITHOUT rotation_bases while
PageInterleavePoolAllocator.alloc_decode asserts one base per request
(the extend path's forwarding arrived at static_kv_storage:180-187, the
decode path's was dropped). As merged, ANY sharded-QSA decode raises on
that assert -- the entry-200 contract half-dead. RE-PLANTED: take_decode
forwards [req.kv_rotation_base for req in batch.reqs] under
page_interleave_shard_size(allocator) > 1, mirroring the tip's helper-era
forwarding and take_extend's shape.

(test_qsa_kv_pool.py): KEEP past sgl-project#45672 audited -- the retained file is a
PURE SUPERSET: upstream's single mooncake-scope test (which sgl-project#45672's file
deletion would otherwise have LOST) + 5 fork cases (125/200 sharding
budget + 285-287 ring). est_time=5 vs 8.7s wall = the constant interpreter
boot other registered files share; kept. Marker consumed.

(test_hicache_pp_sync_drain.py): TestPPSyncDrain RECOVERED, not just
recorded: _drain_async_work is UNCHANGED production (unified_radix_cache
.py:416, waits all + clears) so the 2 lost cases + _FakeWork/_Holder
transplant verbatim. 4P/0F.

Battery ACTUALS (CVD=9, prod venv, PYTHONPATH=python):
  test_page_interleave_shard: 80P/17F -> **91P/17F/56sub** (17F == the
  documented _1_rust cargo class EXACTLY; +11 nodes = the fork 9
  re-homed, incl. 2 parametrized)
  test_hicache_pp_sync_drain: 2P -> **4P**
  test_qsa_kv_pool: 8P (unchanged, marker consumed)
  ruff F821+E9 + format clean on all 4 files
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

blackwell SM100/SM120 hicache Hierarchical Caching for SGLang lora Multi-modal multi-modal language model npu quant LLM Quantization run-ci CI: run the baseline test suite on this PR speculative-decoding

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant