diff options
author | Sanjay Patel <spatel@rotateright.com> | 2015-01-09 16:28:15 +0000 |
---|---|---|
committer | Sanjay Patel <spatel@rotateright.com> | 2015-01-09 16:28:15 +0000 |
commit | d729115fa76e7c6c45da10ff4aad39088c1a5399 (patch) | |
tree | 3d4d940010d6302db10eed9dcd2edda582738be9 /llvm/lib/Analysis/LazyValueInfo.cpp | |
parent | b359b735d6c0b90f6cfe583002ac56e1cc633f30 (diff) | |
download | bcm5719-llvm-d729115fa76e7c6c45da10ff4aad39088c1a5399.tar.gz bcm5719-llvm-d729115fa76e7c6c45da10ff4aad39088c1a5399.zip |
more efficient use of a dyn_cast; no functional change intended
llvm-svn: 225523
Diffstat (limited to 'llvm/lib/Analysis/LazyValueInfo.cpp')
-rw-r--r-- | llvm/lib/Analysis/LazyValueInfo.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Analysis/LazyValueInfo.cpp b/llvm/lib/Analysis/LazyValueInfo.cpp index 342d1d13834..f7f5e32d442 100644 --- a/llvm/lib/Analysis/LazyValueInfo.cpp +++ b/llvm/lib/Analysis/LazyValueInfo.cpp @@ -905,9 +905,9 @@ static bool getEdgeValueLocal(Value *Val, BasicBlock *BBFrom, // If the condition of the branch is an equality comparison, we may be // able to infer the value. - ICmpInst *ICI = dyn_cast<ICmpInst>(BI->getCondition()); - if (getValueFromFromCondition(Val, ICI, Result, isTrueDest)) - return true; + if (ICmpInst *ICI = dyn_cast<ICmpInst>(BI->getCondition())) + if (getValueFromFromCondition(Val, ICI, Result, isTrueDest)) + return true; } } |