34 #define DEBUG_TYPE "objc-arc-aa" 59 if (UA != SA || UB != SB) {
142 "ObjC-ARC-Based Alias Analysis",
false,
true)
bool pointsToConstantMemory(const MemoryLocation &Loc, AAQueryInfo &AAQI, bool OrLocal)
The access neither references nor modifies the value stored in memory.
static PassRegistry * getPassRegistry()
getPassRegistry - Access the global registry object, which is automatically initialized at applicatio...
This class represents lattice values for constants.
A Module instance is used to store all the information related to an LLVM module. ...
ObjCARCAAResult run(Function &F, FunctionAnalysisManager &AM)
This class stores info we want to provide to or retain within an alias query.
objc_retainedObject, etc.
The two locations do not alias at all.
FunctionModRefBehavior getModRefBehavior(const CallBase *Call)
Base class for all callable instructions (InvokeInst and CallInst) Holds everything related to callin...
AliasResult alias(const MemoryLocation &LocA, const MemoryLocation &LocB, AAQueryInfo &AAQI)
objc_autoreleaseReturnValue
const DataLayout & getDataLayout() const
Get the data layout for the module's target platform.
bool doFinalization(Module &M) override
doFinalization - Virtual method overriden by subclasses to do any necessary clean up after all passes...
bool pointsToConstantMemory(const MemoryLocation &Loc, AAQueryInfo &AAQI, bool OrLocal)
AliasResult alias(const MemoryLocation &LocA, const MemoryLocation &LocB, AAQueryInfo &AAQI)
objc_retainAutoreleasedReturnValue
FunctionModRefBehavior
Summary of how a function affects memory in the program.
bool EnableARCOpts
A handy option to enable/disable all ARC Optimizations.
FunctionModRefBehavior getModRefBehavior(const Function *F)
AliasResult
The possible results of an alias query.
Represent the analysis usage information of a pass.
ARCInstKind GetFunctionClass(const Function *F)
Determine if F is one of the special known Functions.
LocationSize Size
The maximum size of the location, in address-units, or UnknownSize if the size is not known...
ModRefInfo getModRefInfo(const CallBase *Call, const MemoryLocation &Loc, AAQueryInfo &AAQI)
This file defines common analysis utilities used by the ObjC ARC Optimizer.
This file declares a simple ARC-aware AliasAnalysis using special knowledge of Objective C to enhance...
This function does not perform any non-local loads or stores to memory.
ARCInstKind GetBasicARCInstKind(const Value *V)
Determine which objc runtime call instruction class V belongs to.
The two locations may or may not alias. This is the least precise result.
const Value * Ptr
The address of the start of the location.
Representation for a specific memory location.
ImmutablePass class - This class is used to provide information that does not need to be run...
bool doInitialization(Module &M) override
doInitialization - Virtual method overridden by subclasses to do any necessary initialization before ...
void initializeObjCARCAAWrapperPassPass(PassRegistry &)
void setPreservesAll()
Set by analyses that do not transform their input at all.
This is a simple alias analysis implementation that uses knowledge of ARC constructs to answer querie...
AAMDNodes AATags
The metadata nodes which describes the aliasing of the location (each member is null if that kind of ...
const Value * GetUnderlyingObjCPtr(const Value *V, const DataLayout &DL)
This is a wrapper around getUnderlyingObject which also knows how to look through objc_retain and obj...
objc_retainAutoreleaseReturnValue
ObjCARCAAResult(const DataLayout &DL)
Module * getParent()
Get the module that this global value is contained inside of...
LLVM Value Representation.
Legacy wrapper pass to provide the ObjCARCAAResult object.
ModRefInfo
Flags indicating whether a memory access modifies or references memory.
const Value * GetRCIdentityRoot(const Value *V)
The RCIdentity root of a value V is a dominating value U for which retaining or releasing U is equiva...
A container for analyses that lazily runs them and caches their results.
INITIALIZE_PASS(ObjCARCAAWrapperPass, "objc-arc-aa", "ObjC-ARC-Based Alias Analysis", false, true) ImmutablePass *llvm
ModRefInfo getModRefInfo(const CallBase *Call, const MemoryLocation &Loc, AAQueryInfo &AAQI)
ImmutablePass * createObjCARCAAWrapperPass()
void getAnalysisUsage(AnalysisUsage &AU) const override
getAnalysisUsage - This function should be overriden by passes that need analysis information to do t...