LLVM
8.0.1
|
Classes | |
struct | AliasSummary |
AliasSummary is just a collection of ExternalRelation and ExternalAttribute. More... | |
class | CFLGraph |
The Program Expression Graph (PEG) of CFL analysis CFLGraph is auxiliary data structure used by CFL-based alias analysis to describe flow-insensitive pointer-related behaviors. More... | |
class | CFLGraphBuilder |
A builder class used to create CFLGraph instance from a given function The CFL-AA that uses this builder must provide its own type as a template argument. More... | |
struct | ExternalAttribute |
We use ExternalAttribute to describe an externally visible AliasAttrs for parameters/return value. More... | |
struct | ExternalRelation |
We use ExternalRelation to describe an externally visible aliasing relations between parameters/return value of a function. More... | |
struct | FunctionHandle |
struct | InstantiatedAttr |
This is the result of instantiating ExternalAttribute at a particular callsite. More... | |
struct | InstantiatedRelation |
This is the result of instantiating ExternalRelation at a particular callsite. More... | |
struct | InstantiatedValue |
This is the result of instantiating InterfaceValue at a particular callsite. More... | |
struct | InterfaceValue |
We use InterfaceValue to describe parameters/return value, as well as potential memory locations that are pointed to by parameters/return value, of a function. More... | |
struct | StratifiedInfo |
NOTE: ^ This can't be a short – bootstrapping clang has a case where ~1M sets exist. More... | |
struct | StratifiedLink |
A "link" between two StratifiedSets. More... | |
class | StratifiedSets |
These are stratified sets, as described in "Fast algorithms for
Dyck-CFL-reachability with applications to Alias Analysis" by Zhang Q, Lyu M R, Yuan H, and Su Z. More... | |
class | StratifiedSetsBuilder |
Generic Builder class that produces StratifiedSets instances. More... | |
Typedefs | |
typedef std::bitset< NumAliasAttrs > | AliasAttrs |
These are attributes that an alias analysis can use to mark certain special properties of a given pointer. More... | |
typedef unsigned | StratifiedIndex |
An index into Stratified Sets. More... | |
Variables | |
static const unsigned | NumAliasAttrs = 32 |
The number of attributes that AliasAttr should contain. More... | |
static const unsigned | MaxSupportedArgsInSummary = 50 |
The maximum number of arguments we can put into a summary. More... | |
static const int64_t | UnknownOffset = INT64_MAX |
typedef std::bitset<NumAliasAttrs> llvm::cflaa::AliasAttrs |
These are attributes that an alias analysis can use to mark certain special properties of a given pointer.
Refer to the related functions below to see what kinds of attributes are currently defined.
Definition at line 59 of file AliasAnalysisSummary.h.
typedef unsigned llvm::cflaa::StratifiedIndex |
An index into Stratified Sets.
Definition at line 28 of file StratifiedSets.h.
|
inline |
Definition at line 142 of file AliasAnalysisSummary.h.
References UnknownOffset.
Referenced by getLeaOP().
|
static |
Definition at line 43 of file AliasAnalysisSummary.cpp.
Referenced by getGlobalOrArgAttrFromValue().
AliasAttrs llvm::cflaa::getAttrCaller | ( | ) |
AttrCaller represent whether the said pointer comes from a source not known to the current function but known to the caller.
Values pointed to by the arguments of the current function have this attribute set
Definition at line 34 of file AliasAnalysisSummary.cpp.
AliasAttrs llvm::cflaa::getAttrEscaped | ( | ) |
AttrEscaped represent whether the said pointer comes from a known source but escapes to the unknown world (e.g.
casted to an integer, or passed as an argument to opaque function). Unlike non-escaped pointers, escaped ones may alias pointers coming from unknown sources.
Definition at line 40 of file AliasAnalysisSummary.cpp.
AliasAttrs llvm::cflaa::getAttrNone | ( | ) |
Attr represent whether the said pointer comes from an unknown source (such as opaque memory or an integer cast).
Definition at line 29 of file AliasAnalysisSummary.cpp.
AliasAttrs llvm::cflaa::getAttrUnknown | ( | ) |
AttrUnknown represent whether the said pointer comes from a source not known to alias analyses (such as opaque memory or an integer cast).
Definition at line 31 of file AliasAnalysisSummary.cpp.
AliasAttrs llvm::cflaa::getExternallyVisibleAttrs | ( | AliasAttrs | ) |
Given an AliasAttrs, return a new AliasAttrs that only contains attributes meaningful to the caller.
This function is primarily used for interprocedural analysis Currently, externally visible AliasAttrs include AttrUnknown, AttrGlobal, and AttrEscaped
Definition at line 71 of file AliasAnalysisSummary.cpp.
Referenced by llvm::CFLSteensAAResult::FunctionInfo::FunctionInfo(), and populateExternalAttributes().
AliasAttrs llvm::cflaa::getGlobalOrArgAttrFromValue | ( | const Value & | ) |
AttrGlobal represent whether the said pointer is a global value.
AttrArg represent whether the said pointer is an argument, and if so, what index the argument has.
Definition at line 51 of file AliasAnalysisSummary.cpp.
References Arg, and argNumberToAttr().
bool llvm::cflaa::hasCallerAttr | ( | AliasAttrs | Attr | ) |
Definition at line 35 of file AliasAnalysisSummary.cpp.
bool llvm::cflaa::hasEscapedAttr | ( | AliasAttrs | Attr | ) |
Definition at line 41 of file AliasAnalysisSummary.cpp.
bool llvm::cflaa::hasUnknownAttr | ( | AliasAttrs | Attr | ) |
Definition at line 32 of file AliasAnalysisSummary.cpp.
bool llvm::cflaa::hasUnknownOrCallerAttr | ( | AliasAttrs | Attr | ) |
Definition at line 36 of file AliasAnalysisSummary.cpp.
Referenced by llvm::CFLAndersAAResult::FunctionInfo::mayAlias(), and llvm::CFLSteensAAResult::query().
Optional< InstantiatedAttr > llvm::cflaa::instantiateExternalAttribute | ( | ExternalAttribute | EAttr, |
CallSite | CS | ||
) |
Definition at line 95 of file AliasAnalysisSummary.cpp.
References llvm::cflaa::ExternalAttribute::Attr, instantiateInterfaceValue(), llvm::cflaa::ExternalAttribute::IValue, and llvm::None.
Optional< InstantiatedRelation > llvm::cflaa::instantiateExternalRelation | ( | ExternalRelation | ERelation, |
CallSite | CS | ||
) |
Definition at line 85 of file AliasAnalysisSummary.cpp.
References From, llvm::cflaa::ExternalRelation::From, instantiateInterfaceValue(), llvm::None, llvm::cflaa::ExternalRelation::Offset, and llvm::cflaa::ExternalRelation::To.
Optional< InstantiatedValue > llvm::cflaa::instantiateInterfaceValue | ( | InterfaceValue | IValue, |
CallSite | CS | ||
) |
Definition at line 75 of file AliasAnalysisSummary.cpp.
References llvm::cflaa::InterfaceValue::DerefLevel, llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, IterTy >::getArgument(), llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, IterTy >::getInstruction(), llvm::Value::getType(), llvm::cflaa::InterfaceValue::Index, llvm::Type::isPointerTy(), and llvm::None.
Referenced by instantiateExternalAttribute(), and instantiateExternalRelation().
bool llvm::cflaa::isGlobalOrArgAttr | ( | AliasAttrs | Attr | ) |
Definition at line 64 of file AliasAnalysisSummary.cpp.
Referenced by llvm::CFLAndersAAResult::FunctionInfo::mayAlias(), and llvm::CFLSteensAAResult::query().
|
inline |
Definition at line 120 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 159 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 209 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 123 of file AliasAnalysisSummary.h.
References llvm::cflaa::InterfaceValue::DerefLevel, and llvm::cflaa::InterfaceValue::Index.
|
inline |
Definition at line 162 of file AliasAnalysisSummary.h.
References llvm::cflaa::ExternalRelation::From, llvm::cflaa::ExternalRelation::Offset, and llvm::cflaa::ExternalRelation::To.
|
inline |
Definition at line 212 of file AliasAnalysisSummary.h.
References llvm::cflaa::InstantiatedValue::DerefLevel, and llvm::cflaa::InstantiatedValue::Val.
|
inline |
Definition at line 130 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 176 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 219 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 117 of file AliasAnalysisSummary.h.
References llvm::cflaa::InterfaceValue::DerefLevel, and llvm::cflaa::InterfaceValue::Index.
|
inline |
Definition at line 156 of file AliasAnalysisSummary.h.
References llvm::cflaa::ExternalRelation::From, llvm::cflaa::ExternalRelation::Offset, and llvm::cflaa::ExternalRelation::To.
|
inline |
Definition at line 206 of file AliasAnalysisSummary.h.
References llvm::cflaa::InstantiatedValue::DerefLevel, and llvm::cflaa::InstantiatedValue::Val.
|
inline |
Definition at line 127 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 173 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 216 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 133 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 179 of file AliasAnalysisSummary.h.
|
inline |
Definition at line 222 of file AliasAnalysisSummary.h.
Definition at line 45 of file CFLAliasAnalysisUtils.h.
References Arg, and llvm::GlobalValue::getParent().
Referenced by llvm::CFLAndersAAResult::query(), and llvm::CFLSteensAAResult::query().
The maximum number of arguments we can put into a summary.
Definition at line 102 of file AliasAnalysisSummary.h.
Referenced by llvm::CFLSteensAAResult::FunctionInfo::FunctionInfo().
The number of attributes that AliasAttr should contain.
Attributes are described below, and 32 was an arbitrary choice because it fits nicely in 32 bits (because we use a bitset for AliasAttr).
Definition at line 54 of file AliasAnalysisSummary.h.
Definition at line 140 of file AliasAnalysisSummary.h.
Referenced by addOffset(), llvm::CFLSteensAAResult::FunctionInfo::FunctionInfo(), llvm::CFLAndersAAResult::FunctionInfo::mayAlias(), populateAliasMap(), and populateExternalRelations().