[ScopInfo] Scalar access do not have indirect base pointers.
authorMichael Kruse <llvm@meinersbur.de>
Tue, 4 Oct 2016 17:33:34 +0000 (17:33 +0000)
committerMichael Kruse <llvm@meinersbur.de>
Tue, 4 Oct 2016 17:33:34 +0000 (17:33 +0000)
commitca7cbcca373c8ae451b36a9c033d967dde35dcdf
tree6d61ec4113fe1a586926ec77c3463ad9128cd535
parent0428e93217a55384f08c754ca8353a55334f3ef8
[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.

llvm-svn: 283232
polly/lib/Analysis/ScopInfo.cpp
polly/test/ScopInfo/non_affine_region_4.ll
polly/test/ScopInfo/scalar.ll