[PATCH] D147309: [RISCV][NFC] Simplify PatFrag mul_const_oneuse
Ben Shi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 31 03:11:35 PDT 2023
benshi001 created this revision.
benshi001 added reviewers: craig.topper, asb, luismarques, kito-cheng.
Herald added subscribers: jobnoorman, luke, VincentWu, vkmr, frasercrmck, evandro, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, shiva0217, niosHD, sabuasal, simoncook, johnrusso, rbar, hiraditya, arichardson.
Herald added a project: All.
benshi001 requested review of this revision.
Herald added subscribers: llvm-commits, pcwang-thead, eopXD, jacquesguan, MaskRay.
Herald added a project: LLVM.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D147309
Files:
llvm/lib/Target/RISCV/RISCVInstrInfo.td
Index: llvm/lib/Target/RISCV/RISCVInstrInfo.td
===================================================================
--- llvm/lib/Target/RISCV/RISCVInstrInfo.td
+++ llvm/lib/Target/RISCV/RISCVInstrInfo.td
@@ -1247,8 +1247,7 @@
def mul_const_oneuse : PatFrag<(ops node:$A, node:$B),
(mul node:$A, node:$B), [{
if (auto *N1C = dyn_cast<ConstantSDNode>(N->getOperand(1)))
- if (N1C->hasOneUse())
- return true;
+ return N1C->hasOneUse();
return false;
}]>;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D147309.509954.patch
Type: text/x-patch
Size: 505 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230331/c5ec5a0c/attachment.bin>
More information about the llvm-commits
mailing list