[AArch64] Prefer FPRs over GPRs for CLASTB
authorRichard Sandiford <richard.sandiford@arm.com>
Wed, 7 Aug 2019 19:08:55 +0000 (19:08 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Wed, 7 Aug 2019 19:08:55 +0000 (19:08 +0000)
commit801790b37ca817089ecbae214340162e6d94ea6a
tree35bd16b516b6402219f067fbb2d825df2c4a1859
parentb0760a40bef3ca690691bf5d214da95b5dc25266
[AArch64] Prefer FPRs over GPRs for CLASTB

This patch makes the SVE CLASTB GPR alternative more expensive than the
FPR alternative in order to avoid unnecessary cross-file moves.  It also
fixes the prefix used to print the FPR; <vw> only handles 32-bit and
64-bit elements.

2019-08-07  Richard Sandiford  <richard.sandiford@arm.com>

gcc/
* config/aarch64/aarch64-sve.md (fold_extract_last_<mode>):
Disparage the GPR alternative relative to the FPR one.
Fix handling of 8-bit and 16-bit FPR values.

gcc/testsuite/
* gcc.target/aarch64/sve/clastb_8.c: New test.

From-SVN: r274191
gcc/ChangeLog
gcc/config/aarch64/aarch64-sve.md
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/aarch64/sve/clastb_8.c [new file with mode: 0644]