[llvm] r328764 - [NFC] Fix meaningless assert in SCEV

Max Kazantsev via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 29 00:54:59 PDT 2018


Author: mkazantsev
Date: Thu Mar 29 00:54:59 2018
New Revision: 328764

URL: http://llvm.org/viewvc/llvm-project?rev=328764&view=rev
Log:
[NFC] Fix meaningless assert in SCEV

Modified:
    llvm/trunk/lib/Analysis/ScalarEvolution.cpp

Modified: llvm/trunk/lib/Analysis/ScalarEvolution.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/ScalarEvolution.cpp?rev=328764&r1=328763&r2=328764&view=diff
==============================================================================
--- llvm/trunk/lib/Analysis/ScalarEvolution.cpp (original)
+++ llvm/trunk/lib/Analysis/ScalarEvolution.cpp Thu Mar 29 00:54:59 2018
@@ -8720,13 +8720,13 @@ bool ScalarEvolution::isKnownViaInductio
   // if LHS contains unknown non-invariant SCEV then bail out.
   if (SplitLHS.first == getCouldNotCompute())
     return false;
-  assert (SplitLHS.first != getCouldNotCompute() && "Unexpected CNC");
+  assert (SplitLHS.second != getCouldNotCompute() && "Unexpected CNC");
   // Get init and post increment value for RHS.
   auto SplitRHS = SplitIntoInitAndPostInc(MDL, RHS);
   // if RHS contains unknown non-invariant SCEV then bail out.
   if (SplitRHS.first == getCouldNotCompute())
     return false;
-  assert (SplitRHS.first != getCouldNotCompute() && "Unexpected CNC");
+  assert (SplitRHS.second != getCouldNotCompute() && "Unexpected CNC");
   // It is possible that init SCEV contains an invariant load but it does
   // not dominate MDL and is not available at MDL loop entry, so we should
   // check it here.




More information about the llvm-commits mailing list