[NFC][IRCE] Remove meaningless local variable
authorMax Kazantsev <mkazantsev@azul.com>
Thu, 13 Apr 2023 06:04:45 +0000 (13:04 +0700)
committerMax Kazantsev <mkazantsev@azul.com>
Thu, 13 Apr 2023 06:04:45 +0000 (13:04 +0700)
llvm/lib/Transforms/Scalar/InductiveRangeCheckElimination.cpp

index 0241b40..7be124b 100644 (file)
@@ -1054,14 +1054,11 @@ static const SCEV *NoopOrExtend(const SCEV *S, Type *Ty, ScalarEvolution &SE,
 
 std::optional<LoopConstrainer::SubRanges>
 LoopConstrainer::calculateSubRanges(bool IsSignedPredicate) const {
-  const IntegerType *Ty = ExitCountTy;
-
   auto *RTy = cast<IntegerType>(Range.getType());
-
   // We only support wide range checks and narrow latches.
-  if (!AllowNarrowLatchCondition && RTy != Ty)
+  if (!AllowNarrowLatchCondition && RTy != ExitCountTy)
     return std::nullopt;
-  if (RTy->getBitWidth() < Ty->getBitWidth())
+  if (RTy->getBitWidth() < ExitCountTy->getBitWidth())
     return std::nullopt;
 
   LoopConstrainer::SubRanges Result;