mirror of
https://github.com/mw00/project-maya.git
synced 2026-12-03 21:08:26 +07:00
[GH-ISSUE #185] Windows: RAM tier stops at ~45 GB on a 64 GB PC, ~7 GB stays free (pinning cap) - can it be raised? #71
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
mw00/project-maya#71
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Hosein20000 on GitHub (Oct 14, 2026).
Original GitHub issue: https://github.com/mw00/project-maya/issues/185
Setup
Problem
About 6.7-7 GB of RAM stays "Available" the whole time, while about a third of the experts are read from the SSD. Decode is ~8 tok/s with exact decoding (no DISK_SKIP).
What the log shows
glm fast: CUDA0 a pinning cap: 33.00 GB more pin, the RAM tier sized to it
glm fast: CUDA0 RAM tier 45.08 GB pinned, 6768 slots
glm fast: CUDA0 layers [0,45) expert pool 15.94 GB, 2408 slots total
glm fast: CUDA0 tiers warm: 9042 experts (64.5 GB) in 46 s
glm fast: CUDA0 CPU lane: 14 threads, an expert 0.249 ms on the CPU vs 0.315 ms over PCIe
9042 of the 13248 experts are held; the rest come from disk.
What I tried
What I found in the code
glm_fast_path.cu (pin_alloc / pin_room) measures a pinning cap at the first refused cudaHostAlloc and sizes the tier to it. A comment mentions a Windows laptop with 64 GB hitting the cap at a 45.3 GB tier (#67), which is almost my number (45.08 GB, about 70.7% of RAM). STRATA_GLM_PIN_CAP_MB only lowers the cap for tests, so it can't raise it. So I think the limit comes from Windows or the NVIDIA driver, not from Maya's defaults.
Questions
I can run any test or send the full log (--report) if it helps.
@technerd-official commented on GitHub (Oct 15, 2026):
Im on Windows 10 (i7-6700K, 64GB DDR4 RAM, RTX3090) Im getting 6 tok/s with Maya-S24 but I see in windows task-manager that only 39 GB out of my 64GB are used the rest is free. Why is that? The VRAM is used correctly 23.1GB out of 24GB. Any hints?
@uvtzxpm commented on GitHub (Oct 15, 2026):
It's not something that can be fixed by any kind of setting on Windows on a 3090. It's not a problem on Linux, it will just work.
It's up to the project author if he wants to support Windows in this, by allocating memory differently (it seems complicated and the project is Linux focused mostly).
AI explanation:
@hiroki-abe-58 commented on GitHub (Oct 15, 2026):
A data point from the other side of this question, with a small tool to separate the two possible causes.
Setup: Windows 11 build 26200, RTX 5090 (WDDM, driver 610.88), 63.4 GB RAM (4x16 GB), page file system-managed (~21-26 GB), VBS and HVCI running (as in the report above). Maya v1.1.11, Maya-S-v2-IQ2_XXS.
Pinning outside Maya. A 150-line CUDA program (
tools/pin_probe, MIT) callscudaHostAlloc(..., cudaHostAllocPortable)in chunks and prints RAM and commit before and at the end:--max-gb 30--max-gb 44.5cudaHostAllocwas not refused at 44.5 GB (the ~45 GB / ~70% point of this issue and of #67). The probe stopped because free RAM was almost gone, so I cannot say whether a cap exists above 44.5 GB here.So "WDDM caps pinning at ~70% of RAM" does not look like a rule that holds on every Windows PC. It may still be what happens on the reporter's RTX 3090 (different GPU generation and driver; and their page file is 64 GB, so commit is not the limit there). The probe takes a few seconds and would tell the two cases apart on those PCs:
If
stopped_bynames a CUDA error whilephys_avail_gbandcommit_avail_gbare both still large, that is a driver refusal; if it runs to--max-gb, the limit is somewhere else (commit, or Maya's own sizing).What I did not test: anything above 44.5 GB pinned, a 3090, other drivers,
cudaHostRegisteron this card (the tool has--mode register, I only ranalloc). For context, with the tier pinned to 26 GB here (the commit limit), 10 / 18 / 26 GB tiers gave 6.9 / 8.8 / 11.2 tokens/s on--bench(n=3 each, interleaved): https://github.com/hiroki-abe-58/moe-tiering-lab/blob/main/docs/findings.mdI am not proposing a code change from this; it is only meant to help narrow down where the limit sits.
@hiroki-abe-58 commented on GitHub (Oct 15, 2026):
Follow-up to my earlier comment with the part I could not do then: what a bigger RAM tier is worth, and what limited it on my PC.
Setup: RTX 5090 (32 GB, driver 610.88, WDDM), Core Ultra 9 285K, 64 GB DDR5, Windows 11 26200 with VBS/HVCI on, Maya v1.1.11, Maya-S-v2-IQ2_XXS, 32K context,
STRATA_GLM_RAM_GBpinned per arm, 3 interleaved rounds per arm, greedy.What limited the tier here: the commit limit, not a refusal by the driver. Before: system-managed page file (~21-26 GB), commit limit ~84-90 GB, and Maya's start-up line said the commit limit capped the tier 17 GB below free RAM (my
pin_probealso showed pinned memory is charged 1:1 to commit). After: a fixed 48 GiB page file (commit limit 111.4 GB), one reboot.STRATA_GLM_RAM_GBSpread inside each arm was <= ~1%. The VRAM hit rate stayed at ~65% in all arms; the gain is fewer SSD waits per token (24 -> 13) and shorter ones (2.03 -> 1.33 ms). The engine pinned 42 GB without any refusal (VBS/HVCI on).
What this does and does not show:
pin_probe; I stopped there because free RAM was down to 2-10 GB. I did not test above that, so I cannot say whether a driver cap exists above 44.5 GB on this card, and this says nothing about the RTX 3090 / the driver in your report.pin_probeprints both).One side finding that may matter for anyone comparing runs: with the default CPU lane, greedy output depends on the RAM tier size (tier 26 and 42 diverge within the first ~200 tokens), because the CPU path and the GPU path of an expert differ at quantisation level (relative L2 error against a double-precision reference on one calibration expert, from
STRATA_GLM_CPU_LANE_CHECK=1: GPU 1.63%, CPU lane 2.89%). WithSTRATA_GLM_CPU_LANE=0tier 26 and 42 gave bit-identical tokens on 6/6 prompts (also withSTRATA_GLM_MTP_DECODE=1), at -4% (tier 26) / -10% (tier 42) decode. A 42-task graded quality check showed no difference (39/42 vs 40/42), but that is too small to detect a small one. I did not compare logits at the divergence points.Scripts, raw token ids and the exact commands are in https://github.com/hiroki-abe-58/moe-tiering-lab (v0.2.0;
results/phase2/exp4-summary.md,results/phase3/exp5-determinism/SUMMARY.md). One PC, one model; no claim about other hardware.