fix PR4848 an infinite loop when indexing down through a recursive gep
authorChris Lattner <sabre@nondot.org>
Wed, 2 Sep 2009 05:35:45 +0000 (05:35 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 2 Sep 2009 05:35:45 +0000 (05:35 +0000)
commitf19f9347b85279100f7d549154e37b6d726c3c94
treedb74b60eface483db794885f33c201e27dd71948
parent9e17b632ec7fdd150a2f08ed4b661011ed47dcfa
fix PR4848 an infinite loop when indexing down through a recursive gep
and we get the original pointer type.  This doesn't mean that we're
at the first pointer being indexed.  Correct the predicate.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80762 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Analysis/ConstantFolding.cpp
test/Transforms/ConstProp/2009-10-01-GEP-Crash.ll [new file with mode: 0644]