PR84033, powerpc64le -moptimize-swaps bad code with vec_vbpermq
authorAlan Modra <amodra@gmail.com>
Thu, 25 Jan 2018 23:57:18 +0000 (10:27 +1030)
committerAlan Modra <amodra@gcc.gnu.org>
Thu, 25 Jan 2018 23:57:18 +0000 (10:27 +1030)
commit73598b3330377a9970f4489f5c5d517f62b51386
tree359af78554346f366a1c1b304b5d5009c12ba6b2
parent1bfbe9adbc554930163eb551f9904cf4fe096696
PR84033, powerpc64le -moptimize-swaps bad code with vec_vbpermq

vbpermq produces its output in bits 48..63 of the target vector reg,
so the output cannot be lane swapped.

gcc/
PR target/84033
* config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
UNSPEC_VBPERMQ.  Sort other unspecs.
gcc/testsuite/
PR target/84033
* gcc.target/powerpc/swaps-p8-46.c: New.

From-SVN: r257070
gcc/ChangeLog
gcc/config/rs6000/rs6000-p8swap.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/powerpc/swaps-p8-46.c [new file with mode: 0644]