13#ifndef LLVM_ANALYSIS_GLOBALSMODREF_H
14#define LLVM_ANALYSIS_GLOBALSMODREF_H
24struct AnalysisOptions;
35 const AnalysisOptions &Opts;
42 bool UnknownFunctionsWithLocalLinkage =
false;
63 std::list<DeletionCallbackHandle>::iterator
I;
65 DeletionCallbackHandle(GlobalsAAResult &GAR,
Value *
V)
68 void deleted()
override;
75 std::list<DeletionCallbackHandle> Handles;
77 explicit GlobalsAAResult(
const AnalysisOptions &Opts,
const DataLayout &DL);
82 LLVM_ABI GlobalsAAResult(GlobalsAAResult &&Arg);
86 ModuleAnalysisManager::Invalidator &);
111 void AnalyzeGlobals(
Module &M);
113 bool AnalyzeUsesOfPointer(
Value *
V,
118 void CollectSCCMembership(
CallGraph &CG);
143 std::unique_ptr<GlobalsAAResult> Result;
153 bool runOnModule(
Module &M)
override;
154 bool doFinalization(
Module &M)
override;
This header defines various interfaces for pass management in LLVM.
The mod/ref information collected for a particular function.
This class stores info we want to provide to or retain within an alias query.
MemoryEffects getMemoryEffects(const CallBase *Call, AAQueryInfo &AAQI)
ModRefInfo getModRefInfo(const CallBase *Call, const MemoryLocation &Loc, AAQueryInfo &AAQI)
The possible results of an alias query.
Represent the analysis usage information of a pass.
Base class for all callable instructions (InvokeInst and CallInst) Holds everything related to callin...
The basic data container for the call graph of a Module of IR.
Value handle with callbacks on RAUW and destruction.
A parsed version of the target data layout string in and methods for querying it.
An alias analysis result set for globals.
static LLVM_ABI GlobalsAAResult analyzeModule(Module &M, CallGraph &CG)
LLVM_ABI ~GlobalsAAResult()
LLVM_ABI ModRefInfo getModRefInfo(const CallBase *Call, const MemoryLocation &Loc, AAQueryInfo &AAQI)
LLVM_ABI bool invalidate(Module &M, const PreservedAnalyses &PA, ModuleAnalysisManager::Invalidator &)
LLVM_ABI MemoryEffects getMemoryEffects(const Function *F)
getMemoryEffects - Return the behavior of the specified function if called from the specified call si...
LLVM_ABI AliasResult alias(const MemoryLocation &LocA, const MemoryLocation &LocB, AAQueryInfo &AAQI, const Instruction *CtxI)
alias - If one of the pointers is to a global that we are tracking, and the other is some random poin...
friend struct RecomputeGlobalsAAPass
const GlobalsAAResult & getResult() const
GlobalsAAResult & getResult()
Analysis pass providing a never-invalidated alias analysis result.
LLVM_ABI GlobalsAAResult run(Module &M, ModuleAnalysisManager &AM)
Representation for a specific memory location.
A Module instance is used to store all the information related to an LLVM module.
A set of analyses that are preserved following a run of a transformation pass.
A templated base class for SmallPtrSet which provides the typesafe interface that is common across al...
SmallPtrSet - This class implements a set which is optimized for holding SmallSize or less elements.
LLVM Value Representation.
This is an optimization pass for GlobalISel generic memory operations.
MemoryEffectsBase< IRMemLocation > MemoryEffects
Summary of how a function affects memory in the program.
LLVM_ABI ModulePass * createGlobalsAAWrapperPass()
ModRefInfo
Flags indicating whether a memory access modifies or references memory.
AnalysisManager< Module > ModuleAnalysisManager
Convenience typedef for the Module analysis manager.
A CRTP mix-in that provides informational APIs needed for analysis passes.
A special type used by analysis passes to provide an address that identifies that particular analysis...
A CRTP mix-in for passes that can be skipped.
LLVM_ABI PreservedAnalyses run(Module &M, ModuleAnalysisManager &AM)