mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #3518] [Engine] the host-aware prompt plan picks smaller chunks that make 16K-32K prompts 7-67% slower (RX 9070 XT, Windows, Coder) #1445
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#1445
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 @facundopanizza on GitHub (Oct 20, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/3518
Area
[Engine]
Desktop app, Terminal or source?
Source (START-HERE.bat, setup.sh or a build)
What happened
With
--prefill auto, the host-aware prompt plan (#2824,include/strata/program/prefill_plan.hpp) changed the chunk for long prompts on this PC on every start where it engaged (to 1024, 3072 or 4096 tokens), and each time long prompts read slower than with the chunk it replaced (6144). It predicted a faster prompt each time. Short prompts and decode were unchanged.A/B in one boot, alternating starts, the same config and binary; only
STRATA_PREFILL_HOST_PLANdiffers (unset = on,0= off).tools/strata_bench.py --long, 3 fresh prompts per length, medians, prompt tok/s from the engine's timings:An earlier start the same evening (plan on) chose 1024 with a 16-slot ring: 16K 429 tok/s (37.5 s), 32K 685 tok/s (46.8 s), against 1,314 and 1,398 tok/s in the start before it, which kept 6144 (that pair is not a controlled A/B: the two starts had 3,263 vs 3,118 GPU cache slots and 14.25 vs 15.43 GiB of RAM copy).
The two "off" starts agree within 1% on the long prompts, so the differences above are not run-to-run noise.
What the plan predicted for a 32,768-token prompt, against what was measured (32K first token):
Expected: the plan keeps 6144 when it is faster, as its "near-ties keep the established behaviour" rule intends.
Unconfirmed static analysis (read, not tested): on Windows
drive_read_gbps()(src/program/generate.cpp:1356-1370) has no measurement and returns 1.5 GB/s ("drive 1.50 GB/s (assumed)" in every plan line here); the model files are on a PCIe 4.0 NVMe (Kingston NV3). The baseline's predicted time (38-51 s) is well above the measured 23-25 s, which is what a drive-cost overestimate would do. I did not testSTRATA_SSD_GBPS, and the page-cache figure (3.5 GiB available) may also be under what Windows actually keeps.Workaround in use:
"STRATA_PREFILL_HOST_PLAN": "0"in the config's"env"; after it the engine printsprompt chunk auto: 6144 tokens, a 96-slot ringand no plan line.Smallest steps or command that reproduce it
--prefill auto,--resident-experts, the low-RAM mode).python tools/strata_bench.py --config strata-coder-iq1_m.json --url http://127.0.0.1:8080 --longagainst a running server; the self-start path fails, #3235).STRATA_PREFILL_HOST_PLAN=0and repeat. Whether the plan engages depends on the free RAM at start (it did on every plan-on start here).Reproduction status
Reproduced locally
Strata version
Commit
e88ee39d(0.2.0-beta + 12) · engine 0.1.45.3, built on this PC withtools\hip\build_windows.bat(gfx1201 only, ROCm 10.2.0a20260930)Graphics card, memory and system
RX 9070 XT 16 GB (gfx1201, HIP device 1; device 0 is the integrated Radeon) · Ryzen 9 9950X · 31.1 GiB RAM (2x16 GB DDR5 at 5600, EXPO on) · Kingston NV3 2 TB NVMe · Windows 11 (10.0.26300), AMD driver 32.0.31041.1004
Model, size and settings
Coder IQ1_M · 65,536 context · KV int8 ·
--prefill auto --resident-experts --spec 4 --mtp· pictures on (CPU reader) · experimental speed projection on (same in every arm)Logs
The plan lines of each start (paths removed):
Engine timings of the earlier start's long prompts:
Not tested: Linux; other cards, models or RAM sizes;
STRATA_SSD_GBPS; more than one suite per start. The machine and the first benchmark of this setup are in #3375.@Niko1221 commented on GitHub (Nov 5, 2026):
Thanks for taking the time to report this.
Strata has changed a lot since this was opened, and 0.2.11 is out now, so many older reports no longer apply. We're closing issues older than a week that have had no new reports in the last week. Closed here does not mean rejected.
To reopen it takes about two minutes:
/reopen. A check runs and either reopens the issue or lists what is still missing.The rules are in CONTRIBUTING.md.