aboutsummaryrefslogtreecommitdiffstats
path: root/lib/VMCore/Instructions.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2007-03-22 16:38:57 +0000
committerDan Gohman <gohman@apple.com>2007-03-22 16:38:57 +0000
commitecb7a77885b174cf4d001a9b48533b3979e7810d (patch)
treeed6b55df739771a7691a200f47883ddde4c45f53 /lib/VMCore/Instructions.cpp
parent2b48420c642de2fbf68a96d9b0bf45b5379455f3 (diff)
downloadexternal_llvm-ecb7a77885b174cf4d001a9b48533b3979e7810d.zip
external_llvm-ecb7a77885b174cf4d001a9b48533b3979e7810d.tar.gz
external_llvm-ecb7a77885b174cf4d001a9b48533b3979e7810d.tar.bz2
Change uses of Function::front to Function::getEntryBlock for readability.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35265 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Instructions.cpp')
-rw-r--r--lib/VMCore/Instructions.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/VMCore/Instructions.cpp b/lib/VMCore/Instructions.cpp
index 8c836a2..c7da56b 100644
--- a/lib/VMCore/Instructions.cpp
+++ b/lib/VMCore/Instructions.cpp
@@ -170,7 +170,7 @@ Value *PHINode::hasConstantValue(bool AllowNonDominatingInstruction) const {
if (HasUndefInput && !AllowNonDominatingInstruction)
if (Instruction *IV = dyn_cast<Instruction>(InVal))
// If it's in the entry block, it dominates everything.
- if (IV->getParent() != &IV->getParent()->getParent()->front() ||
+ if (IV->getParent() != &IV->getParent()->getParent()->getEntryBlock() ||
isa<InvokeInst>(IV))
return 0; // Cannot guarantee that InVal dominates this PHINode.