File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -1235,10 +1235,7 @@ Register AMDGPULegalizerInfo::getSegmentAperture(
1235
1235
MRI.setType (GetReg, S32);
1236
1236
1237
1237
auto ShiftAmt = B.buildConstant (S32, WidthM1 + 1 );
1238
- B.buildInstr (TargetOpcode::G_SHL)
1239
- .addDef (ApertureReg)
1240
- .addUse (GetReg)
1241
- .addUse (ShiftAmt.getReg (0 ));
1238
+ B.buildShl (ApertureReg, GetReg, ShiftAmt);
1242
1239
1243
1240
return ApertureReg;
1244
1241
}
@@ -1365,9 +1362,7 @@ bool AMDGPULegalizerInfo::legalizeAddrSpaceCast(
1365
1362
1366
1363
// Coerce the type of the low half of the result so we can use merge_values.
1367
1364
Register SrcAsInt = MRI.createGenericVirtualRegister (S32);
1368
- B.buildInstr (TargetOpcode::G_PTRTOINT)
1369
- .addDef (SrcAsInt)
1370
- .addUse (Src);
1365
+ B.buildPtrToInt (SrcAsInt, Src);
1371
1366
1372
1367
// TODO: Should we allow mismatched types but matching sizes in merges to
1373
1368
// avoid the ptrtoint?
@@ -1420,7 +1415,7 @@ bool AMDGPULegalizerInfo::legalizeFceil(
1420
1415
// if (src > 0.0 && src != result)
1421
1416
// result += 1.0
1422
1417
1423
- auto Trunc = B.buildInstr (TargetOpcode::G_INTRINSIC_TRUNC, { S64}, { Src} );
1418
+ auto Trunc = B.buildIntrinsicTrunc ( S64, Src);
1424
1419
1425
1420
const auto Zero = B.buildFConstant (S64, 0.0 );
1426
1421
const auto One = B.buildFConstant (S64, 1.0 );
You can’t perform that action at this time.
0 commit comments