Skip to content

Commit ee78787

Browse files
committed
Address comments
1 parent 42d24e4 commit ee78787

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

llvm/lib/Target/SPIRV/SPIRVInstructionSelector.cpp

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2820,14 +2820,9 @@ bool SPIRVInstructionSelector::selectIntrinsic(Register ResVReg,
28202820
return selectWaveActiveCountBits(ResVReg, ResType, I);
28212821
case Intrinsic::spv_wave_any:
28222822
return selectWaveNOpInst(ResVReg, ResType, I, SPIRV::OpGroupNonUniformAny);
2823-
case Intrinsic::spv_wave_is_first_lane: {
2824-
SPIRVType *IntTy = GR.getOrCreateSPIRVIntegerType(32, I, TII);
2825-
return BuildMI(BB, I, I.getDebugLoc(),
2826-
TII.get(SPIRV::OpGroupNonUniformElect))
2827-
.addDef(ResVReg)
2828-
.addUse(GR.getSPIRVTypeID(ResType))
2829-
.addUse(GR.getOrCreateConstInt(3, I, IntTy, TII));
2830-
}
2823+
case Intrinsic::spv_wave_is_first_lane:
2824+
return selectWaveNOpInst(ResVReg, ResType, I,
2825+
SPIRV::OpGroupNonUniformElect);
28312826
case Intrinsic::spv_wave_readlane:
28322827
return selectWaveNOpInst(ResVReg, ResType, I,
28332828
SPIRV::OpGroupNonUniformShuffle);

0 commit comments

Comments
 (0)