15 #ifndef LLVM_ANALYSIS_LAZYVALUEINFO_H
16 #define LLVM_ANALYSIS_LAZYVALUEINFO_H
22 class AssumptionCache;
28 class TargetLibraryInfo;
38 void *PImpl =
nullptr;
46 : AC(AC_),
DL(DL_), TLI(TLI_), DT(DT_) {}
48 : AC(Arg.AC),
DL(Arg.
DL), TLI(Arg.TLI), DT(Arg.DT), PImpl(Arg.PImpl) {
145 assert(!Info.PImpl &&
"releaseMemory not called");
LazyValueInfo(AssumptionCache *AC_, const DataLayout *DL_, TargetLibraryInfo *TLI_, DominatorTree *DT_)
A parsed version of the target data layout string in and methods for querying it. ...
static PassRegistry * getPassRegistry()
getPassRegistry - Access the global registry object, which is automatically initialized at applicatio...
ConstantRange getConstantRange(Value *V, BasicBlock *BB, Instruction *CxtI=nullptr)
Return the ConstantRange constraint that is known to hold for the specified value at the end of the s...
Wrapper around LazyValueInfo.
LazyValueInfoWrapperPass()
void initializeLazyValueInfoWrapperPassPass(PassRegistry &)
~LazyValueInfoWrapperPass() override
A cache of .assume calls within a function.
Constant * getConstant(Value *V, BasicBlock *BB, Instruction *CxtI=nullptr)
Determine whether the specified value is known to be a constant at the end of the specified block...
void getAnalysisUsage(AnalysisUsage &AU) const override
getAnalysisUsage - This function should be overriden by passes that need analysis information to do t...
Result run(Function &F, FunctionAnalysisManager &FAM)
Concrete subclass of DominatorTreeBase that is used to compute a normal dominator tree...
A set of analyses that are preserved following a run of a transformation pass.
Constant * getConstantOnEdge(Value *V, BasicBlock *FromBB, BasicBlock *ToBB, Instruction *CxtI=nullptr)
Determine whether the specified value is known to be a constant on the specified edge.
LLVM Basic Block Representation.
This is an important base class in LLVM.
bool invalidate(Function &F, const PreservedAnalyses &PA, FunctionAnalysisManager::Invalidator &Inv)
Handle invalidation events in the new pass manager.
A CRTP mix-in that provides informational APIs needed for analysis passes.
Represent the analysis usage information of a pass.
FunctionPass class - This class is used to implement most global optimizations.
void releaseMemory() override
releaseMemory() - This member can be implemented by a pass if it wants to be able to release its memo...
Tristate
This is used to return true/false/dunno results.
Tristate getPredicateOnEdge(unsigned Pred, Value *V, Constant *C, BasicBlock *FromBB, BasicBlock *ToBB, Instruction *CxtI=nullptr)
Determine whether the specified value comparison with a constant is known to be true or false on the ...
Tristate getPredicateAt(unsigned Pred, Value *V, Constant *C, Instruction *CxtI)
Determine whether the specified value comparison with a constant is known to be true or false at the ...
bool runOnFunction(Function &F) override
runOnFunction - Virtual method overriden by subclasses to do the per-function processing of the pass...
Provides information about what library functions are available for the current target.
This class represents a range of values.
void threadEdge(BasicBlock *PredBB, BasicBlock *OldSucc, BasicBlock *NewSucc)
Inform the analysis cache that we have threaded an edge from PredBB to OldSucc to be from PredBB to N...
LazyValueInfo & operator=(LazyValueInfo &&Arg)
void eraseBlock(BasicBlock *BB)
Inform the analysis cache that we have erased a block.
API to communicate dependencies between analyses during invalidation.
This pass computes, caches, and vends lazy value constraint information.
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
LLVM Value Representation.
LazyValueInfo(LazyValueInfo &&Arg)
This class implements an extremely fast bulk output stream that can only output to a stream...
A container for analyses that lazily runs them and caches their results.
void printLVI(Function &F, DominatorTree &DTree, raw_ostream &OS)
Print the Analysis.
ConstantRange getConstantRangeOnEdge(Value *V, BasicBlock *FromBB, BasicBlock *ToBB, Instruction *CxtI=nullptr)
Return the ConstantRage constraint that is known to hold for the specified value on the specified edg...
This header defines various interfaces for pass management in LLVM.
A special type used by analysis passes to provide an address that identifies that particular analysis...
Analysis to compute lazy value information.