aboutsummaryrefslogtreecommitdiff
path: root/gcc/fold-const.cc
diff options
context:
space:
mode:
authorXi Ruoyao <xry111@xry111.site>2023-11-19 17:28:06 +0800
committerXi Ruoyao <xry111@xry111.site>2023-11-29 15:07:09 +0800
commit77f662a831083f76896b85f22729e2a6f8a38e73 (patch)
treeb9df77bc35f8f612e3fc7a4ef55c7eb57b51be07 /gcc/fold-const.cc
parentcbbc3eeb07794062c892b9284b139a224acdfb2b (diff)
downloadgcc-77f662a831083f76896b85f22729e2a6f8a38e73.zip
gcc-77f662a831083f76896b85f22729e2a6f8a38e73.tar.gz
gcc-77f662a831083f76896b85f22729e2a6f8a38e73.tar.bz2
LoongArch: Use standard pattern name and RTX code for LSX/LASX rotate shift
Remove unnecessary UNSPECs and make the [x]vrotr[i] instructions useful with GNU vectors and auto vectorization. gcc/ChangeLog: * config/loongarch/lsx.md (bitimm): Move to ... (UNSPEC_LSX_VROTR): Remove. (lsx_vrotr_<lsxfmt>): Remove. (lsx_vrotri_<lsxfmt>): Remove. * config/loongarch/lasx.md (UNSPEC_LASX_XVROTR): Remove. (lsx_vrotr_<lsxfmt>): Remove. (lsx_vrotri_<lsxfmt>): Remove. * config/loongarch/simd.md (bitimm): ... here. Expand it to cover LASX modes. (vrotr<mode>3): New define_insn. (vrotri<mode>3): New define_insn. * config/loongarch/loongarch-builtins.cc: (CODE_FOR_lsx_vrotr_b): Use standard pattern name. (CODE_FOR_lsx_vrotr_h): Likewise. (CODE_FOR_lsx_vrotr_w): Likewise. (CODE_FOR_lsx_vrotr_d): Likewise. (CODE_FOR_lasx_xvrotr_b): Likewise. (CODE_FOR_lasx_xvrotr_h): Likewise. (CODE_FOR_lasx_xvrotr_w): Likewise. (CODE_FOR_lasx_xvrotr_d): Likewise. (CODE_FOR_lsx_vrotri_b): Define to standard pattern name. (CODE_FOR_lsx_vrotri_h): Likewise. (CODE_FOR_lsx_vrotri_w): Likewise. (CODE_FOR_lsx_vrotri_d): Likewise. (CODE_FOR_lasx_xvrotri_b): Likewise. (CODE_FOR_lasx_xvrotri_h): Likewise. (CODE_FOR_lasx_xvrotri_w): Likewise. (CODE_FOR_lasx_xvrotri_d): Likewise. gcc/testsuite/ChangeLog: * gcc.target/loongarch/vect-rotr.c: New test.
Diffstat (limited to 'gcc/fold-const.cc')
0 files changed, 0 insertions, 0 deletions