Skip to content

Commit

Permalink
[AOT]Aot module post-test error workaround (#13685)
Browse files Browse the repository at this point in the history
The deletion of the AotModule python object results in the device shutting down RPC too early, causing an assertion in the DSP. This is a temporary workaround while this is still being investigated. The workaround is to keep a reference to the AotModule object in the HexagonSession object, so it stays until the session has been shut down.
  • Loading branch information
janetsc authored Jan 11, 2023
1 parent d979949 commit bf4fedd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions python/tvm/contrib/hexagon/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,9 @@ def get_aot_executor(
GraphModule :
Runtime graph module that can be used to execute the graph.
"""
aot_mod = self.load_module(module_file)
return tvm.runtime.executor.AotModule(aot_mod["default"](self.device))
# Temporary workaround for https://github.com/apache/tvm/issues/13741
self.aot_mod = self.load_module(module_file)
return tvm.runtime.executor.AotModule(self.aot_mod["default"](self.device))

def get_graph_debug_executor(
self,
Expand Down

0 comments on commit bf4fedd

Please sign in to comment.