[llvm] [NFC][Scalarizer][TargetTransformInfo] Add `isVectorIntrinsicWithOverloadTypeAtArg` api (PR #114849)

Justin Bogner via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 13 14:58:13 PST 2024


bogner wrote:

We really should be updating the other users of the `isVectorIntrinsicWithOverloadTypeAtArg` API to be passing in the `TTI`, or at least explicitly opting out of it if it makes sense. I think we should not have a default `nullptr` for the TTI argument here, as that makes it easy to misuse.

As for updating the vectorizer uses:
- SLPVectorizer should be easy to do, since the pass already uses TTI elsewhere
- VPlanRecipes is probably also not too hard, as it looks like TTI is used in some places there as well
- ReplaceWithVeclib would need to add a dependency on TTI. It might be okay to have that one pass in a null TTI though, since a target specific vectorizable function probably isn't going to be replaced with a generic vector library function anyway.

https://github.com/llvm/llvm-project/pull/114849


More information about the llvm-commits mailing list