[ScopInliner] Add a simple Scop-based inliner to polly.
commit2fe4f23d5dcc910e32c7950383a92fc37c714897
authorSiddharth Bhat <siddu.druid@gmail.com>
Thu, 17 Aug 2017 21:57:23 +0000 (17 21:57 +0000)
committerSiddharth Bhat <siddu.druid@gmail.com>
Thu, 17 Aug 2017 21:57:23 +0000 (17 21:57 +0000)
tree5a273f43c176a85ffd62076a50ccf054d2c5f963
parentce782fc08a3b313e6fef8bcd6162a154735d7339
[ScopInliner] Add a simple Scop-based inliner to polly.

We add a ScopInliner pass which inlines functions based on a simple heuristic:
Let `g` call `f`.
If we can model all of `f` as a Scop, we inline `f` into `g`.

This requires `-polly-detect-full-function` to be enabled. So, the pass
asserts that `-polly-detect-full-function` is enabled.

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

git-svn-id: https://llvm.org/svn/llvm-project/polly/trunk@311126 91177308-0d34-0410-b5e6-96231b3b80d8
include/polly/LinkAllPasses.h
include/polly/ScopDetection.h
lib/Analysis/ScopDetection.cpp
lib/CMakeLists.txt
lib/Support/RegisterPasses.cpp
lib/Transform/ScopInliner.cpp [new file with mode: 0644]
test/ScopInliner/ignore-declares.ll [new file with mode: 0644]
test/ScopInliner/invariant-load-func.ll [new file with mode: 0644]
test/ScopInliner/simple-inline-loop.ll [new file with mode: 0644]