Skip to content

Add parallel MLA inference tests, fix corresponding issues#3787

Draft
janEbert wants to merge 7 commits intoNVIDIA:mainfrom
janEbert:parallel-mla-inference-tests
Draft

Add parallel MLA inference tests, fix corresponding issues#3787
janEbert wants to merge 7 commits intoNVIDIA:mainfrom
janEbert:parallel-mla-inference-tests

Conversation

@janEbert
Copy link
Contributor

MLA used to not be tested for parallel dynamic inference. This PR implements appropriate test parameters into TestDynamicInferenceEngine.test_parallel_inference to test MLA with and without latent caching (although MLA currently only works with latent caching).

The test itself would fail without further changes, so the PR contributes several fixes to the code and improvements like making FlashMLA optional. For example, FlashMLA expects a block size of exactly 64 while FlashAttention expects a block size divisible by 256. In the generative phase, FlashMLA is not used, only FlashAttention, so any inference work other than decode-only tasks would not work with MLA without the changes in this PR.

Since the added tests are smoke-tests only, it's important to also add functional tests in future revisions to ensure correctness of the results.

Finally, tests for Mamba with the inference-optimized Transformer implementation are enabled since they pass without issues.

@copy-pr-bot
Copy link

copy-pr-bot bot commented Mar 10, 2026

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant