Maxrio9/glm-5.3-flash-maya-dflash-recipe
About
Lossless Project Maya + DFlash2 optimization recipe & benchmark receipts for GLM-5.3-Flash EXL3 4.05 bpw on RTX PRO 6000 Blackwell + Xeon (50.9 -> 131.0 tok/s code, 2.54x, 256K ctx).
Other ProjectsMeasured star growth
- in 24h
- 0
- in 7 days
- Collecting history
- in 15 days
- Collecting history
- in 1 month
- Collecting history
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
README.md
Original
GLM-5.3-Flash + DFlash2 on Project Maya — Multi-User Concurrency, Prefill & Lossless Decode (v3)
Run GLM-5.3-Flash (turboderp/GLM-5.3-Flash-exl3 @ 4.05bpw, ~152.6 GB experts) with Anbeeld DFlash2 Q4_K_M speculative decoding using our public fork of Project Maya (v1.1.86 + 72 commits at release glm53-dflash-opt-v3).
What is new in v3 (+33 commits atop v2):
- 2.49× faster multi-user concurrency (
2.78×vs Stock):60.0 (Stock) → 66.9 (v2) → 166.6 tok/saggregate atc=8(164.7default AVX-512 /166.6Intel AMX-BF16 opt-in), withc=8p95 time-to-first-token cut by 73% (4.24 s → 1.00–1.14 s). - 2.35× faster on long concurrent prompts (~1.5K words):
40.4 (Stock) → 42.0 (v2) → 98.6 tok/saggregate atc=8, cuttingc=8p95 TTFT by 59% (14.78 s → 6.05 s). - 2.08× faster short prefill & +46% faster 64K prefill:
64Kprompt ingest jumps from3,233 tok/s(15.98 sTTFT) to4,224 tok/s(12.23 s,+30.6%) strictly lossless FP32, or4,720 tok/s(10.94 s,+46.0%) with opt-in TF32/BF16 Tensor Core paths;2Kprompt ingest doubles from910 → 1,857(lossless) /1,889 tok/s(opt-in). - Zero regression on
v2single-user decode: Preservesv2's9/9exacttext_sha256greedy parity and7,258resident VRAM slots at--parallel 1.
[!WARNING] Single-System Hardware & Portability Disclaimer
All benchmarks, environment defaults, and receipts in this repository were measured on one specific Linux workstation:
- GPU: NVIDIA RTX PRO 6000 Blackwell Workstation Edition (
96 GBGDDR7,sm_120,600 W)- CPU / RAM: Intel Xeon w7-3465X (
1socket,28 cores / 56 threads, AVX-512 VBMI2 + Intel AMX-BF16),128 GB8-channel DDR5-4800 (partly RAM-offloaded experts)- OS / Stack: Linux
x86_64, NVIDIA driver580.178.04, CUDA13.1.115We do not know how these numbers scale on different hardware. Results will differ on non-Blackwell GPUs, dual-socket NUMA systems, hosts with
<128 GBRAM (MAYA_GLM_RAM_RESIDENT=0), CPUs without AVX-512 VBMI2 / AMX, PCIe Gen4, or Windows/ROCm. Note also thatconcur-amx(MAYA_EXL3_CPU_AMX=1, Sapphire/Emerald/Granite Rapids Xeon) andprefill-fast(TF32/BF16-TC) are explicit precision opt-ins rather than bit-identical FP32 defaults. See the Agent & Reproducer Technical Tail before deploying elsewhere.
Which Profile Should I Run?
Pick the profile that matches your workload via ./scripts/start.sh --profile ...:
| Use Case | Start Command | Server Config | Precision | Headline Speed |
|---|---|---|---|---|
Solo interactive coding / chat (maximum 1-user speed & 256K context) |
./scripts/start.sh --profile single --config ... |
configs/maya-config.example.json (--parallel 1) |
Bit-exact FP32 (9/9 parity vs v2) |
Matches v2 peak (7,258 VRAM slots; 256K KV streaming) |
| Multi-user / multi-agent server (2–8 concurrent streams + DFlash2) | ./scripts/start.sh --profile concur --config ... |
configs/maya-config-concur.example.json (--parallel 8) |
Lossless FP32 (AVX-512) | 164.7 tok/s @ c=8 (30.1/stream, 1.00 s p95 TTFT); 4,224 tok/s 64K prefill |
| Max concurrency on AMX Xeon (Sapphire/Emerald/Granite Rapids) | ./scripts/start.sh --profile concur-amx --cpu-lane 28 --config ... |
configs/maya-config-concur.example.json (--parallel 8) |
Opt-in Intel AMX-BF16 CPU (0.17–0.31% RMS rel vs FP32) |
166.6 tok/s @ c=8; 98.6 tok/s long c=8 (6.05 s p95 TTFT) |
| Fastest long-context ingest (heavy RAG / repo dumps) | ./scripts/start.sh --profile prefill-fast --config ... |
Either --parallel 1 or --parallel 8 |
Opt-in TF32 + BF16-TC GPU prefill | 4,720 tok/s @ 64K (10.94 s TTFT), 1,889 tok/s @ 2K |
Why is
--parallel 8atc=1(~85–88 tok/s) slower than--parallel 1?
--parallel 8reserves4.87 GBof VRAM (-415resident expert slots,7,258 → 6,843) upfront for 8 KV caches, 8 DFlash2 KV rings, and multi-slot draft/batch buffers — so even a single lone request experiences more PCIe/CPU expert misses.- Concurrency
agg_tok/sincludes prompt prefill (TTFT), whereas single-stream decode excludes it: OnC16_concur(c=1),1.60 s(17.6%) of the9.07 selapsed across 4 cold 256-token requests is prompt prefill; pure decode (stream_tok/s) is103.97 tok/s(code 112.2,edit 127.5).- Use
--parallel 1for solo sessions and--parallel 8whenever 2+ users or agents share the box.
Measured Results (v3 Concurrency & Prefill)
1. Multi-User Concurrency (--parallel 8 + DFlash2, 32K ctx)
Measured with thinking off, greedy sampling, 4.05 bpw EXL3 + DFlash2 Q4_K_M:
- Standard suite (
concur):256output tokens, mixed short prompts acrossc=1, 2, 4, 8concurrent requests. - Long-prompt suite (
concur_long): ~1.5K-word cold prompts,128output tokens acrossc=1, 2, 4, 8.
| Suite / Configuration | c=1 agg / stream |
c=2 agg |
c=4 agg |
c=8 agg |
c=8 / stream |
c=8 p95 TTFT |
Speedup vs v2 (c=8) |
|---|---|---|---|---|---|---|---|
Stock v1.1.86 + --dflash (DFlash disabled >1) |
42.81 / 39.66 | 55.16 | 55.28 | 59.97 | 8.23 | (empty chunk) | 0.90× |
v2 (c3cd5983) |
45.95 / 53.02 | 59.92 | 60.72 | 66.93 | 10.01 | 4.24 s | 1.00× |
v3 Default AVX-512 (AMX=0, C12v3 / C13v2) |
86.35 / 101.39 | 141.18 | 146.30 | 164.73 / 158.08 | 30.05 / 27.89 | 1.00 s / 1.09 s | 2.46× (2.75× Stock) |
v3 Intel AMX-BF16 opt-in (C13v2, 63495723) |
84.68 / 99.82 | 141.26 | 147.12 | 166.57 | 28.78 | 1.14 s | 2.49× (2.78× Stock) |
v3 HEAD Wave 12 (2cae96bd + cols64, C16) |
88.09 / 103.97 | 139.16 | 146.79 | 164.00 | 28.45 | 1.17 s | 2.45× (97.3% spec acc) |
Long (1.5K in): Stock v1.1.86 |
30.88 / 54.04 | 35.52 | 38.35 | 40.41 | 7.98 | 14.77 s | 0.96× |
Long (1.5K in): v2 (c3cd5983) |
32.93 / 61.00 | 38.03 | 39.35 | 42.04 | 8.58 | 14.78 s | 1.00× |
Long (1.5K in): v3 AMX (C13v2) |
58.23 / 97.12 | 84.01 | 91.09 | 98.59 | 19.36 | 6.05 s | 2.35× (−59% TTFT) |
Long (1.5K in): v3 HEAD Wave 12 (C16) |
58.39 / 95.68 | 79.62 | 88.11 | 97.44 | 19.48 | 6.07 s | 2.32× (96.0% spec acc) |
(Every v3 concurrency run recorded 0 errors and 96.0%–97.3% speculative acceptance across 2,546–4,877 verified positions. See receipt caveats for the C13v2 vs C16 column-cap note.)
2. Long-Context Prompt Prefill (2K → 64K, tok/s & 64K TTFT)
Measured across 2,048 (~1.66K tok) through 65,536 (~51.65K tok) prompt targets in 128K context:
| Configuration | 2K (tok/s) |
8K (tok/s) |
16K (tok/s) |
32K (tok/s) |
64K (tok/s) |
64K TTFT |
Gain vs v2 (2K / 64K) |
|---|---|---|---|---|---|---|---|
Stock v1.1.86 (38f1b77f) |
910.1 | 2,399.8 | 3,046.7 | 3,210.1 | 3,226.9 | 16.01 s | 1.00× / 1.00× |
v2 (c3cd5983) |
910.1 | 2,397.9 | 3,066.4 | 3,218.2 | 3,233.3 | 15.98 s | 1.00× / 1.00× |
v3 Lossless FP32 (P5a_lossless) |
1,825.3 | 3,563.1 | 3,826.4 | 4,179.6 | 4,223.6 | 12.23 s | 2.01× / +30.6% |
v3 Lossless FP32 peak short (C6b) |
1,857.5 | 3,603.6 | 3,936.0 | 4,127.2 | 4,198.6 | 12.30 s | 2.04× / +29.9% |
v3 Opt-In TF32 / BF16-TC (P5a_optin) |
1,888.9 | 3,647.3 | 4,248.2 | 4,631.0 | 4,719.9 | 10.94 s | 2.08× / +46.0% |
- Total suite stream time (
205Kprompt tokens across all runs):67,261 ms(v2) →49,117 ms(v3lossless FP32) →44,377 ms(v3opt-in TF32/BF16-TC). - Exact needle recall under lossless
v3prefill (Q5_needle_32k_64k): Recalled both34,898-token (9.70 s) and69,714-token (18.71 s) needles verbatim (receipt).
Quick Start
Requirements on Linux: NVIDIA GPU (
sm_80+; tuned/verified on Blackwellsm_120), CUDA toolkit, CMake3.24+, Ninja (recommended), C++20 compiler, Python3.10+, and sufficient GPU VRAM + system RAM (~152.6 GBEXL3 expert pool).
1. Clone recipes & build the pinned v3 Maya fork
git clone https://github.com/Maxrio9/glm-5.3-flash-maya-dflash-recipe.git
cd glm-5.3-flash-maya-dflash-recipe
# Preview build commands first:
./scripts/build-engine.sh --dry-run
# Clone Maxrio9/project-maya @ glm53-dflash-opt-v3 (2cae96bd) and build ./project-maya/build/maya:
./scripts/build-engine.sh --dir ./project-maya
(Pass --cuda-arch 120 for RTX PRO 6000 / RTX 50-series, or keep default native.)
2. Download & EXL3-pack GLM-5.3-Flash + DFlash2 (once)
cd ./project-maya
./maya.sh --setup --model glm-exl3-4.05bpw --draft dflash2 --context 262144 --download-model --yes --no-start
This creates .venv, downloads pinned turboderp/GLM-5.3-Flash-exl3 (4.05bpw) and Anbeeld/GLM-5.3-Flash-DFlash2-GGUF, SHA-256 checks them, and writes a base config JSON (or copy configs/maya-config.example.json / configs/maya-config-concur.example.json and replace <...>).
3. Launch your chosen profile
# Single-user lossless (--parallel 1, 256K ctx):
./scripts/start.sh --profile single --config /path/to/single-config.json
# Multi-user concurrency (--parallel 8 + DFlash2 + lossless prefill):
./scripts/start.sh --profile concur --config /path/to/concur-config.json
# Multi-user + Intel AMX-BF16 opt-in (Sapphire/Emerald/Granite Rapids Xeon):
./scripts/start.sh --profile concur-amx --cpu-lane 28 --config /path/to/concur-config.json
# Fastest prefill (opt-in TF32/BF16-TC):
./scripts/start.sh --profile prefill-fast --config /path/to/config.json
Pass --dry-run to inspect effective environment variables, --cpu-lane N to override CPU threads, or --no-ram-resident if your host cannot pin ~75 GB of offloaded experts in RAM.
What v3 Changed (Plain-English Summary)
Why multi-user concurrency jumped 2.49× (66.9 → 166.6 tok/s) & p95 TTFT dropped 73%:
- Multi-slot water-fill DFlash2 (
c=1..8, up to48draft rows/step): Previously,--parallel > 1disabled DFlash2 and fell back to MTP.v3keeps DFlash2 active forc=1preemption and introduces batchedmtpwverification + water-fill batching across up to8concurrent sequences (4039a2eareclaims ~1.14 GBVRAM by moving per-sequence state snapshots to pinned host RAM). - Batched + CUDA-graphed
GlmDflash::draft_batch: Replaced per-sequence draft loops and host syncs with batched Q4_K/Q6_K Tensor Core heads (mvc_mma_q6_K), batchedinject_feat_batch, and single-graph CUDA capture (2cae96bd). - Promo-first PCIe/CPU balance + wide-span CPU kernels: Enabled batched 2-pass
rows_moe_groupedoverlap (c13e7e95), fusedkda_win_multi(811a4e3a), L1d-tiledN>=4AVX-512 EXL3 (84690b50), opt-in Intel AMX-BF16 (05b38fe6), and promo-only PCIe gating (953420e5).
Why prompt prefill jumped up to 2.08× at 2K & +46% at 64K:
- Balanced CPU/PCIe prefill on short/medium prompts (
2K–8K): Calibrated CPU EXL3 cost (15a80cd9), proportional short-chunk prestage (9577fd40), andPREFILL_CPU_GATE=0eliminate PCIe stall bottlenecks on shorter prompts without losing bit-exact FP32 accuracy. - Bigger EXL3 Tensor Core tiles (
BM=64), 256 MBw16weight cache & kernel fusion: Upgraded EXL3 prefill TC kernels toBM=64+ldmatrix.x4, expandedw16on multi-sub-batch chunks (ea1b8400), and fusedx3_run_blasrot+swiglu+rot(f686c5d3). - Chunkwise WY KDA,
mma64DSA & opt-in Tensor Core paths: Added chunkwise WY KDA recurrence (8120f058, FP32 default / TF32 opt-in),score_kernelfitting in 99 KB SMEM (5f7fe73f),kda_conv_v4(09439eb7), plus opt-inTF32SGEMM,BF16_TCMLA/gates,mma64DSA, and fusedhc_update_mix.
Upstream PR Status (
mw00/project-maya): 5 of our initial 8 PRs (#1403,#1422,#1423,#1424,#1426) were merged into upstream Mayav1.1.88(credited@Maxrio9), and 10 more PRs (#1402,#1425,#1427,#1438,#1439,#1441,#1442,#1443,#1445,#1446) are open upstream while all72commits live cleanly in thisv3fork.
Agent & Reproducer Technical Tail
This section documents exact pinned commits, every environment flag, single-user regression parity, the complete 72-commit patch archive, and raw caveats for automated agents and reproducers.
Pinned Artifacts
| Component | Source | Exact Pinned Revision / SHA |
|---|---|---|
Engine fork (v3) |
Maxrio9/project-maya |
Tag glm53-dflash-opt-v3 / 2cae96bdbfb03e633f37cf4c412eec371433387c (72 commits atop mw00/project-maya v1.1.86 38f1b77fdf4230abe6cffd8d6ea2a4b59ec01dda) |
| Prior milestones | Maxrio9/project-maya |
v1: glm53-dflash-opt-v1 (96d04e27), v2: glm53-dflash-opt-v2 (c3cd5983) |
| Target model | turboderp/GLM-5.3-Flash-exl3 |
Branch 4.05bpw / 2a30229e67012798ba9f0cd832bb78abf4c363d5 |
| Speculative drafter | Anbeeld/GLM-5.3-Flash-DFlash2-GGUF |
GLM-5.3-Flash-DFlash2-Q4_K_M.gguf / f3569acb7f9cee95e66d24442d75536eb00ab842 |
Complete Environment Flag Reference
A. Base Single-User & Hardware Flags (configs/recipe.env)
| Variable | Value | Purpose | When to adjust on other hardware |
|---|---|---|---|
MAYA_GLM_DFLASH_GPU_STAGE |
1 |
Keep DFlash2 staging ring in GPU VRAM (~170 MB) | Keep 1 if VRAM fits |
MAYA_GLM_WIN_STAGGER |
0 |
Single-pass verify windows instead of 2-pass staggered dense weight reads | Keep 0 when CPU/GPU are balanced |
MAYA_EXL3_WIN_TOK |
1 |
CUDA EXL3 K2=8 win_tok=2/4 specialization |
Test 0 vs 1 on older GPUs |
MAYA_GLM_WIN_KDA_FUSED / HC_ROWS / WAIT_ROWS / MV_EXACT_COLS |
1 |
Fused KDA prep/recurrence, HC rows, wait rows, exact cols | Debugging toggles (0 disables) |
MAYA_GLM_WIN_ROUTE_FUSED / GLOBAL / EARLY_ROUTE / PARX / PARW |
1 |
2-pass window-global router + overlapped shared expert & warp-parallel passes | Core verify-window speedup |
MAYA_GLM_WIN_FETCH_OVERLAP / SMS |
1 / 16 |
Overlap async PCIe moe_fetch_win using 16 SMs |
Lower SMS on smaller GPUs or set 0 |
MAYA_GLM_WIN_PCIE_PROMO_ONLY / CAP / PROMOTE_MIN |
1 / 2 / 2 |
Reserve PCIe in single mode for promoting misses (cap=2) to spare host DDR5 |
Critical on 1-socket Xeon + PCIe Gen5; re-tune on dual-socket or Gen4 |
MAYA_GLM_WIN_CPU_MERGE / CPU_PIN / CPU_PIN_1S |
1 |
Deduplicate CPU experts per window + 1-socket physical/SMT pinning | Set CPU_PIN_1S=0 / WIN_CPU_MERGE=0 on multi-socket NUMA |
MAYA_GLM_X3_OVERSUB |
2 |
Oversubscribe CPU x3_jobs across slices (0..4) |
Set 0 if using fewer threads |
MAYA_GLM_RAM_RESIDENT |
1 |
Pin all non-VRAM experts in RAM (~75 GB on 96 GB GPU + 4.05bpw) |
Set 0 (--no-ram-resident) if host RAM <128 GB |
MAYA_GLM_CPU_LANE |
(unset) | Explicit CPU EXL3 threads (52 AVX-512 single/def, 28 AMX on 28c/56t Xeon) |
Auto-calibrated when unset |
B. Multi-User Concurrency Flags (configs/recipe-concur.env)
| Variable | Value | Notes & Defaults in 2cae96bd |
|---|---|---|
MAYA_GLM_MULTI_DFLASH |
1 |
Multi-slot batched DFlash2 (default 1 in 2cae96bd; MAX=8, CAP=48, PMIN=0.95, WATERFILL=1, BATCH=1) |
MAYA_GLM_MULTI_DFLASH_C1 / GROUP_EXPERTS / ROWS_ATTN / ROWS_BATCH / ROWS_SMALL / SKIP_EMPTY |
1 |
Hybrid c=1 DFlash + grouped concurrency batching/overlap (MAYA_GLM_ROWS_PCIE_PCT=25, CAP=8, PROMO_ONLY=1 default) |
MAYA_GLM_PREFILL_INTERLEAVE |
512:1 |
Chunk interleave under concurrent decode |
MAYA_GLM_DFLASH_BGRAPH |
(default 1) |
CUDA-graphed batched draft_batch (2cae96bd); set 0 only to debug |
MAYA_GLM_MULTI_HOST_SNAP |
(default 1) |
Host-pinned per-sequence snapshots (+1.14 GB VRAM reclaimed) |
MAYA_EXL3_CPU_AMX |
0 (default) |
Opt-in Intel AMX-BF16 CPU EXL3 kernel (=1 in --profile concur-amx, best w/ --cpu-lane 28 on 28c Xeon) |
C. Prefill Flags (configs/recipe-concur.env lossless vs configs/recipe-prefill-optin.env fast opt-in)
| Variable | Lossless (concur / FP32) |
Fast Opt-In (prefill-fast) |
Effect |
|---|---|---|---|
MAYA_GLM_PREFILL_CPU_GATE |
0 |
0 |
Enables balanced CPU/GPU offload on short chunks |
MAYA_GLM_EXL3_MMA_ROWS |
1024 |
512 |
Row threshold for Tensor Core EXL3 vs cublas/cutlass prefill |
MAYA_GLM_EXL3_MMA_ROWS_SHORT |
(unset) | 1024,4096 |
Short-chunk threshold (<=4096 prompt tokens) |
MAYA_GLM_PREFILL_SUB / CKPT_EVERY |
8192 / 32768 |
8192 / 32768 |
Mixer sub-batch size & KDA checkpoint spacing |
MAYA_GLM_PREFILL_W16_CACHE / KDA_CONV_V4 |
(default 1) |
1 / 1 |
256 MB w16 weight cache & vectorized KDA conv (FP32 safe) |
MAYA_GLM_SGEMM_TF32 / PREFILL_BF16_TC |
(default 0) |
1 / 1 |
Relaxed precision: TF32 SGEMM + BF16/FP16 TC MLA/gates |
MAYA_GLM_KDA_CHUNK |
(default 1 FP32) |
2 |
Relaxed precision: TF32 MMA chunkwise WY KDA recurrence |
MAYA_GLM_PREFILL_ATTN |
(default FP32) | mma64 |
Relaxed precision: 64-head prefetched BF16 MMA DSA attention |
MAYA_GLM_HC_FUSE |
(default 0) |
1 |
Fused hc_update_mix prefill kernel |
Single-User Regression & Parity Verification on v3 (2cae96bd)
Although v3 focused on Concurrency & Prefill rather than changing single-stream decode ceilings, we verified zero regression against v2 (c3cd5983) on final HEAD 2cae96bd:
C16_single_parityvsBV0_single(v2,--parallel 1):code 139.93,prose 99.39,structured 106.19,edit 188.76 tok/s(TTFC 0.32 / 0.32 / 0.39 / 1.70 s,7,258resident VRAM slots,23lent experts,9 / 9exacttext_sha256greedy parity,0errors; receipt).- Suite & static checks on
2cae96bd:12/12ctestpassing (4.66 s) andtools/check_hip_compat.pyclean. - (Note:
C16_single_parityabove usespc_probe.pyTTFCtiming, whereas thev2table inreceipts/BENCHMARKS.mdrecordedspeed_probe.pynumbers onv2c3cd5983— do not mix the two harnesses numerically; always compare withinBV0vsC16.)
Complete 72-Commit Patch Breakdown (v1 + v2 + v3 on v1.1.86)
Complete 72-Commit Patch Breakdown (12 from v1 + 27 from v2 + 33 from v3 atop v1.1.86)
All 72 commits sit cleanly atop mw00/project-maya v1.1.86 (38f1b77f) in Maxrio9/project-maya (glm53-dflash-opt-v3), archived as git format-patch files in patches/maya-v1.1.86/:
| # | Release | Commit | Summary | Patch File |
|---|---|---|---|---|
| 1 | v1 |
a18bdfb3 |
Base v1.1.86 + 16 verify scratch slots + 40 KDA CUDA graphs active with DFlash2 |
0001-hc-base...patch |
| 2 | v1 |
1348afac |
H2: Adaptive verify-window CPU/PCIe split (MAYA_GLM_WIN_ALLCPU_MAX_T) |
0002-hc-H2-...patch |
| 3 | v1 |
5a753978 |
H3 + H4: GPU-local DFlash2 staging ring + skip empty moe_wait/moe_fetch launches |
0003-hc-H3-...patch |
| 4 | v1 |
efb604d2 |
H6: CUDA EXL3 win_tok 2/4 specialization + configurable WIN_STAGGER_MIN_T |
0004-hc-H6-...patch |
| 5 | v1 |
32b0347b |
H7: Fused multi-token KDA prep + register-resident recurrence (MAYA_GLM_WIN_KDA_FUSED) |
0005-hc-H7-...patch |
| 6 | v1 |
097e93ba |
H12a: Batched route-first + scratch expert dedup + async moe_fetch_win |
0006-hc-H12...patch |
| 7 | v1 |
c731dce9 |
H12b: Overlap async moe_fetch_win with resident exl3::win_experts |
0007-hc-H12...patch |
| 8 | v1 |
9921fc05 |
H13: Bit-exact AVX-512 VBMI2 4-group transpose + 2-tile unpack for EXL3 K2=8 |
0008-hc-H13...patch |
| 9 | v1 |
c9acf438 |
H15: Fused multi-token moe_route_win kernel |
0009-hc-H15...patch |
| 10 | v1 |
17300eb4 |
H18: Enable win_cpu_merged verify-window deduplication on 1-socket hosts |
0010-hc-H18...patch |
| 11 | v1 |
2734ef78 |
H19 + H20: Zero-spill vnni_k8 (N=2..8) + 2-pass window-global router (PROMO_ONLY) |
0011-hc-H19...patch |
| 12 | v1 |
96d04e27 |
H23: sm_120 4 KB BlockSmem union + 40-reg 6-block occupancy for EXL3 K2=8 |
0012-hc-H23...patch |
| 13 | v2 |
4e4aa84f |
H27: Opt-in MAYA_GLM_WIN_EARLY_ROUTE hides shared expert behind Pass-1 fetch wait |
0013-hc-H27...patch |
| 14 | v2 |
6552cad6 |
H28: L2-bypass moe_fetch_win + Pass-2 max_groups + win_tok fix + EXL3 __funnelshift_r/__ldcs |
0014-hc-H28...patch |
| 15 | v2 |
d4d244b9 |
H29: AVX-512 combine_weighted + opt-in MAYA_GLM_CPU_PIN_1S |
0015-hc-H29...patch |
| 16 | v2 |
8c953dd1 |
H31: Opt-in MAYA_GLM_X3_OVERSUB ceiling cut & c-outer pre-prep order in x3_jobs |
0016-hc-H31...patch |
| 17 | v2 |
b01f59d2 |
H33b: sm_100+ block_gemv kDeferX L1 prefetch (chunk_prefetch) |
0017-hc-H33...patch |
| 18 | v2 |
cb6cb900 |
H34b: window() setup cleanup & kda_bak_cur_ backup reuse |
0018-hc-H34...patch |
| 19 | v2 |
8bddb96c |
H36: Workers cache-line isolation, batched done_, and x3_jobs inline out |
0019-hc-H36...patch |
| 20 | v2 |
32bee799 |
H37: moe_route_win O(1) dedup & opt-in MAYA_GLM_WIN_ROUTE_PARX overlapped rq->x copy |
0020-hc-H37...patch |
| 21 | v2 |
b7238f79 |
H39: Opt-in MAYA_GLM_WIN_ROUTE_PARW warp-parallel route Pass 1 & 2 + cached dev_sms |
0021-hc-H39...patch |
| 22 | v2 |
8b62736c |
H41a: Gate PARW Pass 1 to T >= 6 while keeping batched Pass 2 for all T |
0022-hc-H41...patch |
| 23 | v2 |
efcf0ff1 |
H41b: AVX-512 x3_sum_pieces_128 and parallel win_cpu_merged combine |
0023-hc-H41...patch |
| 24 | v2 |
24ba802b |
H42: Peeled N=1 fast path in vnni_k8 rows_avx512_k8 |
0024-hc-H42...patch |
| 25 | v2 |
58c27cb8 |
H43: Zero-spill kda_prep_win & win_combine and cut kda_rec_win barriers |
0025-hc-H43...patch |
| 26 | v2 |
09517536 |
H44b: Multi-warp 2-cols/warp BF16 GEMV for small-row projections | 0026-hc-H44...patch |
| 27 | v2 |
0ffe0cbc |
H45: Register-only K=6 EXL3 shuffle decode and 256-thread Split-K/SwiGLU |
0027-hc-H45...patch |
| 28 | v2 |
ad2898bf |
H48a: 1-warp/row BF16 GEMV for single-column small-row projections | 0028-hc-H48...patch |
| 29 | v2 |
9269add4 |
H48b: Peeled FirstKs fast path for N=2..8 in vnni_k8 |
0029-hc-H48...patch |
| 30 | v2 |
60096282 |
H50a: Streaming T=1 moe_fetch, ram_resident moe_wait skip, zero-spill moe_down, kda_rec barrier cut |
0030-hc-H50...patch |
| 31 | v2 |
87b878a6 |
H53a: Fuse DFlash2 draft kernels & specialize NT=1 mvc_mma_q4_K (MAYA_GLM_DFLASH_FUSED=1) |
0031-hc-H53...patch |
| 32 | v2 |
b623c463 |
H55a: 3-part CUDA graph capture for DFlash2 draft_start (MAYA_GLM_DFLASH_GRAPH=1 on CUDA) |
0032-hc-H55...patch |
| 33 | v2 |
fa3614fc |
H55b: Fuse per-token combine_weighted and publish into x3_jobs (MAYA_GLM_WIN_FUSE_COMBINE=1) |
0033-hc-H55...patch |
| 34 | v2 |
a8918263 |
H56a: 4-way split kda_rec_win (MAYA_GLM_KDA_WIN_SPLIT=1) and batched dsa_prep_win |
0034-hc-H56...patch |
| 35 | v2 |
145b1f2e |
H56b: Vectorize DFlash2 attn_split loads and __ldcs mvc_mma_q4_K |
0035-hc-H56...patch |
| 36 | v2 |
52249696 |
H57a: Overlap hc3 Sinkhorn, specialize headwise_gemv_cols, batch dsa_select_all |
0036-hc-H57...patch |
| 37 | v2 |
be707fe5 |
H57b: Wait-free fetch_add BatchSlot ring and templated Workers::run |
0037-hc-H57...patch |
| 38 | v2 |
6ef44dfd |
H59a: vpshrdd+vpshufb zero-spill vnni_k8 and X3Rows stride padding (FF+16/E+16) |
0038-hc-H59...patch |
| 39 | v2 |
c3cd5983 |
H59b: win_gu grid reorder, guarded float4/uint2 IO, and single CUDA pair_last fence |
0039-hc-H59...patch |
| 40 | v3 |
4877a19f |
exl3: upgrade prefill tc kernels to BM=64 with K2=8 reg shuffle | 0040-exl3-up...patch |
| 41 | v3 |
0a15baba |
prefill: add opt-in MAYA_GLM_SGEMM_TF32=1 for sgemm_bf16 | 0041-prefill...patch |
| 42 | v3 |
7cc7631f |
rows: batched moe_route_win + bounded 16-slot scratch in rows_moe_grouped | 0042-rows-ba...patch |
| 43 | v3 |
c13e7e95 |
rows: overlap_fetch 2-pass x3::win_experts in rows_moe_grouped | 0043-rows-ov...patch |
| 44 | v3 |
5dd5edbf |
rows: overlap shared expert gate/up/down behind Pass 1 in rows_moe_grouped | 0044-rows-ov...patch |
| 45 | v3 |
70dc9159 |
dflash: enable hybrid c=1 decode_dflash in --parallel N with safe preemption and kda_bak reuse | 0045-dflash-...patch |
| 46 | v3 |
5f7fe73f |
dsa: fit prompt DSA score_kernel in 99 KB smem via 16-pool half-stage dot tile | 0046-dsa-fit...patch |
| 47 | v3 |
8120f058 |
kda: add chunkwise WY prefill recurrence (FP32 default, opt-in TF32 MMA) | 0047-kda-add...patch |
| 48 | v3 |
aef0e319 |
hc: add opt-in fused hc_update_mix kernel (MAYA_GLM_HC_FUSE=1, default 0) | 0048-hc-add-...patch |
| 49 | v3 |
2250c2be |
dsa: add opt-in 64-head prefetched mla_attn_mma64_kernel (MAYA_GLM_PREFILL_ATTN=mma64) | 0049-dsa-add...patch |
| 50 | v3 |
0f239073 |
exl3: optimize tc::gemm_kernel and tc::gate_up_kernel (ldmatrix.x4, prefetch, fused load_a_pair, 0 stack) | 0050-exl3-op...patch |
| 51 | v3 |
f686c5d3 |
exl3/prefill: fuse x3_run_blas rot+swiglu+rot, optimize recon/inner_rows, reuse KDA Q/K in w16 | 0051-exl3-pr...patch |
| 52 | v3 |
ed55d559 |
dflash: add multi-slot batched DFlash2 verification for c=2..4 via mtpw (MAYA_GLM_MULTI_DFLASH) | 0052-dflash-...patch |
| 53 | v3 |
9577fd40 |
prefill: scale short-chunk prestage proportionally when CPU lane active (MAYA_GLM_PRESTAGE_PROP) | 0053-prefill...patch |
| 54 | v3 |
f8a2da69 |
glm rows: default balanced PCIe/CPU routing (25%, cap 8) for multi-row concurrency | 0054-glm-row...patch |
| 55 | v3 |
4039a2ea |
glm multi: allocate per-sequence state snapshots in host pinned RAM (reclaims ~1.14 GB VRAM) | 0055-glm-mul...patch |
| 56 | v3 |
d1cf96a9 |
glm dflash: async per-slot host/dyn state and single-sync batched multi-slot drafting | 0056-glm-dfl...patch |
| 57 | v3 |
84690b50 |
cpu: tile wide-span N>=4 EXL3 rows for L1d and extend AVX-512 prefetch (C5a2) | 0057-cpu-til...patch |
| 58 | v3 |
811a4e3a |
glm kda: fuse multi-sequence window KDA (kda_win_multi) + opt-in rows_prof (C6a) | 0058-glm-kda...patch |
| 59 | v3 |
15a80cd9 |
glm prefill: calibrate EXL3 CPU base and row cost for balanced CPU/PCIe split (C6b) | 0059-glm-pre...patch |
| 60 | v3 |
05b38fe6 |
exl3 cpu: add opt-in Intel AMX-BF16 K2=8 kernel (D1) | 0060-exl3-cp...patch |
| 61 | v3 |
ce5ef8f0 |
glm rows: split moe_gpu RowsProf into res, sh, fwait, and fet | 0061-glm-row...patch |
| 62 | v3 |
953420e5 |
glm rows: default MAYA_GLM_ROWS_PCIE_PROMO_ONLY=1 for promo-first CPU/PCIe balance (C7a) | 0062-glm-row...patch |
| 63 | v3 |
64de6813 |
exl3 cuda: optimize K2=12 mv_kernel (mv_kernel_k12_v2) with occupancy/smem staging (C7b) | 0063-exl3-cu...patch |
| 64 | v3 |
18528095 |
C8: 32-row grouped concurrency with multi-dflash MAX=8 CAP=32 | 0064-C8-32-r...patch |
| 65 | v3 |
ad3f4391 |
C10: batched multi-slot DFlash2 drafting via mv_wide and draft_batch | 0065-C10-bat...patch |
| 66 | v3 |
03754717 |
C10b: batched multi-slot inject_feat_batch (zero extra VRAM) | 0066-C10b-ba...patch |
| 67 | v3 |
b4c5fc56 |
glm concur(C11): extend par_w to T<=32 and gate K2=12 Tokens=32 mv kernel | 0067-glm-con...patch |
| 68 | v3 |
a6d2a67f |
glm concur(C12): water-fill multi-DFlash2, 48-row cap, win_u scratch, MaxT window templates | 0068-glm-con...patch |
| 69 | v3 |
63495723 |
glm concur(C13): trim win_alloc single-seq buffers to kWinMax (+11 VRAM slots) and add mvc_mma_q6_K for wide DFlash2 | 0069-glm-con...patch |
| 70 | v3 |
ea1b8400 |
glm prefill(P4): expand w16 to 4DIE on multi-sub-batch chunks to cache KDA/DSA/shexp EXL3 weights | 0070-glm-pre...patch |
| 71 | v3 |
09439eb7 |
glm prefill(P5a): add CUDA BF16/FP16 TC paths for MLA/gates, kda_conv_v4, and opt-in SUBPROF | 0071-glm-pre...patch |
| 72 | v3 |
2cae96bd |
glm dflash(C16a): capture batched draft_batch into single CUDA graph with device bmask_d | 0072-glm-dfl...patch |
Honest Quality, Parity & Limitations
- Single-user parity on
2cae96bd:C16_single_parityverified9/9exacttext_sha256greedy parity vsBV0_single(v2,c3cd5983) at7,258resident VRAM slots (0errors,0row-by-row fallbacks,95.6%spec acceptance).256KKV-streaming parity (8/8exact vsv1) and73,844-token needle recall were verified onv2(H59_rel_256k), and34,898- /69,714-token lossless prefill needle recall passed verbatim onv3(Q5_needle_32k_64k,70dc9159). - Commit-to-receipt provenance:
P5a_lossless(4,223.6 tok/s @ 64K),P5a_optin(4,719.9 tok/s @ 64K),C13v2_concur_amx(166.57 tok/s @ c=8), andC13v2_long_amx(98.59 tok/s @ c=8) were captured on63495723/09439eb7.C16_concur(88.09 / 139.16 / 146.79 / 164.00) andC16_concur_long(58.39 / 79.62 / 88.11 / 97.44) ran withdraft_batchCUDA graphs (2cae96bd) during thekMaxMvCols=64probe before revertingkMaxMvColsback to48(which improved/preservedMTPW_TRACEdraftsmedians inC16a_ab:88.33 / 139.30 / 148.78 / 163.33);C16_single_parity(9/9SHA-256) ran directly on final2cae96bd(C16_single_paritynote: identical weights/graphs).
- Precision opt-ins:
concur-amx(MAYA_EXL3_CPU_AMX=1): BF16 CPU activation quantization measures0.17–0.31%RMS rel diff vs FP32; verified96.6–97.3%spec acc,0errors, and32K/64Kexact needles (D1_amx_prefill).prefill-fast(SGEMM_TF32=1,PREFILL_BF16_TC=1,KDA_CHUNK=2,PREFILL_ATTN=mma64,HC_FUSE=1): TF32/BF16 Tensor Core prefill paths change FP accumulation (0errors,94.1%spec acc onP5a_optin); use--profile concur(or unset those 5 flags) when strict FP32 prompt equivalence is required.
- What was NOT tested: Multi-GPU splits, non-Blackwell GPUs (
sm_80/sm_89/sm_90),<128 GBhost RAM (MAYA_GLM_RAM_RESIDENT=0), non-VBMI2 / non-AMX CPUs,--parallel 8at full256Kcontext, AMD HIP/ROCm runtime execution (tools/check_hip_compat.pypassed statically on2cae96bd), or Windows builds.
See receipts/BENCHMARKS.md, receipts/THEORY.md, and raw run logs in receipts/runs/ for full receipts.
Credits & License
- Upstream Engine:
mw00/project-maya(Peasant Smith & contributors, Niko1221 / Strata) - Model & Quants: Z.ai (
GLM-5.3-Flash), turboderp (GLM-5.3-Flash-exl34.05bpw), Anbeeld (GLM-5.3-Flash-DFlash2-GGUF) - License: MIT — see
LICENSEandNOTICE.
Explore related projects
Loading…