|
tvm
|
A more powerful visitor which enables defining arbitrary function signatures with type based dispatch on first argument. More...
#include <tvm/ir/error.h>#include <tvm/node/functor.h>#include <tvm/relay/adt.h>#include <tvm/relay/expr.h>#include <tvm/relay/function.h>#include <tvm/relay/op.h>#include <deque>#include <string>#include <unordered_map>#include <utility>#include <vector>Go to the source code of this file.
Classes | |
| class | tvm::relay::ExprFunctor< FType > |
| A dynamical functor that dispatches on in the first Expr argument. You can use this as a more powerful Visitor, since it allows you to define function signatures of Visit Function. More... | |
| class | tvm::relay::ExprFunctor< R(const Expr &n, Args...)> |
| class | tvm::relay::ExprVisitor |
| A simple visitor wrapper around ExprFunctor. Recursively visit the content. More... | |
| class | tvm::relay::ExprMutator |
| A wrapper around ExprFunctor which functionally updates the AST. More... | |
| class | tvm::relay::MixedModeVisitor |
| A wrapper around ExprVisitor which traverses the Dataflow Normal AST. More... | |
| class | tvm::relay::MixedModeMutator |
| Non-recursive DFS Graph Traversal for Custom Rewriting Passes. More... | |
| class | tvm::relay::ExprRewriter |
| A non-iterating Expression Rewriter. More... | |
| struct | tvm::relay::v_info |
| A struct to keep info of traversed expr in ExpandDataflow function. More... | |
Namespaces | |
| tvm | |
| runtime implementation for LibTorch/TorchScript. | |
| tvm::relay | |
| Relay: a high level functional IR for TVM. | |
Macros | |
| #define | EXPR_FUNCTOR_DEFAULT { return VisitExprDefault_(op, std::forward<Args>(args)...); } |
| #define | RELAY_EXPR_FUNCTOR_DISPATCH(OP) |
| #define | RELAY_EXPR_REWRITER_DISPATCH(OP) |
| #define | EXPR_REWRITER_REWRITE_DEFAULT { return post; } |
Functions | |
| Expr | tvm::relay::PostOrderRewrite (const Expr &expr, ExprRewriter *rewriter) |
| Non-recursive DFS Graph Traversal for Custom Rewriting Passes. More... | |
| void | tvm::relay::PostOrderVisit (const Expr &node, std::function< void(const Expr &)> fvisit) |
| recursively visit the ir in post DFS order node, apply fvisit Each node is guaranteed to be visited only once. More... | |
| template<typename FCheckVisited , typename FVisitLeaf , typename FExpandExpr > | |
| void | tvm::relay::ExpandDataflow (Expr expr, FCheckVisited fcheck_visited, FVisitLeaf fvisit_leaf, FExpandExpr fexpand_expr) |
| A function to iteratively traverse dataflow regions of a graph. More... | |
| template<typename FCheckVisited , typename FVisitLeaf > | |
| void | tvm::relay::ExpandDataflow (Expr expr, FCheckVisited fcheck_visited, FVisitLeaf fvisit_leaf) |
| void | tvm::relay::ExpandANormalForm (const LetNode *op, std::function< void(const LetNode *)> pre_visit, std::function< void(const LetNode *)> post_visit) |
A more powerful visitor which enables defining arbitrary function signatures with type based dispatch on first argument.
| #define EXPR_FUNCTOR_DEFAULT { return VisitExprDefault_(op, std::forward<Args>(args)...); } |
| #define EXPR_REWRITER_REWRITE_DEFAULT { return post; } |
| #define RELAY_EXPR_FUNCTOR_DISPATCH | ( | OP | ) |
| #define RELAY_EXPR_REWRITER_DISPATCH | ( | OP | ) |
1.8.13