[Docs] Fix stale W4A16 NVFP4 default kernel in ModelOpt docs by WarrierRajeev · Pull Request #59135 · vllm-project/vllm · GitHub
Skip to content

[Docs] Fix stale W4A16 NVFP4 default kernel in ModelOpt docs - #59135

Merged
hmellor merged 4 commits into
vllm-project:mainfrom
WarrierRajeev:modelopt-doc
Oct 2, 2026
Merged

hmellor merged 4 commits into
vllm-project:mainfrom
WarrierRajeev:modelopt-doc

Conversation

@WarrierRajeev

@WarrierRajeev WarrierRajeev commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Purpose

The ModelOpt docs say that for W4A16_NVFP4 checkpoints, auto "currently selects Marlin". That isn't what the code does. #53014 added this sentence together with the logic that makes auto pick the FlashInfer CuTe-DSL kernel on SM100/SM103, which the v0.30.0 release notes list under "New defaults".

ModelOpt W4A16 layers go through select_linear_kernel → init_nvfp4_linear_kernel(use_a16=True):

elif linear_backend == "auto" and use_a16:
    ...
    # Weight-only: prefer FlashInfer CuTe-DSL W4A16 on SM100/103,
    # otherwise Marlin.
    cutedsl_ok, _ = FlashInferCuteDslNvFp4W4A16LinearKernel.is_supported(
        compute_capability
    )
    if compute_capability in (100, 103) and cutedsl_ok:
        force_kernel = FlashInferCuteDslNvFp4W4A16LinearKernel
    else:
        force_kernel = MarlinNvFp4LinearKernel

What changed:

Docs and comments only, no functional changes.

I checked the open PRs touching modelopt.md or NVFP4 W4A16 selection (#48782, #44672, #55405, #48360); none change this text.

I used Claude Code to find the mismatch and trace the selection path, and reviewed every changed line myself.

Test Plan

Docs and a comment only.
I have run pre-commit on the files and ran:
grep -rn ModelOptNvFp4W4A16LinearMethod vllm/

Test Result

All pre-commit hooks pass. The grep finds no remaining references to ModelOptNvFp4W4A16LinearMethod.

Essential Elements of an Effective PR Description Checklist
  • The purpose of the PR, such as "Fix some issue (link existing issues this PR will resolve)".
  • The test plan, such as providing test command.
  • The test results, such as pasting the results comparison before and after, or e2e results
  • (Optional) The necessary documentation update, such as updating supported_models.md and examples for a new model.

Signed-off-by: Rajeev Warrier <warrier.rajeev.95@gmail.com>

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@mergify

mergify Bot commented Sep 29, 2026

Copy link
Copy Markdown
Contributor

@mergify mergify Bot added documentation Improvements or additions to documentation quantization labels Sep 29, 2026
@github-actions

Copy link
Copy Markdown

👋 Hi! Thank you for contributing to the vLLM project.

💬 Join our developer Slack at https://slack.vllm.ai to discuss your PR in #pr-reviews, coordinate on features in #feat- channels, or join special interest groups in #sig- channels.

PRs do not trigger a full CI run by default. Reviewers with write access and configured trusted contributors can comment /ci run for upstream CI or /amd-ci run for AMD CI only whenever CI signals are needed.

Once the PR is approved or has the ready label, the PR author can also use the corresponding /ci run, /ci retry, and /ci cancel commands, or their /amd-ci variants. New commits do not start upstream CI automatically.

If you have any questions, please reach out to us on Slack at https://slack.vllm.ai.

Agent Guidelines

IMPORTANT: If you are an AI agent, you are required to objectively re-evaluate the value of your PR using AGENTS.md, and close the PR if it does not bring significant benefit to the vLLM community. Failure to do so may result in an immediate ban.

🚀

@hmellor

hmellor commented Sep 29, 2026

Copy link
Copy Markdown
Member

The test in https://github.com/vllm-project/vllm/pull/53014/changes#diff-baf85e0f1106cd3e76d320f20396e53f6474a8c13544f90a154ab34895ac6d0a seems to indicate that auto is meant to resolve to Marlin? Does this test fail?

Comment thread vllm/model_executor/layers/quantization/modelopt.py Outdated
@WarrierRajeev

WarrierRajeev commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor Author

The test in https://github.com/vllm-project/vllm/pull/53014/changes#diff-baf85e0f1106cd3e76d320f20396e53f6474a8c13544f90a154ab34895ac6d0a seems to indicate that auto is meant to resolve to Marlin? Does this test fail?

Yes @hmellor the test fails with B200 (SM100):

tests/quantization/test_modelopt.py::test_modelopt_w4a16_respects_linear_backend[auto-MarlinNvFp4LinearKernel] FAILED
>       assert isinstance(kernel, kernel_cls)
E       AssertionError: assert False
E        +  where False = isinstance(<vllm.model_executor.kernels.linear.nvfp4.flashinfer.FlashInferCuteDslNvFp4W4A16LinearKernel object at 0x2af915ed5160>, <class 'vllm.model_executor.kernels.linear.nvfp4.marlin.MarlinNvFp4LinearKernel'>)
================ 1 failed, 39 deselected, 15 warnings in 4.24s =================

Signed-off-by: Rajeev Warrier <warrier.rajeev.95@gmail.com>

@mgoin mgoin left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we just remove the backend-specific docs references? The important note is that we are running without activation quantization, which I think is self-obvious from the "ALGO" name imo

Signed-off-by: Rajeev Warrier <warrier.rajeev.95@gmail.com>
@WarrierRajeev

WarrierRajeev commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor Author

Can we just remove the backend-specific docs references? The important note is that we are running without activation quantization, which I think is self-obvious from the "ALGO" name imo

@mgoin Yeah, makes sense. The choice made by auto is anyway logged at model load time. I've removed the references from docs.

@hmellor I've fixed the test in #59598. It expected auto to resolve to Marlin, but now auto prefers CuTe-DSL on SM100/SM103, so it failed on B200.

@hmellor
hmellor enabled auto-merge (squash) October 2, 2026 09:48
@github-actions github-actions Bot added the ready ONLY add when PR is ready to merge/full CI is needed label Oct 2, 2026
@hmellor

hmellor commented Oct 2, 2026

Copy link
Copy Markdown
Member

/ci run --allow-stale

@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown

✅ Triggered Buildkite CI #92596 for commit 31a7802921ab.

⚠️ This PR is 255 commits behind upstream main. Running CI at your own risk because --allow-stale was requested; outdated CI configuration may cause failures. Before merging, merge or rebase onto the latest main, then rerun /ci run on the latest PR commit.

@hmellor

hmellor commented Oct 2, 2026

Copy link
Copy Markdown
Member

/ci run

@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown

✅ Triggered Buildkite CI #92598 for commit 378b8d357774.

@vllm-agent

Copy link
Copy Markdown
Collaborator

CI selector (shadow): 0 test steps (0 jobs) instead of 70 (94 jobs)

Shadow mode: this changes nothing about what CI runs. It shows what the evidence-based selector would pick for this PR, next to today's rules. How it works.

Feedback welcome: reply here if it would skip a step this change needs, or runs something unrelated.

steps (jobs) Today's rules Selector Would skip Would add
NVIDIA, CPU and others 70 (94) 0 (0) 70 (94) 0 (0)
AMD mirrors 77 (115) 0 (0) 77 (115) 0 (0)
Selector would run (0)

none

Would skip (today's rules run them) (70)
  • amd-lm-eval-small-models-harness
  • amd-native-quantization-kernels-mi355
  • ascend-npu-test
  • async-engine-inputs-utils-worker
  • basic-correctness ×2
  • basic-correctness-cpu-offload
  • basic-correctness-cumem
  • basic-correctness-prefetch-offload
  • basic-correctness-sleep-mode
  • basic-models-test-other-cpu
  • basic-models-tests-initialization
  • basic-models-tests-other
  • batch-invariance-b200
  • batch-invariance-h100
  • benchmarks-cli-test
  • cpu-language-generation-and-pooling-model-tests ×3
  • distributed-compile-unit-tests-2xh100
  • entrypoints-integration-api-server ×4
  • entrypoints-integration-api-server-generate
  • entrypoints-integration-api-server-openai-chat_completion
  • entrypoints-integration-api-server-openai-completion
  • entrypoints-integration-llm
  • entrypoints-integration-multimodal
  • entrypoints-integration-pooling
  • entrypoints-integration-responses-api
  • entrypoints-integration-speech_to_text
  • fusion-and-compile-unit-tests-2xb200
  • fusion-e2e-quick-h100
  • fusion-e2e-tp2-b200
  • fusion-e2e-tp2-quick-h100
  • kernels-deepgemm-test-h100
  • kernels-fla-ops-test-b200
  • kernels-fusedmoe-layer-test-2-b200s
  • kernels-fusedmoe-layer-test-2-h100s
  • kernels-mhc-test-b200
  • kernels-quantization-test ×6
  • kernels-root-misc-test-b200
  • language-models-tests-granite-l4-compatibility
  • language-models-tests-hybrid ×2
  • language-models-tests-standard
  • lm-eval-small-models
  • metrics-tracing-2-gpus
  • model-executor
  • multi-modal-models-standard-1-qwen2
  • multi-modal-models-standard-2-qwen3-gemma
  • multi-modal-models-standard-3-llava-qwen2-vl
  • multi-modal-models-standard-4-other-whisper
  • multi-modal-processor ×4
  • multi-modal-processor-cpu ×4
  • pytorch-compilation-dynamic-shapes
  • pytorch-compilation-passes-unit-tests
  • pytorch-compilation-unit-tests
  • pytorch-compilation-unit-tests-h100
  • pytorch-fullgraph-cudagraph-l4-compatibility
  • pytorch-fullgraph-test
  • quantization ×4
  • quantized-fusions
  • quantized-models-test
  • quantized-moe-test-b200
  • regression
  • samplers-multimodal-beam-search
  • samplers-test
  • v1-core
  • v1-executor-worker
  • v1-kv-connectors ×4
  • v1-kv-offload
  • v1-logits-oracle
  • v1-metrics-lmeval
  • v1-sample
  • v1-spec-decode
Would add (today's rules do not run them) (0)

none

AMD mirrors: would skip (77)
  • async-engine-inputs-utils-worker
  • basic-correctness ×2
  • basic-correctness-cpu-offload
  • basic-correctness-cumem
  • basic-correctness-prefetch-offload
  • basic-correctness-sleep-mode
  • basic-models-tests-extra-initialization ×14
  • basic-models-tests-initialization
  • basic-models-tests-other
  • batch-invariance-h100
  • benchmarks-cli-test
  • distributed-model-tests-2-gpus ×3
  • entrypoints-integration-api-server ×4
  • entrypoints-integration-api-server-generate
  • entrypoints-integration-api-server-openai-chat_completion
  • entrypoints-integration-api-server-openai-completion
  • entrypoints-integration-llm
  • entrypoints-integration-multimodal
  • entrypoints-integration-pooling
  • entrypoints-integration-responses-api
  • entrypoints-integration-speech_to_text
  • fault-tolerance-e2e-2xh100
  • fusion-and-compile-unit-tests-2xb200
  • fusion-e2e-quick-h100
  • fusion-e2e-tp2-ar-rms-config-sweep-h100
  • fusion-e2e-tp2-b200
  • fusion-e2e-tp2-quick-h100
  • kernels-fla-ops-test-b200
  • kernels-fp4-moe-test-b200
  • kernels-fusedmoe-layer-test-2-b200s
  • kernels-fusedmoe-layer-test-2-h100s
  • kernels-mhc-test-b200
  • kernels-quantization-test ×6
  • kernels-root-misc-test-b200
  • language-models-tests-extra-standard ×2
  • language-models-tests-granite-l4-compatibility
  • language-models-tests-hybrid ×2
  • language-models-tests-standard
  • lm-eval-small-models
  • metrics-tracing-2-gpus
  • model-executor
  • multi-modal-models-standard-1-qwen2
  • multi-modal-models-standard-2-qwen3-gemma
  • multi-modal-models-standard-3-llava-qwen2-vl
  • multi-modal-models-standard-4-other-whisper
  • multi-modal-processor ×4
  • openai-api-correctness
  • pipeline-context-parallelism-4-gpus
  • platform-tests
  • pytorch-compilation-dynamic-shapes
  • pytorch-compilation-passes-unit-tests
  • pytorch-compilation-unit-tests
  • pytorch-compilation-unit-tests-h100
  • pytorch-fullgraph-test
  • quantization ×4
  • quantized-fusions
  • quantized-models-test
  • quantized-moe-test-b200
  • regression
  • samplers-multimodal-beam-search
  • samplers-test
  • spec-decode-draft-model ×4
  • spec-decode-eagle-1-deepseek-qwen
  • spec-decode-eagle-2-llama3-qwen-vl-other
  • spec-decode-mtp-deepseek-mimo
  • spec-decode-mtp-gemma4
  • spec-decode-mtp-qwen3-5
  • spec-decode-ngram-suffix
  • spec-decode-speculators
  • v1-core
  • v1-executor-worker
  • v1-kv-connectors ×4
  • v1-kv-offload
  • v1-logits-oracle
  • v1-metrics-lmeval
  • v1-sample
  • v1-spec-decode
AMD mirrors: would add (0)

none

2 changed files · base 8e58ac22af · head 378b8d3577 · Python record: build 92561 at 4056c8ac1f · kernel record: table 4056c8a (build 92561), map 4056c8a · not counted: 10 build steps, 5 A100 steps the generator no longer emits, 0 optional steps the selector would also run

@WarrierRajeev

Copy link
Copy Markdown
Contributor Author

/ci retry

@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown

✅ No failed, timed-out, or expired jobs need retrying: https://buildkite.com/vllm/ci/builds/92598

@hmellor

hmellor commented Oct 2, 2026

Copy link
Copy Markdown
Member

@hmellor
hmellor disabled auto-merge October 2, 2026 12:14
@hmellor
hmellor enabled auto-merge (squash) October 2, 2026 12:15
@hmellor
hmellor merged commit 30e956f into vllm-project:main Oct 2, 2026
195 checks passed
michael-gpu pushed a commit to practical-inference/vllm-ampere-extended that referenced this pull request Oct 20, 2026
…oject#59135)

Signed-off-by: Rajeev Warrier <warrier.rajeev.95@gmail.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation quantization ready ONLY add when PR is ready to merge/full CI is needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants