

/*!
 * \file tvm/tsl/tir/buffer.h
 * \brief Symbolic n-dimensional array, to represent a memory buffer.
 */
#ifndef TVM_TSL_TIR_BUFFER_H_
#define TVM_TSL_TIR_BUFFER_H_

#include <tvm/ir/expr.h>
#include <tvm/node/container.h>
#include <tvm/tir/var.h>
#include <tvm/tir/buffer.h>

#include <string>

namespace tvm {
namespace tir {

class TslDataProducerNode : public Object {
 public:
  /*! \brief destructor. */
  virtual ~TslDataProducerNode() {}

  virtual Array<PrimExpr> GetUnionShape() const = 0;
  virtual Array<PrimExpr> GetElemShape() const = 0;


  virtual DataType GetDataType() const = 0;
  /*!
   * \brief Get the name hint of the data producer.
   * \return The data type.
   */
  virtual String GetNameHint() const = 0;

  bool SEqualReduce(const TslDataProducerNode* other, SEqualReducer equal) const {
    return this == other;
  }

  void SHashReduce(SHashReducer hash_reduce) const {}

  static constexpr const char* _type_key = "tir.TslDataProducer";
  static constexpr const bool _type_has_method_sequal_reduce = true;
  static constexpr const bool _type_has_method_shash_reduce = true;
  TVM_DECLARE_BASE_OBJECT_INFO(TslDataProducerNode, Object);
};

class TslDataProducer : public ObjectRef {
 public:
  TVM_DEFINE_OBJECT_REF_METHODS(TslDataProducer, ObjectRef, TslDataProducerNode);
};


}  // namespace tir
}  // namespace tvm
#endif  // TVM_TSL_TIR_BUFFER_H_
