[PATCH] D117191: [RISCV] Add "IsRV64" predicate in xperm.w pattern
Ben Shi via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 14 20:23:31 PST 2022
This revision was automatically updated to reflect the committed changes.
Closed by commit rG21dad9a52207: [RISCV][NFC] Add IsRV64 predicate in xperm.w pattern (authored by Lian Wang <Lian.Wang at streamcomputing.com>, committed by benshi001).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D117191/new/
https://reviews.llvm.org/D117191
Files:
llvm/lib/Target/RISCV/RISCVInstrInfoZb.td
Index: llvm/lib/Target/RISCV/RISCVInstrInfoZb.td
===================================================================
--- llvm/lib/Target/RISCV/RISCVInstrInfoZb.td
+++ llvm/lib/Target/RISCV/RISCVInstrInfoZb.td
@@ -838,13 +838,15 @@
def : PatGprGpr<int_riscv_xperm_n, XPERMN>;
def : PatGprGpr<int_riscv_xperm_b, XPERMB>;
def : PatGprGpr<int_riscv_xperm_h, XPERMH>;
-def : PatGprGpr<int_riscv_xperm_w, XPERMW>;
def : PatGprImm<riscv_shfl, SHFLI, shfl_uimm>;
def : PatGprImm<riscv_unshfl, UNSHFLI, shfl_uimm>;
def : PatGprImm<riscv_grev, GREVI, uimmlog2xlen>;
def : PatGprImm<riscv_gorc, GORCI, uimmlog2xlen>;
} // Predicates = [HasStdExtZbp]
+let Predicates = [HasStdExtZbp, IsRV64] in
+def : PatGprGpr<int_riscv_xperm_w, XPERMW>;
+
let Predicates = [HasStdExtZbp, IsRV32] in {
def : Pat<(i32 (rotr (riscv_grev GPR:$rs1, 24), (i32 16))), (GREVI GPR:$rs1, 8)>;
def : Pat<(i32 (rotl (riscv_grev GPR:$rs1, 24), (i32 16))), (GREVI GPR:$rs1, 8)>;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D117191.400232.patch
Type: text/x-patch
Size: 952 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220115/dbd05802/attachment.bin>
More information about the llvm-commits
mailing list