21 #ifndef LLVM_ANALYSIS_CGSCCPASSMANAGER_H
22 #define LLVM_ANALYSIS_CGSCCPASSMANAGER_H
86 static void *
ID() {
return (
void *)&PassID; }
97 : CGAM(std::move(Arg.CGAM)) {}
157 static void *
ID() {
return (
void *)&PassID; }
168 : MAM(std::move(Arg.MAM)) {}
198 : Pass(std::move(Pass)) {}
209 swap(LHS.Pass, RHS.Pass);
219 assert(AM &&
"We need analyses to compute the call graph!");
244 PA.intersect(std::move(PassPA));
263 template <
typename CGSCCPassT>
264 ModuleToPostOrderCGSCCPassAdaptor<CGSCCPassT>
311 static void *
ID() {
return (
void *)&PassID; }
323 : FAM(std::move(Arg.FAM)) {}
383 static void *
ID() {
return (
void *)&PassID; }
395 : CGAM(std::move(Arg.CGAM)) {}
424 : Pass(std::move(Pass)) {}
434 swap(LHS.Pass, RHS.Pass);
458 PassPA = FAM->
invalidate(
N->getFunction(), std::move(PassPA));
483 template <
typename FunctionPassT>
484 CGSCCToFunctionPassAdaptor<FunctionPassT>
Pass interface - Implemented by all 'passes'.
ModuleToPostOrderCGSCCPassAdaptor(ModuleToPostOrderCGSCCPassAdaptor &&Arg)
PassManager< LazyCallGraph::SCC > CGSCCPassManager
The CGSCC pass manager.
CGSCCAnalysisManagerModuleProxy(CGSCCAnalysisManager &CGAM)
Result proxy object for ModuleAnalysisManagerFunctionProxy.
CGSCCAnalysisManagerFunctionProxy & operator=(CGSCCAnalysisManagerFunctionProxy RHS)
FunctionAnalysisManagerCGSCCProxy(const FunctionAnalysisManagerCGSCCProxy &Arg)
void intersect(const PreservedAnalyses &Arg)
Intersect this set with another in place.
A Module instance is used to store all the information related to an LLVM module. ...
A function analysis which acts as a proxy for a CGSCC analysis manager.
CGSCCToFunctionPassAdaptor & operator=(CGSCCToFunctionPassAdaptor RHS)
bool invalidate(Module &M, const PreservedAnalyses &PA)
Handler for invalidation of the module.
bool invalidate(LazyCallGraph::SCC &)
Handle invalidation by ignoring it, this pass is immutable.
Implements a lazy call graph analysis and related passes for the new pass manager.
CGSCCAnalysisManagerModuleProxy & operator=(CGSCCAnalysisManagerModuleProxy RHS)
const CGSCCAnalysisManager & getManager() const
Result(FunctionAnalysisManager &FAM)
Result run(LazyCallGraph::SCC &)
Run the analysis pass and create our proxy result object.
ModuleToPostOrderCGSCCPassAdaptor< CGSCCPassT > createModuleToPostOrderCGSCCPassAdaptor(CGSCCPassT Pass)
A function to deduce a function pass type and wrap it in the templated adaptor.
CGSCCToFunctionPassAdaptor< FunctionPassT > createCGSCCToFunctionPassAdaptor(FunctionPassT Pass)
A function to deduce a function pass type and wrap it in the templated adaptor.
ModuleToPostOrderCGSCCPassAdaptor & operator=(ModuleToPostOrderCGSCCPassAdaptor RHS)
A CGSCC analysis which acts as a proxy for a function analysis manager.
Result proxy object for ModuleAnalysisManagerCGSCCProxy.
FunctionAnalysisManagerCGSCCProxy(FunctionAnalysisManager &FAM)
Result run(Module &M)
Run the analysis pass and create our proxy result object.
CGSCCAnalysisManager & getManager()
Accessor for the CGSCCAnalysisManager.
ModuleAnalysisManagerCGSCCProxy & operator=(ModuleAnalysisManagerCGSCCProxy RHS)
ModuleToPostOrderCGSCCPassAdaptor(const ModuleToPostOrderCGSCCPassAdaptor &Arg)
ModuleAnalysisManagerCGSCCProxy(const ModuleAnalysisManagerCGSCCProxy &Arg)
PreservedAnalyses run(LazyCallGraph::SCC &C, CGSCCAnalysisManager *AM)
Runs the function pass across every function in the module.
CGSCCToFunctionPassAdaptor(const CGSCCToFunctionPassAdaptor &Arg)
Result run(Function &)
Run the analysis pass and create our proxy result object.
A lazily constructed view of the call graph of a module.
CGSCCAnalysisManagerModuleProxy(CGSCCAnalysisManagerModuleProxy &&Arg)
Result run(LazyCallGraph::SCC &C)
Run the analysis pass and create our proxy result object.
Result(const Result &Arg)
ModuleToPostOrderCGSCCPassAdaptor(CGSCCPassT Pass)
An abstract set of preserved analyses following a transformation pass run.
The core module pass which does a post-order walk of the SCCs and runs a CGSCC pass over each one...
Result(const Result &Arg)
friend void swap(ModuleToPostOrderCGSCCPassAdaptor &LHS, ModuleToPostOrderCGSCCPassAdaptor &RHS)
CGSCCAnalysisManagerFunctionProxy(const CGSCCAnalysisManagerFunctionProxy &Arg)
friend void swap(CGSCCToFunctionPassAdaptor &LHS, CGSCCToFunctionPassAdaptor &RHS)
FunctionAnalysisManager & getManager()
Accessor for the FunctionAnalysisManager.
Result(const Result &Arg)
A node in the call graph.
CGSCCToFunctionPassAdaptor(FunctionPassT Pass)
bool invalidate(LazyCallGraph::SCC &C, const PreservedAnalyses &PA)
Handler for invalidation of the SCC.
Result & operator=(Result RHS)
static PreservedAnalyses all()
Construct a special preserved set that preserves all passes.
bool invalidate(Function &)
Handle invalidation by ignoring it, this pass is immutable.
void invalidate(IRUnitT &IR)
Invalidate a specific analysis pass for an IR module.
iterator_range< postorder_scc_iterator > postorder_sccs()
A module analysis which acts as a proxy for a CGSCC analysis manager.
PassT::Result & getResult(IRUnitT &IR)
Get the result of an analysis pass for this module.
FunctionAnalysisManagerCGSCCProxy(FunctionAnalysisManagerCGSCCProxy &&Arg)
void swap(llvm::BitVector &LHS, llvm::BitVector &RHS)
Implement std::swap in terms of BitVector swap.
FunctionAnalysisManagerCGSCCProxy & operator=(FunctionAnalysisManagerCGSCCProxy RHS)
Result & operator=(Result RHS)
CGSCCToFunctionPassAdaptor(CGSCCToFunctionPassAdaptor &&Arg)
ModuleAnalysisManagerCGSCCProxy(const ModuleAnalysisManager &MAM)
Adaptor that maps from a SCC to its functions.
Result(CGSCCAnalysisManager &CGAM)
PreservedAnalyses run(Module &M, ModuleAnalysisManager *AM)
Runs the CGSCC pass across every SCC in the module.
Result(const CGSCCAnalysisManager &CGAM)
Manages a sequence of passes over units of IR.
A CGSCC analysis which acts as a proxy for a module analysis manager.
ModuleAnalysisManagerCGSCCProxy(ModuleAnalysisManagerCGSCCProxy &&Arg)
void preserve()
Mark a particular pass as preserved, adding it to the set.
const ModuleAnalysisManager & getManager() const
An analysis pass which computes the call graph for a module.
CGSCCAnalysisManagerFunctionProxy(const CGSCCAnalysisManager &CGAM)
Result(const ModuleAnalysisManager &MAM)
An SCC of the call graph.
StringRef - Represent a constant reference to a string, i.e.
A generic analysis pass manager with lazy running and caching of results.
CGSCCAnalysisManagerFunctionProxy(CGSCCAnalysisManagerFunctionProxy &&Arg)
This header defines various interfaces for pass management in LLVM.
Result & operator=(Result RHS)
Result(const Result &Arg)
Result & operator=(Result RHS)
CGSCCAnalysisManagerModuleProxy(const CGSCCAnalysisManagerModuleProxy &Arg)
AnalysisManager< LazyCallGraph::SCC > CGSCCAnalysisManager
The CGSCC analysis manager.