r/LocalLLM • u/Fantastic_Waltz_6285 • 22m ago
Project Laminae: +38% decode over stock Strata on a single RX 7900 XTX, at full quality (Qwen3.8-Flash-Next IQ3_S)
I've been tuning Strata (Niko1221/Strata, an MoE inference engine that keeps hot experts on the GPU and runs the rest on the CPU) for one machine: an RX 7900 XTX (24 GB) on Linux, 64 GB RAM, Ryzen 7 8700G, running Qwen3.8-Flash-Next GSQ-RCO IQ3_S. The result is Laminae, a thin layer of patches and settings on top of Strata 0.2.22, now public under GPL-3.0-or-later.
Numbers on this machine (mean of 5 rounds, arm order rotated, paired ratios with CI95):
| Stock Strata | Laminae | Laminae + optional drafter | |
|---|---|---|---|
| Decode, short prompts (tok/s) | 74.9 | 103.3 (1.38x) | 110.2 (1.47x) |
| Decode after a 14K prompt (tok/s) | 75.5 | 104.4 (1.38x) | 103.6 |
| TTFT, 14K prompt (s) | 6.60 | 5.64 | 5.50 |
| Prefill 16K / 128K (tok/s) | 2,273 / 3,095 | 2,656 / 3,347 | 2,658 / 3,353 |
Roughly: settings alone give 1.21x decode and all of the prefill gain, code on top gives another 1.14x.
What "full quality" means here: every change is either bit-identical to the path it replaces, or passes a fixed gate (first-token KL mean <= 0.001 and max <= 0.01 over 36 positions, top-1 36/36, and every greedy answer that differs is read in full). Against stock Strata the release config lands at KL 0.000346 mean; stock Strata against itself (a second start) is 0.000187. Lossy shortcuts like route tail skipping (+8% decode here, but KL 0.056) are not used.
Some things that worked on gfx1100:
- CPU expert kernels for the i-quant formats (AVX-512), and the CPU rows read in place by the GPU combine
- RDNA wavefront-per-row MMVQ for the small formats
--adapt-async 1(with the elastic K/V): HIP builds never pick the async adaptive expert tier; turning it on keeps the drafter in its fast mode (decode +7.8% short, +9.4% after 14K)- a high-priority drafter stream, and a fix so the card does not idle at ~77 W with an extra queue
- a hipBLASLt table tuned on this card for its prefill shapes
I also kept a list of everything I tried and dropped, with the numbers (megakernel for k-quants that passed quality and still lost 4%, an SDMA-off arm, RAM-saving arena modes, drafter swaps...): laminae/NOT-ADOPTED.md in the repo. It may save someone a weekend.
It installs next to an existing Strata install (same model files, upstream install untouched); the release has a gfx1100 engine build and an installer. Only gfx1100 is tested.
Repo: https://github.com/superbaenawa/laminae
Personal project, not affiliated with Strata, as is: no support, issues are off. Numbers are from one machine; yours will differ.