Skip to content

Qwen3.8-Flash-Next on any consumer hardware: one-click install for Windows / Linux. Strata inference engine, OpenAI/Anthropic API on localhost, optional image input.

C++

Canonical Q2_0 pack: the measured PCIe share is opt-in on Windows (STRATA_PCIE_AUTO_CANON=1); RTX 5070: code +2.5%, a short answer -3.3%, 5 pairs

Niko12217695859aa13a
diff --git a/docs/DETAILS.md b/docs/DETAILS.md
index a9abde4ad..49c49d1ba 100644
--- a/docs/DETAILS.md
+++ b/docs/DETAILS.md
@@ -1650,7 +1650,7 @@ already times: the wall time of the CPU pool per missed expert. With `R` = exper
`L / (L + 1.85 R)`, rounded to 0.05 and kept between 0.10 and 0.60; it is changed at most three times (after 48, 96 and 96 more windows, about 10 s of
decoding), and only by a full step. Each change prints one `PCIe share:` line. A request that sets its own `pcie_frac` is left alone.
**`--pcie-frac N` always wins; `STRATA_PCIE_FRAC_DEFAULT=old` keeps the 0.1.41 rule.** Not used with a layer split, `--batch`, a peer GPU, when every
-expert is in VRAM, or on SYCL or on HIP other than gfx1200 / gfx1201 (RDNA4, where the measured share is the default since 0.1.43; `STRATA_PCIE_FRAC_DEFAULT=old` opts out). The constant 1.85 is a fit to three machines, so it lands within a step of each machine's best, not on it. On HIP, `STRATA_PCIE_AUTO_SPLIT=1` (opt-in, 0.1.43) also refines a two-stage layer split: the pool speed is read once and each stage takes the share its own probed link gives (2x R9700 at 16 GB-eq, tail skip on: Q2_0 story +4.5%, code +9.9%, 4K +8.8%; IQ3_S story -2.1%, code +8.0%, 4K +23.3%; with three or more stages the pipelined loop does not run it).
+expert is in VRAM, or on SYCL or on HIP other than gfx1200 / gfx1201 (RDNA4, where the measured share is the default since 0.1.43; `STRATA_PCIE_FRAC_DEFAULT=old` opts out). The canonical Q2_0 pack uses it on CUDA since 0.1.43, on Linux by default and on Windows with `STRATA_PCIE_AUTO_CANON=1` (an RTX 5070 there: code +2.5%, a short answer -3.3%). The constant 1.85 is a fit to three machines, so it lands within a step of each machine's best, not on it. On HIP, `STRATA_PCIE_AUTO_SPLIT=1` (opt-in, 0.1.43) also refines a two-stage layer split: the pool speed is read once and each stage takes the share its own probed link gives (2x R9700 at 16 GB-eq, tail skip on: Q2_0 story +4.5%, code +9.9%, 4K +8.8%; IQ3_S story -2.1%, code +8.0%, 4K +23.3%; with three or more stages the pipelined loop does not run it).
Measured (interleaved pairs of whole engine runs, new default against `STRATA_PCIE_FRAC_DEFAULT=old`, medians, route tail skip on):
diff --git a/src/program/generate.cpp b/src/program/generate.cpp
index dfad1173f..4aa057db1 100644
--- a/src/program/generate.cpp
+++ b/src/program/generate.cpp
@@ -2738,7 +2738,11 @@ int main(int argc, char** argv) {
std::string bursts;
const char* pfd = std::getenv("STRATA_PCIE_FRAC_DEFAULT");
const bool pf_old = pfd != nullptr && std::strcmp(pfd, "old") == 0;
-#if !defined(STRATA_USE_HIP)
+#if !defined(STRATA_USE_HIP) && defined(_WIN32)
+ // Windows: opt-in (STRATA_PCIE_AUTO_CANON=1); an RTX 5070 decoded a short Q2_0 answer 3% slower with it, code 2.5% faster
+ const char* pac = std::getenv("STRATA_PCIE_AUTO_CANON");
+ const bool pf_old_canon = pf_old || !(pac != nullptr && pac[0] == '1');
+#elif !defined(STRATA_USE_HIP)
const bool pf_old_canon = pf_old;
#else
const bool pf_old_canon = true; // the canonical pack's PcieAuto is CUDA only