Repository navigation
Conversation
Upstream ggml-org#32078 made graph_max_nodes independent of the ubatch. The upstream sync took that change, but the fork's qwen4exp QSA scorer splits each ubatch into score strips that shrink as the context grows, so its graph still grows with n_ubatch. At n_ctx 563200 and n_ubatch 4096 the main and MTP contexts ran out of graph metadata space during reserve (GGML_ASSERT(obj_new)). Give qwen4exp back its n_ubatch * 40 budget, as before the sync, and add test-qwen4exp-long-ctx, which reserves both contexts at that shape. Fixes #301 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YKmjzcT1LTvKtbw9EzBVGE
Collaborator
Author
|
Duplicate of #304, which has the same fix and is approved. The regression test from this branch ( |
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.
Fixes #301: a qwen4exp model with an MTP draft aborts at load with a long context (
GGML_ASSERT(obj_new), "not enough space in the context's memory pool").Cause: a wrong resolution in the last upstream sync. Upstream ggml-org#32078 made
graph_max_nodesindependent of the ubatch, and the sync took it. Upstream's graphs no longer need that budget, but the fork's qwen4exp QSA scorer still does: it splits each ubatch into score strips that get smaller as the context grows, so its node count grows withn_ubatch. This change gives qwen4exp back itsn_ubatch * 40budget, as before the sync. Other archs keep upstream's budget.Tests:
test-qwen4exp-long-ctx(test-llama-archs): reserves the main and MTP contexts at n_ctx 563200, n_ubatch 4096, yarn 2.2 (the shape in the issue). Master aborts with the same assert as the issue; this branch passes. It also passes at n_ctx 1048576 with 64 indexer heads.-L main: CPU 37/37, HIP 37/37.Not tested: the full Qwen3.8 Flash Next model from the issue.
🤖 Generated with Claude Code
https://claude.ai/code/session_01YKmjzcT1LTvKtbw9EzBVGE