MLIR
20.0.0git
|
A reference to a value, suitable for use as an operand of an operation. More...
#include "mlir/IR/UseDefLists.h"
Public Member Functions | |
IROperand (Operation *owner) | |
IROperand (Operation *owner, IRValueT value) | |
IROperand (IROperand &&other) | |
We support a move constructor so IROperand's can be in vectors, but this shouldn't be used by general clients. More... | |
IROperand & | operator= (IROperand &&other) |
bool | operator== (const IROperand< DerivedT, IRValueT > &other) const |
Two operands are equal if they have the same owner and the same operand number. More... | |
bool | operator!= (const IROperand< DerivedT, IRValueT > &other) const |
IRValueT | get () const |
Return the current value being used by this operand. More... | |
void | set (IRValueT newValue) |
Set the current value being used by this operand. More... | |
bool | is (IRValueT other) const |
Returns true if this operand contains the given value. More... | |
void | drop () |
Remove this use of the operand. More... | |
Public Member Functions inherited from mlir::detail::IROperandBase | |
Operation * | getOwner () const |
Return the owner of this operand. More... | |
IROperandBase * | getNextOperandUsingThisValue () |
Return the next operand on the use-list of the value we are referring to. More... | |
void | initChainWithUse (IROperandBase **self) |
Initialize the use-def chain by setting the back address to self and nextUse to nullptr. More... | |
void | linkTo (IROperandBase *next) |
Link the current node to next. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from mlir::detail::IROperandBase | |
IROperandBase (Operation *owner) | |
IROperandBase (IROperandBase &&other) | |
IROperandBase & | operator= (IROperandBase &&other) |
IROperandBase (const IROperandBase &use)=delete | |
Operands are not copyable or assignable. More... | |
IROperandBase & | operator= (const IROperandBase &use)=delete |
~IROperandBase () | |
void | drop () |
Remove this use of the operand. More... | |
void | removeFromCurrent () |
Remove this operand from the current use list. More... | |
template<typename UseListT > | |
void | insertInto (UseListT *useList) |
Insert this operand into the given use list. More... | |
Protected Attributes inherited from mlir::detail::IROperandBase | |
IROperandBase * | nextUse = nullptr |
The next operand in the use-chain. More... | |
IROperandBase ** | back = nullptr |
This points to the previous link in the use-chain. More... | |
A reference to a value, suitable for use as an operand of an operation.
IRValueT is the root type to use for values this tracks. Derived operand types are expected to provide the following:
Definition at line 127 of file UseDefLists.h.
|
inline |
Definition at line 129 of file UseDefLists.h.
|
inline |
Definition at line 130 of file UseDefLists.h.
|
inline |
We support a move constructor so IROperand's can be in vectors, but this shouldn't be used by general clients.
Definition at line 137 of file UseDefLists.h.
|
inline |
Remove this use of the operand.
Definition at line 175 of file UseDefLists.h.
References mlir::detail::IROperandBase::drop().
|
inline |
Return the current value being used by this operand.
Definition at line 160 of file UseDefLists.h.
Referenced by areBinOpsSwapped(), mlir::linalg::areElementwiseOpsFusable(), mlir::bufferization::OneShotAnalysisState::bufferizeInPlace(), buildPackingLoopNestImpl(), canBeHoisted(), cloneAndFuseFirstUse(), computePaddedShape(), fuse(), mlir::linalg::fuseElementwiseOps(), mlir::linalg::fuseProducerOfTensor(), genBuffers(), genConstantDenseAddressFromLevel(), generateFusedElementwiseOpRegion(), genExpand(), genIndex(), genInsertionLoad(), genInvariants(), genResult(), genSubscript(), genTensorLoad(), getAllTidLvlsInLatPoints(), getCollapsedOpOperand(), mlir::mesh::getMeshSharding(), mlir::Operation::getOperand(), getSharding(), getUntiledProducerFromSliceSource(), getUnusedOutOperand(), mlir::getUsedValuesDefinedAbove(), hasNonTrivialAffineOnSparseOut(), mlir::linalg::hoistRedundantVectorBroadcasts(), hoistSubsetAtIterArg(), mlir::sparse_tensor::CodegenEnv::isAdmissibleTensorExp(), mlir::linalg::isaFillOpInterface(), isMaterializing(), isSparseTensor(), isValueUsePotentialConsumer(), mlir::mesh::maybeInsertSourceShardingAnnotation(), mlir::mesh::maybeInsertTargetShardingAnnotation(), numEnclosingInvariantLoops(), mlir::linalg::padAndHoistLinalgOp(), padOperandToSmallestStaticBoundingBox(), relinkBranch(), mlir::scf::replaceAndCastForOpIterArg(), setInPlaceOpOperand(), mlir::sparse_tensor::CodegenEnv::startEmit(), mlir::scf::tileAndFuseConsumerOfSlice(), tileAndFuseFirstExtractUseThroughContainingOpBlockArgument(), transposeOneLinalgOperandAndReplace(), mlir::linalg::detail::verifyStructuredOpInterface(), verifyYield(), mlir::dataflow::LivenessAnalysis::visitBranchOperand(), and mlir::dataflow::LivenessAnalysis::visitCallOperand().
|
inline |
Returns true if this operand contains the given value.
Definition at line 172 of file UseDefLists.h.
|
inline |
Definition at line 155 of file UseDefLists.h.
|
inline |
Definition at line 140 of file UseDefLists.h.
References mlir::detail::IROperandBase::operator=().
|
inline |
Two operands are equal if they have the same owner and the same operand number.
They are stored inside of ops, so it is valid to compare their pointers to determine equality.
Definition at line 152 of file UseDefLists.h.
|
inline |
Set the current value being used by this operand.
Definition at line 163 of file UseDefLists.h.
References mlir::detail::IROperandBase::removeFromCurrent().
Referenced by mlir::linalg::fuseProducerOfTensor(), mlir::Operation::setOperand(), and mlir::scf::tileAndFuseConsumerOfSlice().