MLIR
20.0.0git
|
This class handles the management of operation operands. More...
#include "mlir/IR/OperationSupport.h"
Public Member Functions | |
OperandStorage (Operation *owner, OpOperand *trailingOperands, ValueRange values) | |
~OperandStorage () | |
void | setOperands (Operation *owner, ValueRange values) |
Replace the operands contained in the storage with the ones provided in 'values'. More... | |
void | setOperands (Operation *owner, unsigned start, unsigned length, ValueRange operands) |
Replace the operands beginning at 'start' and ending at 'start' + 'length' with the ones provided in 'operands'. More... | |
void | eraseOperands (unsigned start, unsigned length) |
Erase the operands held by the storage within the given range. More... | |
void | eraseOperands (const BitVector &eraseIndices) |
Erase the operands held by the storage that have their corresponding bit set in eraseIndices . More... | |
MutableArrayRef< OpOperand > | getOperands () |
Get the operation operands held by the storage. More... | |
unsigned | size () |
Return the number of operands held in the storage. More... | |
This class handles the management of operation operands.
Operands are stored either in a trailing array, or a dynamically resizable vector.
Definition at line 1084 of file OperationSupport.h.
detail::OperandStorage::OperandStorage | ( | Operation * | owner, |
OpOperand * | trailingOperands, | ||
ValueRange | values | ||
) |
Definition at line 239 of file OperationSupport.cpp.
detail::OperandStorage::~OperandStorage | ( | ) |
Definition at line 248 of file OperationSupport.cpp.
void detail::OperandStorage::eraseOperands | ( | const BitVector & | eraseIndices | ) |
Erase the operands held by the storage that have their corresponding bit set in eraseIndices
.
Definition at line 313 of file OperationSupport.cpp.
void detail::OperandStorage::eraseOperands | ( | unsigned | start, |
unsigned | length | ||
) |
Erase the operands held by the storage within the given range.
Erase an operand held by the storage.
Definition at line 299 of file OperationSupport.cpp.
Referenced by mlir::Operation::eraseOperands().
|
inline |
Get the operation operands held by the storage.
Definition at line 1108 of file OperationSupport.h.
References size().
Referenced by mlir::Operation::getOpOperand(), and mlir::Operation::getOpOperands().
void detail::OperandStorage::setOperands | ( | Operation * | owner, |
unsigned | start, | ||
unsigned | length, | ||
ValueRange | operands | ||
) |
Replace the operands beginning at 'start' and ending at 'start' + 'length' with the ones provided in 'operands'.
'operands' may be smaller or larger than the range pointed to by 'start'+'length'.
Definition at line 268 of file OperationSupport.cpp.
void detail::OperandStorage::setOperands | ( | Operation * | owner, |
ValueRange | values | ||
) |
Replace the operands contained in the storage with the ones provided in 'values'.
Definition at line 259 of file OperationSupport.cpp.
Referenced by mlir::Operation::setOperands().
|
inline |
Return the number of operands held in the storage.
Definition at line 1111 of file OperationSupport.h.
Referenced by mlir::Operation::getNumOperands(), and getOperands().