Skip to content

Commit 6a6a463

Browse files
committed
notes for ptpu cuda-graph
1 parent ac8d66b commit 6a6a463

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

vllm_fl/compilation/graph.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,10 +207,12 @@ def __call__(self, *args, **kwargs):
207207
pass
208208

209209
graph_kwargs: dict[str, Any] = {"pool": self.graph_pool}
210+
# PTPU: pass the active stream explicitly. torch.ptpu.graph()
210211
if current_platform.device_type == "ptpu":
211212
graph_kwargs["stream"] = (
212213
current_platform.torch_device_fn.current_stream()
213214
)
215+
# FL-specific: use platform-agnostic graph capture
214216
with current_platform.torch_device_fn.graph(graph, **graph_kwargs):
215217
# `output` is managed by pytorch's cudagraph pool
216218
output = self.runnable(*args, **kwargs)

0 commit comments

Comments
 (0)