Repository navigation
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/24638
Note: Links to docs will display an error until the docs builds have been completed. ❌ 147 New Failures, 1 Cancelled Job, 7 Unrelated Failures, 27 Unclassified FailuresAs of commit 24b19de with merge base c7f7931 ( NEW FAILURES - The following jobs have failed:
UNCLASSIFIED FAILURES - DrCI could not classify the following jobs because the workflow did not run on the merge base. The failures may be pre-existing on trunk or introduced by this PR:
CANCELLED JOB - The following job was cancelled. Please retry:
FLAKY - The following jobs failed but were likely due to flakiness present on trunk:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This was referenced Nov 5, 2026
This was referenced Nov 5, 2026
metascroy
force-pushed
the
offgraph-kv-ggml-engine
branch
from
November 5, 2026 22:29
2f88227 to
ab17a5f
Compare
metascroy
force-pushed
the
offgraph-kv-runner
branch
from
November 5, 2026 22:29
804d291 to
87e92f7
Compare
metascroy
force-pushed
the
offgraph-kv-runner
branch
from
November 11, 2026 18:05
87e92f7 to
721d0bb
Compare
metascroy
force-pushed
the
offgraph-kv-ggml-engine
branch
from
November 11, 2026 18:05
ab17a5f to
8128a44
Compare
This was referenced Nov 12, 2026
kiymetakdemir
approved these changes
Nov 12, 2026
Comment on lines
+71
to
+79
| DEFINE_int32( | ||
| kv_capacity, | ||
| 0, | ||
| "Off-graph KV cache capacity in tokens; 0 uses --max_seq_length. Only " | ||
| "for packages exported with --offgraph_cache."); | ||
| DEFINE_string( | ||
| kv_dtype, | ||
| "fp32", | ||
| "Off-graph KV cache storage: fp32 or fp16."); |
Contributor
There was a problem hiding this comment.
Nit: MLX's runners call this --kv_max_capacity
This was referenced Nov 13, 2026
When a method calls kvcache::update_and_attend, the runner derives the cache geometry from the graph, builds the engine's single-sequence cache through the CacheFactory, publishes it with an InstallGuard, and passes its registry key to the engine context. New flags --kv_capacity, --kv_dtype, and --kv_initial_capacity size the cache. Sample verification clears the cache between samples instead of recreating the context. run_hf_llm_ggml registers the ggml cache builders.
metascroy
force-pushed
the
offgraph-kv-ggml-engine
branch
from
November 14, 2026 00:18
8128a44 to
80c68e9
Compare
metascroy
force-pushed
the
offgraph-kv-runner
branch
from
November 14, 2026 00:18
721d0bb to
24b19de
Compare
This branch had an error being deployed
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.
Stack
Off-graph KV cache for the native ggml engine, through serving Muse Glimmer on it. Review bottom-up; each PR builds and passes its tests on its own.
Summary
run_hf_llm_ggml(viaLlmRunner) can now run packages exported with--offgraph_cache.update_and_attendcall'slayer_idand K shape give one flat layer, so the.ptnformat doesn't change.CacheFactory::build(backend_id, kind::kSingle, ...)and publishes it with anInstallGuard. It passes the registry key tocreate_context_with_options, and keeps the cache alive longer than the context.--kv_capacity: tokens; defaults to--max_seq_length.--kv_dtype:fp32orfp16.--kv_initial_capacity: rows allocated up front.--verify_samplesclears the cache between samples instead of recreating the context.run_llmtakes the engine's cache backend id.run_hf_llm_ggmlregisters the ggml cache builders and passesNativeGgml.--kv_capacity,--kv_dtypeand--kv_initial_capacityare errors on an in-graph package instead of being silently ignored.extension_llm_cacheis now also built whenEXECUTORCH_BUILD_NATIVE_LLM_RUNNERis on.Test plan
On an Apple M4 Max:
--verify_samples golden --kv_initial_capacity 1: 0 calls failed, max error about 1.5e-5.--verify_samples golden: 0 calls failed (atol 2, rtol 0.05; max error 0.05-0.14).