diff options
| author | Sanjay Patel <spatel@rotateright.com> | 2016-05-17 01:12:31 +0000 |
|---|---|---|
| committer | Sanjay Patel <spatel@rotateright.com> | 2016-05-17 01:12:31 +0000 |
| commit | 18254935c9d8f6fcf0e5f20c13d5b4ef5424bf94 (patch) | |
| tree | a9d0ac76ab4fc08fb6add489db6e1baadaed9712 | |
| parent | e9b2c32e7f0faa0c31c2c1cb44cbe9c9e234cd64 (diff) | |
| download | bcm5719-llvm-18254935c9d8f6fcf0e5f20c13d5b4ef5424bf94.tar.gz bcm5719-llvm-18254935c9d8f6fcf0e5f20c13d5b4ef5424bf94.zip | |
try to avoid unused variable warning in release build; NFCI
llvm-svn: 269729
| -rw-r--r-- | llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp b/llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp index 1ecd7aeb549..18036356c92 100644 --- a/llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp +++ b/llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp @@ -3121,7 +3121,8 @@ static ICmpInst *canonicalizeCmpWithConstant(ICmpInst &I) { Type *Op1Type = Op1->getType(); bool IsSigned = I.isSigned(); bool IsLE = (Pred == ICmpInst::ICMP_SLE || Pred == ICmpInst::ICMP_ULE); - if (auto *CI = dyn_cast<ConstantInt>(Op1C)) { + auto *CI = dyn_cast<ConstantInt>(Op1C); + if (CI) { // A <= MAX -> TRUE ; A >= MIN -> TRUE assert(IsLE ? !CI->isMaxValue(IsSigned) : !CI->isMinValue(IsSigned)); } else if (Op1Type->isVectorTy()) { |

