Skip to content

Commit 9125754

Browse files
committed
Preserve exact flag for lshr
Signed-off-by: John Lu <[email protected]>
1 parent 46e3ec0 commit 9125754

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

llvm/lib/Target/AMDGPU/AMDGPUISelLowering.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4328,7 +4328,8 @@ SDValue AMDGPUTargetLowering::performSrlCombine(SDNode *N,
43284328
Hi = DAG.getNode(ISD::EXTRACT_VECTOR_ELT, LHSSL, TargetType, SplitLHS, One);
43294329
}
43304330

4331-
SDValue NewShift = DAG.getNode(ISD::SRL, SL, TargetType, Hi, ShiftAmt);
4331+
SDValue NewShift =
4332+
DAG.getNode(ISD::SRL, SL, TargetType, Hi, ShiftAmt, N->getFlags());
43324333

43334334
SDValue Vec;
43344335
if (VT.isVector()) {

0 commit comments

Comments
 (0)