[PR #441] [CLOSED] Contrib/non mtp serving #2640

Closed
opened 2026-11-04 02:01:59 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Niko1221/Strata/pull/441
Author: @CC-David-CC
Created: 10/2/2026
Status: ❌ Closed

Base: main ← Head: contrib/non-mtp-serving


📝 Commits (9)

  • bf0fe5f serve: allow non-MTP decoding and omit unavailable PCIe expert paths
  • 373510f docs: record serving-only CUDA identity and non-MTP checks
  • df24e08 test: respect engine cleanup lifecycle in identity comparison
  • 03eee96 test: add reproducible long-context MTP mode comparisons
  • 66e1faf test: tidy benchmark harness formatting
  • 8964927 test: cover request-level PCIe fraction changes
  • 4f0f97c docs: record completed fleet validation for non-MTP serving
  • 12fa219 docs: record 0.1.34 rebase and targeted regression checks
  • 03ab00c docs: clarify branch selection, activation and public evidence

📊 Changes

11 files changed (+17902 additions, -41 deletions)

View changed files

📝 README.md (+9 -0)
➕ docs/NON_MTP_SERVING_REVIEW.md (+204 -0)
➕ docs/benchmarks/2026-10-01-serving.json (+15889 -0)
➕ docs/benchmarks/2026-10-01-serving.md (+145 -0)
➕ docs/benchmarks/2026-10-02-upstream-sync-serving.json (+1303 -0)
➕ docs/benchmarks/2026-10-02-upstream-sync-serving.md (+51 -0)
📝 include/strata/core/verify.hpp (+5 -1)
📝 src/core/verify.cpp (+16 -10)
📝 src/program/generate.cpp (+45 -17)
➕ tools/bench_mtp_modes.py (+207 -0)
📝 tools/conversation_cache_disabled.py (+28 -13)

📄 Description

Updated to upstream 0.1.34 (1678de3). Fresh targeted builds and regressions passed; the full fleet/context performance numbers below remain measurements of the prior 0.1.33 source.

Rebase checks

This is the shared serving split requested in #323 and #336, based on
upstream 0.1.34 (1678de3). Hardware support and optional performance kernels
have separate branches.

Changes

  • Allow --serve without an MTP drafter. Guard draft binding, prefill, restore,
    sampling and generation; use one-token verification windows.
  • Preserve live-prefix reuse. Cross-conversation snapshots still require draft
    state, so use --conversation-cache-mib 0 without MTP.
  • Omit PCIe graph stages only when the expert source has no GPU-visible aliases.
    A request's pcie_frac=0 does not remove a path that later requests may need.
  • Separate prompt-tail and decode profiling samples.
  • Update the existing identity checker and add a reproducible throughput harness.

Why it helps

On the RX 5500 XT, an 8K-input short code request produced the same 125 output
token IDs
in both modes. Non-MTP completed in 96.44 s, versus 111.47 s
with MTP: 13.48% less total time. Prefill was 85.69 versus 103.41 s.
Generation alone was slower (11.63 versus 15.52 tok/s).

MTP remains better for the measured long RTX PRO and RTX 4090 completions.
For example, RTX PRO 64K code produced identical 2213-token outputs at
104.79 / 222.72 tok/s without/with MTP, taking 30.80 / 19.56 s total.
The report retains the slower cases and actual output lengths.

Validation

  • Six GPU types: RTX 4090, RTX PRO 6000 Blackwell, RTX 3070, one Tesla P4,
    RX 7900 XTX, and consumer RX 5500 XT 8GB.
  • Long code/prose at 8K, 32K and 64K input, both modes, up to 4096 output.
  • Eight identity/replay gates: CUDA, HIP 7, pageable HIP 5.7/7, non-MTP
    independent-instance replay, and request-level PCIe fraction switching.
    Each gate uses eight requests per arm, state/output hashes, known answers
    and live-prefix reuse. The upstream comparison uses MTP; non-MTP replay is
    identified separately because upstream cannot serve that mode.
  • RTX 4090 starts at pcie_frac=0 then alternates 0/0.55. Enabled requests
    actually perform PCIe work; upstream and candidate tokens/state match.
  • The initial RTX 3070 64K MTP-on allocation failed. The retained retry with
    --vram-reserve-mib 1148 passed both tasks/modes.
  • RTX 3070 non-MTP full-input test: 131072 input / 2288
    output
    , 25.28 generation tok/s, 362.25 s prefill,
    452.80 s total; 136192 allocated context with Q8 KV streaming.
  • The separate MTP-on 128K natural-stop request completed at 3893 output tokens;
    only its exact-length assertion failed. A capacity-only retry with EOS stopping
    suppressed completed all 4096 output tokens. These results remain distinct.

The RX 5500 XT tests use the documented combination of this branch and the
hardware contribution. Those source trees and reproduction commands are explicit.

Scope and reproduction
| Full measurements and retained failures
| Machine-readable evidence

GSQ-RCO IQ3_S, Q8 KV, greedy text only. Throughput uses MTP4/threshold0.5;
identity gates use threshold0. Startup is excluded, the OS file cache is not
reset, and outputs may differ. Functional checks are bounded and do not measure
general model quality. The maintainer's broader CI was not run locally.

Credit: this extends Niko1221/Strata;
model execution, expert caching and MTP are upstream work.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Niko1221/Strata/pull/441 **Author:** [@CC-David-CC](https://github.com/CC-David-CC) **Created:** 10/2/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `contrib/non-mtp-serving` --- ### 📝 Commits (9) - [`bf0fe5f`](https://github.com/Niko1221/Strata/commit/bf0fe5faca56ba5629dd3fdd112190d0168488e5) serve: allow non-MTP decoding and omit unavailable PCIe expert paths - [`373510f`](https://github.com/Niko1221/Strata/commit/373510f9a3f0cb8efd08444c2af5a7d2bcd80738) docs: record serving-only CUDA identity and non-MTP checks - [`df24e08`](https://github.com/Niko1221/Strata/commit/df24e089d75be9500e7dd09e90a072de2cc25cdc) test: respect engine cleanup lifecycle in identity comparison - [`03eee96`](https://github.com/Niko1221/Strata/commit/03eee960b03476b94993c7c2463245c63ee1968f) test: add reproducible long-context MTP mode comparisons - [`66e1faf`](https://github.com/Niko1221/Strata/commit/66e1faff2fe7d6e870ff2c3753229762a68de9b8) test: tidy benchmark harness formatting - [`8964927`](https://github.com/Niko1221/Strata/commit/896492736ed8b4b5f1b973332ba96b315d4f8a2d) test: cover request-level PCIe fraction changes - [`4f0f97c`](https://github.com/Niko1221/Strata/commit/4f0f97ccdf73e623ea0f2e7fd68fa8571990d0ed) docs: record completed fleet validation for non-MTP serving - [`12fa219`](https://github.com/Niko1221/Strata/commit/12fa2196a5a89c6feb577ce65b18b225de0c50e6) docs: record 0.1.34 rebase and targeted regression checks - [`03ab00c`](https://github.com/Niko1221/Strata/commit/03ab00c632ce8b5640239583b3ff75236e36c163) docs: clarify branch selection, activation and public evidence ### 📊 Changes **11 files changed** (+17902 additions, -41 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+9 -0) ➕ `docs/NON_MTP_SERVING_REVIEW.md` (+204 -0) ➕ `docs/benchmarks/2026-10-01-serving.json` (+15889 -0) ➕ `docs/benchmarks/2026-10-01-serving.md` (+145 -0) ➕ `docs/benchmarks/2026-10-02-upstream-sync-serving.json` (+1303 -0) ➕ `docs/benchmarks/2026-10-02-upstream-sync-serving.md` (+51 -0) 📝 `include/strata/core/verify.hpp` (+5 -1) 📝 `src/core/verify.cpp` (+16 -10) 📝 `src/program/generate.cpp` (+45 -17) ➕ `tools/bench_mtp_modes.py` (+207 -0) 📝 `tools/conversation_cache_disabled.py` (+28 -13) </details> ### 📄 Description Updated to upstream 0.1.34 (`1678de3`). Fresh targeted builds and regressions passed; the full fleet/context performance numbers below remain measurements of the prior 0.1.33 source. [Rebase checks](https://github.com/CC-David-CC/Strata-a5500/blob/contrib/non-mtp-serving/docs/benchmarks/2026-10-02-upstream-sync-serving.md) This is the shared serving split requested in #323 and #336, based on upstream 0.1.34 (`1678de3`). Hardware support and optional performance kernels have separate branches. ## Changes - Allow `--serve` without an MTP drafter. Guard draft binding, prefill, restore, sampling and generation; use one-token verification windows. - Preserve live-prefix reuse. Cross-conversation snapshots still require draft state, so use `--conversation-cache-mib 0` without MTP. - Omit PCIe graph stages only when the expert source has no GPU-visible aliases. A request's `pcie_frac=0` does not remove a path that later requests may need. - Separate prompt-tail and decode profiling samples. - Update the existing identity checker and add a reproducible throughput harness. ## Why it helps On the RX 5500 XT, an 8K-input short code request produced the **same 125 output token IDs** in both modes. Non-MTP completed in **96.44 s**, versus **111.47 s** with MTP: **13.48% less total time**. Prefill was 85.69 versus 103.41 s. Generation alone was slower (11.63 versus 15.52 tok/s). MTP remains better for the measured long RTX PRO and RTX 4090 completions. For example, RTX PRO 64K code produced identical 2213-token outputs at 104.79 / 222.72 tok/s without/with MTP, taking 30.80 / 19.56 s total. The report retains the slower cases and actual output lengths. ## Validation - Six GPU types: RTX 4090, RTX PRO 6000 Blackwell, RTX 3070, one Tesla P4, RX 7900 XTX, and consumer RX 5500 XT 8GB. - Long code/prose at 8K, 32K and 64K input, both modes, up to 4096 output. - Eight identity/replay gates: CUDA, HIP 7, pageable HIP 5.7/7, non-MTP independent-instance replay, and request-level PCIe fraction switching. Each gate uses eight requests per arm, state/output hashes, known answers and live-prefix reuse. The upstream comparison uses MTP; non-MTP replay is identified separately because upstream cannot serve that mode. - RTX 4090 starts at `pcie_frac=0` then alternates 0/0.55. Enabled requests actually perform PCIe work; upstream and candidate tokens/state match. - The initial RTX 3070 64K MTP-on allocation failed. The retained retry with `--vram-reserve-mib 1148` passed both tasks/modes. - RTX 3070 non-MTP full-input test: **131072 input / 2288 output**, 25.28 generation tok/s, 362.25 s prefill, 452.80 s total; 136192 allocated context with Q8 KV streaming. - The separate MTP-on 128K natural-stop request completed at 3893 output tokens; only its exact-length assertion failed. A capacity-only retry with EOS stopping suppressed completed all 4096 output tokens. These results remain distinct. The RX 5500 XT tests use the documented combination of this branch and the hardware contribution. Those source trees and reproduction commands are explicit. [Scope and reproduction](https://github.com/CC-David-CC/Strata-a5500/blob/contrib/non-mtp-serving/docs/NON_MTP_SERVING_REVIEW.md) | [Full measurements and retained failures](https://github.com/CC-David-CC/Strata-a5500/blob/contrib/non-mtp-serving/docs/benchmarks/2026-10-01-serving.md) | [Machine-readable evidence](https://github.com/CC-David-CC/Strata-a5500/blob/contrib/non-mtp-serving/docs/benchmarks/2026-10-01-serving.json) GSQ-RCO IQ3_S, Q8 KV, greedy text only. Throughput uses MTP4/threshold0.5; identity gates use threshold0. Startup is excluded, the OS file cache is not reset, and outputs may differ. Functional checks are bounded and do not measure general model quality. The maintainer's broader CI was not run locally. Credit: this extends [Niko1221/Strata](https://github.com/Niko1221/Strata); model execution, expert caching and MTP are upstream work. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-04 02:01:59 +07:00
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#2640
No description provided.