[PATCH] D90554: [CostModel] remove cost-kind predicate for intrinsics in basic TTI implementation
Sanjay Patel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 13 04:38:43 PST 2020
spatel added a comment.
In D90554#2393351 <https://reviews.llvm.org/D90554#2393351>, @mstorsjo wrote:
> In D90554#2385414 <https://reviews.llvm.org/D90554#2385414>, @spatel wrote:
>
>> Thanks, all!
>> It's almost inevitable that some target will regress on some intrinsic with this change, so I'll be watching for fallout.
>
> I noticed a change in behaviour due to this commit - on ARM and AArch64, for cases involving the log2 intrinsic - previously, llvm was able to evaluate a big pile of code to deduce that a comparison involving log2 always is true, but after this change, it no longer does that. Is that something you want to have a look into, or is that expected? I wouldn't classify it as a bug in itself, as the code does what it's supposed to, it just optimizes differently than before.
If you can reduce a test that shows the difference, that would be great. I'm not sure which pass was responsible for the optimization.
My first guess is that we should create a basic class size-cost exception for all of the scalar intrinsics that correspond to libm functions.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D90554/new/
https://reviews.llvm.org/D90554
More information about the llvm-commits
mailing list