Experiment: validate placement and backend residency assumptions - #893
Experiment: validate placement and backend residency assumptions#893terrizoaguimor wants to merge 2 commits into
Conversation
|
Green on all 17, and the individual observations look sound. I am still going to ask you to split it, and the reason is in your own summary:
That several reports share a family is an argument for splitting, not for bundling. #887, #892, #813, #585, #759, #653, #766, #767, #687 are nine issues, on four backends, reported by different people on hardware none of us has. One PR that touches
The natural cut is the one your description already makes:
Send 1 and 2 and I will take them without ceremony. 3 and 4 want their reporters attached. One correction while you are here, since you cite it: #856 was fixed in #869, but the same constant was also feeding |
|
Per your review, I split PR #893 into two focused PRs from |
Summary
This PR is the local-first Phase 0 and placement-contract work requested before a runtime CNRE admission policy is considered. It combines the offline residency simulator with small fixes that make placement accounting, backend selection, and fallback claims more truthful.
It does not add an external cache service, change routing, add prefetch, or change model outputs by policy. It also does not yet implement a runtime frequency-admission policy.
Why These Changes Are Connected
Several reports describe the same user-visible failure family: the plan says that a GPU/cache tier is available, but the actual execution falls back to CPU/disk, or the computed budget omits a memory term and fails later.
Related reports:
Implemented
Offline simulator
Placement accounting
resource_plan.pynow records per-layer expert widths and maximum width.doctorreports a backend-neutralaccelerator.gpucheck instead of calling every device CUDA.Backend truthfulness
COLI_VK_DEVselects the primary Vulkan physical-device enumeration index for reproducible multi-GPU/hybrid testing.VK=1enables one.Real-trace evidence
Before this PR, a DigitalOcean H200 pilot collected 13 GLM-5.2 traces: 8 train and 5 held-out across coding, chat, reasoning, multilingual, and long-context prompts.
The simulator predicted the following held-out felt-wait gains against uniform LRU:
These are offline predictions, not runtime speedup claims. The pilot also showed why backend and overlap telemetry must be correct:
RAM_GB=120, PIPE=0measured 1.66 tok/s at 57.2% hit, whileRAM_GB=120, PIPE=1measured 2.00 tok/s at the same hit rate. Hit rate alone is not the objective.Verification
407 passed, 57 skipped.make metal-test: passed, including grouped-int4 batched MoE.python3 -m py_compile: passed.git diff --check: passed.Scope and follow-up
The simulator and methodology are intentionally included so the next runtime policy can be measured against the real held-out gate rather than selected on synthetic or in-sample wins.
The next PR should be a separate, small, GLM-only opt-in admission policy with no routing change, no new prefetch, fixed memory budget, and ABBA measurements for tok/s, p50/p99 latency, felt wait, physical bytes, admissions, rejections, evictions, migration bytes, and output identity.
The Intel Vulkan report in #887 still needs hardware confirmation. This PR improves device selection and removes misleading generic CUDA wording, but it does not claim DeepSeek V4 Vulkan support that the engine does not currently implement.