Skip to content

Commit cfdf94a

Browse files
committed
Remove unnecessary trunc
1 parent f49dbe9 commit cfdf94a

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

llvm/lib/Target/AMDGPU/SIISelLowering.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4092,9 +4092,8 @@ SDValue SITargetLowering::lowerSET_ROUNDING(SDValue Op,
40924092
SDValue RoundModeTimesNumBits =
40934093
DAG.getNode(ISD::SHL, SL, MVT::i32, NewMode, Two);
40944094

4095-
SDValue TableValue =
4095+
NewMode =
40964096
DAG.getNode(ISD::SRL, SL, MVT::i32, BitTable, RoundModeTimesNumBits);
4097-
NewMode = DAG.getNode(ISD::TRUNCATE, SL, MVT::i32, TableValue);
40984097

40994098
// TODO: SimplifyDemandedBits on the setreg source here can likely reduce
41004099
// the table extracted bits into inline immediates.

0 commit comments

Comments
 (0)