]> granicus.if.org Git - llvm/commit
[IndVars] Fix a bug noticed by inspection
authorPhilip Reames <listmail@philipreames.com>
Fri, 23 Aug 2019 04:03:23 +0000 (04:03 +0000)
committerPhilip Reames <listmail@philipreames.com>
Fri, 23 Aug 2019 04:03:23 +0000 (04:03 +0000)
commit919a01374a87990df740c6f75e7921808054a5e7
treeedaac11006fdde9285280e56c1a2f2480fb287ad
parenta8fb688f582d4effc91181320aaa3ff603399444
[IndVars] Fix a bug noticed by inspection

We were computing the loop exit value, but not ensuring the addrec belonged to the loop whose exit value we were computing.  I couldn't actually trip this; the test case shows the basic setup which *might* trip this, but none of the variations I've tried actually do.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@369730 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/IndVarSimplify.cpp
test/Transforms/IndVarSimplify/rlev-add-me.ll