tvm
Public Member Functions | Static Public Attributes | List of all members
tvm::tir::DataProducerNode Class Referenceabstract

Base node for data producers. More...

#include <buffer.h>

Inheritance diagram for tvm::tir::DataProducerNode:
Collaboration diagram for tvm::tir::DataProducerNode:

Public Member Functions

virtual ~DataProducerNode ()
 destructor. More...
 
virtual Array< PrimExprGetShape () const =0
 Get the shape of the result. More...
 
virtual DataType GetDataType () const =0
 Get the data type of the result. More...
 
virtual String GetNameHint () const =0
 Get the name hint of the data producer. More...
 
 TVM_DECLARE_BASE_OBJECT_INFO (DataProducerNode, PrimExprConvertibleNode)
 
- Public Member Functions inherited from tvm::PrimExprConvertibleNode
virtual ~PrimExprConvertibleNode ()
 
virtual PrimExpr ToPrimExpr () const =0
 
 TVM_DECLARE_BASE_OBJECT_INFO (PrimExprConvertibleNode, Object)
 

Static Public Attributes

static constexpr const char * _type_key = "tir.DataProducer"
 
- Static Public Attributes inherited from tvm::PrimExprConvertibleNode
static constexpr const char * _type_key = "ir.PrimExprConvertible"
 

Detailed Description

Base node for data producers.

A DataProducer stores necessary information(e.g. a tensor expression) to produce a multi-dimensional array. The stored information is opaque to the TIR. DataProducer can appear in high-level DSLs that are built on top of the TIR.

A valid TIR PrimFunc should not contain any DataProducer, high level DSLs should lower all DataProducers to Buffers before TIR transformations.

See also
tvm::te::Tensor

Constructor & Destructor Documentation

◆ ~DataProducerNode()

virtual tvm::tir::DataProducerNode::~DataProducerNode ( )
inlinevirtual

destructor.

Member Function Documentation

◆ GetDataType()

virtual DataType tvm::tir::DataProducerNode::GetDataType ( ) const
pure virtual

Get the data type of the result.

Returns
The data type.

Implemented in tvm::te::TensorNode.

◆ GetNameHint()

virtual String tvm::tir::DataProducerNode::GetNameHint ( ) const
pure virtual

Get the name hint of the data producer.

Returns
The data type.

Implemented in tvm::te::TensorNode.

◆ GetShape()

virtual Array<PrimExpr> tvm::tir::DataProducerNode::GetShape ( ) const
pure virtual

Get the shape of the result.

Returns
The shape.

Implemented in tvm::te::TensorNode.

◆ TVM_DECLARE_BASE_OBJECT_INFO()

tvm::tir::DataProducerNode::TVM_DECLARE_BASE_OBJECT_INFO ( DataProducerNode  ,
PrimExprConvertibleNode   
)

Member Data Documentation

◆ _type_key

constexpr const char* tvm::tir::DataProducerNode::_type_key = "tir.DataProducer"
staticconstexpr

The documentation for this class was generated from the following file: