vllm - 💡(How to fix) Fix [RFC]: Custom graph dumping for vLLM-compile and depyf deprecation [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
vllm-project/vllm#41296Fetched 2026-04-30 06:18:56
View on GitHub
Comments
1
Participants
2
Timeline
16
Reactions
0
Timeline (top)
mentioned ×5subscribed ×5labeled ×2added_to_project_v2 ×1
RAW_BUFFERClick to expand / collapse

Motivation.

Currently, vLLM uses depyf for graph dumping and introspection. However:

  • depyf is becoming a maintenance burden
  • tlparse (an alternative) is clunky, time-consuming and designed for PyTorch, not vLLM use cases
  • We need an extremely lightweight (single <300LOC PR), vLLM-aware graph dumping system

The goal is that any vLLM developer not even familiar with torch.compile can set VLLM_DEBUG_DUMP_PATH and easily navigate the produced graph dumps.

Proposed Change.

Implement a mini-system that:

  1. Hooks into lazy_format_graph_code to capture graphs at every (relevant) stage
    • Not sure if we need something different for output code
  2. Dumps to VLLM_DEBUG_DUMP_PATH/CompilationConfig.debug_dump_path, with easily navigable structure
  3. Preserves vLLM compilation context, including:
    • pass_context properties (e.g., compile ranges, donated inputs)
    • vllm config and model name associated with the dump
    • Any relevant vllm_ir metadata (like what provider will be selected in pre-lowered graphs)
    • Captures function names for torch.compile on smaller functions
  4. Exports both representations:
    • Structured traces nesting by layer: #39215
    • Unstructured traces: raw fx.Graph dump

We can finally deprecate depyf once this is implemented.

Feedback Period.

1 week, 4/29 - 5/6

CC List.

@zou3519 @youkaichao @benchislett

Any Other Things.

This should not take much core committer bandwidth as I think it would be easyu to implement for a community contributor.

Before submitting a new issue...

  • Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the documentation page, which can answer lots of frequently asked questions.

extent analysis

TL;DR

Implement a custom graph dumping system that hooks into lazy_format_graph_code to capture and dump graphs at relevant stages, preserving vLLM compilation context and exporting both structured and unstructured traces.

Guidance

  • Identify the key components required for the graph dumping system, including capturing graphs at every relevant stage, preserving vLLM compilation context, and exporting both structured and unstructured traces.
  • Determine the best approach to hook into lazy_format_graph_code to capture graphs, considering the need for a lightweight and vLLM-aware solution.
  • Consider the requirements for the dump structure and navigation, ensuring it is easily navigable for vLLM developers.
  • Evaluate the need for capturing function names for torch.compile on smaller functions and how to incorporate this into the graph dumping system.

Example

No specific code example can be provided without further implementation details, but the solution will likely involve creating a custom function to hook into lazy_format_graph_code and handle the graph dumping and export.

Notes

The implementation should be extremely lightweight, with a single PR of less than 300 lines of code, and should not require significant core committer bandwidth.

Recommendation

Apply a custom graph dumping system workaround, as it addresses the maintenance burden of depyf and the limitations of tlparse, while providing a vLLM-aware solution.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

vllm - 💡(How to fix) Fix [RFC]: Custom graph dumping for vLLM-compile and depyf deprecation [1 comments, 2 participants]