areusch commented on a change in pull request #9243:
URL: https://github.com/apache/tvm/pull/9243#discussion_r746228180
##########
File path: python/tvm/runtime/module.py
##########
@@ -185,6 +185,11 @@ def type_key(self):
"""Get type key of the module."""
return _ffi_api.ModuleGetTypeKey(self)
+ @property
+ def format(self):
+ """Get the format of the module."""
+ return _ffi_api.ModuleGetFormat(self)
+
def get_source(self, fmt=""):
Review comment:
i think Module can sometimes have multiple formats (e.g. CUDA modules do
this I believe). what about leveraging this and modifying export_module to try
with fmt="c" here and if not also try fmt="cc"?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]