@@ -258,9 +258,8 @@ class SPIRVInstructionSelector : public InstructionSelector {
258258 MachineInstr &I) const ;
259259
260260 bool selectWaveNOpInst (Register ResVReg, const SPIRVType *ResType,
261- MachineInstr &I,
262- unsigned Opcode,
263- unsigned OperandCount) const ;
261+ MachineInstr &I, unsigned Opcode,
262+ unsigned OperandCount) const ;
264263 bool selectWaveActiveAnyTrue (Register ResVReg, const SPIRVType *ResType,
265264 MachineInstr &I) const ;
266265
@@ -1957,10 +1956,10 @@ bool SPIRVInstructionSelector::selectSign(Register ResVReg,
19571956}
19581957
19591958bool SPIRVInstructionSelector::selectWaveNOpInst (Register ResVReg,
1960- const SPIRVType *ResType,
1961- MachineInstr &I,
1962- unsigned Opcode,
1963- unsigned OperandCount) const {
1959+ const SPIRVType *ResType,
1960+ MachineInstr &I,
1961+ unsigned Opcode,
1962+ unsigned OperandCount) const {
19641963 assert (I.getNumOperands () == OperandCount);
19651964 for (unsigned j = 2 ; j < OperandCount; j++) {
19661965 assert (I.getOperand (j).isReg ());
@@ -1970,9 +1969,10 @@ bool SPIRVInstructionSelector::selectWaveNOpInst(Register ResVReg,
19701969 SPIRVType *IntTy = GR.getOrCreateSPIRVIntegerType (32 , I, TII);
19711970
19721971 auto BMI = BuildMI (BB, I, I.getDebugLoc (), TII.get (Opcode))
1973- .addDef (ResVReg)
1974- .addUse (GR.getSPIRVTypeID (ResType))
1975- .addUse (GR.getOrCreateConstInt (SPIRV::Scope::Subgroup, I, IntTy, TII));
1972+ .addDef (ResVReg)
1973+ .addUse (GR.getSPIRVTypeID (ResType))
1974+ .addUse (GR.getOrCreateConstInt (SPIRV::Scope::Subgroup, I,
1975+ IntTy, TII));
19761976
19771977 for (unsigned j = 2 ; j < OperandCount; j++) {
19781978 BMI.addUse (I.getOperand (j).getReg ());
@@ -1981,7 +1981,6 @@ bool SPIRVInstructionSelector::selectWaveNOpInst(Register ResVReg,
19811981 return BMI.constrainAllUses (TII, TRI, RBI);
19821982}
19831983
1984-
19851984bool SPIRVInstructionSelector::selectWaveActiveAnyTrue (Register ResVReg,
19861985 const SPIRVType *ResType,
19871986 MachineInstr &I) const {
@@ -1994,7 +1993,8 @@ bool SPIRVInstructionSelector::selectWaveActiveCountBits(
19941993 SPIRVType *IntTy = GR.getOrCreateSPIRVIntegerType (32 , I, TII);
19951994 SPIRVType *BallotType = GR.getOrCreateSPIRVVectorType (IntTy, 4 , I, TII);
19961995 Register BallotReg = MRI->createVirtualRegister (GR.getRegClass (BallotType));
1997- bool Result = selectWaveNOpInst (BallotReg, BallotType, I, SPIRV::OpGroupNonUniformBallot, 3 );
1996+ bool Result = selectWaveNOpInst (BallotReg, BallotType, I,
1997+ SPIRV::OpGroupNonUniformBallot, 3 );
19981998
19991999 MachineBasicBlock &BB = *I.getParent ();
20002000 Result &=
@@ -2013,7 +2013,8 @@ bool SPIRVInstructionSelector::selectWaveActiveCountBits(
20132013bool SPIRVInstructionSelector::selectWaveReadLaneAt (Register ResVReg,
20142014 const SPIRVType *ResType,
20152015 MachineInstr &I) const {
2016- return selectWaveNOpInst (ResVReg, ResType, I, SPIRV::OpGroupNonUniformShuffle, 4 );
2016+ return selectWaveNOpInst (ResVReg, ResType, I, SPIRV::OpGroupNonUniformShuffle,
2017+ 4 );
20172018}
20182019
20192020bool SPIRVInstructionSelector::selectBitreverse (Register ResVReg,
0 commit comments