[Bugfix] Report compile time for in-memory cache hit path (#41023)

Signed-off-by: Frederik Gossen <frgossen@meta.com>
This commit is contained in:
Frederik Gossen
2026-04-29 15:32:03 +00:00
committed by GitHub
parent 51fda1ba44
commit a05848e255
+2 -1
View File
@@ -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