The default promotion uses zero extends that become shifts. We
cam use sign extend instead which is better for RISCV.
I've used two different implementations based on whether we
have minu/maxu instructions.
Paths
| Differential D98683
[RISCV] Improve i32 UADDSAT/USUBSAT on RV64. ClosedPublic Authored by craig.topper on Mar 16 2021, 12:33 AM.
Details Summary The default promotion uses zero extends that become shifts. We I've used two different implementations based on whether we
Diff Detail
Event TimelineHerald added subscribers: StephenFan, vkmr, evandro and 23 others. · View Herald TranscriptMar 16 2021, 12:33 AM This revision is now accepted and ready to land.Mar 16 2021, 5:45 AM
Closed by commit rGa33ce06cf59a: [RISCV] Improve i32 UADDSAT/USUBSAT on RV64. (authored by craig.topper). · Explain WhyMar 16 2021, 7:47 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 330986 llvm/lib/Target/RISCV/RISCVISelLowering.cpp
llvm/test/CodeGen/RISCV/uadd_sat.ll
llvm/test/CodeGen/RISCV/uadd_sat_plus.ll
llvm/test/CodeGen/RISCV/usub_sat.ll
llvm/test/CodeGen/RISCV/usub_sat_plus.ll
|
Nit: British spelling :)