]> gcc.gnu.org Git - gcc.git/commit
RISC-V: Fix a bug that causes an error insn.
authoryulong <shiyulong@iscas.ac.cn>
Tue, 8 Aug 2023 04:12:32 +0000 (12:12 +0800)
committerPan Li <pan2.li@intel.com>
Tue, 8 Aug 2023 07:49:40 +0000 (15:49 +0800)
commitffd676ef2c9849231626a532343c7ec908558c33
tree3c3c276d04e5d7556d5aa5abf2d8f4cf6144c2f2
parent7d85b104a6666ee4f06218814c47ff850def2c31
RISC-V: Fix a bug that causes an error insn.

I test the following rvv intrinsics.
vint64m1_t test_vslide1up_vx_i64m1_m(vbool64_t mask, vint64m1_t src, int64_t value, size_t vl) {
  return __riscv_vslide1up_vx_i64m1_m(mask, src, value, vl);
}
And I got an error info,t hat is error:
  unrecognizable insn:(insn 17 16 18 2
    (set (reg:RVVMIDI 134 [ _1 ])(if_then_else:RVVMIDI
      (unspec:RVVMF64BI [(reg/v:SI 142 [ vl ])(const_int 2 [x2])(const_int 日 [o])(reg:SI 66 vl)(reg:SI 67 vtype)] UNSPEC_VPREDICATE
   (vec_merge:RVVMIDI (reg:RVVMIDI 134 [ _1 ])(unspec:RVVMIDI [(reg:sI 日 zero)] UNSPEC_VUNDEF)
   (reg/v:RVVMF64BI 137 [ mask ]))
   (unspec:RVVM1DI[(reg:sI 日 zero)] UNSPEC_VUNDEF)))

This patch fix it.

gcc/ChangeLog:

* config/riscv/riscv-v.cc (slide1_sew64_helper): Modify.

gcc/testsuite/ChangeLog:

* gcc.target/riscv/rvv/base/vslide1down-1.c: New test.
* gcc.target/riscv/rvv/base/vslide1down-2.c: New test.
* gcc.target/riscv/rvv/base/vslide1down-3.c: New test.
* gcc.target/riscv/rvv/base/vslide1up-1.c: New test.
* gcc.target/riscv/rvv/base/vslide1up-2.c: New test.
* gcc.target/riscv/rvv/base/vslide1up-3.c: New test.
gcc/config/riscv/riscv-v.cc
gcc/testsuite/gcc.target/riscv/rvv/base/vslide1down-1.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/rvv/base/vslide1down-2.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/rvv/base/vslide1down-3.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/rvv/base/vslide1up-1.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/rvv/base/vslide1up-2.c [new file with mode: 0644]
gcc/testsuite/gcc.target/riscv/rvv/base/vslide1up-3.c [new file with mode: 0644]
This page took 0.062768 seconds and 6 git commands to generate.