24 #ifndef TVM_TE_TENSOR_INTRIN_H_ 25 #define TVM_TE_TENSOR_INTRIN_H_ 75 v->Visit(
"name", &name);
77 v->Visit(
"inputs", &inputs);
78 v->Visit(
"buffers", &buffers);
79 v->Visit(
"scalar_params", &scalar_params);
80 v->Visit(
"body", &body);
81 v->Visit(
"reduce_init", &reduce_init);
82 v->Visit(
"reduce_update", &reduce_update);
85 static constexpr
const char*
_type_key =
"TensorIntrin";
120 v->Visit(
"intrin", &intrin);
121 v->Visit(
"tensors", &tensors);
122 v->Visit(
"regions", ®ions);
123 v->Visit(
"reduce_axis", &reduce_axis);
124 v->Visit(
"scalar_inputs", &scalar_inputs);
127 static constexpr
const char*
_type_key =
"TensorIntrinCall";
145 #endif // TVM_TE_TENSOR_INTRIN_H_ Array< Region > regions
regions of input tensors
Definition: tensor_intrin.h:108
Operation op
The operation this intrinsics is carrying out.
Definition: tensor_intrin.h:41
Node to represent a Tensor intrinsic operator.
Definition: tensor_intrin.h:36
void VisitAttrs(AttrVisitor *v)
Definition: tensor_intrin.h:74
TensorIntrinNode()
constructor
Definition: tensor_intrin.h:72
Array< IterVar > reduce_axis
IterVar on each reduction axis, if the intrin will use the reduce axis.
Definition: tensor_intrin.h:114
runtime implementation for LibTorch/TorchScript.
Definition: analyzer.h:36
Operation that produces tensors.
Definition: tensor.h:47
Array< Var > scalar_params
List of scalar variables, used in body. These placeholders will be bound to expressions passed in whe...
Definition: tensor_intrin.h:58
Stmt body
The normal statement to execute the intrinsic.
Definition: tensor_intrin.h:60
base class of all object containers.
Definition: object.h:167
Stmt reduce_init
Special statement for reduction op, can be None reset the value of output buffer to identity value...
Definition: tensor_intrin.h:65
Definition: tensor_intrin.h:101
Visitor class to get the attributes of an AST/IR node. The content is going to be called for each fie...
Definition: reflection.h:52
Managed reference to TensorIntrinCallNode.
Definition: tensor_intrin.h:135
TVM_DECLARE_FINAL_OBJECT_INFO(TensorIntrinNode, Object)
Managed reference to TensorIntrinNode.
Definition: tensor_intrin.h:93
void VisitAttrs(AttrVisitor *v)
Definition: tensor_intrin.h:119
Array, container representing a contiguous sequence of ObjectRefs.
Definition: array.h:289
Stmt reduce_update
Special statement for reduction op, can be None Reduce: do a reduction of current output buffer with ...
Definition: tensor_intrin.h:70
Array< Buffer > buffers
Symbolic buffers of each output/input tensor buffers[0:len(inputs)] are buffers of the inputs...
Definition: tensor_intrin.h:53
Container of all statements.
Definition: stmt.h:59
#define TVM_DEFINE_OBJECT_REF_METHODS(TypeName, ParentType, ObjectName)
Definition: object.h:713
IterVar reduce_axis(Range dom, std::string name="rv")
Create a new IterVar for reduction operations.
Base class of all object reference.
Definition: object.h:511
std::string name
The name of the intrinsic.
Definition: tensor_intrin.h:39
Symbolic n-dimensional array, to represent a memory buffer.
Array< PrimExpr > scalar_inputs
scalar expression inputs
Definition: tensor_intrin.h:117
Array< Tensor > inputs
List of inputs of operator, placeholder in postdfs order.
Definition: tensor_intrin.h:43
TensorIntrin intrin
the tensor intrinsic
Definition: tensor_intrin.h:104
static constexpr const char * _type_key
Definition: tensor_intrin.h:85
Array< Tensor > tensors
input tensors of the intrinsic
Definition: tensor_intrin.h:106