projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7334b15
)
Use Function::getEntryBlock() instead of Function::front(), for clarity.
author
Dan Gohman
<gohman@apple.com>
Tue, 21 Oct 2008 03:10:28 +0000
(
03:10
+0000)
committer
Dan Gohman
<gohman@apple.com>
Tue, 21 Oct 2008 03:10:28 +0000
(
03:10
+0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57870
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/Instrumentation/BlockProfiling.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/Instrumentation/BlockProfiling.cpp
b/lib/Transforms/Instrumentation/BlockProfiling.cpp
index acde01888ca47f1ece8832a12a759dbbeafaf490..2bd9809a396150e0547f2a95733ca45879d8f42f 100644
(file)
--- a/
lib/Transforms/Instrumentation/BlockProfiling.cpp
+++ b/
lib/Transforms/Instrumentation/BlockProfiling.cpp
@@
-72,7
+72,7
@@
bool FunctionProfiler::runOnModule(Module &M) {
for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I)
if (!I->isDeclaration())
// Insert counter at the start of the function
- IncrementCounterInBlock(
I->begin
(), i++, Counters);
+ IncrementCounterInBlock(
&I->getEntryBlock
(), i++, Counters);
// Add the initialization call to main.
InsertProfilingInitCall(Main, "llvm_start_func_profiling", Counters);