[SCEV] Slightly generalize getRangeViaFactoring
authorSanjoy Das <sanjoy@playingwithpointers.com>
Wed, 9 Mar 2016 01:51:02 +0000 (01:51 +0000)
committerSanjoy Das <sanjoy@playingwithpointers.com>
Wed, 9 Mar 2016 01:51:02 +0000 (01:51 +0000)
commit97d19bd95fb724c937cf3e32d91296fe12476ad5
tree88c659f69bb88213c80ab1896333b65faa2e57a1
parentd3488c6060efc5cc554c15d30917c25acf98eeaa
[SCEV] Slightly generalize getRangeViaFactoring

Building on the previous change, this generalizes
ScalarEvolution::getRangeViaFactoring to work with
{Ext(C?A:B)+k0,+,Ext(C?A:B)+k1} where Ext can be a zero extend, sign
extend or truncate operation, and k0 and k1 are constants.

llvm-svn: 262979
llvm/lib/Analysis/ScalarEvolution.cpp
llvm/test/Analysis/ScalarEvolution/increasing-or-decreasing-iv.ll