24 #ifndef TVM_RELAY_TRANSFORM_H_ 25 #define TVM_RELAY_TRANSFORM_H_ 435 TVM_DLL
Pass EtaExpand(
bool expand_constructor,
bool expand_global_var);
617 std::function<
Expr(
const Expr&)> fmulti_ref_trigger =
nullptr);
633 std::function<
Expr(
const Expr&)> fmulti_ref_trigger =
nullptr);
689 #endif // TVM_RELAY_TRANSFORM_H_
Managed reference class to CompilationConfig.
Definition: compilation_config.h:183
Expr ForwardRewrite(const Expr &expr, const String &rewrite_map_attr_name, std::function< ObjectRef(const Call &)> fcontext=nullptr, std::function< Expr(const Expr &)> fmulti_ref_trigger=nullptr)
Apply rewrite rules to rewrite the expr in post DFS order. This function is used as a helper function...
Function UnCPS(const Function &f)
Remove the continuation argument of a CPS function.
Managed reference to FunctionNode.
Definition: function.h:105
A compile time representation for where data is to be stored at runtime, and how to compile code to c...
Relay expression language.
runtime implementation for LibTorch/TorchScript.
Definition: analyzer.h:36
The Expr and related elements in DataFlow construction.
Managed reference class to VirtualDeviceNode.
Definition: virtual_device.h:261
Expr Bind(const Expr &expr, const tvm::Map< Var, Expr > &binds)
Bind the free variables to a Relay expression. This is a helper function usually called by other pass...
Expr DeDup(const Expr &e)
Deduplicate the bound variables and type variables in the expression.
Array, container representing a contiguous sequence of ObjectRefs.
Definition: array.h:270
PassContext that is used to configure the pass behavior.
Definition: transform.h:154
A helper class to collect all the targets in canonical form necessary for compilation.
Reference to string objects.
Definition: string.h:124
Please refer to TypedPackedFunc<R(Args..)>.
Definition: packed_func.h:60
Managed reference to RelayExprNode.
Definition: expr.h:217
Base class of all object reference.
Definition: object.h:511
Function SubstituteBoundVars(const Function &func, const tvm::Map< Var, Expr > &binds)
Substitute variables with new variables (including function parameters) in a function. This is a helper function usually called by other pass functions to help optimizations. Expects all values in the bind map to be Vars.
tvm::RelayExpr Expr
Definition: expr.h:54
Managed reference class to IRModuleNode.
Definition: module.h:360
PassContextNode contains the information that a pass can rely on, such as analysis results...
Definition: transform.h:78
Compilation target object.
Map container of NodeRef->NodeRef in DSL graph. Map implements copy on write semantics, which means map is mutable but copy will happen when array is referenced in more than two places.
Definition: map.h:1268
Packed function is a type-erased function. The arguments are passed by packed format.
Definition: packed_func.h:138
Managed reference to TypeNode.
Definition: type.h:93
tvm::PrimExpr mod(const tvm::PrimExpr &a, const tvm::PrimExpr &b)
Definition: broadcast.h:290
Primitive operators(builtin intrinsics).