re PR target/81593 (Optimize PowerPC vector set from vector extract)
authorMichael Meissner <meissner@linux.vnet.ibm.com>
Mon, 7 Aug 2017 23:51:27 +0000 (23:51 +0000)
committerMichael Meissner <meissner@gcc.gnu.org>
Mon, 7 Aug 2017 23:51:27 +0000 (23:51 +0000)
commit08c4c51e365e2957a590db0f4860ad886a6a20e9
treec99cbe4963984941b131f2ad8788c4096940ff47
parent1abeb09f83033e0dce2aee908a4021ed9e1d3300
re PR target/81593 (Optimize PowerPC vector set from vector extract)

[gcc]
2017-08-07  Michael Meissner  <meissner@linux.vnet.ibm.com>

PR target/81593
* config/rs6000/vsx.md (vsx_concat_<mode>, VSX_D): Cleanup
constraints since the -mupper-regs-* switches have been
eliminated.
(vsx_concat_<mode>_1): New combiner insns to recognize inserting
into a vector from a double word element that was extracted from
another vector, and eliminate extra XXPERMDI instructions.
(vsx_concat_<mode>_2): Likewise.
(vsx_concat_<mode>_3): Likewise.
(vsx_set_<mode>, VSX_D): Rewrite vector set in terms of vector
concat to allow optimizing inserts from previous extracts.

[gcc/testsuite]
2017-08-07  Michael Meissner  <meissner@linux.vnet.ibm.com>

PR target/81593
* gcc.target/powerpc/vec-setup.h: New tests to test various
combinations of setting up vectors of 2 double word elements.
* gcc.target/powerpc/vec-setup-long.c: Likewise.
* gcc.target/powerpc/vec-setup-double.c: Likewise.
* gcc.target/powerpc/vec-setup-be-long.c: Likewise.
* gcc.target/powerpc/vec-setup-be-double.c: Likewise.
* gcc.target/powerpc/vsx-extract-6.c: New tests for optimzing
vector inserts from vector extracts.
* gcc.target/powerpc/vsx-extract-7.c: Likewise.

From-SVN: r250936
gcc/ChangeLog
gcc/config/rs6000/vsx.md
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/powerpc/vec-setup-be-double.c [new file with mode: 0644]
gcc/testsuite/gcc.target/powerpc/vec-setup-be-long.c [new file with mode: 0644]
gcc/testsuite/gcc.target/powerpc/vec-setup-double.c [new file with mode: 0644]
gcc/testsuite/gcc.target/powerpc/vec-setup-long.c [new file with mode: 0644]
gcc/testsuite/gcc.target/powerpc/vec-setup.h [new file with mode: 0644]
gcc/testsuite/gcc.target/powerpc/vsx-extract-6.c [new file with mode: 0644]
gcc/testsuite/gcc.target/powerpc/vsx-extract-7.c [new file with mode: 0644]