Skip to content

fix: resolve nightly eval - #1426

Merged
zhyncs merged 1 commit into
mainfrom
tmp
Sep 14, 2024
Merged

zhyncs merged 1 commit into
mainfrom
tmp

Conversation

@zhyncs

@zhyncs zhyncs commented Sep 14, 2024

Copy link
Copy Markdown
Contributor

Motivation

as titled

ref https://github.com/sgl-project/sglang/actions/workflows/nightly-eval.yml

Modifications

Checklist

  • Format your code according to the Contributor Guide.
  • Add unit tests as outlined in the Contributor Guide.
  • Update documentation as needed, including docstrings or example tutorials.

@zhyncs
zhyncs merged commit e3fc465 into main Sep 14, 2024
@zhyncs
zhyncs deleted the tmp branch September 14, 2024 16:07
other_args.extend(["--tp", "2"])
if "DeepSeek" in model:
other_args.append("--enable-mla")
other_args.extend(["--enable-mla", "--mem-frac", "0.85"])

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is because after implementing CUDA Graph in Triton Runtime, the original mem-frac will cause OOM, so it is necessary to manually adjust mem-frac to bypass this issue. cc @merrymercy

timethink pushed a commit to timethink/sglang that referenced this pull request Mar 9, 2025
efschu pushed a commit to efschu/htsglang that referenced this pull request Sep 16, 2026
…d CUDA graphs. Verify step: the spec_info plan is rebuilt with the weighted owner rule (checked equal), split into body and tail, the tail planned on a BatchPrefill wrapper over the ring and merged after the paged body call; the ring is armed for verify writes (begin_step). Captured decode/verify use graph-mode tail wrappers (use_cuda_graph, frozen buffers sized to the ring) re-planned out of graph each step (basis 2.9). The speculative refusal of sgl-project#1425 is lifted. Tests: kv_tail_1243: 120 passed (desk); metal proof = boot kvt1.
efschu pushed a commit to efschu/htsglang that referenced this pull request Sep 16, 2026
…uires --disable-cuda-graph (slice 2 graph-mode tail wrappers); kvt1 refused at start on this check.
efschu pushed a commit to efschu/htsglang that referenced this pull request Sep 16, 2026
efschu pushed a commit to efschu/htsglang that referenced this pull request Sep 16, 2026
…ive decoding for the precision tail

The target's verify EXTEND now plans the tail over the ring (_kv_tail_plan_verify)
and merges it after the paged body call (_kv_tail_merge_verify), so the argv gate
that refused --speculative-algorithm NEXTN/EAGLE is stale and cost the kvt1 window
(boots kvt1d/kvt1p 16.09. 14:22Z refused at launch). No other parse-time tail gate
remains besides --page-size 1 (server_args._handle_kv_tail).

Tests: test/registered/unit/mem_cache/test_kv_tail_1243.py 120 passed, 19 subtests
(hermetic, CUDA_VISIBLE_DEVICES="").
efschu pushed a commit to efschu/htsglang that referenced this pull request Sep 16, 2026
…DCP extend path

Boot kvt6d (16.09. 15:35Z, D-layout TP3 uneven DCP + MTP + graphs, --kv-tail-min-tokens 16384,
no memory saver): READY after 120 s, ring 36864 rows/rank bf16, 0 tracebacks at boot. On the
needle request the verify plan attended 3 tail rows (6 ring rows held) but tail_merges stayed 0
and the W56 falsifier stopped the step by name: the sgl-project#1426 merge hook sat only on the non-DCP
forward_extend, while this layout runs _forward_extend_dcp.

Fix: after each of the two paged body reads of _forward_extend_dcp (prefill_wrapper_paged
.forward_return_lse over q_full) the rank-local body partial is merged with the rank-local
ring partial (_kv_tail_merge_verify) BEFORE cp_lse_ag_out_ar_mha_uneven -- the tail is a
partition of this rank's owned set. _kv_tail_merge_verify accepts the 3-D q_full unchanged
(the tail wrapper is planned with the same iu.num_qo_heads as the body wrapper).

Tests: test/registered/unit/mem_cache/test_kv_tail_1243.py 127 passed, 19 subtests
(hermetic); new Test1428: every DCP paged read is followed by the tail merge before the
LSE all-gather; merge accepts 3-D q.
efschu pushed a commit to efschu/htsglang that referenced this pull request Sep 16, 2026
…unt was a second bookkeeping next to the tree counter and turned the OOM into a three-minute park (P: 2 queued, 0 running, sweeps refused 8/8 with the ring empty and no reason in the log). Removed. The peel now does what upstream's synchronous write-back does: on a refused leaf it drains the in-flight write-throughs (acks rebind rows to arena slots and free the staging ring) and retries once; a second zero is a real wall and stays reported by the under-delivery check. The one silent zero in write_backup (controller.write None) is named (tier_disarmed / unaddressable_rows / host_alloc), and sgl-project#1421 samples per reason so the innermost refusal of a parent_unbacked chain is never hidden again. Tests: 1426 (4), 1417, 1175, mamba floor/773/924 green.
efschu pushed a commit to efschu/htsglang that referenced this pull request Oct 12, 2026
…m takes both drop routes (l3_drop and ud_drop); the state can change after the top L3 check

Review finding (major): the fallback after the refused arena claim accepted only
ROUTE_UD_DROP, but device_exit_route returns ROUTE_L3_DROP for an l3_present
node whenever it is droppable. If the node changed between the top-of-function
L3 check and the fallback (the sgl-project#1426 drain clears ongoing_write_through, the
store ack sets l3_present, ARENA-DROP clears host children), nothing was
dropped where the base 6c53a95 (unbacked_drop_allowed, no l3 term) dropped
it, and AgreedRoomShort could fire where the base survived. Now the route is
re-read (peel_route host_room=0): L3_DROP -> _l3_drop_leaf, UD_DROP -> as before.
No switch, no reserve, no threshold.

Tests: test_weg2_room_vote_one_check_1011.py +3 (drain clears in-flight l3 node
-> dropped; drain sets l3_present on an un-backed node -> dropped; mutant
UD-only fallback delivers 0). The first two are red on the round-2 source
(2 failed, 24 passed) and green now. The test tree's writing_check stub gained
an on_drain hook (the real drain's effect).

pytest_gedeckelt.sh PYTEST_MEMMAX=4G, one lock:
- test_weg2_room_vote_one_check_1011.py: 26 passed, 0 failed.
- 207 vote/room/evict/hicache/spill/park/arena/w3/l3/pp + n3/golden files:
  2004 passed, 25 failed, 19 skipped (that run held 1 failure of the new test,
  a test-stub bug fixed afterwards, see above). The other 24 red: 22 red on
  base 6c53a95 in a separate run of the same files (22 failed, 197 passed);
  the 2 others (test_hicache_era_purge TestStoreRefusesTwoBlobGenerations,
  test_hicache_sharding_558 TestLegacyFindability) are 'retry() exceed maximum
  number of retries' flakes and pass on re-run on this branch. Goldens
  (test_planer_referenz_n3_1006) red identically on base, fixtures untouched.
Metal: not measured (CPU only, no boot).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants