Skip to content
This repository was archived by the owner on Feb 5, 2019. It is now read-only.

Commit 04f74a1

Browse files
committed
Use <0 checks in place of ==-1 because it results in simpler code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173010 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent bbf9d3e commit 04f74a1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/Target/X86/X86ISelLowering.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5678,12 +5678,12 @@ LowerVECTOR_SHUFFLEtoBlend(ShuffleVectorSDNode *SVOp,
56785678
SVOp->getMaskElt(i + NumElemsInLane) : -1;
56795679
int EltIdx = SVOp->getMaskElt(i);
56805680

5681-
if ((EltIdx == -1 || EltIdx == (int)i) &&
5682-
(SndLaneEltIdx == -1 || SndLaneEltIdx == (int)(i + NumElemsInLane)))
5681+
if ((EltIdx < 0 || EltIdx == (int)i) &&
5682+
(SndLaneEltIdx < 0 || SndLaneEltIdx == (int)(i + NumElemsInLane)))
56835683
continue;
56845684

56855685
if (((unsigned)EltIdx == (i + NumElems)) &&
5686-
(SndLaneEltIdx == -1 ||
5686+
(SndLaneEltIdx < 0 ||
56875687
(unsigned)SndLaneEltIdx == i + NumElems + NumElemsInLane))
56885688
MaskValue |= (1<<i);
56895689
else

0 commit comments

Comments
 (0)