[GH-ISSUE #3858] [Engine] Unlocked RTX 3090 tensor rate (+77%) buys +12.9%/+8.0%/+1.5% prefill and zero decode — where is the headroom left? #1645

Closed
opened 2026-11-04 01:52:52 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @flamesugar on GitHub (Oct 23, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/3858

Setup

  • GPU: RTX 3090 24 GB (GA102, sm_86), 300 W power cap (deliberate, cooling-limited), PCIe Gen3 x16
  • CPU: Xeon E5-2667 v4, 8 cores / 16 threads, 125 GiB DDR4
  • OS: Arch Linux, driver 610.57.04
  • Strata: project 0.1.44.1, commit b4c78ac3, engine 0.1.44.1
  • Models: Qwen3.8-Flash-Next — IQ2_XS (512K ctx), IQ3_S (256K), UD-IQ4_XS (256K)

What I did

I unlocked the card's BF16/FP16 tensor rate with Zagitta/gpu-unlock (V67 firmware, runs in initramfs before nvidia binds, per power cycle). Verified in the kernel log: pci 0000:02:00.0: gpu_unlock: unlocked.

Measured with torch matmul, N=4096, 3 warmup + 20 iterations, same power cap before and after:

precision before after gain
FP16 60.38 107.34 +77.8%
BF16 62.66 110.72 +76.7%
TF32 31.37 54.51 +73.8%
FP32 21.52 22.08 +2.6%

FP32 is unchanged, so only the tensor path moved — as expected. Peak draw during the runs was 263–275 W, i.e. still under the 300 W cap.

What the engine gets out of it

Same protocol before and after (bench_ctx.py, same temperature per tier, reps=3, 256 output tokens, unique nonce per rep so no prefix-cache hit), permutation test on median difference (10k shuffles):

Prefill gain by context

ctx IQ2_XS IQ3_S UD-IQ4_XS
16K +14.9% (p=0.015) +9.2% (p=0.15) −1.3% (p=1.0)
32K +13.6% (p=0.009) +6.3% (p=0.15) +1.1% (p=0.20)
64K +11.3% (p=0.023) +8.6% (p=0.20) +1.4% (p=0.20)
227K +12.0% (p=0.035) +8.1% (p=0.023) +3.6% (p=0.20)

Decode: no significant change in any tier at any context (all p > 0.15, signs mixed).

So a 77% tensor-rate gain buys +12.9% prefill on the lightest quant, +8.0% on IQ3_S and +1.5% on IQ4_XS, and nothing at all in decode. The gain shrinks as the quant gets heavier, which fits the explanation that heavier quant = more CPU expert work per token = the GPU's share of the step is smaller.

The question

Decode looks bound by the CPU expert pool / RAM bandwidth rather than by tensor throughput (docs/QUANTS.md:126 — "One token per expert (most of decode) is at the RAM bound"), so more GPU FLOPS buys nothing there. That matches our numbers: expert cache is 8270 slots / 16,060 MiB, hit rate 68.8%, pool_workers 7.

What levers exist to convert the now-available GPU compute into decode throughput?

Specifically:

  1. Is there any decode path where faster BF16 matmul helps at all — e.g. a larger --spec value, so the per-step verify is a bigger batched GEMM and the CPU expert pass is amortised over more tokens? Currently --spec 4 --spec-min-p 0.70. Is there a measured optimum for a fast-tensor-core / slow-CPU combination, and does the balance shift once the tensor rate doubles?
  2. When an expert misses the VRAM cache, its rows are computed on the CPU pool. Is there a mode that computes misses on the GPU instead (streaming the weights over PCIe into a scratch buffer) — and would that be worth it now that GPU FLOP/W is ~1.8× better?
  3. Anything in 0.1.47 / 0.2.x that changes this picture? I'm on 0.1.44.1.

What I already ruled out

  • --expert-cache N (explicit value) is not a cap — the fill overshoots it (matches #3693), so I could not run a fixed-slot A/B.
  • --expert-cache-per-layer: hit rate 68.80% → 68.81%, slots 8270 → 8112, prefill −0.4…−0.7%. No gain at this budget (only ~138 slots/layer).
  • Raising the power limit 300 → 350 W is not an option: the 300 W cap is deliberate.
  • VRAM is full (16 GB of the 24 GB is expert cache), so "put more experts in VRAM" has no room.

Full numbers and the analysis script: I can paste the results.json / engine log excerpt if useful.

Originally created by @flamesugar on GitHub (Oct 23, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/3858 ### Setup - **GPU:** RTX 3090 24 GB (GA102, sm_86), 300 W power cap (deliberate, cooling-limited), PCIe Gen3 x16 - **CPU:** Xeon E5-2667 v4, 8 cores / 16 threads, 125 GiB DDR4 - **OS:** Arch Linux, driver 610.57.04 - **Strata:** project 0.1.44.1, commit b4c78ac3, engine 0.1.44.1 - **Models:** Qwen3.8-Flash-Next — IQ2_XS (512K ctx), IQ3_S (256K), UD-IQ4_XS (256K) ### What I did I unlocked the card's BF16/FP16 tensor rate with `Zagitta/gpu-unlock` (V67 firmware, runs in initramfs before `nvidia` binds, per power cycle). Verified in the kernel log: `pci 0000:02:00.0: gpu_unlock: unlocked`. Measured with torch matmul, N=4096, 3 warmup + 20 iterations, same power cap before and after: | precision | before | after | gain | |---|---:|---:|---:| | FP16 | 60.38 | 107.34 | **+77.8%** | | BF16 | 62.66 | 110.72 | **+76.7%** | | TF32 | 31.37 | 54.51 | **+73.8%** | | FP32 | 21.52 | 22.08 | +2.6% | FP32 is unchanged, so only the tensor path moved — as expected. Peak draw during the runs was 263–275 W, i.e. still under the 300 W cap. ### What the engine gets out of it Same protocol before and after (`bench_ctx.py`, same temperature per tier, reps=3, 256 output tokens, unique nonce per rep so no prefix-cache hit), permutation test on median difference (10k shuffles): **Prefill gain by context** | ctx | IQ2_XS | IQ3_S | UD-IQ4_XS | |---|---:|---:|---:| | 16K | **+14.9%** (p=0.015) | +9.2% (p=0.15) | −1.3% (p=1.0) | | 32K | **+13.6%** (p=0.009) | +6.3% (p=0.15) | +1.1% (p=0.20) | | 64K | **+11.3%** (p=0.023) | +8.6% (p=0.20) | +1.4% (p=0.20) | | 227K | **+12.0%** (p=0.035) | **+8.1%** (p=0.023) | +3.6% (p=0.20) | **Decode:** no significant change in any tier at any context (all p > 0.15, signs mixed). So a 77% tensor-rate gain buys **+12.9% prefill on the lightest quant, +8.0% on IQ3_S and +1.5% on IQ4_XS**, and nothing at all in decode. The gain shrinks as the quant gets heavier, which fits the explanation that heavier quant = more CPU expert work per token = the GPU's share of the step is smaller. ### The question Decode looks bound by the CPU expert pool / RAM bandwidth rather than by tensor throughput (`docs/QUANTS.md:126` — "One token per expert (most of decode) is at the RAM bound"), so more GPU FLOPS buys nothing there. That matches our numbers: expert cache is 8270 slots / 16,060 MiB, hit rate 68.8%, `pool_workers 7`. **What levers exist to convert the now-available GPU compute into decode throughput?** Specifically: 1. Is there any decode path where faster BF16 matmul helps at all — e.g. a larger `--spec` value, so the per-step verify is a bigger batched GEMM and the CPU expert pass is amortised over more tokens? Currently `--spec 4 --spec-min-p 0.70`. Is there a measured optimum for a fast-tensor-core / slow-CPU combination, and does the balance shift once the tensor rate doubles? 2. When an expert misses the VRAM cache, its rows are computed on the CPU pool. Is there a mode that computes misses on the GPU instead (streaming the weights over PCIe into a scratch buffer) — and would that be worth it now that GPU FLOP/W is ~1.8× better? 3. Anything in 0.1.47 / 0.2.x that changes this picture? I'm on 0.1.44.1. ### What I already ruled out - `--expert-cache N` (explicit value) is not a cap — the fill overshoots it (matches #3693), so I could not run a fixed-slot A/B. - `--expert-cache-per-layer`: hit rate 68.80% → 68.81%, slots 8270 → 8112, prefill −0.4…−0.7%. No gain at this budget (only ~138 slots/layer). - Raising the power limit 300 → 350 W is not an option: the 300 W cap is deliberate. - VRAM is full (16 GB of the 24 GB is expert cache), so "put more experts in VRAM" has no room. Full numbers and the analysis script: I can paste the `results.json` / engine log excerpt if useful.
Author
Owner

@Niko1221 commented on GitHub (Oct 26, 2026):

Thank you for the clean before and after numbers. Decode on a card with a large expert tail is limited by the CPU expert pass and RAM bandwidth, so more tensor rate mainly helps prefill. A larger --spec is the most direct lever for the CPU pass, but the result depends on the hardware, so we do not change the default. If decode still does not move on 0.2.6 or later, you are welcome to reopen this with your numbers.

<!-- gh-comment-id:6424529477 --> @Niko1221 commented on GitHub (Oct 26, 2026): Thank you for the clean before and after numbers. Decode on a card with a large expert tail is limited by the CPU expert pass and RAM bandwidth, so more tensor rate mainly helps prefill. A larger --spec is the most direct lever for the CPU pass, but the result depends on the hardware, so we do not change the default. If decode still does not move on 0.2.6 or later, you are welcome to reopen this with your numbers.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#1645
No description provided.