[PATCH] D40953: [SCEV] Fix predicate usage in computeExitLimitFromICmp

Max Kazantsev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 8 01:33:36 PST 2017


mkazantsev added inline comments.


================
Comment at: lib/Analysis/ScalarEvolution.cpp:7061
     Cond = ExitCond->getInversePredicate();
+  ICmpInst::Predicate OriginalCond = Cond;
 
----------------
sanjoy wrote:
> If possible, I'd suggest also cleaning this up a bit -- the variable should be called `Pred` and not `Cond` (a later NFC change is fine).
> 
> Also, how about making `OriginalCond` `const` so that it obviously can't be modified?
Fair point, I'll do it.


https://reviews.llvm.org/D40953





More information about the llvm-commits mailing list