diff options
| author | Chandler Carruth <chandlerc@gmail.com> | 2014-04-17 07:22:19 +0000 |
|---|---|---|
| committer | Chandler Carruth <chandlerc@gmail.com> | 2014-04-17 07:22:19 +0000 |
| commit | 81f497d176acbb98421d4f4263ce46e91a9adc99 (patch) | |
| tree | 97529e58f7128d81af8ed7178b4c6cf75a1e1fce | |
| parent | 75f2ca47877ee1ad07e8709ecd55186609082c57 (diff) | |
| download | bcm5719-llvm-81f497d176acbb98421d4f4263ce46e91a9adc99.tar.gz bcm5719-llvm-81f497d176acbb98421d4f4263ce46e91a9adc99.zip | |
[LCG] Remove the Module reference member which we weren't using for
anything and doesn't make sense if assigning.
llvm-svn: 206449
| -rw-r--r-- | llvm/include/llvm/Analysis/LazyCallGraph.h | 2 | ||||
| -rw-r--r-- | llvm/lib/Analysis/LazyCallGraph.cpp | 6 |
2 files changed, 3 insertions, 5 deletions
diff --git a/llvm/include/llvm/Analysis/LazyCallGraph.h b/llvm/include/llvm/Analysis/LazyCallGraph.h index d5785e740ae..0215cfc11c4 100644 --- a/llvm/include/llvm/Analysis/LazyCallGraph.h +++ b/llvm/include/llvm/Analysis/LazyCallGraph.h @@ -209,8 +209,6 @@ public: } private: - Module &M; - /// \brief Allocator that holds all the call graph nodes. SpecificBumpPtrAllocator<Node> BPA; diff --git a/llvm/lib/Analysis/LazyCallGraph.cpp b/llvm/lib/Analysis/LazyCallGraph.cpp index ea213f27acb..17d7d894ce4 100644 --- a/llvm/lib/Analysis/LazyCallGraph.cpp +++ b/llvm/lib/Analysis/LazyCallGraph.cpp @@ -86,7 +86,7 @@ LazyCallGraph::Node::Node(LazyCallGraph &G, Node &&OtherN) Callee = G.moveInto(std::move(*ChildN)); } -LazyCallGraph::LazyCallGraph(Module &M) : M(M) { +LazyCallGraph::LazyCallGraph(Module &M) { for (Function &F : M) if (!F.isDeclaration() && !F.hasLocalLinkage()) if (EntryNodeSet.insert(&F)) @@ -104,7 +104,7 @@ LazyCallGraph::LazyCallGraph(Module &M) : M(M) { } LazyCallGraph::LazyCallGraph(const LazyCallGraph &G) - : M(G.M), EntryNodeSet(G.EntryNodeSet) { + : EntryNodeSet(G.EntryNodeSet) { EntryNodes.reserve(G.EntryNodes.size()); for (const auto &EntryNode : G.EntryNodes) if (Function *Callee = EntryNode.dyn_cast<Function *>()) @@ -117,7 +117,7 @@ LazyCallGraph::LazyCallGraph(const LazyCallGraph &G) // invalidating any of the allocated memory. We should make that be the case at // some point and delete this. LazyCallGraph::LazyCallGraph(LazyCallGraph &&G) - : M(G.M), EntryNodes(std::move(G.EntryNodes)), + : EntryNodes(std::move(G.EntryNodes)), EntryNodeSet(std::move(G.EntryNodeSet)) { // Loop over our EntryNodes. They've been moved from another graph, so we // need to move the Node*s to live under our bump ptr allocator. We can just |

