[PATCH] D151139: [RISCV] Increase scalar integer divide latency for SiFive7.
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon May 22 12:30:40 PDT 2023
craig.topper created this revision.
craig.topper added reviewers: michaelmaitland, reames, arcbbb, monkchiang.
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.
craig.topper requested review of this revision.
Herald added subscribers: pcwang-thead, eopXD, MaskRay.
Herald added a project: LLVM.
The scalar divider produces 1 bit per cycle so the worst case
latency is the input width plus a couple cycles.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D151139
Files:
llvm/lib/Target/RISCV/RISCVSchedSiFive7.td
Index: llvm/lib/Target/RISCV/RISCVSchedSiFive7.td
===================================================================
--- llvm/lib/Target/RISCV/RISCVSchedSiFive7.td
+++ llvm/lib/Target/RISCV/RISCVSchedSiFive7.td
@@ -198,12 +198,12 @@
// Integer division
def : WriteRes<WriteIDiv, [SiFive7PipeB, SiFive7IDiv]> {
- let Latency = 16;
- let ResourceCycles = [1, 15];
+ let Latency = 66;
+ let ResourceCycles = [1, 65];
}
def : WriteRes<WriteIDiv32, [SiFive7PipeB, SiFive7IDiv]> {
- let Latency = 16;
- let ResourceCycles = [1, 15];
+ let Latency = 34;
+ let ResourceCycles = [1, 33];
}
// Bitmanip
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D151139.524431.patch
Type: text/x-patch
Size: 613 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230522/18dde7ce/attachment.bin>
More information about the llvm-commits
mailing list