diff options
Diffstat (limited to 'lib/Analysis/ProfileInfo.cpp')
-rw-r--r-- | lib/Analysis/ProfileInfo.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Analysis/ProfileInfo.cpp b/lib/Analysis/ProfileInfo.cpp index 719eeada15..6eead0fd6e 100644 --- a/lib/Analysis/ProfileInfo.cpp +++ b/lib/Analysis/ProfileInfo.cpp @@ -33,7 +33,7 @@ unsigned ProfileInfo::getExecutionCount(BasicBlock *BB) const { // Are there zero predecessors of this block? if (PI == PE) { // If this is the entry block, look for the Null -> Entry edge. - if (BB == &BB->getParent()->front()) + if (BB == &BB->getParent()->getEntryBlock()) return getEdgeWeight(0, BB); else return 0; // Otherwise, this is a dead block. |