Repository navigation
Metal: a request's stats list its prompt pass widths, on every text family - #2293
Merged
Merged
Conversation
Owner
Author
|
The LFM2 rerun on an Apple M5 Ultra is level (LFM2.5-24B-A2B 4-bit, main against this branch, warm base new new base base new, three runs an arm):
With the first LFM2 run's REVIEW now settled, this lands from the queue, and #2304 follows once its CUDA cells are in. |
Count the actual target slices in the shared Metal prompt path. Keep verify and drafter absorb work out of the list and preserve inference when observation allocation fails. Forward the request-owned list through the lane host and existing raw/chat runtime fields. Host regressions cover stepped and serial cuts, the lone scheduler, drafted verify exclusion, observation failure, mailbox ownership, and whole/streamed raw and chat replies. Refs #2089, #2120.
Share the request-owned observation policy with Qwen27. Count GLM chunks after completion and Nemotron prompt buffers at their existing landing wait, preserving its one-chunk lookahead. Clear abandoned observation owners on a failed release drain. Host cases exercise chunked and one-pass prompts, actual cut planning, completion and ownership, verify exclusion, and request stats. Add shader-free compiles of the real family callbacks. Refs #2089, #2120.
ashhart
force-pushed
the
lead/prefill-widths
branch
from
November 6, 2026 08:08
a4770d2 to
b215807
Compare
4 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A request's finished stats now say how its prompt was cut on Metal:
tensorfold.prefill_widthslists one entry per completed target prompt pass, with its real row count, for Qwen3.8-27B, Nemotron, GLM-5.3-Flash and every other Metal text family: Gemma 4, LFM2-MoE, Step5, Spark2.5, GLM-DSA, Kimi K3, Llama, MiniMax-M3, Qwen 3.5 and Qwen4. It answers "how was my prompt chunked?" without a profile build.prompt_flight.zig, with the same chunk cuts, wait, error and timing path).Checks (the third commit adds
check-metal-prefill-rest-hostandtest-qwen4-prefill-widths-host: 31 of 31 steps and 16 of 16 tests, with the earlier steps):zig build test-qwen27-prefill-stats-host test-qwen27-prefill-widths-http-host test-glm-prefill-widths-host test-glm-scheduling-host test-nemotron-prefill-widths-host check-nemotron-prefill-widths-host: 19 of 19 steps, 78 of 78 tests. Chunked prompts report their real cuts, a one-pass prompt reports one entry, a resumed prompt reports only what it ran, and a failed chunk reports nothing.zig fmt --checkon every touched file; lean unchanged at 426.zig buildpasses: 255 of 255 steps.