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

Farzon Lotfi via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 13 15:20:45 PST 2024


farzonl 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.

Does it make sense to make a few issues for this and let this pr go in as is? I started this pattern with some of the other isVectorIntrinsic functions so feels like the cleanup should cover all the functions.  


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


More information about the llvm-commits mailing list