MLIR
16.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 707 of file OperationSupport.h.
detail::OperandStorage::OperandStorage | ( | Operation * | owner, |
OpOperand * | trailingOperands, | ||
ValueRange | values | ||
) |
Definition at line 221 of file OperationSupport.cpp.
detail::OperandStorage::~OperandStorage | ( | ) |
Definition at line 230 of file OperationSupport.cpp.
References getOperands().
Referenced by mlir::Operation::create().
Erase the operands held by the storage within the given range.
Erase an operand held by the storage.
Definition at line 281 of file OperationSupport.cpp.
References getOperands().
Referenced by setOperands().
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 295 of file OperationSupport.cpp.
References getOperands(), and max().
|
inline |
Get the operation operands held by the storage.
Definition at line 731 of file OperationSupport.h.
Referenced by eraseOperands(), setOperands(), and ~OperandStorage().
void detail::OperandStorage::setOperands | ( | Operation * | owner, |
ValueRange | values | ||
) |
Replace the operands contained in the storage with the ones provided in 'values'.
Definition at line 241 of file OperationSupport.cpp.
Referenced by mlir::Operation::setOperands(), and setOperands().
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 250 of file OperationSupport.cpp.
References eraseOperands(), getOperands(), setOperands(), and size().
|
inline |
Return the number of operands held in the storage.
Definition at line 734 of file OperationSupport.h.
Referenced by setOperands().