LLVM API Documentation
#include <AliasAnalysis.h>
Definition at line 57 of file AliasAnalysis.h.
anonymous enum |
These values define additional bits used to define the ModRefBehavior values.
Definition at line 237 of file AliasAnalysis.h.
Alias analysis result - Either we know for sure that it does not alias, we know for sure it must alias, or we don't know anything: The two pointers _might_ alias. This enum is designed so you can do things like: if (AA.alias(P1, P2)) { ... } to check to see if two pointers might alias.
See docs/AliasAnalysis.html for more information on the specific meanings of these values.
NoAlias |
No dependencies. |
MayAlias |
Anything goes. |
PartialAlias |
Pointers differ, but pointees overlap. |
MustAlias |
Pointers are equal. |
Definition at line 163 of file AliasAnalysis.h.
ModRefBehavior - Summary of how a function affects memory in the program. Loads from constant globals are not considered memory accesses for this interface. Also, functions may freely modify stack space local to their invocation without having to report it through these interfaces.
Definition at line 243 of file AliasAnalysis.h.
Simple mod/ref information... ModRefResult - Represent the result of a mod/ref query. Mod and Ref are bits which may be or'd together.
Definition at line 233 of file AliasAnalysis.h.
llvm::AliasAnalysis::AliasAnalysis | ( | ) | [inline] |
Definition at line 79 of file AliasAnalysis.h.
AliasAnalysis::~AliasAnalysis | ( | ) | [virtual] |
Definition at line 461 of file AliasAnalysis.cpp.
void AliasAnalysis::addEscapingUse | ( | Use & | U | ) | [virtual] |
addEscapingUse - This method should be used whenever an escaping use is added to a pointer value. Analysis implementations may either return conservative responses for that value in the future, or may recompute some or all internal state to continue providing precise responses.
Escaping uses are considered by anything _except_ the following:
Definition at line 80 of file AliasAnalysis.cpp.
References addEscapingUse().
Referenced by addEscapingUse(), and ConstructSSAForLoadSet().
AliasAnalysis::AliasResult AliasAnalysis::alias | ( | const Location & | LocA, |
const Location & | LocB | ||
) | [virtual] |
alias - The main low level interface to the alias analysis implementation. Returns an AliasResult indicating whether the two pointers are aliased to each other. This is the interface that must be implemented by specific alias analysis implementations.
Definition at line 52 of file AliasAnalysis.cpp.
Referenced by alias(), llvm::AliasSet::aliasesPointer(), getModRefInfo(), llvm::MemoryDependenceAnalysis::getPointerDependencyFrom(), isMustAlias(), isNoAlias(), llvm::AliasSet::mergeSetIn(), MIsNeedChainEdge(), and underlyingObjectsAlias().
AliasResult llvm::AliasAnalysis::alias | ( | const Value * | V1, |
uint64_t | V1Size, | ||
const Value * | V2, | ||
uint64_t | V2Size | ||
) | [inline] |
AliasResult llvm::AliasAnalysis::alias | ( | const Value * | V1, |
const Value * | V2 | ||
) | [inline] |
alias - A convenience wrapper.
Definition at line 183 of file AliasAnalysis.h.
References alias(), and UnknownSize.
AliasAnalysis::ModRefResult AliasAnalysis::callCapturesBefore | ( | const Instruction * | I, |
const AliasAnalysis::Location & | MemLoc, | ||
DominatorTree * | DT | ||
) |
callCapturesBefore - Return information about whether a particular call site modifies or reads the specified memory location.
Definition at line 408 of file AliasAnalysis.cpp.
References llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::arg_begin(), llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::arg_end(), llvm::WinEH::CE, DL, llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::doesNotAccessMemory(), llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::doesNotCapture(), llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::getInstruction(), llvm::GetUnderlyingObject(), llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::isByValArgument(), llvm::isIdentifiedObject(), isNoAlias(), ModRef, NoModRef, llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::onlyReadsMemory(), llvm::PointerMayBeCapturedBefore(), llvm::AliasAnalysis::Location::Ptr, and Ref.
Referenced by callCapturesBefore(), and llvm::MemoryDependenceAnalysis::getPointerDependencyFrom().
ModRefResult llvm::AliasAnalysis::callCapturesBefore | ( | const Instruction * | I, |
const Value * | P, | ||
uint64_t | Size, | ||
DominatorTree * | DT | ||
) | [inline] |
callCapturesBefore - A convenience wrapper.
Definition at line 495 of file AliasAnalysis.h.
References callCapturesBefore().
bool AliasAnalysis::canBasicBlockModify | ( | const BasicBlock & | BB, |
const Location & | Loc | ||
) |
Higher level methods for querying mod/ref information. canBasicBlockModify - Return true if it is possible for execution of the specified basic block to modify the value pointed to by Ptr.
canBasicBlockModify - Return true if it is possible for execution of the specified basic block to modify the value pointed to by Ptr.
Definition at line 489 of file AliasAnalysis.cpp.
References llvm::BasicBlock::back(), canInstructionRangeModify(), and llvm::BasicBlock::front().
Referenced by canBasicBlockModify().
bool llvm::AliasAnalysis::canBasicBlockModify | ( | const BasicBlock & | BB, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
canBasicBlockModify - A convenience wrapper.
Definition at line 509 of file AliasAnalysis.h.
References canBasicBlockModify().
bool AliasAnalysis::canInstructionRangeModify | ( | const Instruction & | I1, |
const Instruction & | I2, | ||
const Location & | Loc | ||
) |
canInstructionRangeModify - Return true if it is possible for the execution of the specified instructions to modify the value pointed to by Ptr. The instructions to consider are all of the instructions in the range of [I1,I2] INCLUSIVE. I1 and I2 must be in the same basic block.
Definition at line 499 of file AliasAnalysis.cpp.
References getModRefInfo(), llvm::Instruction::getParent(), I, and Mod.
Referenced by canBasicBlockModify(), and canInstructionRangeModify().
bool llvm::AliasAnalysis::canInstructionRangeModify | ( | const Instruction & | I1, |
const Instruction & | I2, | ||
const Value * | Ptr, | ||
uint64_t | Size | ||
) | [inline] |
canInstructionRangeModify - A convenience wrapper.
Definition at line 521 of file AliasAnalysis.h.
References canInstructionRangeModify().
void AliasAnalysis::copyValue | ( | Value * | From, |
Value * | To | ||
) | [virtual] |
copyValue - This method should be used whenever a preexisting value in the program is copied or cloned, introducing a new value. Note that analysis implementations should tolerate clients that use this method to introduce the same value multiple times: if the analysis already knows about a value, it should ignore the request.
Definition at line 75 of file AliasAnalysis.cpp.
References copyValue().
Referenced by ConstructSSAForLoadSet(), llvm::AliasSetTracker::copyValue(), copyValue(), insertUniqueBackedgeBlock(), replaceWithNewValue(), and UpdatePHINodes().
void AliasAnalysis::deleteValue | ( | Value * | V | ) | [virtual] |
Methods that clients should call when they transform the program to allow alias analyses to update their internal data structures. Note that these methods may be called on any instruction, regardless of whether or not they have pointer-analysis implications. deleteValue - This method should be called whenever an LLVM Value is deleted from the program, for example when an instruction is found to be redundant and is eliminated.
Definition at line 70 of file AliasAnalysis.cpp.
References deleteValue().
Referenced by llvm::AliasSetTracker::deleteValue(), deleteValue(), findPHIToPartitionLoops(), llvm::FoldSingleEntryPHINodes(), insertUniqueBackedgeBlock(), llvm::MemoryDependenceAnalysis::removeInstruction(), replaceWithNewValue(), and simplifyOneLoop().
static bool llvm::AliasAnalysis::doesAccessArgPointees | ( | ModRefBehavior | MRB | ) | [inline, static] |
doesAccessArgPointees - Return true if functions with the specified behavior are known to potentially read or write from objects pointed to be their pointer-typed arguments (with arbitrary offsets).
Definition at line 356 of file AliasAnalysis.h.
References ArgumentPointees, and ModRef.
Referenced by getModRefInfo().
bool llvm::AliasAnalysis::doesNotAccessMemory | ( | ImmutableCallSite | CS | ) | [inline] |
doesNotAccessMemory - If the specified call is known to never read or write memory, return true. If the call only reads from known-constant memory, it is also legal to return true. Calls that unwind the stack are legal for this predicate.
Many optimizations (such as CSE and LICM) can be performed on such calls without worrying about aliasing properties, and many calls have this property (e.g. calls to 'sin' and 'cos').
This property corresponds to the GCC 'const' attribute.
Definition at line 305 of file AliasAnalysis.h.
References DoesNotAccessMemory, and getModRefBehavior().
bool llvm::AliasAnalysis::doesNotAccessMemory | ( | const Function * | F | ) | [inline] |
doesNotAccessMemory - If the specified function is known to never read or write memory, return true. For use when the call site is not known.
Definition at line 312 of file AliasAnalysis.h.
References DoesNotAccessMemory, and getModRefBehavior().
void AliasAnalysis::getAnalysisUsage | ( | AnalysisUsage & | AU | ) | const [protected, virtual] |
getAnalysisUsage - All alias analysis implementations should invoke this directly (using AliasAnalysis::getAnalysisUsage(AU)).
Reimplemented in llvm::LibCallAliasAnalysis.
Definition at line 475 of file AliasAnalysis.cpp.
References llvm::AnalysisUsage::addRequired().
AliasAnalysis::Location AliasAnalysis::getArgLocation | ( | ImmutableCallSite | CS, |
unsigned | ArgIdx, | ||
AliasAnalysis::ModRefResult & | Mask | ||
) | [virtual] |
Get the location associated with a pointer argument of a callsite. The mask bits are set to indicate the allowed aliasing ModRef kinds. Note that these mask bits do not necessarily account for the overall behavior of the function, but rather only provide additional per-argument information.
Definition at line 64 of file AliasAnalysis.cpp.
References getArgLocation().
Referenced by getArgLocation(), and getModRefInfo().
const DataLayout* llvm::AliasAnalysis::getDataLayout | ( | ) | const [inline] |
getDataLayout - Return a pointer to the current DataLayout object, or null if no DataLayout object is available.
Definition at line 90 of file AliasAnalysis.h.
References DL.
Referenced by getLocForWrite(), getPointerSize(), and isOverwrite().
getLocation - Fill in Loc with information about the memory reference by the given instruction.
Definition at line 254 of file AliasAnalysis.cpp.
References llvm::Instruction::getAAMetadata(), llvm::LoadInst::getPointerOperand(), llvm::Value::getType(), and getTypeStoreSize().
Referenced by GetLocation(), getLocForWrite(), getModRefInfo(), llvm::MemoryDependenceAnalysis::getPointerDependencyFrom(), and isSafeToMove().
Definition at line 262 of file AliasAnalysis.cpp.
References llvm::Instruction::getAAMetadata(), llvm::StoreInst::getPointerOperand(), llvm::Value::getType(), getTypeStoreSize(), and llvm::StoreInst::getValueOperand().
Definition at line 270 of file AliasAnalysis.cpp.
References llvm::Instruction::getAAMetadata(), llvm::VAArgInst::getPointerOperand(), and UnknownSize.
Definition at line 278 of file AliasAnalysis.cpp.
References llvm::Instruction::getAAMetadata(), llvm::AtomicCmpXchgInst::getCompareOperand(), llvm::AtomicCmpXchgInst::getPointerOperand(), llvm::Value::getType(), and getTypeStoreSize().
Definition at line 288 of file AliasAnalysis.cpp.
References llvm::Instruction::getAAMetadata(), llvm::AtomicRMWInst::getPointerOperand(), llvm::Value::getType(), getTypeStoreSize(), and llvm::AtomicRMWInst::getValOperand().
AliasAnalysis::Location AliasAnalysis::getLocationForDest | ( | const MemIntrinsic * | MI | ) | [static] |
Definition at line 311 of file AliasAnalysis.cpp.
References llvm::CallingConv::C, llvm::MemIntrinsic::getLength(), llvm::Instruction::getMetadata(), llvm::MemIntrinsic::getRawDest(), and UnknownSize.
Referenced by getLocForWrite().
AliasAnalysis::Location AliasAnalysis::getLocationForSource | ( | const MemTransferInst * | MTI | ) | [static] |
Definition at line 297 of file AliasAnalysis.cpp.
References llvm::CallingConv::C, llvm::Instruction::getAAMetadata(), llvm::MemIntrinsic::getLength(), llvm::MemTransferInst::getRawSource(), and UnknownSize.
Referenced by getLocForRead().
getModRefBehavior - Return the behavior when calling the given call site.
Definition at line 226 of file AliasAnalysis.cpp.
References F(), llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::getCalledFunction(), getModRefBehavior(), and UnknownModRefBehavior.
Referenced by AddAliasScopeMetadata(), llvm::objcarc::CanAlterRefCount(), doesNotAccessMemory(), getModRefBehavior(), getModRefInfo(), and onlyReadsMemory().
AliasAnalysis::ModRefBehavior AliasAnalysis::getModRefBehavior | ( | const Function * | F | ) | [virtual] |
getModRefBehavior - Return the behavior when calling the given function. For use when the call site is not known.
Definition at line 245 of file AliasAnalysis.cpp.
References getModRefBehavior().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const Instruction * | I, |
const Location & | Loc | ||
) | [inline] |
getModRefInfo - Return information about whether or not an instruction may read or write the specified memory location. An instruction that doesn't read or write memory may be trivially LICM'd for example.
Definition at line 363 of file AliasAnalysis.h.
References llvm::Call, llvm::Instruction::getOpcode(), llvm::SPII::Load, NoModRef, llvm::SPII::Store, and llvm::VAArg.
Referenced by llvm::AliasSet::aliasesPointer(), llvm::AliasSet::aliasesUnknownInst(), canInstructionRangeModify(), llvm::FindAvailableLoadedValue(), getModRefInfo(), llvm::MemoryDependenceAnalysis::getPointerDependencyFrom(), isSafeToMove(), and mayLoopAccessLocation().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const Instruction * | I, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo - A convenience wrapper.
Definition at line 381 of file AliasAnalysis.h.
References getModRefInfo().
AliasAnalysis::ModRefResult AliasAnalysis::getModRefInfo | ( | ImmutableCallSite | CS, |
const Location & | Loc | ||
) | [virtual] |
getModRefInfo (for call sites) - Return information about whether a particular call site modifies or reads the specified memory location.
Reimplemented in llvm::LibCallAliasAnalysis.
Definition at line 87 of file AliasAnalysis.cpp.
References llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::arg_begin(), llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::arg_end(), doesAccessArgPointees(), DoesNotAccessMemory, getArgLocation(), getModRefBehavior(), getModRefInfo(), llvm::Value::getType(), isNoAlias(), llvm::Type::isPointerTy(), Mod, ModRef, NoModRef, onlyAccessesArgPointees(), onlyReadsMemory(), pointsToConstantMemory(), and Ref.
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | ImmutableCallSite | CS, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo (for call sites) - A convenience wrapper.
Definition at line 392 of file AliasAnalysis.h.
References getModRefInfo().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const CallInst * | C, |
const Location & | Loc | ||
) | [inline] |
getModRefInfo (for calls) - Return information about whether a particular call modifies or reads the specified memory location.
Definition at line 399 of file AliasAnalysis.h.
References getModRefInfo().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const CallInst * | C, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo (for calls) - A convenience wrapper.
Definition at line 404 of file AliasAnalysis.h.
References getModRefInfo().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const InvokeInst * | I, |
const Location & | Loc | ||
) | [inline] |
getModRefInfo (for invokes) - Return information about whether a particular invoke modifies or reads the specified memory location.
Definition at line 410 of file AliasAnalysis.h.
References getModRefInfo().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const InvokeInst * | I, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo (for invokes) - A convenience wrapper.
Definition at line 416 of file AliasAnalysis.h.
References getModRefInfo().
AliasAnalysis::ModRefResult AliasAnalysis::getModRefInfo | ( | const LoadInst * | L, |
const Location & | Loc | ||
) |
getModRefInfo (for loads) - Return information about whether a particular load modifies or reads the specified memory location.
Definition at line 327 of file AliasAnalysis.cpp.
References alias(), getLocation(), llvm::LoadInst::isUnordered(), ModRef, NoModRef, and Ref.
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const LoadInst * | L, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo (for loads) - A convenience wrapper.
Definition at line 426 of file AliasAnalysis.h.
References getModRefInfo().
AliasAnalysis::ModRefResult AliasAnalysis::getModRefInfo | ( | const StoreInst * | S, |
const Location & | Loc | ||
) |
getModRefInfo (for stores) - Return information about whether a particular store modifies or reads the specified memory location.
Definition at line 342 of file AliasAnalysis.cpp.
References alias(), getLocation(), llvm::StoreInst::isUnordered(), Mod, ModRef, NoModRef, and pointsToConstantMemory().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const StoreInst * | S, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo (for stores) - A convenience wrapper.
Definition at line 435 of file AliasAnalysis.h.
References getModRefInfo().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const FenceInst * | S, |
const Location & | Loc | ||
) | [inline] |
getModRefInfo (for fences) - Return information about whether a particular store modifies or reads the specified memory location.
Definition at line 441 of file AliasAnalysis.h.
References ModRef.
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const FenceInst * | S, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo (for fences) - A convenience wrapper.
Definition at line 448 of file AliasAnalysis.h.
References getModRefInfo().
AliasAnalysis::ModRefResult AliasAnalysis::getModRefInfo | ( | const AtomicCmpXchgInst * | CX, |
const Location & | Loc | ||
) |
getModRefInfo (for cmpxchges) - Return information about whether a particular cmpxchg modifies or reads the specified memory location.
Definition at line 378 of file AliasAnalysis.cpp.
References alias(), getLocation(), llvm::AtomicCmpXchgInst::getSuccessOrdering(), ModRef, llvm::Monotonic, and NoModRef.
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const AtomicCmpXchgInst * | CX, |
const Value * | P, | ||
unsigned | Size | ||
) | [inline] |
getModRefInfo (for cmpxchges) - A convenience wrapper.
Definition at line 457 of file AliasAnalysis.h.
References getModRefInfo().
AliasAnalysis::ModRefResult AliasAnalysis::getModRefInfo | ( | const AtomicRMWInst * | RMW, |
const Location & | Loc | ||
) |
getModRefInfo (for atomicrmws) - Return information about whether a particular atomicrmw modifies or reads the specified memory location.
Definition at line 391 of file AliasAnalysis.cpp.
References alias(), getLocation(), llvm::AtomicRMWInst::getOrdering(), ModRef, llvm::Monotonic, and NoModRef.
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const AtomicRMWInst * | RMW, |
const Value * | P, | ||
unsigned | Size | ||
) | [inline] |
getModRefInfo (for atomicrmws) - A convenience wrapper.
Definition at line 467 of file AliasAnalysis.h.
References getModRefInfo().
AliasAnalysis::ModRefResult AliasAnalysis::getModRefInfo | ( | const VAArgInst * | I, |
const Location & | Loc | ||
) |
getModRefInfo (for va_args) - Return information about whether a particular va_arg modifies or reads the specified memory location.
Definition at line 362 of file AliasAnalysis.cpp.
References alias(), getLocation(), ModRef, NoModRef, and pointsToConstantMemory().
ModRefResult llvm::AliasAnalysis::getModRefInfo | ( | const VAArgInst * | I, |
const Value * | P, | ||
uint64_t | Size | ||
) | [inline] |
getModRefInfo (for va_args) - A convenience wrapper.
Definition at line 477 of file AliasAnalysis.h.
References getModRefInfo().
AliasAnalysis::ModRefResult AliasAnalysis::getModRefInfo | ( | ImmutableCallSite | CS1, |
ImmutableCallSite | CS2 | ||
) | [virtual] |
getModRefInfo - Return information about whether two call sites may refer to the same set of memory locations. See http://llvm.org/docs/AliasAnalysis.html#ModRefInfo for details.
Reimplemented in llvm::LibCallAliasAnalysis.
Definition at line 137 of file AliasAnalysis.cpp.
References llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::arg_begin(), llvm::CallSiteBase< FunTy, ValTy, UserTy, InstrTy, CallTy, InvokeTy, IterTy >::arg_end(), doesAccessArgPointees(), DoesNotAccessMemory, getArgLocation(), getModRefBehavior(), getModRefInfo(), llvm::Value::getType(), I, llvm::Type::isPointerTy(), Mod, ModRef, NoModRef, onlyAccessesArgPointees(), onlyReadsMemory(), and Ref.
const TargetLibraryInfo* llvm::AliasAnalysis::getTargetLibraryInfo | ( | ) | const [inline] |
getTargetLibraryInfo - Return a pointer to the current TargetLibraryInfo object, or null if no TargetLibraryInfo object is available.
Definition at line 95 of file AliasAnalysis.h.
References TLI.
Referenced by GetLocation(), getLocForRead(), llvm::MemoryDependenceAnalysis::getPointerDependencyFrom(), and getPointerSize().
uint64_t AliasAnalysis::getTypeStoreSize | ( | Type * | Ty | ) |
getTypeStoreSize - Return the DataLayout store size for the given type, if known, or a conservative value otherwise.
Definition at line 482 of file AliasAnalysis.cpp.
References DL, llvm::DataLayout::getTypeStoreSize(), and UnknownSize.
Referenced by llvm::AliasSetTracker::add(), llvm::FindAvailableLoadedValue(), getLocation(), llvm::AliasSetTracker::remove(), and underlyingObjectsAlias().
void AliasAnalysis::InitializeAliasAnalysis | ( | Pass * | P | ) | [protected] |
InitializeAliasAnalysis - Subclasses must call this method to initialize the AliasAnalysis interface before any other methods are called. This is typically called by the run* methods of these subclasses. This may be called multiple times.
InitializeAliasAnalysis - Subclasses must call this method to initialize the AliasAnalysis interface before any other methods are called.
Definition at line 466 of file AliasAnalysis.cpp.
References DL, llvm::Pass::getAnalysis(), llvm::Pass::getAnalysisIfAvailable(), llvm::DataLayoutPass::getDataLayout(), and TLI.
Referenced by llvm::LibCallAliasAnalysis::runOnFunction().
isMustAlias - A convenience wrapper.
Definition at line 205 of file AliasAnalysis.h.
References alias(), and MustAlias.
Referenced by llvm::MemoryDependenceAnalysis::getPointerDependencyFrom(), and isPossibleSelfRead().
isMustAlias - A convenience wrapper.
Definition at line 210 of file AliasAnalysis.h.
isNoAlias - A trivial helper function to check to see if the specified pointers are no-alias.
Definition at line 189 of file AliasAnalysis.h.
References alias(), and NoAlias.
Referenced by callCapturesBefore(), getModRefInfo(), isNoAlias(), and isPossibleSelfRead().
bool llvm::AliasAnalysis::isNoAlias | ( | const Value * | V1, |
uint64_t | V1Size, | ||
const Value * | V2, | ||
uint64_t | V2Size | ||
) | [inline] |
isNoAlias - A convenience wrapper.
Definition at line 194 of file AliasAnalysis.h.
References isNoAlias().
isNoAlias - A convenience wrapper.
Definition at line 200 of file AliasAnalysis.h.
References isNoAlias().
static bool llvm::AliasAnalysis::onlyAccessesArgPointees | ( | ModRefBehavior | MRB | ) | [inline, static] |
onlyAccessesArgPointees - Return true if functions with the specified behavior are known to read and write at most from objects pointed to by their pointer-typed arguments (with arbitrary offsets).
Definition at line 348 of file AliasAnalysis.h.
References Anywhere, and ArgumentPointees.
Referenced by llvm::objcarc::CanAlterRefCount(), and getModRefInfo().
bool llvm::AliasAnalysis::onlyReadsMemory | ( | ImmutableCallSite | CS | ) | [inline] |
onlyReadsMemory - If the specified call is known to only read from non-volatile memory (or not access memory at all), return true. Calls that unwind the stack are legal for this predicate.
This property allows many common optimizations to be performed in the absence of interfering store instructions, such as CSE of strlen calls.
This property corresponds to the GCC 'pure' attribute.
Definition at line 325 of file AliasAnalysis.h.
References getModRefBehavior().
Referenced by llvm::objcarc::CanAlterRefCount(), llvm::MemoryDependenceAnalysis::getDependency(), getModRefInfo(), llvm::MemoryDependenceAnalysis::getNonLocalCallDependency(), and onlyReadsMemory().
bool llvm::AliasAnalysis::onlyReadsMemory | ( | const Function * | F | ) | [inline] |
onlyReadsMemory - If the specified function is known to only read from non-volatile memory (or not access memory at all), return true. For use when the call site is not known.
Definition at line 333 of file AliasAnalysis.h.
References getModRefBehavior(), and onlyReadsMemory().
static bool llvm::AliasAnalysis::onlyReadsMemory | ( | ModRefBehavior | MRB | ) | [inline, static] |
onlyReadsMemory - Return true if functions with the specified behavior are known to only read from non-volatile memory (or not access memory at all).
Definition at line 340 of file AliasAnalysis.h.
References Mod.
pointsToConstantMemory - If the specified memory location is known to be constant, return true. If OrLocal is true and the specified memory location is known to be "local" (derived from an alloca), return true. Otherwise return false.
Definition at line 57 of file AliasAnalysis.cpp.
References pointsToConstantMemory().
Referenced by getMemCmpLoad(), getModRefInfo(), llvm::MemoryDependenceAnalysis::getPointerDependencyFrom(), llvm::MachineInstr::isInvariantLoad(), llvm::objcarc::IsPotentialRetainableObjPtr(), and pointsToConstantMemory().
pointsToConstantMemory - A convenient wrapper.
Definition at line 222 of file AliasAnalysis.h.
References pointsToConstantMemory().
void llvm::AliasAnalysis::replaceWithNewValue | ( | Value * | Old, |
Value * | New | ||
) | [inline] |
replaceWithNewValue - This method is the obvious combination of the two above, and it provided as a helper to simplify client code.
Definition at line 561 of file AliasAnalysis.h.
References copyValue(), and deleteValue().
const DataLayout* llvm::AliasAnalysis::DL [protected] |
Definition at line 59 of file AliasAnalysis.h.
Referenced by callCapturesBefore(), getDataLayout(), getTypeStoreSize(), and InitializeAliasAnalysis().
char AliasAnalysis::ID = 0 [static] |
Reimplemented in llvm::objcarc::ObjCARCAliasAnalysis, and llvm::LibCallAliasAnalysis.
Definition at line 78 of file AliasAnalysis.h.
Referenced by llvm::LibCallAliasAnalysis::getAdjustedAnalysisPointer().
const TargetLibraryInfo* llvm::AliasAnalysis::TLI [protected] |
Definition at line 60 of file AliasAnalysis.h.
Referenced by getTargetLibraryInfo(), and InitializeAliasAnalysis().
uint64_t const llvm::AliasAnalysis::UnknownSize = ~UINT64_C(0) [static] |
UnknownSize - This is a special value which can be used with the size arguments in alias queries to indicate that the caller does not know the sizes of the potential memory references.
Definition at line 85 of file AliasAnalysis.h.
Referenced by llvm::AliasSetTracker::add(), alias(), getLocation(), getLocationForDest(), getLocationForSource(), getLocForWrite(), getObjectSize(), getPointerSize(), getTypeStoreSize(), isObjectSize(), isObjectSmallerThan(), isOverwrite(), and llvm::AliasSetTracker::remove().