[PPCGCodeGeneration] Teach Polly to start using live range reordering.
commita8c5597677d245309082604d431ce7be4d79ccd8
authorSiddharth Bhat <siddu.druid@gmail.com>
Wed, 5 Jul 2017 14:57:04 +0000 (5 14:57 +0000)
committerSiddharth Bhat <siddu.druid@gmail.com>
Wed, 5 Jul 2017 14:57:04 +0000 (5 14:57 +0000)
tree7ca1e9a0a4c71bdbf62545a61b161a9a90c74dab
parentae906fe404fb16fa5963cf79ec5501d5ec2b9564
[PPCGCodeGeneration] Teach Polly to start using live range reordering.

Polly did not use PPCG's live range reordering feature. Teach
PPCGCodeGeneration to use this.

Documentation on this is sparse, so much of the code is conservative.

We currently kill all phi nodes in a Scop by appending them to the
must_kill map we pass to PPCG. I do not have a proof of correctness,
but it seems to be intuitively correct.

We also do not handle `array_order`, which, quoting PPCG, is:
PPCG/gpu.h: "Order dependences on non-scalars."
It seems to consist of RAW dependences between arrays. We need to
pass this information for more complex privatization cases.

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

git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@307163 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/PPCGCodeGeneration.cpp
test/GPGPU/non-read-only-scalars.ll
test/GPGPU/phi-nodes-in-kernel.ll
test/GPGPU/privatization-simple.ll [new file with mode: 0644]
test/GPGPU/privatization.ll [new file with mode: 0644]