[PATCH] D152222: [RISCV] Fix the num of chain SDNode introduced in 9e0f9f113248093e737c4cf5450f0a3c2bcd90ba
Zixuan Wu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jun 5 19:42:48 PDT 2023
zixuan-wu created this revision.
zixuan-wu added a reviewer: craig.topper.
Herald added subscribers: jobnoorman, luke, VincentWu, vkmr, frasercrmck, luismarques, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, shiva0217, kito-cheng, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, hiraditya, arichardson.
Herald added a project: All.
zixuan-wu requested review of this revision.
Herald added subscribers: llvm-commits, pcwang-thead, eopXD, MaskRay.
Herald added a project: LLVM.
It's a little bug fix of patch 9e0f9f113248093e737c4cf5450f0a3c2bcd90ba <https://reviews.llvm.org/rG9e0f9f113248093e737c4cf5450f0a3c2bcd90ba> which will get wrong chain num when it's load and update node.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D152222
Files:
llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
Index: llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
===================================================================
--- llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
+++ llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
@@ -2127,7 +2127,7 @@
}
// Update the chain.
- ReplaceUses(Src.getValue(1), SDValue(Load, 1));
+ ReplaceUses(Src.getValue(Ld->isIndexed() ? 2 : 1), SDValue(Load, 1));
// Record the mem-refs
CurDAG->setNodeMemRefs(Load, {Ld->getMemOperand()});
// Replace the splat with the vlse.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D152222.528665.patch
Type: text/x-patch
Size: 527 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230606/728eb4ae/attachment.bin>
More information about the llvm-commits
mailing list