From 0483d018c4f15f206a83364e498957127e74f431 Mon Sep 17 00:00:00 2001 From: Nuno Lopes Date: Tue, 30 Sep 2008 22:04:30 +0000 Subject: [PATCH] add preserversCFG() + preservers(CallGraph) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56887 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Transforms/IPO/Internalize.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/Transforms/IPO/Internalize.cpp b/lib/Transforms/IPO/Internalize.cpp index cbfccf2a2c7..4a30e1443f8 100644 --- a/lib/Transforms/IPO/Internalize.cpp +++ b/lib/Transforms/IPO/Internalize.cpp @@ -14,6 +14,7 @@ //===----------------------------------------------------------------------===// #define DEBUG_TYPE "internalize" +#include "llvm/Analysis/CallGraph.h" #include "llvm/Transforms/IPO.h" #include "llvm/Pass.h" #include "llvm/Module.h" @@ -52,6 +53,11 @@ namespace { explicit InternalizePass(const std::vector & exportList); void LoadFile(const char *Filename); virtual bool runOnModule(Module &M); + + virtual void getAnalysisUsage(AnalysisUsage &AU) const { + AU.setPreservesCFG(); + AU.addPreserved(); + } }; } // end anonymous namespace