[llvm] [SLP][NFC] Remove useless code of deleting ExtractElementInst (PR #106697)

via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 30 05:19:39 PDT 2024


tcwzxx wrote:

> 
> No, they are still part of the buildvector, it's just SLP vectorizer is smart enough to vectorize them. removeInstructionsAndOperands works only for the scalars, which part of the Vectorize nodes

removeInstructionsAndOperands works only for the scalars, which part of the Vectorize nodes. And then it will check the operator of those scalars. 

The extractelements of buildvector must be the operators of vectorized scalars. Then it will be removed by  removeInstructionsAndOperands . Is there any exception?



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


More information about the llvm-commits mailing list