[all-commits] [llvm/llvm-project] f264da: [lsr][term-fold] Restrict transform to low cost ex...
Philip Reames via All-commits
all-commits at lists.llvm.org
Wed Jan 31 14:48:32 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: f264da432207064f4716f81485399ef127b57fd4
https://github.com/llvm/llvm-project/commit/f264da432207064f4716f81485399ef127b57fd4
Author: Philip Reames <preames at rivosinc.com>
Date: 2024-01-31 (Wed, 31 Jan 2024)
Changed paths:
M llvm/lib/Transforms/Scalar/LoopStrengthReduce.cpp
M llvm/test/Transforms/LoopStrengthReduce/lsr-term-fold.ll
Log Message:
-----------
[lsr][term-fold] Restrict transform to low cost expansions (#74747)
This is a follow up to an item I noted in my submission comment for
e947f95. I don't have a real world example where this is triggering
unprofitably, but avoiding the transform when we estimate the loop to be
short running from profiling seems quite reasonable. It's also now come
up as a possibility in a regression twice in two days, so I'd like to
get this in to close out the possibility if nothing else.
The original review dropped the threshold for short trip count loops. I
will return to that in a separate review if this lands.
More information about the All-commits
mailing list