# torch.compile integration

**URL:** https://discuss.vllm.ai/c/torch-compile-integration/30.md

[Latest](https://discuss.vllm.ai/latest.md) · [Categories](https://discuss.vllm.ai/categories.md)

---

## [About the torch.compile integration category](https://discuss.vllm.ai/t/about-the-torch-compile-integration-category/252)

<div class="topic-metadata">

**Author:** [@youkaichao](https://discuss.vllm.ai/u/youkaichao)\
**Replies:** 0

</div>

---

## [Does setting TRITON\_CACHE\_DIR break the bundled (AOT) static-autotuner cubin restore?](https://discuss.vllm.ai/t/does-setting-triton-cache-dir-break-the-bundled-aot-static-autotuner-cubin-restore/2965)

<div class="topic-metadata">

**Author:** [@kaiste99](https://discuss.vllm.ai/u/kaiste99)\
**Replies:** 1\
**Last updated:** [September 11, 2026, 5:04pm UTC](https://discuss.vllm.ai/t/does-setting-triton-cache-dir-break-the-bundled-aot-static-autotuner-cubin-restore/2965 "2026-09-11T17:04:15Z")

</div>

Context vLLM 0.29.0 (pip install, not Docker), torch 2.13.0 NVIDIA GB10 (DGX Spark), single device, driver 580.173.02 / CUDA 13.0 Qwen/Qwen3.6-35B-A3B-FP8, --max-cudagraph-capture-size 8192, --max-model-len 262144, --…

---

## [How can I choose custom backend in torch.compile](https://discuss.vllm.ai/t/how-can-i-choose-custom-backend-in-torch-compile/2889)

<div class="topic-metadata">

**Author:** [@PrimedErwin](https://discuss.vllm.ai/u/PrimedErwin)\
**Replies:** 3\
**Last updated:** [August 18, 2026, 9:04am UTC](https://discuss.vllm.ai/t/how-can-i-choose-custom-backend-in-torch-compile/2889 "2026-08-18T09:04:21Z")

</div>

in vllm/compilation/backends.py, function make\_compiler() says that we can “Using custom backend:”, but how can I use my own compiler backend? I also noticed that wrapper.py in the same dir may help. What exactly should …

---

## [Questions on piecewise torch compile design](https://discuss.vllm.ai/t/questions-on-piecewise-torch-compile-design/589)

<div class="topic-metadata">

**Author:** [@Juelianqvq](https://discuss.vllm.ai/u/Juelianqvq)\
**Replies:** 50\
**Last updated:** [November 5, 2025, 3:32am UTC](https://discuss.vllm.ai/t/questions-on-piecewise-torch-compile-design/589 "2025-11-05T03:32:14Z")

</div>

Hi, vLLM Team, I’m a student and interested in v1’s feature especially on piecewise torch compile mechanism. Though have reviewed your codes in a few days and try to improve my understanding, I was puzzled on some detail…

---

## [Who ensures inputs for middle piecewise graph are static buffers?](https://discuss.vllm.ai/t/who-ensures-inputs-for-middle-piecewise-graph-are-static-buffers/1548)

<div class="topic-metadata">

**Author:** [@gx16377](https://discuss.vllm.ai/u/gx16377)\
**Replies:** 1\
**Last updated:** [September 4, 2025, 1:34am UTC](https://discuss.vllm.ai/t/who-ensures-inputs-for-middle-piecewise-graph-are-static-buffers/1548 "2025-09-04T01:34:10Z")

</div>

Hi, vLLM Team, I’m curious about piecewise graph mechanism. I just run into a question, CUDAGraphWrapper(or previous CudaPiecewiseBackend) needs caller ensure input buffers are same address during capture and replay, bu…

---

## [Some questions about torch.compile](https://discuss.vllm.ai/t/some-questions-about-torch-compile/1412)

<div class="topic-metadata">

**Author:** [@wyzqwq](https://discuss.vllm.ai/u/wyzqwq)\
**Replies:** 1\
**Last updated:** [August 17, 2025, 12:23am UTC](https://discuss.vllm.ai/t/some-questions-about-torch-compile/1412 "2025-08-17T00:23:31Z")

</div>

Hi vLLM team, The article “PyTorch + vLLM = :heart:” shows 1.05x–1.9x speedups with torch.compile for models like Llama4/Qwen3/Gemma3. To better understand: What benchmark setup (hardware, input shape) was used? W…

---

## [How vllm v1 enable compile as default feature](https://discuss.vllm.ai/t/how-vllm-v1-enable-compile-as-default-feature/988)

<div class="topic-metadata">

**Author:** [@Yepgang](https://discuss.vllm.ai/u/Yepgang)\
**Replies:** 5\
**Last updated:** [July 2, 2025, 2:29am UTC](https://discuss.vllm.ai/t/how-vllm-v1-enable-compile-as-default-feature/988 "2025-07-02T02:29:15Z")

</div>

我在runner中，没看到load模型后，有显式的调用torch.compile接口
