vllm.compilation.vllm_inductor_pass ¶
PrinterInductorPass ¶
Bases: VllmInductorPass
Source code in vllm/compilation/vllm_inductor_pass.py
VllmInductorPass ¶
Bases: InductorPass
An inductor pass with access to vLLM PassConfig. It provides timing, logging, and dumping utilities.
Source code in vllm/compilation/vllm_inductor_pass.py
VllmPatternMatcherPass ¶
Bases: VllmInductorPass
A VllmInductorPass that uses the Inductor pattern matcher. Its main use is providing the dump_patterns utility that dumps the Inductor pattern matcher patterns into a file, which greatly aids debugging.
TODO(luka) move more utilities to this pass.
Source code in vllm/compilation/vllm_inductor_pass.py
_OP_OVERLOAD_PATTERN class-attribute
¶
matched_count class-attribute
instance-attribute
¶
matched_count: int = 0
The number of matched patterns in the pass.
_replace_op_overloads ¶
Replace
dump_patterns ¶
dump_patterns(
config: VllmConfig, pm_pass: PatternMatcherPass
)
If debug dumping is enabled, dump the Inductor pattern-matcher patterns into the debug_dump_path folder next to the dumped fx graphs.
This method does its best to print something that looks like Python code for easier debugging and potentially navigation. If any errors appear in the output, please add to this method.
TODO(luka): use pattern object to manually produce pattern graph