Skip to content

Conversation

@ProExpertProg
Copy link
Collaborator

@ProExpertProg ProExpertProg commented Sep 9, 2025

Fixes #23091.

Purpose

Cleanup compilation tests and custom passes and address #23091 and part of #24376. This PR is a prerequisite for matching torch implementations of custom ops in #24604.

Cleanup:

  • RMSNorm + QuantFP8 fusion:
    • remove custom multi-output matching workaround
    • remove .instance() workaround
    • remove _seen_patterns.clear() workaround
    • rename FusionPass to RMSNormQuantFusionPass
  • reduce test_fusion.py running time
  • add cleanup pass that topo-sorts and does DCE
  • add LazyInitPass test utility
  • add env var for pattern match debugging (TODO: docs)
  • fix test_sequence_parallelism.py
  • add assert to test_silu_mul_quant_fusion for easier diagnostics of fp4 failures.
  • add init check for custom_ops field syntax and warnings for specifying ops that don't exist
  • add timing and graph dumping decorator for VllmInductorPass
  • add VllmPatternMatchPass common pass superclass with pattern tracking and dumping utilities

Test Plan

Unit tests all pass.

@mergify
Copy link

mergify bot commented Sep 9, 2025

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @ProExpertProg.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
@ProExpertProg ProExpertProg added the ready ONLY add when PR is ready to merge/full CI is needed label Sep 20, 2025
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
@ProExpertProg ProExpertProg enabled auto-merge (squash) September 22, 2025 16:48
@simon-mo simon-mo disabled auto-merge September 22, 2025 19:30
@simon-mo simon-mo merged commit d5e0fca into vllm-project:main Sep 22, 2025
41 of 43 checks passed
@github-project-automation github-project-automation bot moved this from In review to Done in torch.compile integration Sep 22, 2025
@ProExpertProg ProExpertProg deleted the luka/custom-pass-cleanup branch September 22, 2025 19:50
FeiDaLI pushed a commit to FeiDaLI/vllm that referenced this pull request Sep 25, 2025
…g utils, fix DCE bug (vllm-project#23091), fix test (vllm-project#24376), and prep for custom op matching (vllm-project#24604) (vllm-project#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
debug_dump_path = Path(debug_dump_path) / f"rank_{rank}"
debug_dump_path.mkdir(parents=True, exist_ok=True)

from vllm.utils import unique_filepath
Copy link
Contributor

Choose a reason for hiding this comment

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

It seems that vllm.utils does not have unique_filepath.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yep, my bad, was working on a newer branch. I'll fix in #24604 unless you want to extract the change from there (and pull the import back up) in a separate PR to fix earlier

Copy link
Contributor

Choose a reason for hiding this comment

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

I will fix it in a separate PR

charlifu pushed a commit to ROCm/vllm that referenced this pull request Sep 25, 2025
…g utils, fix DCE bug (vllm-project#23091), fix test (vllm-project#24376), and prep for custom op matching (vllm-project#24604) (vllm-project#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
yewentao256 pushed a commit that referenced this pull request Oct 3, 2025
…g utils, fix DCE bug (#23091), fix test (#24376), and prep for custom op matching (#24604) (#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: yewentao256 <[email protected]>
gjc0824 pushed a commit to gjc0824/vllm that referenced this pull request Oct 10, 2025
…g utils, fix DCE bug (vllm-project#23091), fix test (vllm-project#24376), and prep for custom op matching (vllm-project#24604) (vllm-project#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: gaojc <[email protected]>
xuebwang-amd pushed a commit to xuebwang-amd/vllm that referenced this pull request Oct 10, 2025
…g utils, fix DCE bug (vllm-project#23091), fix test (vllm-project#24376), and prep for custom op matching (vllm-project#24604) (vllm-project#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: xuebwang-amd <[email protected]>
choprahetarth pushed a commit to Tandemn-Labs/vllm that referenced this pull request Oct 11, 2025
…g utils, fix DCE bug (vllm-project#23091), fix test (vllm-project#24376), and prep for custom op matching (vllm-project#24604) (vllm-project#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
lywa1998 pushed a commit to lywa1998/vllm that referenced this pull request Oct 20, 2025
…g utils, fix DCE bug (vllm-project#23091), fix test (vllm-project#24376), and prep for custom op matching (vllm-project#24604) (vllm-project#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
xuebwang-amd pushed a commit to xuebwang-amd/vllm that referenced this pull request Oct 24, 2025
…g utils, fix DCE bug (vllm-project#23091), fix test (vllm-project#24376), and prep for custom op matching (vllm-project#24604) (vllm-project#24542)

Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: luka <[email protected]>
Signed-off-by: Luka Govedič <[email protected]>
Signed-off-by: xuebwang-amd <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready ONLY add when PR is ready to merge/full CI is needed torch.compile

Projects

Status: Done

8 participants