Fixes PR2395. Looking for a constant in a GEP tail (when the first GEP
authorWojciech Matyjewicz <wmatyjewicz@fastmail.fm>
Mon, 2 Jun 2008 17:26:12 +0000 (17:26 +0000)
committerWojciech Matyjewicz <wmatyjewicz@fastmail.fm>
Mon, 2 Jun 2008 17:26:12 +0000 (17:26 +0000)
commit98e3a6829aaf070a8893a164d6dc8c75f9f9feaa
tree9c370b392634c81157b1ea1af941e872f60b3c49
parent370a25c16af4394c2e800d63f9c7c0350f868948
Fixes PR2395. Looking for a constant in a GEP tail (when the first GEP
is longer than the second one) should stop after finding one. Added break
instruction guarantees it. It also changes difference between offsets to
absolute value of this difference in the condition.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51875 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Analysis/BasicAliasAnalysis.cpp
test/Analysis/BasicAA/2008-06-02-GEPTailCrash.ll [new file with mode: 0644]