[GH-ISSUE #246] # Issue draft — Project Maya (Maya-S-v2 IQ2_XXS, single RTX 5090D 24 GB): full 1M-context measurements, the long-context decode bottleneck, and a v1.1.11 → v1.1.15 retest #92

Closed
opened 2026-10-29 21:20:42 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @biurquezjoselina-design on GitHub (Oct 17, 2026).
Original GitHub issue: https://github.com/mw00/project-maya/issues/246

Hardware: one RTX 5090D v2 (24 GB) + i7-14700KF + 128 GB DDR5, Windows 10.
Model: GLM-5.3-Flash Maya-S-v2 IQ2_XXS (96.5 GB, 3 shards), engine path strata.exe, context 1,048,576.
Method: needle_1m.py (staged needle test, unique filler per stage so no prompt-cache reuse, 3 needles at 15/50/85 % depth), engine /metrics numbers. Short-conversation numbers from speedtest_temp.py.
All runs on one GPU, no drafter (single-GPU setup runs the MTP drafter on the same card; drafting is disabled there).

1. Full 1M ladder (v1.1.11, 2026-10-15)

Config opened --context 1048576 directly (the setup menu only offers up to 128K; passing 1M on the command line is accepted and works). 1,039,819 tokens ingested without overflow or a crash.

Actual context (tok) prefill read (tok/s) decode write (tok/s) needles notes
76K ~1120* 6.9 3/3 *wall-clock estimate (metrics poll missed)
130K 1756 7.7 3/3
151K 2163 6.3 3/3
260K 2246 7.5 3/3
303K 2058 8.0 3/3
522K 2066 7.7 3/3
612K 1711 7.7 3/3 wall 8.3 min
1040K 1801 9.2 3/3 wall 12.6 min (read+think+write)

Findings:

  1. 1M truly works. KV streams from RAM (fp16, ~20 GB), only the window sits in VRAM; expert pool shrinks to ~11 GB to make room.
  2. Prefill stays at 1700-2250 tok/s from 151K through 1M — a gentle decline, no quadratic collapse. Long-document ingestion is healthy (610K tokens ≈ 8 min).
  3. Decode after a long ingest is 6.3-9.2 tok/s, vs 27-29 tok/s for a 32K short conversation (32K-sized config). At full context the answer is written at 6-9 chars/s — below the ~25-30 chars/s cloud-feel line. "Reads fast, writes slow" is this engine's shape on a single 24 GB card.
  4. Zero recall errors: 24/24 needles, including at 1.04M-token depth.

2. int8 KV + 256K resident window — the bottleneck is NOT KV transfer

Config: STRATA_GLM_KV_INT8=1, STRATA_GLM_KV_RESIDENT=262144 (262,144-token window resident in VRAM, 3.06 GB; expert pool 11 → 10 GB; total VRAM 22.3 GB, unchanged).

prefill decode needles
fp16 KV, streaming 2246 tok/s (260K stage) 7.5 tok/s 3/3
int8 KV + 256K resident 2365 tok/s (+5 %) 7.2 tok/s (unchanged) 3/3

With the entire 260K working set resident in VRAM as int8, decode did not move. That rules out KV transfer as the bottleneck: the per-token cost is the indexer/attention scan over the full history, and that kernel runs on ordinary CUDA cores, not tensor cores. All long-context decode numbers (6.3-9.2) correlate with expert hit-rate, not with context length or KV format. int8 KV was kept (free 3 GB, +5 % prefill, no quality loss observed); user-side knobs for decode speed are exhausted after this.

3. Retest on v1.1.15 (2026-10-17): unchanged

Same config (maya-maya-s-v2-iq2_xxs.json, 1M context, int8 KV + 256K resident), cold process, engine rebuilt from the v1.1.15 tag (VERSION verified).

test v1.1.11 v1.1.15 verdict
130K needle, decode 5.8 tok/s (warm) 5.9 / 6.1 tok/s (two rounds, different seeds) unchanged
130K needle, prefill 2224 tok/s (warm) 2202 tok/s (warm; cold-cache round 1 was 1287) unchanged
128K@b second round 1.0 tok/s (that run hit memory pressure) 6.1 tok/s stable this time
32K short conversation (1M-sized config, cold) 12-16 tok/s 12.0 / 16.5 tok/s unchanged
needles 3/3 3/3 ×2 all hit

Conclusion: nothing between v1.1.12 and v1.1.15 touched the long-context decode path — every number reproduces within noise. The single-digit decode at full context is still the non-tensor-core indexer scan identified in §2.

4. Why I'm posting this

The README performance tables have no data for the combination this card forces: a single 24 GB GPU with the full 1M context enabled (expert pool + resident KV window + streamed weights). These measurements fill that gap:

  • 1M context works on 24 GB with IQ2_XXS once the config is passed explicitly;
  • prefill is healthy end-to-end (1700-2250 tok/s up to 1M);
  • decode at full context is bounded by the indexer kernel, at 6-9 tok/s regardless of context length, KV format, or window residency — so the fix belongs upstream (indexer on tensor cores, or a draft path wired for GLM), not in user tuning.

Happy to run any specific config or measurement that would help — the harness (needle_1m.py, speedtest_temp.py) is already set up on this machine.

Originally created by @biurquezjoselina-design on GitHub (Oct 17, 2026). Original GitHub issue: https://github.com/mw00/project-maya/issues/246 > Hardware: one RTX 5090D v2 (24 GB) + i7-14700KF + 128 GB DDR5, Windows 10. > Model: GLM-5.3-Flash Maya-S-v2 IQ2_XXS (96.5 GB, 3 shards), engine path `strata.exe`, context 1,048,576. > Method: `needle_1m.py` (staged needle test, unique filler per stage so no prompt-cache reuse, 3 needles at 15/50/85 % depth), engine `/metrics` numbers. Short-conversation numbers from `speedtest_temp.py`. > All runs on one GPU, no drafter (single-GPU setup runs the MTP drafter on the same card; drafting is disabled there). ## 1. Full 1M ladder (v1.1.11, 2026-10-15) Config opened `--context 1048576` directly (the setup menu only offers up to 128K; passing 1M on the command line is accepted and works). 1,039,819 tokens ingested without overflow or a crash. | Actual context (tok) | prefill read (tok/s) | decode write (tok/s) | needles | notes | |---|---|---|---|---| | 76K | ~1120* | 6.9 | 3/3 | *wall-clock estimate (metrics poll missed) | | 130K | 1756 | 7.7 | 3/3 | | | 151K | 2163 | 6.3 | 3/3 | | | 260K | 2246 | 7.5 | 3/3 | | | 303K | 2058 | 8.0 | 3/3 | | | 522K | 2066 | 7.7 | 3/3 | | | 612K | 1711 | 7.7 | 3/3 | wall 8.3 min | | **1040K** | **1801** | **9.2** | **3/3** | **wall 12.6 min (read+think+write)** | Findings: 1. **1M truly works.** KV streams from RAM (fp16, ~20 GB), only the window sits in VRAM; expert pool shrinks to ~11 GB to make room. 2. **Prefill stays at 1700-2250 tok/s from 151K through 1M** — a gentle decline, no quadratic collapse. Long-document ingestion is healthy (610K tokens ≈ 8 min). 3. **Decode after a long ingest is 6.3-9.2 tok/s**, vs 27-29 tok/s for a 32K short conversation (32K-sized config). At full context the answer is written at 6-9 chars/s — below the ~25-30 chars/s cloud-feel line. "Reads fast, writes slow" is this engine's shape on a single 24 GB card. 4. **Zero recall errors: 24/24 needles**, including at 1.04M-token depth. ## 2. int8 KV + 256K resident window — the bottleneck is NOT KV transfer Config: `STRATA_GLM_KV_INT8=1`, `STRATA_GLM_KV_RESIDENT=262144` (262,144-token window resident in VRAM, 3.06 GB; expert pool 11 → 10 GB; total VRAM 22.3 GB, unchanged). | | prefill | decode | needles | |---|---|---|---| | fp16 KV, streaming | 2246 tok/s (260K stage) | 7.5 tok/s | 3/3 | | int8 KV + 256K resident | 2365 tok/s (+5 %) | 7.2 tok/s (unchanged) | 3/3 | With the entire 260K working set resident in VRAM as int8, decode did not move. That rules out KV transfer as the bottleneck: **the per-token cost is the indexer/attention scan over the full history, and that kernel runs on ordinary CUDA cores, not tensor cores.** All long-context decode numbers (6.3-9.2) correlate with expert hit-rate, not with context length or KV format. int8 KV was kept (free 3 GB, +5 % prefill, no quality loss observed); user-side knobs for decode speed are exhausted after this. ## 3. Retest on v1.1.15 (2026-10-17): unchanged Same config (`maya-maya-s-v2-iq2_xxs.json`, 1M context, int8 KV + 256K resident), cold process, engine rebuilt from the v1.1.15 tag (VERSION verified). | test | v1.1.11 | v1.1.15 | verdict | |---|---|---|---| | 130K needle, decode | 5.8 tok/s (warm) | 5.9 / 6.1 tok/s (two rounds, different seeds) | unchanged | | 130K needle, prefill | 2224 tok/s (warm) | 2202 tok/s (warm; cold-cache round 1 was 1287) | unchanged | | 128K@b second round | 1.0 tok/s (that run hit memory pressure) | 6.1 tok/s | stable this time | | 32K short conversation (1M-sized config, cold) | 12-16 tok/s | 12.0 / 16.5 tok/s | unchanged | | needles | 3/3 | 3/3 ×2 | all hit | Conclusion: **nothing between v1.1.12 and v1.1.15 touched the long-context decode path** — every number reproduces within noise. The single-digit decode at full context is still the non-tensor-core indexer scan identified in §2. ## 4. Why I'm posting this The README performance tables have no data for the combination this card forces: **a single 24 GB GPU with the full 1M context enabled** (expert pool + resident KV window + streamed weights). These measurements fill that gap: - 1M context works on 24 GB with IQ2_XXS once the config is passed explicitly; - prefill is healthy end-to-end (1700-2250 tok/s up to 1M); - decode at full context is bounded by the indexer kernel, at 6-9 tok/s regardless of context length, KV format, or window residency — so the fix belongs upstream (indexer on tensor cores, or a draft path wired for GLM), not in user tuning. Happy to run any specific config or measurement that would help — the harness (`needle_1m.py`, `speedtest_temp.py`) is already set up on this machine.
Author
Owner

@mw00 commented on GitHub (Oct 20, 2026):

Thank you for the 1M-context measurements - the needle results across the whole range are very useful. Decode after a very long prompt on one 24 GB card is limited by how much of the model fits beside the KV window; closing this report, and the findings stay here for reference.

<!-- gh-comment-id:6295603848 --> @mw00 commented on GitHub (Oct 20, 2026): Thank you for the 1M-context measurements - the needle results across the whole range are very useful. Decode after a very long prompt on one 24 GB card is limited by how much of the model fits beside the KV window; closing this report, and the findings stay here for reference.
Sign in to join this conversation.
No labels
pull-request
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
mw00/project-maya#92
No description provided.