Teach LoopUnrollPass to respect loop unrolling hints in metadata.
authorEli Bendersky <eliben@google.com>
Mon, 16 Jun 2014 23:53:02 +0000 (23:53 +0000)
committerEli Bendersky <eliben@google.com>
Mon, 16 Jun 2014 23:53:02 +0000 (23:53 +0000)
commit4046db0cdb53b5383b2234f29d0ff478f5293b4b
tree43402be8bfb985ad02935835b8b6c5bbe8bce2ec
parent5ea46694d0b48eebcf04d9e1fc0dac6382356f32
Teach LoopUnrollPass to respect loop unrolling hints in metadata.

[This is resubmitting r210721, which was reverted due to suspected breakage
which turned out to be unrelated].

Some extra review comments were addressed. See D4090 and D4147 for more details.

The Clang change that produces this metadata was committed in r210667

Patch by Mark Heffernan.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@211076 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Scalar/LoopUnrollPass.cpp
test/Transforms/LoopUnroll/unroll-pragmas.ll [new file with mode: 0644]