Class StreamWriteOp

Inheritance Relationships

Base Type

  • public mlir::Op< StreamWriteOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::AtLeastNOperands< 2 >::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait >

Class Documentation

class StreamWriteOp : public mlir::Op<StreamWriteOp, ::mlir::OpTrait::ZeroRegions, ::mlir::OpTrait::ZeroResults, ::mlir::OpTrait::ZeroSuccessors, ::mlir::OpTrait::AtLeastNOperands<2>::Impl, ::mlir::OpTrait::OpInvariants, ::mlir::MemoryEffectOpInterface::Trait>

Public Types

using Adaptor = StreamWriteOpAdaptor
template<typename RangeT>
using GenericAdaptor = StreamWriteOpGenericAdaptor<RangeT>
using FoldAdaptor = GenericAdaptor<::llvm::ArrayRef<::mlir::Attribute>>
using Properties = FoldAdaptor::Properties

Public Functions

inline ::llvm::ArrayRef<::llvm::StringRef> getAttributeNames()
std::pair<unsigned, unsigned> getODSOperandIndexAndLength(unsigned index)
inline ::mlir::Operation::operand_range getODSOperands(unsigned index)
inline ::mlir::TypedValue<::mlir::Type> getData()
inline ::mlir::TypedValue<::mlir::Type> getStream()
inline ::mlir::Operation::operand_range getIndices()
inline ::mlir::OpOperand &getDataMutable()
inline ::mlir::OpOperand &getStreamMutable()
::mlir::MutableOperandRange getIndicesMutable()
inline std::pair<unsigned, unsigned> getODSResultIndexAndLength(unsigned index)
inline ::mlir::Operation::result_range getODSResults(unsigned index)
::llvm::LogicalResult verifyInvariantsImpl()
::llvm::LogicalResult verifyInvariants()
::llvm::LogicalResult verify()

Verifies an emithls::StreamWriteOp has consistent stream and data types.

When the operand is an ArrayType, its element must be a StreamType and the number of indices must match the array rank. For a plain StreamType no indices are allowed. In both cases the stream’s element type must equal the type of the data operand.

void print(::mlir::OpAsmPrinter &_odsPrinter)
inline void getEffects(SmallVectorImpl<SideEffects::EffectInstance<MemoryEffects::Effect>> &effects)

Public Static Functions

static inline constexpr ::llvm::StringLiteral getOperationName()
static ::llvm::LogicalResult setPropertiesFromAttr(Properties &prop, ::mlir::Attribute attr, ::llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
static ::mlir::Attribute getPropertiesAsAttr(::mlir::MLIRContext *ctx, const Properties &prop)
static llvm::hash_code computePropertiesHash(const Properties &prop)
static std::optional<mlir::Attribute> getInherentAttr(::mlir::MLIRContext *ctx, const Properties &prop, llvm::StringRef name)
static void setInherentAttr(Properties &prop, llvm::StringRef name, mlir::Attribute value)
static void populateInherentAttrs(::mlir::MLIRContext *ctx, const Properties &prop, ::mlir::NamedAttrList &attrs)
static ::llvm::LogicalResult verifyInherentAttrs(::mlir::OperationName opName, ::mlir::NamedAttrList &attrs, llvm::function_ref<::mlir::InFlightDiagnostic()> emitError)
static void build(::mlir::OpBuilder &odsBuilder, ::mlir::OperationState &odsState, Value data, Value stream, ValueRange indices)

Builds an emithls::StreamWriteOp.

Parameters:
  • data – The value to write into the stream.

  • stream – The stream (or array of streams) to write to.

  • indices – Index operands when stream is an array of streams; empty for a plain stream.

static StreamWriteOp create(::mlir::OpBuilder &builder, ::mlir::Location location, Value data, Value stream, ValueRange indices)
static StreamWriteOp create(::mlir::ImplicitLocOpBuilder &builder, Value data, Value stream, ValueRange indices)
static ::mlir::ParseResult parse(::mlir::OpAsmParser &parser, ::mlir::OperationState &result)

Public Static Attributes

static constexpr int odsIndex_data = 0
static constexpr int odsIndex_stream = 1
static constexpr int odsIndex_indices = 2