[X86] combineX86ShufflesRecursively - merge shuffles with more than 2 inputs
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 27 Jun 2019 17:30:51 +0000 (17:30 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Thu, 27 Jun 2019 17:30:51 +0000 (17:30 +0000)
We already had the infrastructure for this, but were waiting for the fix for a number of regressions which were handled by the recent shuffle(extract_subvector(),extract_subvector()) -> extract_subvector(shuffle()) shuffle combines

llvm-svn: 364569

llvm/lib/Target/X86/X86ISelLowering.cpp

index a8ef563..037dc03 100644 (file)
@@ -32519,10 +32519,6 @@ static SDValue combineX86ShufflesRecursively(
   if (!resolveTargetShuffleInputs(Op, OpInputs, OpMask, DAG))
     return SDValue();
 
-  // TODO - Add support for more than 2 inputs.
-  if (2 < OpInputs.size())
-    return SDValue();
-
   // Add the inputs to the Ops list, avoiding duplicates.
   SmallVector<SDValue, 16> Ops(SrcOps.begin(), SrcOps.end());