From: Pan Li <[email protected]>

This patch would like to introduce the combine of vec_dup + vmsltu.wv
into vmsltu.wx on the cost value of GR2VR.  The late-combine will
take place if the cost of GR2VRlike 1, 2, 15 in test.

From:
 |   ...
 |   vmv.v.x
 | L1:
 |   vmsltu.vv
 |   J L1
 |   ...

To:
 |   ...
 | L1:
 |   vmsltu.vx
 |   J L1
 |   ...

The below test suites are passed for this patch series.
* The rv64gcv fully regression test.

Pan Li (2):
  RISC-V: Combine vec_duplicate + vmsltu.vv to vmsltu.vx on GR2VR cost
  RISC-V: Add test for vec_duplicate + vmsltu.vv combine with GR2VR cost 0, 1 
and 15

 gcc/config/riscv/autovec-opt.md               |  30 ++++
 gcc/config/riscv/predicates.md                |   3 +
 gcc/config/riscv/riscv-protos.h               |   1 +
 gcc/config/riscv/riscv-v.cc                   |  32 +++++
 .../riscv/rvv/autovec/vx_vf/vx-1-u16.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-1-u32.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-1-u64.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-1-u8.c         |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-2-u16.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-2-u32.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-2-u64.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-2-u8.c         |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-3-u16.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-3-u32.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-3-u64.c        |   1 +
 .../riscv/rvv/autovec/vx_vf/vx-3-u8.c         |   1 +
 .../riscv/rvv/autovec/vx_vf/vx_binary.h       |   1 +
 .../riscv/rvv/autovec/vx_vf/vx_binary_data.h  | 136 ++++++++++++++++++
 .../rvv/autovec/vx_vf/vx_vmsltu-run-1-u16.c   |  15 ++
 .../rvv/autovec/vx_vf/vx_vmsltu-run-1-u32.c   |  15 ++
 .../rvv/autovec/vx_vf/vx_vmsltu-run-1-u64.c   |  15 ++
 .../rvv/autovec/vx_vf/vx_vmsltu-run-1-u8.c    |  15 ++
 22 files changed, 275 insertions(+)
 create mode 100644 
gcc/testsuite/gcc.target/riscv/rvv/autovec/vx_vf/vx_vmsltu-run-1-u16.c
 create mode 100644 
gcc/testsuite/gcc.target/riscv/rvv/autovec/vx_vf/vx_vmsltu-run-1-u32.c
 create mode 100644 
gcc/testsuite/gcc.target/riscv/rvv/autovec/vx_vf/vx_vmsltu-run-1-u64.c
 create mode 100644 
gcc/testsuite/gcc.target/riscv/rvv/autovec/vx_vf/vx_vmsltu-run-1-u8.c

-- 
2.43.0

Reply via email to