summaryrefslogtreecommitdiff
path: root/gcc/config/rs6000/rs6000.c
diff options
context:
space:
mode:
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2017-09-25 12:57:49 +0000
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2017-09-25 12:57:49 +0000
commit9b8079ea2e9bf8fc279aa81d2a39dcfb60f42400 (patch)
tree98c3c05927d33eaae50459c94801c537ec7abec0 /gcc/config/rs6000/rs6000.c
parentc7db9cf55ae4022f134624db81cc70d694079b6c (diff)
downloadgcc-9b8079ea2e9bf8fc279aa81d2a39dcfb60f42400.tar.gz
Update interface to TARGET_VECTORIZE_VEC_PERM_CONST_OK
This patch makes TARGET_VECTORIZE_VEC_PERM_CONST_OK take the permute vector in the form of a vec_perm_indices instead of an unsigned char *. It follows on from the recent patch that did the same in target-independent code. It was easy to make ARM and AArch64 use vec_perm_indices internally as well, and converting AArch64 helps with SVE. I did try doing the same for the other ports, but the surgery needed was much more invasive and much less obviously correct. 2017-09-22 Richard Sandiford <richard.sandifird@linaro.org> gcc/ * target.def (vec_perm_const_ok): Change sel parameter to vec_perm_indices. * optabs-query.c (can_vec_perm_p): Update accordingly. * doc/tm.texi: Regenerate. * config/aarch64/aarch64.c (expand_vec_perm_d): Change perm to auto_vec_perm_indices and remove separate nelt field. (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip) (aarch64_evpc_ext, aarch64_evpc_rev, aarch64_evpc_dup) (aarch64_evpc_tbl, aarch64_expand_vec_perm_const_1) (aarch64_expand_vec_perm_const): Update accordingly. (aarch64_vectorize_vec_perm_const_ok): Likewise. Change sel to vec_perm_indices. * config/arm/arm.c (expand_vec_perm_d): Change perm to auto_vec_perm_indices and remove separate nelt field. (arm_evpc_neon_vuzp, arm_evpc_neon_vzip, arm_evpc_neon_vrev) (arm_evpc_neon_vtrn, arm_evpc_neon_vext, arm_evpc_neon_vtbl) (arm_expand_vec_perm_const_1, arm_expand_vec_perm_const): Update accordingly. (arm_vectorize_vec_perm_const_ok): Likewise. Change sel to vec_perm_indices. * config/i386/i386.c (ix86_vectorize_vec_perm_const_ok): Change sel to vec_perm_indices. * config/ia64/ia64.c (ia64_vectorize_vec_perm_const_ok): Likewise. * config/mips/mips.c (mips_vectorize_vec_perm_const_ok): Likewise. * config/powerpcspe/powerpcspe.c (rs6000_vectorize_vec_perm_const_ok): Likewise. * config/rs6000/rs6000.c (rs6000_vectorize_vec_perm_const_ok): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@253148 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/rs6000/rs6000.c')
-rw-r--r--gcc/config/rs6000/rs6000.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
index e5ef63889b7..9198e9ebeba 100644
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -35594,8 +35594,7 @@ rs6000_expand_vec_perm_const (rtx operands[4])
/* Test whether a constant permutation is supported. */
static bool
-rs6000_vectorize_vec_perm_const_ok (machine_mode vmode,
- const unsigned char *sel)
+rs6000_vectorize_vec_perm_const_ok (machine_mode vmode, vec_perm_indices sel)
{
/* AltiVec (and thus VSX) can handle arbitrary permutations. */
if (TARGET_ALTIVEC)