LLVM
15.0.0git
|
The mod/ref information collected for a particular function. More...
Public Member Functions | |
FunctionInfo ()=default | |
Checks to document the invariants of the bit packing here. More... | |
~FunctionInfo () | |
FunctionInfo (const FunctionInfo &Arg) | |
FunctionInfo (FunctionInfo &&Arg) | |
FunctionInfo & | operator= (const FunctionInfo &RHS) |
FunctionInfo & | operator= (FunctionInfo &&RHS) |
ModRefInfo | globalClearMayReadAnyGlobal (int I) const |
This method clears MayReadAnyGlobal bit added by GlobalsAAResult to return the corresponding ModRefInfo. More... | |
ModRefInfo | getModRefInfo () const |
Returns the ModRefInfo info for this function. More... | |
void | addModRefInfo (ModRefInfo NewMRI) |
Adds new ModRefInfo for this function to its state. More... | |
bool | mayReadAnyGlobal () const |
Returns whether this function may read any global variable, and we don't know which global. More... | |
void | setMayReadAnyGlobal () |
Sets this function as potentially reading from any global. More... | |
ModRefInfo | getModRefInfoForGlobal (const GlobalValue &GV) const |
Returns the ModRefInfo info for this function w.r.t. More... | |
void | addFunctionInfo (const FunctionInfo &FI) |
Add mod/ref info from another function into ours, saturating towards ModRef. More... | |
void | addModRefInfoForGlobal (const GlobalValue &GV, ModRefInfo NewMRI) |
void | eraseModRefInfoForGlobal (const GlobalValue &GV) |
Clear a global's ModRef info. More... | |
The mod/ref information collected for a particular function.
We collect information about mod/ref behavior of a function here, both in general and as pertains to specific globals. We only have this detailed information when we know something useful about the behavior. If we saturate to fully general mod/ref, we remove the info for the function.
Definition at line 64 of file GlobalsModRef.cpp.
|
default |
Checks to document the invariants of the bit packing here.
|
inline |
Definition at line 106 of file GlobalsModRef.cpp.
References Info.
|
inline |
Definition at line 112 of file GlobalsModRef.cpp.
|
inline |
Definition at line 117 of file GlobalsModRef.cpp.
|
inline |
Add mod/ref info from another function into ours, saturating towards ModRef.
Definition at line 175 of file GlobalsModRef.cpp.
References llvm::GlobalsAAResult::FunctionInfo::addModRefInfo(), llvm::GlobalsAAResult::FunctionInfo::addModRefInfoForGlobal(), G, llvm::GlobalsAAResult::FunctionInfo::getModRefInfo(), llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits, Info >::getPointer(), llvm::GlobalsAAResult::FunctionInfo::mayReadAnyGlobal(), P, and llvm::GlobalsAAResult::FunctionInfo::setMayReadAnyGlobal().
|
inline |
Adds new ModRefInfo
for this function to its state.
Definition at line 149 of file GlobalsModRef.cpp.
References Info, and llvm::setMust().
Referenced by llvm::GlobalsAAResult::FunctionInfo::addFunctionInfo().
|
inline |
Definition at line 186 of file GlobalsModRef.cpp.
References Info, P, and llvm::unionModRef().
Referenced by llvm::GlobalsAAResult::FunctionInfo::addFunctionInfo().
|
inline |
Clear a global's ModRef info.
Should be used when a global is being deleted.
Definition at line 198 of file GlobalsModRef.cpp.
|
inline |
Returns the ModRefInfo
info for this function.
Definition at line 144 of file GlobalsModRef.cpp.
References llvm::GlobalsAAResult::FunctionInfo::globalClearMayReadAnyGlobal(), and Info.
Referenced by llvm::GlobalsAAResult::FunctionInfo::addFunctionInfo().
|
inline |
Returns the ModRefInfo
info for this function w.r.t.
a particular global, which may be more precise than the general information above.
Definition at line 162 of file GlobalsModRef.cpp.
References I, Info, llvm::GlobalsAAResult::FunctionInfo::mayReadAnyGlobal(), llvm::NoModRef, P, llvm::Ref, and llvm::unionModRef().
|
inline |
This method clears MayReadAnyGlobal bit added by GlobalsAAResult to return the corresponding ModRefInfo.
It must align in functionality with clearMust().
Definition at line 138 of file GlobalsModRef.cpp.
References I, llvm::ModRef, and llvm::NoModRef.
Referenced by llvm::GlobalsAAResult::FunctionInfo::getModRefInfo().
|
inline |
Returns whether this function may read any global variable, and we don't know which global.
Definition at line 155 of file GlobalsModRef.cpp.
References Info.
Referenced by llvm::GlobalsAAResult::FunctionInfo::addFunctionInfo(), and llvm::GlobalsAAResult::FunctionInfo::getModRefInfoForGlobal().
|
inline |
Definition at line 121 of file GlobalsModRef.cpp.
|
inline |
Definition at line 128 of file GlobalsModRef.cpp.
|
inline |
Sets this function as potentially reading from any global.
Definition at line 158 of file GlobalsModRef.cpp.
References Info.
Referenced by llvm::GlobalsAAResult::FunctionInfo::addFunctionInfo().