[ScopInfo] Scalar access do not have indirect base pointers.
commita41d16111e6090481e7516d23dc0b98b6fe9983b
authorMichael Kruse <llvm@meinersbur.de>
Tue, 4 Oct 2016 17:33:34 +0000 (4 17:33 +0000)
committerMichael Kruse <llvm@meinersbur.de>
Tue, 4 Oct 2016 17:33:34 +0000 (4 17:33 +0000)
tree5605f6ae41f306b56a71eedd3881f84ab82b80cf
parent27679c63116f8a933019598f9cbfbe7254b666da
[ScopInfo] Scalar access do not have indirect base pointers.

ScopArrayInfo used to determine base pointer origins by looking up whether the
base pointer is a load. The "base pointer" for scalar accesses is the
llvm::Value being accessed. This is only a symbolic base pointer, it
represents the alloca variable (.s2a or .phiops) generated for it at code
generation.

This patch disables determining base pointer origin for scalars.
A test case where this caused a crash will be added in the next commit. In that
test SAI tried to get the origin base pointer that was only declared later,
therefore not existing. This is probably only possible for scalars used in
PHINode incoming blocks.

git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@283232 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Analysis/ScopInfo.cpp
test/ScopInfo/non_affine_region_4.ll
test/ScopInfo/scalar.ll