[X86][SSE] Add early-out when trying to match blend shuffle. NFCI.

llvm-svn: 294864
This commit is contained in:
Simon Pilgrim 2017-02-11 18:06:24 +00:00
parent 63499b61c9
commit 4ef9672f0f
1 changed files with 4 additions and 3 deletions

View File

@ -26684,10 +26684,11 @@ static bool matchBinaryPermuteVectorShuffle(MVT MaskVT, ArrayRef<int> Mask,
int M = Mask[i];
if (M == SM_SentinelUndef)
continue;
else if (M == SM_SentinelZero)
MatchBlend = false;
else if ((M != i) && (M != (i + (int)NumMaskElts)))
if ((M == SM_SentinelZero) ||
((M != i) && (M != (i + (int)NumMaskElts)))) {
MatchBlend = false;
break;
}
}
if (MatchBlend) {