LLVM 22.0.0git
|
A Use represents the edge between a Value definition and its users. More...
#include "llvm/IR/Use.h"
Public Member Functions | |
Use (const Use &U)=delete | |
LLVM_ABI void | swap (Use &RHS) |
Provide a fast substitute to std::swap<Use> that also works with less standard-compliant compilers. | |
operator Value * () const | |
Value * | get () const |
User * | getUser () const |
Returns the User that contains this Use. | |
LLVM_ABI void | set (Value *Val) |
LLVM_ABI Value * | operator= (Value *RHS) |
LLVM_ABI const Use & | operator= (const Use &RHS) |
Value * | operator-> () |
const Value * | operator-> () const |
Use * | getNext () const |
LLVM_ABI unsigned | getOperandNo () const |
Return the operand # of this use in its User. | |
Static Public Member Functions | |
static LLVM_ABI void | zap (Use *Start, const Use *Stop, bool del=false) |
Destroys Use operands when the number of operands of a User changes. | |
Friends | |
class | Value |
class | User |
A Use represents the edge between a Value definition and its users.
This is notionally a two-dimensional linked list. It supports traversing all of the uses for a particular value definition. It also supports jumping directly to the used value when we arrive from the User's operands, and jumping directly to the User when we arrive from the Value's uses.
|
inline |
Definition at line 55 of file Use.h.
Referenced by llvm::simplify_type< const Use >::getSimplifiedValue(), llvm::simplify_type< Use >::getSimplifiedValue(), and operandWithNewAddressSpaceOrCreatePoison().
unsigned llvm::Use::getOperandNo | ( | ) | const |
Return the operand # of this use in its User.
Definition at line 35 of file Use.cpp.
Referenced by allUsesTruncate(), CombineBaseUpdate(), combineOp_VLToVWOp_VL(), combineVSelectToBLENDV(), dominatesAllUsesOf(), llvm::InstCombinerImpl::foldShuffledIntrinsicOperands(), llvm::RISCVDAGToDAGISel::hasAllNBitUsers(), llvm::SITargetLowering::hasMemSDNodeUser(), hasNonFlagsUse(), isCompatibleReplacement(), and llvm::propagatesPoison().
|
inline |
Returns the User that contains this Use.
For an instruction operand, for example, this will return the instruction.
Definition at line 61 of file Use.h.
Referenced by allUsesTruncate(), CombineBaseUpdate(), combineOp_VLToVWOp_VL(), CombineVLDDUP(), combineVSelectToBLENDV(), llvm::MemorySSA::dominates(), eliminateSwiftErrorAlloca(), ExtendUsesToFormExtLoad(), getCaseResults(), llvm::RISCVDAGToDAGISel::hasAllNBitUsers(), llvm::SITargetLowering::hasMemSDNodeUser(), hasNonFlagsUse(), isF128MovedToParts(), isI128MovedToParts(), operandWithNewAddressSpaceOrCreatePoison(), OptimizeGlobalAddressOfAllocation(), passingValueIsAlwaysUndefined(), performMemPairCombine(), PerformMVEVLDCombine(), performNEONPostLDSTCombine(), performPostLD1Combine(), performSTORECombine(), llvm::propagatesPoison(), llvm::SelectionDAG::ReplaceAllUsesOfValuesWith(), replaceAllUsesOfWithIn(), llvm::X86TargetLowering::shouldReduceLoadWidth(), usePartialVectorLoads(), and llvm::Value::Value().
|
inline |
Definition at line 905 of file Value.h.
Referenced by llvm::SDNode::DropOperands(), eliminateSwiftErrorAlloca(), llvm::SITargetLowering::emitExpandAtomicAddrSpacePredicate(), llvm::SelectionDAG::MorphNodeTo(), operator=(), OptimizeGlobalAddressOfAllocation(), llvm::SwitchInst::removeCase(), llvm::SelectionDAG::RemoveDeadNodes(), llvm::IndirectBrInst::removeDestination(), llvm::SelectionDAG::ReplaceAllUsesOfValuesWith(), llvm::SelectionDAG::ReplaceAllUsesOfValueWith(), llvm::SelectionDAG::ReplaceAllUsesWith(), and sinkLastInstruction().
void llvm::Use::swap | ( | Use & | RHS | ) |
Provide a fast substitute to std::swap<Use> that also works with less standard-compliant compilers.
Definition at line 14 of file Use.cpp.
Referenced by Use().