Repository navigation
[None][refactor] Clean up the MiniMax-M3 modeling_v2 family under the Modeling V2 code rules - #23200
Draft
Wanli-Jiang wants to merge 2 commits into
Draft
Wanli-Jiang wants to merge 2 commits into
Wanli-Jiang wants to merge 2 commits into
Conversation
… Modeling V2 code rules Bring the 11 minimax_m3 ModelCores (M3 sm_103 tp4 / tp8 and sm_107 tp2 / tp4 / tp8; M3.1-Flash sm_107 tp2 / tp4 / tp8 / tp2ctx / dep2ctx / dep) and the family's shared code in line with the Modeling V2 code rules. - Routing: each ModelCore has its own check in minimax_m3/deployment.py; configurations that would fail at load or on the first step (breakable prefill CUDA graph where unsupported, Eagle3 on M3.1) are rejected at routing. - ModelCore switches: the environment switch registry goes from 387 entries to the 5 kept ones, each documented and read once at load; handles and workspaces are built at load; no per-step mode flags. - Targets and drafters: every ModelCore has Targets whose forward calls modules and ops in execution order; the Eagle3 and DSpark drafter steps follow the same form; row-count dispatch between kernels moves into ops. - Ops: direct kernel calls are wrapped in ops with __call__, reference, CELLS, is_valid and ARCHS. - Kernel copies and C++: identical kernel / op copies are merged into the family (69 groups to 1); each remaining near-copy states how and why it differs. The MiniMax-only C++ moves from cpp/ into the family library (csrc/, torch.ops.mv2_minimax_m3); cpp/ keeps the 3 ops shared code calls. - Unit tests: tests follow their ops to the family; bitwise checks remain only for ops without floating-point arithmetic, the others compare with the reference within derived tolerances; one CUDA graph test per ModelCore replaces the per-op graph tests; architecture skips go through one conftest hook. - Accuracy tests: two cases per ModelCore, acceptance-length floors in acceptance_length.yaml, the sm_103 tp4 Eagle3 case pre-merge. - Dead code: paths no engine reaches are removed (DSpark prebuild paths gated on hooks no worker defines, the M3.1 one-model Eagle3 code, native ops without callers, cute_dsl_kernels/minimax_m3). Also fixed: M3.1 tp2ctx failed to load (a logging-only NCCL window probe), M3.1 tp2 kept every earlier ModelCore alive in _BCG_CORES (now a WeakValueDictionary), and the NVIDIA#21848 m3_lowm_splitk fix is applied to the family copy the M3.1 tp2 / tp4 DSpark drafters use. Signed-off-by: Wanli Jiang <35160485+Wanli-Jiang@users.noreply.github.com>
Collaborator
Author
|
The routing (27)
modelcore (7)
target (2)
kernel (25)
unit-test (39)
|
Wanli-Jiang
commented
Dec 2, 2026
| Source properties the family's CMakeLists.txt sets with | ||
| set_source_files_properties (e.g. COMPILE_OPTIONS) apply to shared | ||
| and target sources alike. | ||
| and target sources alike. A .cu source's MODELING_V2_ARCHS property |
Collaborator
Author
There was a problem hiding this comment.
Why do we need to update building cmake here?
…ting declines, test layout - M3 sm_107 tp2 and tp4: the projection's choice between the engine MXFP8 GEMM and the decode GEMV by execution mode moves from the module into the m3_projection op, as in M3 sm_103 tp4. The kernels each step runs are the same (per-step kernel sequences compared before and after; greedy tokens identical). - M3.1 tp8: routing declines a breakable prefill CUDA graph, and the two checks that raised in its Targets are deleted. - Unit tests: regression cases become cells of their op's CELLS where they are inputs; one family-level copy of the sm_103 select-long and multicast all-reduce + RMSNorm tests replaces the per-ModelCore copies; a capture option joins its op's CELLS and reference; tests that run no kernel become CPU tests; tests no CI stage can run are registered in _NO_CI_STAGE; two msa sm_103 tests are listed in an sm_103 stage. - MV2-EXCEPTION comments that mark no exception under the code rules are removed or reworded (142 to 100). Signed-off-by: Wanli Jiang <35160485+Wanli-Jiang@users.noreply.github.com>
This branch has not been 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.
Description
This brings the existing
minimax_m3Modeling V2 family in line with the Modeling V2 code rules proposed in #23183. The family has 11 ModelCores: MiniMax-M3 NVFP4 on sm_103 (tp4, tp8) and sm_107 (tp2, tp4, tp8), and MiniMax-M3.1 Flash NVFP4 on sm_107 (tp2, tp4, tp8, tp2ctx, dep2ctx, dep). The results of the supported deployments do not change (see Verification). Deployments that failed at load or at their first step are now declined at routing.The diff is large because the clean-up deletes much more than it adds: 1,575 files, +51,866 / -171,866 lines.
This is a draft and a first step: it brings the parts listed under "What changes" in line with the rules, and "Not in this pull request" lists what is left for follow-up pull requests. The second commit moves two kernel choices into ops, adds a routing decline, fixes the unit-test layout and removes comments that mark no exception.
What changes, by layer
minimax_m3/deployment.py. Configurations that failed at load or at the first step are declined at routing (listed below).ROUTER_TF32_48_ROWS,TP4_WHOLECHAIN,TP4WC_HOIST,DEP2CTX_ROUTER_BF16S,DEP_VLLM_TOPK), each with a comment that says why it exists, its default and when to turn it off. The others are deleted with the paths they guarded and those paths' tests. Environment reads in the family go from 89 to 43.forwardcalls its modules and ops in execution order. The Eagle3 and DSpark drafter steps are written the same way. Choices of a collective or a kernel by row count moved from modules into ops.reference,CELLSandARCHS; 23 ops gained anis_valid.cpp/tensorrt_llm/(149 files, 40,654 lines) moved into the family's and the ModelCores'csrc/and is reached throughtorch.ops.mv2_minimax_m3; 10 files (1,710 lines) of shared build and registration code stay.referencewithin a tolerance whose derivation is in a comment. Each ModelCore has one whole-step CUDA graph test; 43 per-op CUDA graph tests are removed and 17 remain. Tests skip on GPU architectures their code does not serve, and tests of family ops moved with the ops.tests/integration/defs/accuracy/references/acceptance_length.yaml.main(about 21,800 lines, including M3.1's Eagle3 code), and the DEP tail and side-stream code whose registration hooks do not exist.Deployments now declined at routing
Under
modeling_v2="auto"these run on Modeling V1; under"require"they fail with the reason. Before, they failed at load or at the first step.Fixes of problems on
main_BCG_CORES), so a second load in the same process ran out of memory. The dictionary holds weak references now.m3_lowm_splitk.py, which the M3.1 tp2 and tp4 DSpark drafters use. It changes those drafters' split-K results.Not in this pull request
forwardor a module picks a kernel by execution mode (for example a second MoE engine only on a decode graph) or by whether an op covers the step's shape, or passes data to a later op through module-level state. The rules put kernel choices in ops and fix every other choice at load. The choices between op sequences by row count (about 66 more) are allowed by the rules.get_env_enable_pdl(), which readsTRTLLM_ENABLE_PDL, is called on every step (about 75 sites); some steps test whether a native op exists; decode ops keep module-level state they rewrite per step.maindoes not have: the M3.1 ModelCores request hooks throughruntime_hooks_compat, which drops the ones the engine lacks. The family MSA backend (msa/) is therefore never built, and the code behind the other dropped hooks never runs. Whether to keep it for an engine change is one of the owner's decisions.importlibnames (CI test selection does not see them), and 11 ops without a reference test.is_validwould help have none yet; each would need a GPU run over all itsCELLS.TLLM_DISABLE_ALLREDUCE_AUTOTUNEis still set withos.environ.setdefaultat load (the engine'sAllReducereads it from the environment only).forward, removed per-step checks) were not timed.Verification
How: for each change, before and after, on the same nodes: the kernel sequence of each step on every rank (kernel by kernel, or by kernel family where the autotuner picks the tactic, with two loads of unchanged code as the control), the greedy tokens, the unit tests and the accuracy cases. GPUs: GB300 (sm_103) and VR200 (sm_107), one and two nodes. The numbers below are from this change on
main5e5196675b. After the update tomainf1965254e7, the unit tests of the files main's new commits touched were run again on both GPUs and pass.Unit tests (whole
minimax_m3unit tree):The 5 failures are the new CUDA graph tests of M3 sm_103 tp4, M3 sm_107 tp2 / tp4 and M3.1 tp2 / tp4: a decode step replayed from a CUDA graph gives logits that differ from the same step run eagerly, by 1.6 to 7. They fail the same way on
mainwith only the test added, and the M3 sm_103 tp8 graph test (two nodes, not in the run above) fails the same way. The eager path is deterministic, and a load with CUDA graphs that does not replay matches eager bit for bit. A bug is being filed, and the two sm_103 graph tests, which post-merge CI runs, will be waived until it is fixed.Accuracy (GSM8K; acceptance length from the iteration statistics of the whole GSM8K run):
mainmainthe DSpark case runs out of memory after the first case in the same process (fixed here)mainfails to loadmainand on this branch alike: the process-wide autotuner cache changes which all-reduce small decode steps use. Its Eagle3 GSM8K takes 89.651 or 90.751 between runs onmaintoo.Accuracy coverage and CI stages
The features covered are decoding without speculation, speculative decoding (Eagle3 on M3, DSpark on M3.1) and, on M3 sm_107, piecewise CUDA graphs. Each ModelCore has one test file with two cases, each loading the model once.
CI cost: unit-test functions go from 1,708 to 780. Test-list entries with a timeout that this pull request adds: pre-merge 19 family op-test entries (1 GPU, 30 min each, 570 GPU-minutes; these tests ran before inside the ModelCore directories) and the accuracy case above (160 GPU-minutes); post-merge the two sm_103 CUDA graph tests (4 GPUs and 8 GPUs, 60 min each, 720 GPU-minutes). Other entries use the stage's default timeout.
Exceptions, copies and decisions for the owner
MV2-EXCEPTIONcomments: routing 27, modelcore 7, target 2, kernel 25, unit-test 39. Under the latest rules these are notes for readers, and the exceptions the rules list are allowed without them; the list is in the first comment below. Places that break a rule in a way the rules do not list are the items of "Not in this pull request", plus two branches in M3.1 dep2ctx that follow what the MoE backend reports after each launch.maindoes not have, one deployment question and one placement question. They are in the table below.Decisions for the owner
Decisions for the family owner (22). ModelCore short names:
M3 sm_103 tp4isminimax_m3_nvfp4__sm_103__tp4,M3.1 tp2isminimax_m3_1_flash_nvfp4__sm_107__tp2, and so on.TLLM_DISABLE_ALLREDUCE_AUTOTUNEos.environ.setdefault("TLLM_DISABLE_ALLREDUCE_AUTOTUNE", "1")at load, with a comment: AUTO's timed autotuner varies per start on SM107; set0to restore timing. The engine reads it on every AUTO all-reduce, so it affects the whole worker process, drafter and other models included. PR #23107 keeps it.ROUTER_TF32_48_ROWS(TRTLLM_M31_DISABLE_ROUTER_TF32_48_ROWS)TP4_WHOLECHAIN(variables namedTRTLLM_M31_DISABLE_<ID>)tp_agreebefore the engine build. On: whole-chain port (reference fused engine at 8 rows, hoist blocks with hoist). Off: 8 rows runm3_moewithout the engine or hoist. Off run: DSpark GSM8K 96.361 (pass). No test of the off path.m3_moechain, or the reference engine fails on a new build, driver or device.TP4WC_HOISTTP4_WHOLECHAINon, agreed across the TP group in_prebuild_hoist; off builds no hoist blocks. On saves 8.19 us per layer, not bitwise (the accuracy test gates it). Off run: DSpark GSM8K 97.043 (pass), TP4 MoE engine still on. No test of the off path.DEP2CTX_ROUTER_BF16S(TRTLLM_M31_DISABLE_DEP2CTX_ROUTER_BF16S)MiniMaxM3GateBf16s(FP32 weight split into two BF16 terms, closer to FP64 than TF32, no FP32 copy). Off:MiniMaxM3Gate(TF32 router on an FP32 copy, main's path). New testtest_both_gates_bound_at_loadchecks both bitwise. Off run: GSM8K 96.285 (pass).TRTLLM_M31_DISABLE_DEP_VLLM_TOPKmsa/msa_indexer.py. Read once at import, default on (vLLM 16-bit-key decode top-16 select);1returns to the exactminimax_m3_select_blocks. Commented, withMV2-EXCEPTION(modelcore).TRTLLM_MODELING_V2_VALUE_DUMPmodeling.pyof M3 sm_107 tp2, tp4, tp8 all read it)mpi_rank(), notOMPI_COMM_WORLD_RANK/RANK. Eagle3 drafter ops still record through it. PR #23107 keeps it as is.TRTLLM_M31_CUTE_AOT_DIR,TRTLLM_M31_CUTE_AOT_EXPORT_DIR,TRTLLM_M31_CUTE_AOT_DISABLEcute_aot.py)MV2-EXCEPTION(modelcore)at the reads removed.DIRkept: objects exported from the same source, key and toolchain replace load-time compiles.EXPORT_DIRkept: the only way to produce them; no test drives_export.DISABLEis a deletion candidate: same effect as leavingDIRunset.TRTLLM_M31_CUTE_AOT_DISABLE; whether the untestedEXPORT_DIRpath is acceptable.kernels/hoist/tp4c1/runtime/debug.py)M31_TP4C1_DEBUG_<name>andM3_LLK_DEBUG_<name>(nothing buildsDebug(enabled=True)or callsBuildContext.debug);H1_DBG,H1_DIE,H1_NOSPECandhost_env_set(no source reads them); uncalledstray_debug_env(); alsoDebug.get,BuildContext.debug,Runtime.debug. Each now has a comment.TRTLLM_M3_KV_POOL_ZERO_INITruntime_hooks_compat.py)tensorrt_llm/_torch/attention/backends/sparse/minimax_m3/cache_manager.py:299) that zeroes the MSA KV pool, replacing themsa_kv_cache_fixeshook this engine lacks. The family reads it at routing and hook build; off declines M3.1 targets. Kept, with a family comment. The engine's comment only says "Kill switch (diagnostics only)"; not changed.MIN_ACCEPTANCE_RATE = 0.78andMIN_ACCEPTANCE_LENGTH = 3.3:references/acceptance_length.yaml,min_al = ref_al - 0.10.ref_al/min_al: sm_103 tp4 3.488 / 3.388; sm_103 tp8 3.498 / 3.398; sm_107 tp2 3.517 / 3.417; sm_107 tp4 3.507 / 3.407; sm_107 tp8 3.506 / 3.406 (sm_107 tp8 measured 3.506 on this branch too).ref_al/min_al.references/acceptance_length.yamlat the measured value minus 0.10 (lower of two runs where there were two): tp2 4.552, tp2ctx 4.532, tp8 4.619, dep 4.541, dep2ctx 4.530. Under attention DP only rank 0's requests are counted, so dep2ctx measured 4.630 and 4.803 in two runs.min_alis 4.545746. Another branch run also measured 4.645746.min_alis 4.530189 (the lower run minus 0.10). Under attention DP,get_statsholds only rank 0's iterations (TLLM_METRICS_ALL_RANKSunset), so it measures rank 0's share of the requests.TLLM_METRICS_ALL_RANKS=1changes theget_statsrecords, whichacceptance_length_from_iteration_statsdoes not read today).ref_al/min_al, so the acceptance-rate check is gone; the rate is only printed. With draft length 3, rate = (length - 1) / 3 (true in all five runs), so the new gates 3.388 to 3.417 equal rates 0.796 to 0.806, stricter than the old 0.78.TestModelingV2MiniMaxM3Nvfp4Sm103Tp4::test_eagle3_gsm8k_and_acceptancefrom post-mergel0_gb300_multi_gpusto pre-mergel0_gb300(4-GPU block),TIMEOUT (40), cold start 875 s; the comment there says the stage is the model owner's decision. Itstest_gsm8k(deleted in PR #23107, kept here) stays in post-merge.ops/commtests in post-merge_NO_CI_STAGEintol0_gb300_multi_gpus(4 GB300, post-merge, about 72 s). The old reason ("not yet in the 4-GPU list") was not missing hardware: world-4 cells run on sm_103. The list names twotests:ops/commfiles;test_modeling_v2_m3_boundary_allreduce_norm_sm107.pygoes to_NO_CI_STAGE.l0_gb300_multi_gpusand sm_103 tp8's tol0_gb300_multi_nodes_node2_gpu8(bothTIMEOUT (60)); the 9 sm_107 ones go to_NO_CI_STAGE(CI has only single-GPU GR100 stages). Entries listing whole ModelCore directories get--ignore-glob=.../*_cuda_graph.py. Both sm_103 graph tests also fail on main (see "CUDA graph replay and eager give different logits").l0_gr100.ymllists the familyops/attentiondirectory, so moved tests run there too:test_modeling_v2_m3_dense_decode_sm103.py(later deleted) andtest_modeling_v2_m3_msa_attention.py(covers the M3.1 tp4 caller on sm_107; this op had no test before).l0_gb300.ymlandl0_b300.ymllist the new sm_103 family files by name.maindoes not havemain: the DSpark worker's prebuild items after its hook check (15 to 17 missingenable_*hooks), the one-model Eagle3 drafter of M3.1 (routing never selects it), and the DEP tail, side-stream and co-run band (no MoE registration hook). Kept for now: the M3.1 ModelCores request runtime hooks throughruntime_hooks_compat, which drops the ones the engine lacks, so the family MSA backend undermsa/is never built (nosparse_attentionhook), tile select never registers, and the code behind the other dropped hooks and the other DEP items never runs.moe_backendmoe_backend(a deployment question for the owner).weights.py/modeling.py, each with itsMV2-EXCEPTION(routing)comment (checkpoint contents are known only once the weights are read).Copies kept separate (44)
Paths are relative to
tensorrt_llm/_torch/modeling_v2/models/minimax_m3/.kernels/attention/producer_tp8.pyminimax_m3_1_flash_nvfp4__sm_107__tp8/kernels/m3_layer/phase_producer.pykernels/gemm/m3_lowm_splitk.pykernels/m3_lowm_splitk.pykernels/gemm/m3_mx_gemv_kernel.pyminimax_m3_1_flash_nvfp4__sm_107__tp8/kernels/mx_gemv/m3_mx_gemv_kernel.pykernels/m3_lowm_splitk.pykernels/gemm/m3_lowm_splitk.pyminimax_m3_1_flash_nvfp4__sm_107__tp2/ops/attention/m3_sparse_decode.pyminimax_m3_nvfp4__sm_103__tp4/ops/attention/m3_sparse_decode.pyminimax_m3_1_flash_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv.pyminimax_m3_1_flash_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv.pyminimax_m3_1_flash_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_1_flash_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_1_flash_nvfp4__sm_107__tp4/ops/attention/m3_index_score_t2sc.pyminimax_m3_nvfp4__sm_107__tp4/ops/attention/m3_index_score_t2sc.pyminimax_m3_1_flash_nvfp4__sm_107__tp4/ops/attention/m3_sparse_decode.pyminimax_m3_nvfp4__sm_103__tp4/ops/attention/m3_sparse_decode.pyminimax_m3_1_flash_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv.pyminimax_m3_1_flash_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv.pyminimax_m3_1_flash_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_1_flash_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_1_flash_nvfp4__sm_107__tp8/ops/activation/m3_dense_swiglu_oai.pytensorrt_llm/_torch/modeling_v2/models/minimax_m3/minimax_m3_1_flash_nvfp4__sm_107__tp4/ops/activation/m3_dense_swiglu_oai.pyminimax_m3_sm107_tp8_swiglu_oaithrough its own ...minimax_m3_1_flash_nvfp4__sm_107__tp8/ops/attention/m3_dense_fullctx_decode.pytensorrt_llm/_torch/modeling_v2/models/minimax_m3/minimax_m3_1_flash_nvfp4__sm_107__tp4/ops/attention/m3_dense_fullctx_decode.pykernels/m3_fullctx_decode, compiled for 8 query heads over ...minimax_m3_1_flash_nvfp4__sm_107__tp8/ops/attention/m3_select_top16.pytensorrt_llm/_torch/modeling_v2/models/minimax_m3/minimax_m3_1_flash_nvfp4__sm_107__tp4/ops/attention/m3_select_top16.pyminimax_m3_1_flash_nvfp4__sm_107__tp8/ops/moe/m3_decode_router.pytensorrt_llm/_torch/modeling_v2/models/minimax_m3/minimax_m3_1_flash_nvfp4__sm_107__tp4/ops/moe/m3_decode_router.pyminimax_m3_nvfp4__sm_103__tp4/ops/attention/m3_index_score.pyops/attention/m31_index_score.pyminimax_m3_nvfp4__sm_103__tp4/ops/attention/m3_sparse_decode.pyminimax_m3_nvfp4__sm_103__tp8/ops/attention/m3_sparse_decode.pyminimax_m3_nvfp4__sm_103__tp4/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_103__tp4/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_nvfp4__sm_103__tp4/ops/moe/m3_moe16_engine.pyminimax_m3_nvfp4__sm_107__tp4/ops/moe/m3_moe16_engine.pyminimax_m3_nvfp4__sm_103__tp8/ops/attention/m3_sparse_decode.pyminimax_m3_nvfp4__sm_103__tp4/ops/attention/m3_sparse_decode.pyminimax_m3_nvfp4__sm_107__tp2/ops/attention/m3_fullctx_decode.pyops/attention/m3_fullctx_decode.pyminimax_m3_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_107__tp8/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_nvfp4__sm_107__tp8/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_nvfp4__sm_107__tp2/ops/moe/m3_moe_engine.pyminimax_m3_nvfp4__sm_107__tp8/ops/moe/m3_moe_engine.pyminimax_m3_nvfp4__sm_107__tp4/ops/attention/m3_index_score_t2sc.pyminimax_m3_1_flash_nvfp4__sm_107__tp4/ops/attention/m3_index_score_t2sc.pyminimax_m3_nvfp4__sm_107__tp4/ops/gemm/m3_draft_lowm.pyops/gemm/m3_draft_lowm.pyminimax_m3_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_103__tp4/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_107__tp4/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_nvfp4__sm_103__tp4/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_nvfp4__sm_107__tp4/ops/m3_drafter_attn.pyminimax_m3_nvfp4__sm_107__tp8/ops/m3_drafter_attn.pyminimax_m3_nvfp4__sm_107__tp4/ops/moe/m3_moe16_engine.pyminimax_m3_nvfp4__sm_103__tp4/ops/moe/m3_moe16_engine.pyminimax_m3_nvfp4__sm_107__tp8/ops/attention/m3_decode_index_score.pytensorrt_llm/_torch/modeling_v2/models/minimax_m3/minimax_m3_nvfp4__sm_107__tp2/ops/attention/m3_decode_index_score.pyminimax_m3_nvfp4__sm_107__tp8/ops/gemm/m3_projection.pytensorrt_llm/_torch/modeling_v2/models/minimax_m3/minimax_m3_nvfp4__sm_107__tp4/ops/gemm/m3_projection.pyops/attention/m31_index_score.pyminimax_m3_nvfp4__sm_103__tp4/ops/attention/m3_index_score.pyops/attention/m3_fullctx_decode.pyminimax_m3_nvfp4__sm_107__tp2/ops/attention/m3_fullctx_decode.pyops/gemm/m3_draft_lowm.pyminimax_m3_nvfp4__sm_107__tp4/ops/gemm/m3_draft_lowm.pyminimax_m3_1_flash_nvfp4__sm_107__tp8/kernels/mx_gemv/m3_mx_gemv_kernel.pykernels/gemm/m3_mx_gemv_kernel.pyminimax_m3_1_flash_nvfp4__sm_107__tp8/kernels/m3_layer/phase_producer.pykernels/attention/producer_tp8.pyminimax_m3_1_flash_nvfp4__sm_107__tp8/ops/attention/m3_fullctx_decode.pyops/attention/m3_fullctx_decode.pyminimax_m3_nvfp4__sm_107__tp8/ops/attention/m3_fullctx_decode.pyminimax_m3_nvfp4__sm_107__tp4/ops/attention/m3_fullctx_decode.pyminimax_m3_nvfp4__sm_107__tp8/ops/moe/m3_moe_engine.pyminimax_m3_nvfp4__sm_107__tp2/ops/moe/m3_moe_engine.pyminimax_m3_nvfp4__sm_107__tp8/ops/m3_drafter_attn.pyminimax_m3_nvfp4__sm_107__tp4/ops/m3_drafter_attn.pyminimax_m3_nvfp4__sm_107__tp8/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv.pyminimax_m3_nvfp4__sm_107__tp8/ops/gemm/m3_mx_gemv_bf16.pyminimax_m3_nvfp4__sm_107__tp2/ops/gemm/m3_mx_gemv_bf16.pyTest Coverage
tests/unittest/_torch/modeling_v2/models/minimax_m3/(whole tree on GB300 and VR200, results above).tests/integration/defs/accuracy/modeling_v2/minimax_m3/(all 11 ModelCores, results above).tests/unittest/_torch/modeling_v2/test_modeling_v2_ci_selection.pyandtest_modeling_v2_contracts.pypass;ruff checkandruff format --checkare clean on the changed files.PR Checklist
Please review the following before submitting your PR:
PR description clearly explains what and why. If using CodeRabbit's summary, please make sure it makes sense.
PR Follows TRT-LLM CODING GUIDELINES to the best of your knowledge.
Test cases are provided for new code paths (see test instructions)
If PR introduces API changes, an appropriate PR label is added - either
api-compatibleorapi-breaking. Forapi-breaking, includeBREAKINGin the PR title.Any new dependencies have been scanned for license and vulnerabilities
CODEOWNERS updated if ownership changes
Documentation updated as needed
Update tava architecture diagram if there is a significant design change in PR.
The reviewers assigned automatically/manually are appropriate for the PR.
Please check this after reviewing the above items as appropriate for this PR.
GitHub Bot Help
To see a list of available CI bot commands, please comment
/bot help.