[all-commits] [llvm/llvm-project] 076e08: [LSR] Filter for postinc formulae
David Green via All-commits
all-commits at lists.llvm.org
Wed Jun 17 04:32:32 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: 076e08aa4501f682c43e71a8fed1e12da485abc7
https://github.com/llvm/llvm-project/commit/076e08aa4501f682c43e71a8fed1e12da485abc7
Author: David Green <david.green at arm.com>
Date: 2020-06-17 (Wed, 17 Jun 2020)
Changed paths:
M llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
M llvm/test/CodeGen/Thumb2/mve-float16regloops.ll
M llvm/test/CodeGen/Thumb2/mve-float32regloops.ll
Log Message:
-----------
[LSR] Filter for postinc formulae
In more complicated loops we can easily hit the complexity limits of
loop strength reduction. If we do and filtering occurs, it's all too
easy to remove the wrong formulae for post-inc preferring accesses due
to it attempting to maximise register re-use. The patch adds an
alternative filtering step when the target is preferring postinc to pick
postinc formulae instead, hopefully lowering the complexity to below the
limit so that aggressive filtering is not needed.
There is also a change in here to stop considering existing addrecs as
free under postinc. We should already be modelling them as a reg so
don't want it to cause us to get the cost wrong. (I'm not sure that code
makes sense in general, but there are X86 tests specifically for it
where it seems to be helping so have left it around for the standard
non-post-inc case).
Differential Revision: https://reviews.llvm.org/D80273
More information about the All-commits
mailing list