[PATCH] D107009: [WIP][X86] combineX86ShuffleChain(): canonicalize mask elts picking from splats
Roman Lebedev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 4 07:25:38 PDT 2021
lebedev.ri marked an inline comment as done.
lebedev.ri added inline comments.
================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:35838
+ // This may allow to simplify the shuffle into a blend.
+ SmallVector<int> NewMask;
+ if (InputIsSplat[0] || InputIsSplat[1]) {
----------------
RKSimon wrote:
> lebedev.ri wrote:
> > RKSimon wrote:
> > > Move this inside the if() ?
> > This can't work, because `BaseMask` is an `ArrayRef`,
> > so if we narrow the scope of `NewMask`,
> > then we can't assign it to `BaseMask`,
> > because that would result in use-after-scope.
> >
> > Later in the function we have `SmallVector<int, 64> Mask;` with the same purpose,
> > so the solution is to change the code inbetween to use `NewMask` instead of `BaseMask`,
> > but that is a separate change that i will do afterwards.
> OK - got it - cheers
Done in rG35c0848b570214ed2b2d96cca4dd62bb7ae725cd.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D107009/new/
https://reviews.llvm.org/D107009
More information about the llvm-commits
mailing list