Go to file
Hal Finkel 2eed29f3c8 Implement X86TTI::getUnrollingPreferences
This provides an initial implementation of getUnrollingPreferences for x86.
getUnrollingPreferences is used by the generic (concatenation) unroller, which
is distinct from the unrolling done by the loop vectorizer. Many modern x86
cores have some kind of uop cache and loop-stream detector (LSD) used to
efficiently dispatch small loops, and taking full advantage of this requires
unrolling small loops (small here means 10s of uops).

These caches also have limits on the number of taken branches in the loop, and
so we also cap the loop unrolling factor based on the maximum "depth" of the
loop. This is currently calculated with a partial DFS traversal (partial
because it will stop early if the path length grows too much). This is still an
approximation, and one that is both conservative (because it does not account
for branches eliminated via block placement) and optimistic (because it is only
recording the maximum depth over minimum paths). Nevertheless, because the
loops that fit in these uop caches are so small, it is not clear how much the
details matter.

The original set of patches posted for review produced the following test-suite
performance results (from the TSVC benchmark) at that time:
  ControlLoops-dbl - 13% speedup
  ControlLoops-flt - 15% speedup
  Reductions-dbl - 7.5% speedup

llvm-svn: 205348
2014-04-01 18:50:34 +00:00
clang Fix self-referential comment. 2014-04-01 18:33:50 +00:00
clang-tools-extra clang-modernize: fix invalid assignment in findClangApplyReplacements() 2014-03-30 10:50:25 +00:00
compiler-rt Move __addsf3 and __adddf3 into the corresponding blocks that define 2014-04-01 18:39:58 +00:00
debuginfo-tests relax testcase for LLDB output format compatibility. 2014-03-19 23:06:18 +00:00
libclc Introduce M_LOG2E_F and M_LOG2E 2014-03-28 21:19:03 +00:00
libcxx Use defined(__APPLE__) rather than __APPLE__ 2014-03-30 14:59:12 +00:00
libcxxabi Simplify. 2014-03-20 01:28:28 +00:00
lld s/dyn_cast/cast/ where return value should never be null. 2014-04-01 18:04:56 +00:00
lldb Use libc++ on FreeBSD as on Darwin 2014-04-01 18:47:58 +00:00
llvm Implement X86TTI::getUnrollingPreferences 2014-04-01 18:50:34 +00:00
openmp Revert commit (testing commit hook). 2014-03-04 18:06:04 +00:00
polly Delete trivial PHI nodes (aka stack slot sharing) 2014-04-01 16:01:33 +00:00