mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-05 15:58:53 +00:00
The guard that steps the gfx11 / gfx12 / NVIDIA auto chunk ceiling down (32768 -> 16384 ->
8192) counted every extra lent cache slot as RAM held during the prompt. That is the
--resident-experts case it was written for (#2090). Without pinned experts the lent slots'
experts come from the expert arena or from file pages that are already resident or
reclaimable, and the estimate was far too high:
- RX 7900 XT (gfx1100, IQ2_XS, whole arena in RAM): a 32K-chunk plan lowered MemAvailable by
0.46 GiB against 8K chunks, while the guard counted 11.3 GiB (log of a run with
--memory-limit-mib 44000: "32768 would lend 7843 more cache slots (11297 MiB)").
- the report (RX 7900 XTX, 125B IQ3_XXS, 62 GiB host): 3.95 GiB measured, 9.4 GiB counted.
Half of the estimate stays counted without pinned experts (the worst measured ratio is 0.42),
all of it with --resident-experts; the reserve (STRATA_PREFILL_RAM_RESERVE_MIB, 3 GiB / 6 GiB)
is unchanged. With the report's numbers (7,830 MiB available) the ceiling now stays at 32768;
it stepped down to 8192 before 94e1fc4fb and to 16384 after it.
What the chunk is worth, same card, 32K prompt (31,817 tokens), 3 rounds: 8K chunks 1,648
tok/s, 16K chunks 1,946 tok/s (+18%). prefill_loan_ram_mib() is a pure function with
checks in gfx12_extra_test.