aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/ProfileInfo.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2009-08-08 18:59:03 +0000
committerDaniel Dunbar <daniel@zuster.org>2009-08-08 18:59:03 +0000
commitc43782cf7163805fb6d727382b5f807ea035b2b0 (patch)
tree6d66db6a874af9d7c48d4357655665c547c1ffd0 /lib/Analysis/ProfileInfo.cpp
parent55e354ac0e294bde258420f80a2cc11ea19db482 (diff)
Some ProfileInfo cleanups.
- Part of optimal static profiling patch sequence by Andreas Neustifter. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78485 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/ProfileInfo.cpp')
-rw-r--r--lib/Analysis/ProfileInfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Analysis/ProfileInfo.cpp b/lib/Analysis/ProfileInfo.cpp
index 670d4e7379..2ed466bf32 100644
--- a/lib/Analysis/ProfileInfo.cpp
+++ b/lib/Analysis/ProfileInfo.cpp
@@ -64,6 +64,7 @@ double ProfileInfo::getExecutionCount(const BasicBlock *BB) {
}
double ProfileInfo::getExecutionCount(const Function *F) {
+ if (F->isDeclaration()) return MissingValue;
std::map<const Function*, double>::iterator J =
FunctionInformation.find(F);
if (J != FunctionInformation.end())