summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Instrumentation
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2007-02-05 21:19:13 +0000
committerReid Spencer <rspencer@reidspencer.com>2007-02-05 21:19:13 +0000
commit1241d6d5abb58dc8af3f3dc8edc3d3b3158111a4 (patch)
treead451cdec90d6387b43be20fdfdd733e8003a1b6 /llvm/lib/Transforms/Instrumentation
parent3c52e275ea70ff0466b7a49f14ae02fa136f52f7 (diff)
downloadbcm5719-llvm-1241d6d5abb58dc8af3f3dc8edc3d3b3158111a4.tar.gz
bcm5719-llvm-1241d6d5abb58dc8af3f3dc8edc3d3b3158111a4.zip
For PR411:
Adjust to changes in Module interface: getMainFunction() -> getFunction("main") getNamedFunction(X) -> getFunction(X) llvm-svn: 33922
Diffstat (limited to 'llvm/lib/Transforms/Instrumentation')
-rw-r--r--llvm/lib/Transforms/Instrumentation/BlockProfiling.cpp4
-rw-r--r--llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp2
-rw-r--r--llvm/lib/Transforms/Instrumentation/TraceBasicBlocks.cpp2
3 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Transforms/Instrumentation/BlockProfiling.cpp b/llvm/lib/Transforms/Instrumentation/BlockProfiling.cpp
index add1bf01ef0..23f2093499c 100644
--- a/llvm/lib/Transforms/Instrumentation/BlockProfiling.cpp
+++ b/llvm/lib/Transforms/Instrumentation/BlockProfiling.cpp
@@ -45,7 +45,7 @@ ModulePass *llvm::createFunctionProfilerPass() {
}
bool FunctionProfiler::runOnModule(Module &M) {
- Function *Main = M.getMainFunction();
+ Function *Main = M.getFunction("main");
if (Main == 0) {
cerr << "WARNING: cannot insert function profiling into a module"
<< " with no main function!\n";
@@ -88,7 +88,7 @@ namespace {
ModulePass *llvm::createBlockProfilerPass() { return new BlockProfiler(); }
bool BlockProfiler::runOnModule(Module &M) {
- Function *Main = M.getMainFunction();
+ Function *Main = M.getFunction("main");
if (Main == 0) {
cerr << "WARNING: cannot insert block profiling into a module"
<< " with no main function!\n";
diff --git a/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp b/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp
index 97b5d5ca424..4960d3c2065 100644
--- a/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp
+++ b/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp
@@ -40,7 +40,7 @@ namespace {
ModulePass *llvm::createEdgeProfilerPass() { return new EdgeProfiler(); }
bool EdgeProfiler::runOnModule(Module &M) {
- Function *Main = M.getMainFunction();
+ Function *Main = M.getFunction("main");
if (Main == 0) {
cerr << "WARNING: cannot insert edge profiling into a module"
<< " with no main function!\n";
diff --git a/llvm/lib/Transforms/Instrumentation/TraceBasicBlocks.cpp b/llvm/lib/Transforms/Instrumentation/TraceBasicBlocks.cpp
index 68e0d282cc5..4c09fb61c58 100644
--- a/llvm/lib/Transforms/Instrumentation/TraceBasicBlocks.cpp
+++ b/llvm/lib/Transforms/Instrumentation/TraceBasicBlocks.cpp
@@ -58,7 +58,7 @@ static void InsertInstrumentationCall (BasicBlock *BB,
}
bool TraceBasicBlocks::runOnModule(Module &M) {
- Function *Main = M.getMainFunction();
+ Function *Main = M.getFunction("main");
if (Main == 0) {
cerr << "WARNING: cannot insert basic-block trace instrumentation"
<< " into a module with no main function!\n";
OpenPOWER on IntegriCloud