refactor(runtime)!: adopt the modern Infini stack - #506
Draft
voltjia wants to merge 49 commits into
Draft
Conversation
voltjia
force-pushed
the
refactor/adopt-modern-infini-stack
branch
3 times, most recently
from
August 13, 2026 15:26
7c36e2f to
077867b
Compare
BREAKING CHANGE: legacy InfiniCore runtime and inference APIs are removed in favor of InfiniRT, InfiniOps, and the migrated InfiniLM runtime.
Carry segmented P2P graph replay, graph-aware tensor initializers, runtime compatibility helpers, and long-context chunking into the InfiniLM-owned runtime. Preserve the stronger migrated graph ownership, cancellation, and allocation lease semantics while reconciling current InfiniLM attention behavior.
voltjia
force-pushed
the
refactor/adopt-modern-infini-stack
branch
from
August 25, 2026 05:12
9439ea6 to
9d64e14
Compare
voltjia
force-pushed
the
refactor/adopt-modern-infini-stack
branch
from
August 31, 2026 07:07
03d7533 to
dcfbebc
Compare
voltjia
force-pushed
the
refactor/adopt-modern-infini-stack
branch
from
September 2, 2026 14:17
2a44095 to
5de9a02
Compare
…ention feat(cambricon): enable tensor-parallel flash attention
* feat(iluvatar): enable modern Infini stack * feat(iluvatar): enable canonical attention adapters * feat(iluvatar): enable flash attention backend * fix(iluvatar): address review feedback * fix(model-loading): mmap zip-format pytorch checkpoints * fix(bench): reuse paged cache during warmup
wooway777
reviewed
Sep 8, 2026
| throw std::invalid_argument("infinilm::config::ConfigFactory::createConfig: Unsupported model config type: " + model_type); | ||
| } | ||
|
|
||
| static const std::unordered_set<std::string> kModernModelTypes{ |
wooway777
reviewed
Sep 8, 2026
| const std::string quant_method = quantization_config.value("quant_method", ""); | ||
|
|
||
| // Determine the quantization scheme from the JSON config | ||
| if (quant_method == "compressed-tensors") { |
Collaborator
There was a problem hiding this comment.
为啥在这儿就都不支持了,我感觉是不是到了算子调用再拦住比较好。不然回头把东西补回来的时候又要一串一串改。
以及之前的全量测试好像确实忘记加量化相关的东西了
Register Hygon with the canonical InfiniOps bridge, greedy sampling, RoPE cache, and FlashAttention adapters. Extend the integration builder with Hygon architecture and RCCL wiring. Keep the platform-specific InfiniOps operator selection outside the repository and require it through --operator-config, matching the Iluvatar workflow.
* perf(runtime): make stream access constant time * perf(mlp): consume packed gate-up output * perf(ops): cache default infiniops implementation * perf(paged): reuse decode metadata buffers * perf(cache): skip unused paged cache scale upload * perf(graph): avoid eager output snapshots * perf(inference): optimize reviewed execution paths * perf(speculative): reuse graphs for token verification * perf(paged): capture ChatGLM short decode graph * test(runtime): cover optimized inference paths * style: format optimized inference paths * refactor(graph): centralize reviewed profile checks
wooway777
reviewed
Sep 9, 2026
| throw std::invalid_argument("infinilm::config::ConfigFactory::createConfig: Unsupported model config type: " + model_type); | ||
| } | ||
|
|
||
| static const std::unordered_set<std::string> kModernModelTypes{ |
Collaborator
There was a problem hiding this comment.
所以现在是要求显示列举支持的模型类型了么?本来应该是不需要的
wooway777
reviewed
Sep 9, 2026
Collaborator
There was a problem hiding this comment.
同上,这样以后恢复起来岂不是很费劲。由缺失算子支持造成的问题还是建议直接暴露在算子层,而不是直接从基建里把痕迹都移除了
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.
Summary
mainat80bb09ecebc9aabf198b9b866a89456bca1df946.Current head:
5de9a0283ec66ed30006372c535a75983407cdfb.The branch contains 43 commits on top of current
mainand remains mergeable.Related to InfiniTensor/InfiniCore#1373.
Migration and Runtime Changes
MhaKVCachework in host segments while the remaining operators run in device-graph segments; TP paged decode no longer falls back to a wholly eager engine.beta=0plus broadcast Add, including correct row/column-parallel placement and pre-transposed weights.infinicclCommInitRank. This avoids heap corruption caused by destroying a short-lived InfiniCore Runtime in each worker thread.Current Upstream Stack
55cfe5e6761c4ebb5e8eb77b65301479a7b6032c0cdbb16967e15f2e055dea1ec9641617bf3b6cf670e50081f181d8a3c4f9a6226c8524a648ed90c4c2d76051ca21774f0b515dfd8afe59537e200ac2e8ccc0cb23ca5b1b1d63be29ba61ea031de72807f74ce8033ce601dbb0bbf31277755d033693768c#506 uses AllGather, Send, and Recv, so #57/#58/#59 remain required. #69 is an independent
master-based prerequisite; validation combined itsMARCH_TYPE=310behavior with the API stack.Newly Validated Moore Capability
InfiniOps #819/#962 provide the missing paged prefill/decode attention closure. InfiniCCL #69 passes the actual MUSA architecture into MCCL so S5000's existing BF16 collective support is visible.
The selected formal matrix passed 13/13 commands:
Every row reported segmented graph execution with
host_segments > 0; none used whole-engine eager fallback. D14 and D17 additionally prove TP4/TP2 communicator setup and BF16 AllReduce. D14 completed in 191.391s and D17 in 74.904s after the two single-purpose fixes.The formal operator smoke also passed D64/D128 paged prefill/decode coverage:
4 passed, 8 deselected.All selected Moore commands are greedy/default sampling. Non-greedy sampling remains gated because the Moore manifest does not yet include a supported
top_k_top_p_sampling_from_logitsimplementation.Preserved NVIDIA Validation
CUDA_LAUNCH_BLOCKING.Gates Intentionally Retained
sliding_window, so a short prompt is not sufficient semantic validation.Verification
git diff --check: passed.git range-diff.Type of Change
Landing Order
master.masterbefore updating the final component pin.This PR remains draft until the upstream component PRs and final pins land, but it is ready for code review against the dependency order above.