MLIR
15.0.0git
|
This class provides the implementation for an operation result. More...
#include "mlir/IR/Value.h"
Public Member Functions | |
Operation * | getOwner () const |
Returns the parent operation of this result. More... | |
unsigned | getResultNumber () const |
Returns the result number of this op result. More... | |
OpResultImpl * | getNextResultAtOffset (intptr_t offset) |
Returns the next operation result at offset after this result. More... | |
![]() | |
Type | getType () const |
Return the type of this value. More... | |
void | setType (Type type) |
Set the type of this value. More... | |
Kind | getKind () const |
Return the kind of this value. More... | |
![]() | |
~IRObjectWithUseList () | |
void | dropAllUses () |
Drop all uses of this object from their respective owners. More... | |
void | replaceAllUsesWith (ValueT &&newValue) |
Replace all uses of 'this' value with the new value, updating anything in the IR that uses 'this' to use the other value instead. More... | |
use_iterator | use_begin () const |
use_iterator | use_end () const |
use_range | getUses () const |
Returns a range of all uses, which is useful for iterating over all uses. More... | |
bool | hasOneUse () const |
Returns true if this value has exactly one use. More... | |
bool | use_empty () const |
Returns true if this value has no uses. More... | |
user_iterator | user_begin () const |
user_iterator | user_end () const |
user_range | getUsers () const |
Returns a range of all users. More... | |
Static Public Member Functions | |
static bool | classof (const ValueImpl *value) |
static unsigned | getMaxInlineResults () |
Returns the maximum number of results that can be stored inline. More... | |
Additional Inherited Members | |
![]() | |
enum | Kind { Kind::InlineOpResult = 0, Kind::OutOfLineOpResult = 6, Kind::BlockArgument = 7 } |
The enumeration represents the various different kinds of values the internal representation may take. More... | |
![]() | |
using | use_iterator = ValueUseIterator< OpOperand > |
using | use_range = iterator_range< use_iterator > |
using | user_iterator = ValueUserIterator< use_iterator, OpOperand > |
using | user_range = iterator_range< user_iterator > |
![]() | |
ValueImpl (Type type, Kind kind) | |
![]() | |
IRObjectWithUseList ()=default | |
OpOperand * | getFirstUse () const |
Return the first operand that is using this value, for use by custom use/def iterators. More... | |
![]() | |
llvm::PointerIntPair< Type, 3, Kind > | typeAndKind |
The type of this result and the kind. More... | |
This class provides the implementation for an operation result.
|
inlinestatic |
Definition at line 353 of file Value.h.
References mlir::detail::ValueImpl::BlockArgument, and mlir::detail::ValueImpl::getKind().
|
inlinestatic |
Returns the maximum number of results that can be stored inline.
Definition at line 371 of file Value.h.
References mlir::detail::ValueImpl::OutOfLineOpResult.
Referenced by getNextResultAtOffset(), getOwner(), and mlir::Operation::getUsers().
OpResultImpl * OpResultImpl::getNextResultAtOffset | ( | intptr_t | offset | ) |
Returns the next operation result at offset
after this result.
This method is useful when indexing the result storage of an operation, given that there is more than one kind of operation result (with the different kinds having different sizes) and that operations are stored in reverse order.
Definition at line 130 of file Value.cpp.
References getMaxInlineResults(), and min().
Operation * OpResultImpl::getOwner | ( | ) | const |
Returns the parent operation of this result.
Returns the parent operation of this trailing result.
Definition at line 101 of file Value.cpp.
References getMaxInlineResults(), and mlir::detail::OutOfLineOpResult::outOfLineIndex.
Referenced by mlir::BlockOperand::getOperandNumber(), and mlir::OpOperand::getOperandNumber().
|
inline |