[llvm-commits] [llvm] r56887 - /llvm/trunk/lib/Transforms/IPO/Internalize.cpp
Nuno Lopes
nunoplopes at sapo.pt
Tue Sep 30 15:04:30 PDT 2008
Author: nlopes
Date: Tue Sep 30 17:04:30 2008
New Revision: 56887
URL: http://llvm.org/viewvc/llvm-project?rev=56887&view=rev
Log:
add preserversCFG() + preservers(CallGraph)
Modified:
llvm/trunk/lib/Transforms/IPO/Internalize.cpp
Modified: llvm/trunk/lib/Transforms/IPO/Internalize.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/IPO/Internalize.cpp?rev=56887&r1=56886&r2=56887&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/IPO/Internalize.cpp (original)
+++ llvm/trunk/lib/Transforms/IPO/Internalize.cpp Tue Sep 30 17:04:30 2008
@@ -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 @@
explicit InternalizePass(const std::vector <const char *>& exportList);
void LoadFile(const char *Filename);
virtual bool runOnModule(Module &M);
+
+ virtual void getAnalysisUsage(AnalysisUsage &AU) const {
+ AU.setPreservesCFG();
+ AU.addPreserved<CallGraph>();
+ }
};
} // end anonymous namespace
More information about the llvm-commits
mailing list