llvm-6502/lib/Transforms
Chandler Carruth 5f61e70eac [vectorize] Initial version of respecting PGO in the vectorizer: treat
cold loops as-if they were being optimized for size.

Nothing fancy here. Simply test case included. The nice thing is that we
can now incrementally build on top of this to drive other heuristics.
All of the infrastructure work is done to get the profile information
into this layer.

The remaining work necessary to make this a fully general purpose loop
unroller for very hot loops is to make it a fully general purpose loop
unroller. Things I know of but am not going to have time to benchmark
and fix in the immediate future:

1) Don't disable the entire pass when the target is lacking vector
   registers. This really doesn't make any sense any more.
2) Teach the unroller at least and the vectorizer potentially to handle
   non-if-converted loops. This is trivial for the unroller but hard for
   the vectorizer.
3) Compute the relative hotness of the loop and thread that down to the
   various places that make cost tradeoffs (very likely only the
   unroller makes sense here, and then only when dealing with loops that
   are small enough for unrolling to not completely blow out the LSD).

I'm still dubious how useful hotness information will be. So far, my
experiments show that if we can get the correct logic for determining
when unrolling actually helps performance, the code size impact is
completely unimportant and we can unroll in all cases. But at least
we'll no longer burn code size on cold code.

One somewhat unrelated idea that I've had forever but not had time to
implement: mark all functions which are only reachable via the global
constructors rigging in the module as optsize. This would also decrease
the impact of any more aggressive heuristics here on code size.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@200219 91177308-0d34-0410-b5e6-96231b3b80d8
2014-01-27 13:11:50 +00:00
..
Hello
InstCombine InstCombine: Don't try to use aggregate elements of ConstantExprs. 2014-01-24 19:02:37 +00:00
Instrumentation Fix known typos 2014-01-24 17:20:08 +00:00
IPO Fix known typos 2014-01-24 17:20:08 +00:00
ObjCARC Fix known typos 2014-01-24 17:20:08 +00:00
Scalar ConstantHoisting: We can't insert instructions directly in front of a PHI node. 2014-01-27 13:11:43 +00:00
Utils [LPM] Make LCSSA a utility with a FunctionPass that applies it to all 2014-01-25 04:07:24 +00:00
Vectorize [vectorize] Initial version of respecting PGO in the vectorizer: treat 2014-01-27 13:11:50 +00:00
CMakeLists.txt
LLVMBuild.txt
Makefile