From a05848e255614401e3813c656b8cfa94969952d4 Mon Sep 17 00:00:00 2001 From: Frederik Gossen Date: Wed, 29 Apr 2026 11:32:03 -0400 Subject: [PATCH] [Bugfix] Report compile time for in-memory cache hit path (#41023) Signed-off-by: Frederik Gossen --- vllm/compilation/backends.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/vllm/compilation/backends.py b/vllm/compilation/backends.py index 569b0ac080..353567fd96 100644 --- a/vllm/compilation/backends.py +++ b/vllm/compilation/backends.py @@ -279,6 +279,7 @@ class CompilerManager: compilation_counter.num_backend_compilations += 1 compiled_graph = None + handle = None # try to load from the cache compiled_graph = self.load(graph, example_inputs, graph_index, compile_range) @@ -357,7 +358,7 @@ class CompilerManager: ) except StopCompiling: assert cache_key is not None - return self.loaded_artifacts[cache_key] + compiled_graph = self.loaded_artifacts[cache_key] if cache_key is not None and compiled_graph is not None: self.loaded_artifacts[cache_key] = compiled_graph