[PATCH] D113203: [AMDGPU] Small correction in SITargetLowering::performOrCombine()
Konstantin Pyzhov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 4 10:09:04 PDT 2021
kpyzhov created this revision.
kpyzhov added a reviewer: kzhuravl.
kpyzhov added a project: AMDGPU.
Herald added subscribers: foad, kerbowa, hiraditya, t-tye, tpr, dstuttard, yaxunl, nhaehnle, jvesely, arsenm.
kpyzhov requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.
Using the "LHS" variable in the splitBinaryBitConstantOp() call is not valid since "LHS" and "RHS" may be swapped earlier in the code.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D113203
Files:
llvm/lib/Target/AMDGPU/SIISelLowering.cpp
Index: llvm/lib/Target/AMDGPU/SIISelLowering.cpp
===================================================================
--- llvm/lib/Target/AMDGPU/SIISelLowering.cpp
+++ llvm/lib/Target/AMDGPU/SIISelLowering.cpp
@@ -9474,7 +9474,7 @@
const ConstantSDNode *CRHS = dyn_cast<ConstantSDNode>(N->getOperand(1));
if (CRHS) {
if (SDValue Split
- = splitBinaryBitConstantOp(DCI, SDLoc(N), ISD::OR, LHS, CRHS))
+ = splitBinaryBitConstantOp(DCI, SDLoc(N), ISD::OR, N->getOperand(0), CRHS))
return Split;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D113203.384797.patch
Type: text/x-patch
Size: 534 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211104/6220051c/attachment.bin>
More information about the llvm-commits
mailing list