|
tvm
|
namespace for target translation and codegen. More...
Functions | |
| ffi::Module | Build (IRModule mod, Target target) |
| Build a module from array of lowered function. More... | |
| std::string | SerializeModuleToBytes (const ffi::Module &mod, bool export_dso=true) |
| Serialize runtime module including its submodules. More... | |
| ffi::Module | DeserializeModuleFromBytes (std::string blob) |
| Deserialize runtime module including its submodules. More... | |
| std::string | PackImportsToC (const ffi::Module &m, bool system_lib, const std::string &c_symbol_prefix="") |
| Pack imported device library to a C file. Compile the C file and link with the host library will allow the DSO loader to automatically discover and import the dependency from the shared library. More... | |
| ffi::Module | PackImportsToLLVM (const ffi::Module &m, bool system_lib, const std::string &target_triple, const std::string &c_symbol_prefix="") |
| Pack imported device library to a LLVM module. Compile the LLVM module and link with the host library will allow the DSO loader to automatically discover and import the dependency from the shared library. More... | |
namespace for target translation and codegen.
Build a module from array of lowered function.
| mod | The Module to be built |
| target | The target to be built. |
| ffi::Module tvm::codegen::DeserializeModuleFromBytes | ( | std::string | blob | ) |
Deserialize runtime module including its submodules.
| blob | byte stream, which are generated by SerializeModuleToBytes. |
| std::string tvm::codegen::PackImportsToC | ( | const ffi::Module & | m, |
| bool | system_lib, | ||
| const std::string & | c_symbol_prefix = "" |
||
| ) |
Pack imported device library to a C file. Compile the C file and link with the host library will allow the DSO loader to automatically discover and import the dependency from the shared library.
| m | The host module with the imports. |
| system_lib | Whether expose as system library. |
| c_symbol_prefix | Optional symbol prefix of the blob symbol. |
| ffi::Module tvm::codegen::PackImportsToLLVM | ( | const ffi::Module & | m, |
| bool | system_lib, | ||
| const std::string & | target_triple, | ||
| const std::string & | c_symbol_prefix = "" |
||
| ) |
Pack imported device library to a LLVM module. Compile the LLVM module and link with the host library will allow the DSO loader to automatically discover and import the dependency from the shared library.
| m | The host module with the imports. |
| system_lib | Whether expose as system library. |
| target_triple | LLVM target triple |
| c_symbol_prefix | Optional symbol prefix of the blob symbol. |
| std::string tvm::codegen::SerializeModuleToBytes | ( | const ffi::Module & | mod, |
| bool | export_dso = true |
||
| ) |
Serialize runtime module including its submodules.
| mod | The runtime module to serialize including its import tree. |
| export_dso | By default, include the info of DSOExportable modules. If disabled, an error will be raised when encountering DSO modules. |