diff options
Diffstat (limited to 'llvm/lib/Analysis/IPA/Andersens.cpp')
-rw-r--r-- | llvm/lib/Analysis/IPA/Andersens.cpp | 29 |
1 files changed, 14 insertions, 15 deletions
diff --git a/llvm/lib/Analysis/IPA/Andersens.cpp b/llvm/lib/Analysis/IPA/Andersens.cpp index ab80bab95c7..823a32f85fe 100644 --- a/llvm/lib/Analysis/IPA/Andersens.cpp +++ b/llvm/lib/Analysis/IPA/Andersens.cpp @@ -89,14 +89,14 @@ STATISTIC(NumNodes , "Number of nodes"); STATISTIC(NumUnified , "Number of variables unified"); STATISTIC(NumErased , "Number of redundant constraints erased"); -namespace { - const unsigned SelfRep = (unsigned)-1; - const unsigned Unvisited = (unsigned)-1; - // Position of the function return node relative to the function node. - const unsigned CallReturnPos = 1; - // Position of the function call node relative to the function node. - const unsigned CallFirstArgPos = 2; +static const unsigned SelfRep = (unsigned)-1; +static const unsigned Unvisited = (unsigned)-1; +// Position of the function return node relative to the function node. +static const unsigned CallReturnPos = 1; +// Position of the function call node relative to the function node. +static const unsigned CallFirstArgPos = 2; +namespace { struct BitmapKeyInfo { static inline SparseBitVector<> *getEmptyKey() { return reinterpret_cast<SparseBitVector<> *>(-1); @@ -608,16 +608,15 @@ namespace { PrintPointsToGraph(); } }; +} - char Andersens::ID = 0; - RegisterPass<Andersens> X("anders-aa", - "Andersen's Interprocedural Alias Analysis", false, - true); - RegisterAnalysisGroup<AliasAnalysis> Y(X); +char Andersens::ID = 0; +static RegisterPass<Andersens> +X("anders-aa", "Andersen's Interprocedural Alias Analysis", false, true); +static RegisterAnalysisGroup<AliasAnalysis> Y(X); - // Initialize Timestamp Counter (static). - unsigned Andersens::Node::Counter = 0; -} +// Initialize Timestamp Counter (static). +unsigned Andersens::Node::Counter = 0; ModulePass *llvm::createAndersensPass() { return new Andersens(); } |