]> git.ipfire.org Git - thirdparty/gcc.git/commit
LoongArch: Fix wrong code from loongarch_expand_vec_perm_1 [PR 122695]
authorXi Ruoyao <xry111@xry111.site>
Sat, 15 Nov 2025 16:30:43 +0000 (00:30 +0800)
committerXi Ruoyao <xry111@xry111.site>
Thu, 20 Nov 2025 07:24:12 +0000 (15:24 +0800)
commitf168d62bc552176572832bf129c9b392aeff46ad
treef7ed89fbae5d8ae4f580fe622312f8258a79a6b6
parent6bace0ed49aea613ccd6c4f3c21a9ef0473fe62b
LoongArch: Fix wrong code from loongarch_expand_vec_perm_1 [PR 122695]

PR target/122695

gcc/

* config/loongarch/loongarch.cc (loongarch_expand_vec_perm_1):
Simplify and fix the logic preventing the xvshuf.* unpredictable
behavior.

gcc/testsuite/

* gcc.target/loongarch/pr122695-1.c: New test.
* gcc.target/loongarch/pr122695-2.c: New test.
gcc/config/loongarch/loongarch.cc
gcc/testsuite/gcc.target/loongarch/pr122695-1.c [new file with mode: 0644]
gcc/testsuite/gcc.target/loongarch/pr122695-2.c [new file with mode: 0644]