Fix signed/unsigned comparison warning. NFCI.

llvm-svn: 325359
This commit is contained in:
Simon Pilgrim 2018-02-16 16:52:50 +00:00
parent e16b0cfba9
commit 5d005a359e
1 changed files with 3 additions and 3 deletions

View File

@ -1462,7 +1462,7 @@ bool TargetLowering::SimplifyDemandedVectorElts(
bool Updated = false;
bool IdentityLHS = true, IdentityRHS = true;
SmallVector<int, 32> NewMask(ShuffleMask.begin(), ShuffleMask.end());
for (int i = 0; i != NumElts; ++i) {
for (unsigned i = 0; i != NumElts; ++i) {
int &M = NewMask[i];
if (M < 0)
continue;
@ -1471,8 +1471,8 @@ bool TargetLowering::SimplifyDemandedVectorElts(
Updated = true;
M = -1;
}
IdentityLHS &= (M < 0) || (M == i);
IdentityRHS &= (M < 0) || ((M - NumElts) == i);
IdentityLHS &= (M < 0) || (M == (int)i);
IdentityRHS &= (M < 0) || ((M - NumElts) == (int)i);
}
// Update legal shuffle masks based on demanded elements if it won't reduce