[IndVars] Use isSCEVable; NFC
authorSanjoy Das <sanjoy@playingwithpointers.com>
Wed, 27 Jan 2016 17:05:06 +0000 (17:05 +0000)
committerSanjoy Das <sanjoy@playingwithpointers.com>
Wed, 27 Jan 2016 17:05:06 +0000 (17:05 +0000)
llvm-svn: 258945

llvm/lib/Transforms/Scalar/IndVarSimplify.cpp

index f47eaf9..b9d3bf5 100644 (file)
@@ -564,8 +564,7 @@ void IndVarSimplify::rewriteLoopExitValues(Loop *L, SCEVExpander &Rewriter) {
       if (PN->use_empty())
         continue; // dead use, don't replace it
 
-      // SCEV only supports integer expressions for now.
-      if (!PN->getType()->isIntegerTy() && !PN->getType()->isPointerTy())
+      if (!SE->isSCEVable(PN->getType()))
         continue;
 
       // It's necessary to tell ScalarEvolution about this explicitly so that