summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGExprConstant.cpp
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2012-01-10 01:45:08 +0000
committerAndrew Trick <atrick@apple.com>2012-01-10 01:45:08 +0000
commitd5d2db9af9081582e97ad9595957748eb7f08ff8 (patch)
tree9684ed082ba1d45b58eca18eb45cf69b8b381b5f /clang/lib/CodeGen/CGExprConstant.cpp
parentf09a3165421849db96c2847ed6c7d8c59fafdb49 (diff)
downloadbcm5719-llvm-d5d2db9af9081582e97ad9595957748eb7f08ff8.tar.gz
bcm5719-llvm-d5d2db9af9081582e97ad9595957748eb7f08ff8.zip
Enable LSR IV Chains with sufficient heuristics.
These heuristics are sufficient for enabling IV chains by default. Performance analysis has been done for i386, x86_64, and thumbv7. The optimization is rarely important, but can significantly speed up certain cases by eliminating spill code within the loop. Unrolled loops are prime candidates for IV chains. In many cases, the final code could still be improved with more target specific optimization following LSR. The goal of this feature is for LSR to make the best choice of induction variables. Instruction selection may not completely take advantage of this feature yet. As a result, there could be cases of slight code size increase. Code size can be worse on x86 because it doesn't support postincrement addressing. In fact, when chains are formed, you may see redundant address plus stride addition in the addressing mode. GenerateIVChains tries to compensate for the common cases. On ARM, code size increase can be mitigated by using postincrement addressing, but downstream codegen currently misses some opportunities. llvm-svn: 147826
Diffstat (limited to 'clang/lib/CodeGen/CGExprConstant.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud