Alex Susu via llvm-dev
2017-Aug-16 13:27 UTC
[llvm-dev] LoopVectorize - determine the bounds of the original loop
Hello. Is there an easy way to obtain in the LoopVectorize module the upper and lower bounds of the loop being vectorized - I wasn't really able to find in the original code of LoopVectorize code calculating these bounds, although I know this module quite well and I am wondering if maybe they are already computed. (I put a similar question at http://lists.llvm.org/pipermail/llvm-dev/2016-August/103988.html ) . I have to admit I don't know well the ScalarEvolution class but I think I can also use ScalarEvolution's getUnsignedRangeMax() and getUnsignedRangeMin(), but these are newer methods added to ScalarEvolution in the last months and I normally work on an older LLVM trunk. Any help would be appreciated. Thank you, Alex
Sanjoy Das via llvm-dev
2017-Aug-19 20:21 UTC
[llvm-dev] LoopVectorize - determine the bounds of the original loop
Hi Alex, Did you take a look at ScalarEvolution::getBackedgeTakenCount() ? -- Sanjoy On Wed, Aug 16, 2017 at 6:27 AM, Alex Susu via llvm-dev <llvm-dev at lists.llvm.org> wrote:> Hello. > Is there an easy way to obtain in the LoopVectorize module the upper and > lower bounds of the loop being vectorized - I wasn't really able to find in > the original code of LoopVectorize code calculating these bounds, although I > know this module quite well and I am wondering if maybe they are already > computed. (I put a similar question at > http://lists.llvm.org/pipermail/llvm-dev/2016-August/103988.html ) . > > I have to admit I don't know well the ScalarEvolution class but I think > I can also use ScalarEvolution's getUnsignedRangeMax() and > getUnsignedRangeMin(), but these are newer methods added to ScalarEvolution > in the last months and I normally work on an older LLVM trunk. > > Any help would be appreciated. > > Thank you, > Alex > _______________________________________________ > LLVM Developers mailing list > llvm-dev at lists.llvm.org > http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev