[PPCGCodeGeneration] Correct usage of llvm::Value with getLatestValue.
commit2cbb22bce6100be71f5671d0d04ab06315f236a1
authorSiddharth Bhat <siddu.druid@gmail.com>
Tue, 1 Aug 2017 14:26:39 +0000 (1 14:26 +0000)
committerSiddharth Bhat <siddu.druid@gmail.com>
Tue, 1 Aug 2017 14:26:39 +0000 (1 14:26 +0000)
tree2b839cf284e2a704ab8c71e3e1fab82172fdd54f
parent17fb7046eafd1a9a537338577e7b8c3d68aeb426
[PPCGCodeGeneration] Correct usage of llvm::Value with getLatestValue.

It is possible that the `HostPtr` that coresponds to an array could be
invariant load hoisted. Make sure we use the invariant load hoisted
value by using `IslNodeBuilder::getLatestValue`.

Differential Revision: https://reviews.llvm.org/D36001

git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@309681 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/PPCGCodeGeneration.cpp
test/GPGPU/invariant-load-hoisting-of-array.ll [new file with mode: 0644]