29 #ifndef TVM_DRIVER_DRIVER_API_H_ 30 #define TVM_DRIVER_DRIVER_API_H_ 42 #include <unordered_map> 43 #include <unordered_set> 94 bool simple_mode =
false);
109 const std::string& name,
110 const std::unordered_map<te::Tensor, tir::Buffer>& binds,
111 GlobalVarSupply global_var_supply,
bool simple_mode =
false);
125 const std::string& name,
126 const std::unordered_map<te::Tensor, tir::Buffer>& binds,
127 GlobalVarSupply global_var_supply,
bool simple_mode =
false);
141 const std::unordered_map<te::Tensor, tir::Buffer>& binds,
142 GlobalVarSupply global_var_supply);
150 TVM_DLL runtime::Module
build(
const IRModule& funcs,
const Target& target,
151 const Target& target_host);
162 TVM_DLL runtime::Module
build(
const Map<Target, IRModule>& input,
const Target& target_host);
173 TVM_DLL runtime::Module
build(
const Map<String, IRModule>& input,
const Target& target_host);
176 #endif // TVM_DRIVER_DRIVER_API_H_ IRModule LowerModule(IRModule mod, bool simple_mode=false)
Lower an IRModule (optimize with it with the pass list defined in CreatePassList) ...
transform::Sequential MixedModulePassManager(IRModule mixed_mod, Target target)
Configures and returns the composite Pass for the fused module (pre split) that contains device and h...
IRModule that holds the functions and type definitions.
runtime implementation for LibTorch/TorchScript.
Definition: analyzer.h:36
IRModule LowerSchedule(te::Schedule sch, const Array< te::Tensor > &args, const std::string &name, const std::unordered_map< te::Tensor, tir::Buffer > &binds, GlobalVarSupply global_var_supply, bool simple_mode=false)
Build an IRModule given a TE schedule, args and binds. This function also applies the lowering passes...
IRModule LowerPrimFunc(tvm::tir::PrimFunc func, const std::string &name, bool simple_mode=false)
Lower a primfunc and name (convert to IRModule, and optimize it with the pass list defined in CreateP...
GlobalVarSupply that can be used to generate unique.
Collection of Schedule pass functions.
Managed reference to PrimFuncNode.
Definition: function.h:145
transform::Sequential DeviceModulePassManager(IRModule mixed_mod, Target target)
Configures and returns the composite Pass for the device Target after device/host from mixed module...
Compilation target object.
tvm::PrimExpr mod(const tvm::PrimExpr &a, const tvm::PrimExpr &b)
Definition: broadcast.h:290
IRModuleFrame IRModule()
The IRModule declaration statement.
IRModule ScheduleToModule(te::Schedule sch, const Array< ObjectRef > &args, const std::string &name, const std::unordered_map< te::Tensor, tir::Buffer > &binds, GlobalVarSupply global_var_supply)
Create an IRModule out of a TE Schedule. It does not apply lowering passes. If you want to apply lowe...
Type-erased function used across TVM API.
runtime::Module build(const IRModule &funcs, const Target &target, const Target &target_host)
Build a device and host module for a specific target from an IRModule.
transform::Sequential HostModulePassManager(IRModule mixed_mod, Target target_host)
Configures and returns the composite Pass for the host Target after device/host from mixed module...
RAII wrapper function to enter and exit a context object similar to python's with syntax...