Repository navigation
perf(moe): admit a host-less offload's misses before they run - #916
Conversation
With no host runner every miss is uploaded for its call, and admission then read the same expert again after the layer. Now the misses admission takes are uploaded into the cache before the layer runs them (MoeExpertOffload.AdmitNow, the same admission rule as AfterLayer), pinned with a second lease, and run from that cached copy: one read per admitted miss. Offloads with a host runner keep the after-layer admission. Measured on the 4090 A/B in #914: 1178 admissions there were about 14.8 GB of second reads.
|
@codex review |
|
@claude Review PR |
|
Claude finished @kalebbroo's task in 1m 28s —— View job Review of PR #916: admitting a host-less offload's misses before they runI found no bugs that block this. The approach works. On CUDA, What I checked
Suggestions (non-blocking)
Not done
TL;DR: The change is correct and safe to merge once the pod numbers look good. The main follow-up is to run resident experts while the admitted uploads are in flight. Also worth doing: update the |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
|
Real-checkpoint A/B, RTX 4090 (new pod, 124 GB RAM, network volume, code at 33757b6). Both cases ran resident with tokens 1..5, then 32 greedy decode steps, on the same pod.
🤖 Addressed by Claude Code |
The MoeExpertOffload remarks and the StreamedRows doc now describe the host-less path: misses admitted before they run, pinned with a second lease, and counted as streamed. CollectionsMarshal comes from a using.
|
Addressed in 596bc99:
Not changed:
🤖 Addressed by Claude Code |
|
@codex review |
|
Codex Review: Didn't find any major issues. 🎉 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
What
Follow-up to #914. That PR's 4090 A/B showed the device expert cache about 16% slower than plain auto-promotion over 32 decode steps: 268.7 s vs 231.4 s.
The cause: with no host runner, every miss is uploaded for its call, and admission then read the same expert again after the layer. That came to 1178 admissions, about 14.8 GB of second reads, each a synchronous staged upload from the volume.
Now, for an offload with no host runner:
MoeExpertOffload.AdmitNow, the same fills-then-hot-swaps rule asAfterLayer).Offloads with a host runner (Qwen, GLM and the others) keep the after-layer admission, so nothing changes for them.
MoeOffloadStatscounts an admitted-before-run expert's rows as streamed, not resident, so the resident share still means "served without an upload".Validation