OSDN Git Service

For each loop, keep track of all the IV expressions inserted indexed by
authorEvan Cheng <evan.cheng@apple.com>
Thu, 16 Mar 2006 21:53:05 +0000 (21:53 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Thu, 16 Mar 2006 21:53:05 +0000 (21:53 +0000)
commitd1d6b5cce260808deeac0227b00f6f81a20b2c6f
treedf35ecccc9fe1d71c82392ee45d624563b672491
parent714554d70717c73e0542ca93df36fa78765f87af
For each loop, keep track of all the IV expressions inserted indexed by
stride. For a set of uses of the IV of a stride which is a multiple
of another stride, do not insert a new IV expression. Rather, reuse the
previous IV and rewrite the uses as uses of IV expression multiplied by
the factor.

e.g.
x = 0 ...; x ++
y = 0 ...; y += 4
then use of y can be rewritten as use of 4*x for x86.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26803 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Transforms/Scalar.h
lib/Transforms/Scalar/LoopStrengthReduce.cpp