mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #4870] [Engine] Adaptive tier defaults cost ~10 % code decode on a 2x RTX 3090 split whose cache holds ~45 % of each card's experts #2236
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#2236
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @orochifj on GitHub (Nov 1, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/4870
Problem
On a 2-GPU layer split whose expert cache holds about half of each card's experts, the adaptive tier's defaults (every 4 rounds, 96 swaps, decay x0.7) leave single-stream decode about 10 % slower on code than
--adapt-every 2 --adapt-swaps 192 --adapt-decay 0.92. The decode hit rate on the code prompt is 84-85 % with the defaults and 92 % with the faster settings.Environment
c62d5e3a, engine 0.1.55) built from source for sm_86, with local changes: a data-parallel prompt path, an int8 IQ4 expert prompt kernel and a cap on the batch slots' context. The adaptive tier and the decode path are upstream's. Not repeated on the unmodified build.--max-context 524288 --rope-scaling yarn --rope-scale 2 --kv int8 --kv-resident 32768 --spec 4 --spec-min-p 0.5 --pcie-frac 0,"parallel": 4with--batch-mtp(the measured requests ran alone, on the solo path).slots / (layers x experts)).Reproduce
The same engine started twice per arm; each start: a 128-token warm-up, then four prompts (Chinese prose, Chinese chat, English technical, code) x 2 reps, greedy, thinking off, 1,024 output tokens; the median per prompt. Arm B adds only
--adapt-every 2 --adapt-swaps 192 --adapt-decay 0.92.Results (decode tok/s, run 1 / run 2)
decode expert cache hit rateline): A 83.8 / 84.7 / 84.0 / 84.9 %, B 92.4 / 92.3 / 92.2 / 92.4 %.STRATA_DECODE_TIMING=1, code prompt: CPU-computed experts per layer-window 5.19 (A) vs 2.58 (B), 22.0 vs 19.8 ms a window.Note
The sergqwer/strata-nvfp4 fork applies 2 / 192 / x0.92 by default when the cache holds 20-60 % of the experts (its
generate.cpp, after the expert cache is sized; its comment cites an RTX 5090 with an NVFP4 pack holding 34 %: 19.9 -> 17.8 ms a round). The B arm above is that rule applied by hand. Would a coverage-based default like that be acceptable, or should it stay a documented flag combination?Reproduction status: reproduced locally (two engine starts per arm within 25 minutes, in the order A A B B, not interleaved).