diff --git a/gcc/config/rs6000/altivec.h b/gcc/config/rs6000/altivec.h
index 3729ceaf336..85c5626877d 100644
--- a/gcc/config/rs6000/altivec.h
+++ b/gcc/config/rs6000/altivec.h
@@ -689,8 +689,8 @@ __altivec_scalar_pred(vec_any_nle,
 #ifdef _ARCH_PWR_FUTURE
 /* May modify these macro definitions if future capabilities overload
    with support for different vector argument and result types.  */
-#define vec_clzm(a, b)	__builtin_altivec_vclzdm (a, b)
-#define vec_ctzm(a, b)	__builtin_altivec_vctzdm (a, b)
+#define vec_cntlzm(a, b)	__builtin_altivec_vclzdm (a, b)
+#define vec_cnttzm(a, b)	__builtin_altivec_vctzdm (a, b)
 #define vec_pdep(a, b)	__builtin_altivec_vpdepd (a, b)
 #define vec_pext(a, b)	__builtin_altivec_vpextd (a, b)
 #define vec_cfuge(a, b)	__builtin_altivec_vcfuged (a, b)
diff --git a/gcc/config/rs6000/rs6000-c.c b/gcc/config/rs6000/rs6000-c.c
index cacaea00bd4..07ca33a89b4 100644
--- a/gcc/config/rs6000/rs6000-c.c
+++ b/gcc/config/rs6000/rs6000-c.c
@@ -1813,7 +1813,7 @@ altivec_resolve_overloaded_builtin (location_t loc, tree fndecl,
 		&& rs6000_builtin_type_compatible (types[1], desc->op2)
 		&& rs6000_builtin_type_compatible (types[2], desc->op3)
 		&& rs6000_builtin_type_compatible (types[3],
-						   RS6000_BTI_UINTQI))
+						   RS6000_BTI_UINTSI))
 	      {
 		if (rs6000_builtin_decls[desc->overloaded_code] == NULL_TREE)
 		  unsupported_builtin = true;
diff --git a/gcc/config/rs6000/rs6000-call.c b/gcc/config/rs6000/rs6000-call.c
index 0b9ed7ef018..d6fa1a86c04 100644
--- a/gcc/config/rs6000/rs6000-call.c
+++ b/gcc/config/rs6000/rs6000-call.c
@@ -5522,14 +5522,6 @@ const struct altivec_builtin_types altivec_overloaded_builtins[] = {
     RS6000_BTI_unsigned_V16QI, RS6000_BTI_unsigned_V16QI,
     RS6000_BTI_UINTSI, 0 },
 
-  { FUTURE_BUILTIN_VEC_GNB, FUTURE_BUILTIN_VGNB, RS6000_BTI_unsigned_long_long,
-    RS6000_BTI_unsigned_V16QI, RS6000_BTI_UINTQI, 0 },
-  { FUTURE_BUILTIN_VEC_GNB, FUTURE_BUILTIN_VGNB, RS6000_BTI_unsigned_long_long,
-    RS6000_BTI_unsigned_V8HI, RS6000_BTI_UINTQI, 0 },
-  { FUTURE_BUILTIN_VEC_GNB, FUTURE_BUILTIN_VGNB, RS6000_BTI_unsigned_long_long,
-    RS6000_BTI_unsigned_V4SI, RS6000_BTI_UINTQI, 0 },
-  { FUTURE_BUILTIN_VEC_GNB, FUTURE_BUILTIN_VGNB, RS6000_BTI_unsigned_long_long,
-    RS6000_BTI_unsigned_V2DI, RS6000_BTI_UINTQI, 0 },
   { FUTURE_BUILTIN_VEC_GNB, FUTURE_BUILTIN_VGNB, RS6000_BTI_unsigned_long_long,
     RS6000_BTI_unsigned_V1TI, RS6000_BTI_UINTQI, 0 },
   { FUTURE_BUILTIN_VEC_XXGENPCVM, FUTURE_BUILTIN_XXGENPCVM_V2DI,
diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi
index c352c512285..4c5ed3f3bac 100644
--- a/gcc/doc/extend.texi
+++ b/gcc/doc/extend.texi
@@ -20762,19 +20762,19 @@ Perform a vector centrifuge operation, as if implemented by the Future
 
 @smallexample
 @exdent vector unsigned long long int
-@exdent vec_clzm (vector unsigned long long int, vector unsigned long long int)
+@exdent vec_cntlzm (vector unsigned long long int, vector unsigned long long int)
 @end smallexample
 Perform a vector count leading zeros under bit mask operation, as if
 implemented by the Future @code{vclzdm} instruction.
-@findex vec_clzm
+@findex vec_cntlzm
 
 @smallexample
 @exdent vector unsigned long long int
-@exdent vec_ctzm (vector unsigned long long int, vector unsigned long long int)
+@exdent vec_cnttzm (vector unsigned long long int, vector unsigned long long int)
 @end smallexample
 Perform a vector count trailing zeros under bit mask operation, as if
 implemented by the Future @code{vctzdm} instruction.
-@findex vec_ctzm
+@findex vec_cnttzm
 
 @smallexample
 @exdent vector signed char
@@ -20802,14 +20802,6 @@ value of @code{n} that is greater than 16 is treated as if it equaled 16.
 
 @smallexample
 @exdent vector unsigned long long int
-@exdent vec_gnb (vector unsigned char, const unsigned char)
-@exdent vector unsigned long long int
-@exdent vec_gnb (vector unsigned short, const unsigned char)
-@exdent vector unsigned long long int
-@exdent vec_gnb (vector unsigned int, const unsigned char)
-@exdent vector unsigned long long int
-@exdent vec_gnb (vector unsigned long long int, const unsigned char)
-@exdent vector unsigned long long int
 @exdent vec_gnb (vector unsigned __int128, const unsigned char)
 @end smallexample
 Perform a 128-bit vector gather  operation, as if implemented by the Future
@@ -20889,6 +20881,28 @@ little-endian targets.  Choose this built-in to check for presence of
 zero element if the same argument is also passed to @code{vec_strir}.
 @findex vec_strir_p
 
+@smallexample
+@exdent vector unsigned char
+@exdent vec_ternarylogic (vector unsigned char, vector unsigned char,
+            vector unsigned char, const unsigned int)
+@exdent vector unsigned short
+@exdent vec_ternarylogic (vector unsigned short, vector unsigned short,
+            vector unsigned short, const unsigned int)
+@exdent vector unsigned int
+@exdent vec_ternarylogic (vector unsigned int, vector unsigned int,
+            vector unsigned int, const unsigned int)
+@exdent vector unsigned long long int
+@exdent vec_ternarylogic (vector unsigned long long int, vector unsigned long long int,
+            vector unsigned long long int, const unsigned int)
+@exdent vector unsigned __int128
+@exdent vec_ternarylogic (vector unsigned __int128, vector unsigned __int128,
+            vector unsigned __int128, const unsigned int)
+@end smallexample
+Perform a 128-bit vector evaluate operation, as if implemented by the
+Future @code{xxeval} instruction.  The fourth argument must be a literal
+integer value between 0 and 255 inclusive.
+@findex vec_ternarylogic
+
 @smallexample
 @exdent vector unsigned char vec_genpcvm (vector unsigned char, const int)
 @exdent vector unsigned short vec_genpcvm (vector unsigned short, const int)
@@ -22123,28 +22137,6 @@ else
 @end smallexample
 @end deftypefn
 
-@smallexample
-@exdent vector unsigned char
-@exdent vec_ternarylogic (vector unsigned char, vector unsigned char,
-            vector unsigned char, const unsigned char)
-@exdent vector unsigned short
-@exdent vec_ternarylogic (vector unsigned short, vector unsigned short,
-            vector unsigned short, const unsigned char)
-@exdent vector unsigned int
-@exdent vec_ternarylogic (vector unsigned int, vector unsigned int,
-            vector unsigned int, const unsigned char)
-@exdent vector unsigned long long int
-@exdent vec_ternarylogic (vector unsigned long long int, vector unsigned long long int,
-            vector unsigned long long int, const unsigned char)
-@exdent vector unsigned __int128
-@exdent vec_ternarylogic (vector unsigned __int128, vector unsigned __int128,
-            vector unsigned __int128, const unsigned char)
-@end smallexample
-Perform a 128-bit vector evaluate operation, as if implemented by the
-Future @code{xxeval} instruction.  The fourth argument must be a literal
-integer value between 0 and 255 inclusive.
-@findex vec_ternarylogic
-
 The following built-in functions are made available by @option{-mmmx}.
 All of them generate the machine instruction that is part of the name.
 
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-clzm-0.c b/gcc/testsuite/gcc.target/powerpc/vec-cntlzm-0.c
similarity index 79%
rename from gcc/testsuite/gcc.target/powerpc/vec-clzm-0.c
rename to gcc/testsuite/gcc.target/powerpc/vec-cntlzm-0.c
index 099c5dc99bf..6fe0cbd8875 100644
--- a/gcc/testsuite/gcc.target/powerpc/vec-clzm-0.c
+++ b/gcc/testsuite/gcc.target/powerpc/vec-cntlzm-0.c
@@ -6,10 +6,10 @@
 extern void abort (void);
 
 vector unsigned long long int
-do_vec_clzm (vector unsigned long long int source,
+do_vec_cntlzm (vector unsigned long long int source,
 	     vector unsigned long long int mask)
 {
-  return vec_clzm (source, mask);
+  return vec_cntlzm (source, mask);
 }
 
 int main (int argc, char *argv [])
@@ -39,13 +39,13 @@ int main (int argc, char *argv [])
   vector unsigned long long int result_ba = { 2, 0 };
   vector unsigned long long int result_bb = { 0, 1 };
 
-  if (!vec_all_eq (do_vec_clzm (source_a, mask_a), result_aa))
+  if (!vec_all_eq (do_vec_cntlzm (source_a, mask_a), result_aa))
     abort ();
-  if (!vec_all_eq (do_vec_clzm (source_a, mask_b), result_ab))
+  if (!vec_all_eq (do_vec_cntlzm (source_a, mask_b), result_ab))
     abort ();
-  if (!vec_all_eq (do_vec_clzm (source_b, mask_a), result_ba))
+  if (!vec_all_eq (do_vec_cntlzm (source_b, mask_a), result_ba))
     abort ();
-  if (!vec_all_eq (do_vec_clzm (source_b, mask_b), result_bb))
+  if (!vec_all_eq (do_vec_cntlzm (source_b, mask_b), result_bb))
     abort ();
 
   return 0;
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-clzm-1.c b/gcc/testsuite/gcc.target/powerpc/vec-cntlzm-1.c
similarity index 79%
rename from gcc/testsuite/gcc.target/powerpc/vec-clzm-1.c
rename to gcc/testsuite/gcc.target/powerpc/vec-cntlzm-1.c
index 43b86114487..7e058ed8843 100644
--- a/gcc/testsuite/gcc.target/powerpc/vec-clzm-1.c
+++ b/gcc/testsuite/gcc.target/powerpc/vec-cntlzm-1.c
@@ -7,10 +7,10 @@
 extern void abort (void);
 
 vector unsigned long long int
-do_vec_clzm (vector unsigned long long int source,
+do_vec_cntlzm (vector unsigned long long int source,
 	     vector unsigned long long int mask)
 {
-  return vec_clzm (source, mask);
+  return vec_cntlzm (source, mask);
 }
 
 int main (int argc, char *argv [])
@@ -40,13 +40,13 @@ int main (int argc, char *argv [])
   vector unsigned long long int result_ba = { 2, 0 };
   vector unsigned long long int result_bb = { 0, 1 };
 
-  if (!vec_all_eq (do_vec_clzm (source_a, mask_a), result_aa))
+  if (!vec_all_eq (do_vec_cntlzm (source_a, mask_a), result_aa))
     abort ();
-  if (!vec_all_eq (do_vec_clzm (source_a, mask_b), result_ab))
+  if (!vec_all_eq (do_vec_cntlzm (source_a, mask_b), result_ab))
     abort ();
-  if (!vec_all_eq (do_vec_clzm (source_b, mask_a), result_ba))
+  if (!vec_all_eq (do_vec_cntlzm (source_b, mask_a), result_ba))
     abort ();
-  if (!vec_all_eq (do_vec_clzm (source_b, mask_b), result_bb))
+  if (!vec_all_eq (do_vec_cntlzm (source_b, mask_b), result_bb))
     abort ();
 
   return 0;
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-ctzm-0.c b/gcc/testsuite/gcc.target/powerpc/vec-cnttzm-0.c
similarity index 79%
rename from gcc/testsuite/gcc.target/powerpc/vec-ctzm-0.c
rename to gcc/testsuite/gcc.target/powerpc/vec-cnttzm-0.c
index 315edf4d4cd..94fac3bf817 100644
--- a/gcc/testsuite/gcc.target/powerpc/vec-ctzm-0.c
+++ b/gcc/testsuite/gcc.target/powerpc/vec-cnttzm-0.c
@@ -6,10 +6,10 @@
 extern void abort (void);
 
 vector unsigned long long int
-do_vec_ctzm (vector unsigned long long int source,
+do_vec_cnttzm (vector unsigned long long int source,
 	     vector unsigned long long int mask)
 {
-  return vec_ctzm (source, mask);
+  return vec_cnttzm (source, mask);
 }
 
 int main (int argc, char *argv [])
@@ -39,13 +39,13 @@ int main (int argc, char *argv [])
   vector unsigned long long int result_ba = { 0, 0 };
   vector unsigned long long int result_bb = { 1, 2 };
 
-  if (!vec_all_eq (do_vec_ctzm (source_a, mask_a), result_aa))
+  if (!vec_all_eq (do_vec_cnttzm (source_a, mask_a), result_aa))
     abort ();
-  if (!vec_all_eq (do_vec_ctzm (source_a, mask_b), result_ab))
+  if (!vec_all_eq (do_vec_cnttzm (source_a, mask_b), result_ab))
     abort ();
-  if (!vec_all_eq (do_vec_ctzm (source_b, mask_a),result_ba))
+  if (!vec_all_eq (do_vec_cnttzm (source_b, mask_a),result_ba))
     abort ();
-  if (!vec_all_eq (do_vec_ctzm (source_b, mask_b), result_bb))
+  if (!vec_all_eq (do_vec_cnttzm (source_b, mask_b), result_bb))
     abort ();
 
   return 0;
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-ctzm-1.c b/gcc/testsuite/gcc.target/powerpc/vec-cnttzm-1.c
similarity index 79%
rename from gcc/testsuite/gcc.target/powerpc/vec-ctzm-1.c
rename to gcc/testsuite/gcc.target/powerpc/vec-cnttzm-1.c
index 3dc4a03ab09..27ff3bd4961 100644
--- a/gcc/testsuite/gcc.target/powerpc/vec-ctzm-1.c
+++ b/gcc/testsuite/gcc.target/powerpc/vec-cnttzm-1.c
@@ -7,10 +7,10 @@
 extern void abort (void);
 
 vector unsigned long long int
-do_vec_ctzm (vector unsigned long long int source,
+do_vec_cnttzm (vector unsigned long long int source,
 	     vector unsigned long long int mask)
 {
-  return vec_ctzm (source, mask);
+  return vec_cnttzm (source, mask);
 }
 
 int main (int argc, char *argv [])
@@ -40,13 +40,13 @@ int main (int argc, char *argv [])
   vector unsigned long long int result_ba = { 0, 0 };
   vector unsigned long long int result_bb = { 1, 2 };
 
-  if (!vec_all_eq (do_vec_ctzm (source_a, mask_a), result_aa))
+  if (!vec_all_eq (do_vec_cnttzm (source_a, mask_a), result_aa))
     abort ();
-  if (!vec_all_eq (do_vec_ctzm (source_a, mask_b), result_ab))
+  if (!vec_all_eq (do_vec_cnttzm (source_a, mask_b), result_ab))
     abort ();
-  if (!vec_all_eq (do_vec_ctzm (source_b, mask_a),result_ba))
+  if (!vec_all_eq (do_vec_cnttzm (source_b, mask_a),result_ba))
     abort ();
-  if (!vec_all_eq (do_vec_ctzm (source_b, mask_b), result_bb))
+  if (!vec_all_eq (do_vec_cnttzm (source_b, mask_b), result_bb))
     abort ();
 
   return 0;
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-0.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-0.c
index a95c29cf31d..f18bb16ffb2 100644
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-0.c
+++ b/gcc/testsuite/gcc.target/powerpc/vec-gnb-0.c
@@ -5,10 +5,8 @@
 
 extern void abort (void);
 
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
 unsigned long long int
-do_vec_gnb (vector unsigned char source, int stride)
+do_vec_gnb (vector unsigned __int128 source, int stride)
 {
   switch (stride)
     {
@@ -46,15 +44,15 @@ main (int argc, char *argv [])
 
   /* The last array element appears in the left-most (first) bit
      positions of the vector register.  */
-  vector unsigned char source_a = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x88, 0x88, 0x88, 0x88 };
-  vector unsigned char source_b = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80 };
-  vector unsigned char source_c = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88 };
-  vector unsigned char source_d = {
-    0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80,
-    0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80 };
+  vector unsigned __int128 source_a =
+    { ((unsigned __int128) 0x8888888800000000ull) << 64 };
+  vector unsigned __int128 source_b =
+    { ((unsigned __int128) 0x8080808080808080ull) << 64 };
+  vector unsigned __int128 source_c =
+    { ((unsigned __int128) 0x8888888888888888ull) << 64 };
+  vector unsigned __int128 source_d =
+    { 0x8080808080808080ull |
+      ((unsigned __int128) 0x8080808080808080ull) << 64 };
 
   unsigned long long int results [] =
     { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-1.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-1.c
index e8ceed55994..ee9c44f88b2 100644
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-1.c
+++ b/gcc/testsuite/gcc.target/powerpc/vec-gnb-1.c
@@ -6,10 +6,8 @@
 
 extern void abort (void);
 
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
 unsigned long long int
-do_vec_gnb (vector unsigned char source, int stride)
+do_vec_gnb (vector unsigned __int128 source, int stride)
 {
   switch (stride)
     {
@@ -47,15 +45,15 @@ main (int argc, char *argv [])
 
   /* The last array element appears in the left-most (first) bit
      positions of the vector register.  */
-  vector unsigned char source_a = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x88, 0x88, 0x88, 0x88 };
-  vector unsigned char source_b = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80 };
-  vector unsigned char source_c = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88 };
-  vector unsigned char source_d = {
-    0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80,
-    0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80 };
+  vector unsigned __int128 source_a =
+    { ((unsigned __int128) 0x8888888800000000ull) << 64 };
+  vector unsigned __int128 source_b =
+    { ((unsigned __int128) 0x8080808080808080ull) << 64 };
+  vector unsigned __int128 source_c =
+    { ((unsigned __int128) 0x8888888888888888ull) << 64 };
+  vector unsigned __int128 source_d =
+    { 0x8080808080808080ull |
+      ((unsigned __int128) 0x8080808080808080ull) << 64 };
 
   unsigned long long int results [] =
     { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
@@ -72,4 +70,3 @@ main (int argc, char *argv [])
 
   return 0;
 }
-
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-10.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-10.c
deleted file mode 100644
index 73ff0d9fea7..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-10.c
+++ /dev/null
@@ -1,72 +0,0 @@
-/* { dg-do compile } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-unsigned long long int
-do_vec_gnb (vector unsigned char source, unsigned char stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 0);	/* { dg-error "between 2 and 7" } */
-    case 3:
-      return vec_gnb (source, -1);	/* { dg-error "between 2 and 7" } */
-    case 4:
-      return vec_gnb (source, 8);	/* { dg-error "between 2 and 7" } */
-    case 5:
-      return vec_gnb (source, 1);	/* { dg-error "between 2 and 7" } */
-    case 6:
-      return vec_gnb (source, stride);	/* { dg-error "unsigned literal" } */
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned char source_a = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x88, 0x88, 0x88, 0x88 };
-  vector unsigned char source_b = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80 };
-  vector unsigned char source_c = {
-    0, 0, 0, 0, 0, 0, 0, 0, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88 };
-  vector unsigned char source_d = {
-    0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80,
-    0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80 };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
-
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-2.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-2.c
index eb51a8db219..591f701e820 100644
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-2.c
+++ b/gcc/testsuite/gcc.target/powerpc/vec-gnb-2.c
@@ -5,23 +5,21 @@
 
 extern void abort (void);
 
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
 unsigned long long int
-do_vec_gnb (vector unsigned short int source, int stride)
+do_vec_gnb (vector unsigned __int128 source, int stride)
 {
   switch (stride)
     {
     case 2:
-      return vec_gnb (source, 2);
+      return vec_gnb (source, 0);	/* { dg-error "between 2 and 7" } */
     case 3:
-      return vec_gnb (source, 3);
+      return vec_gnb (source, -1);	/* { dg-error "between 2 and 7" } */
     case 4:
-      return vec_gnb (source, 4);
+      return vec_gnb (source, 8);	/* { dg-error "between 2 and 7" } */
     case 5:
-      return vec_gnb (source, 5);
+      return vec_gnb (source, 1);	/* { dg-error "between 2 and 7" } */
     case 6:
-      return vec_gnb (source, 6);
+      return vec_gnb (source, stride);	/* { dg-error "unsigned literal" } */
     case 7:
       return vec_gnb (source, 7);
 
@@ -46,13 +44,15 @@ main (int argc, char *argv [])
 
   /* The last array element appears in the left-most (first) bit
      positions of the vector register.  */
-  vector unsigned short int source_a = { 0, 0, 0, 0, 0, 0, 0x8888, 0x8888 };
-  vector unsigned short int source_b = {
-    0, 0, 0, 0, 0x8080, 0x8080, 0x8080, 0x8080 };
-  vector unsigned short int source_c = {
-    0, 0, 0, 0, 0x8888, 0x8888, 0x8888, 0x8888 };
-  vector unsigned short int source_d = {
-    0x8080, 0x8080, 0x8080, 0x8080, 0x8080, 0x8080, 0x8080, 0x8080 };
+  vector unsigned __int128 source_a =
+    { ((unsigned __int128) 0x8888888800000000ull) << 64 };
+  vector unsigned __int128 source_b =
+    { ((unsigned __int128) 0x8080808080808080ull) << 64 };
+  vector unsigned __int128 source_c =
+    { ((unsigned __int128) 0x8888888888888888ull) << 64 };
+  vector unsigned __int128 source_d =
+    { 0x8080808080808080ull |
+      ((unsigned __int128) 0x8080808080808080ull) << 64 };
 
   unsigned long long int results [] =
     { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
@@ -70,4 +70,3 @@ main (int argc, char *argv [])
   return 0;
 }
 
-/* { dg-final { scan-assembler {\mvgnb\M} } } */
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-3.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-3.c
deleted file mode 100644
index f36b91a83e5..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-3.c
+++ /dev/null
@@ -1,72 +0,0 @@
-/* { dg-do run } */
-/* { dg-require-effective-target powerpc_future_hw } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
-unsigned long long int
-do_vec_gnb (vector unsigned short int source, int stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 2);
-    case 3:
-      return vec_gnb (source, 3);
-    case 4:
-      return vec_gnb (source, 4);
-    case 5:
-      return vec_gnb (source, 5);
-    case 6:
-      return vec_gnb (source, 6);
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned short int source_a = { 0, 0, 0, 0, 0, 0, 0x8888, 0x8888 };
-  vector unsigned short int source_b = {
-    0, 0, 0, 0, 0x8080, 0x8080, 0x8080, 0x8080 };
-  vector unsigned short int source_c = {
-    0, 0, 0, 0, 0x8888, 0x8888, 0x8888, 0x8888 };
-  vector unsigned short int source_d = {
-    0x8080, 0x8080, 0x8080, 0x8080, 0x8080, 0x8080, 0x8080, 0x8080 };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-4.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-4.c
deleted file mode 100644
index df312ae1b28..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-4.c
+++ /dev/null
@@ -1,71 +0,0 @@
-/* { dg-do compile } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
-unsigned long long int
-do_vec_gnb (vector unsigned int source, int stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 2);
-    case 3:
-      return vec_gnb (source, 3);
-    case 4:
-      return vec_gnb (source, 4);
-    case 5:
-      return vec_gnb (source, 5);
-    case 6:
-      return vec_gnb (source, 6);
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned int source_a = { 0, 0, 0, 0x88888888 };
-  vector unsigned int source_b = { 0, 0, 0x80808080, 0x80808080 };
-  vector unsigned int source_c = { 0, 0, 0x88888888, 0x88888888 };
-  vector unsigned int source_d =
-    { 0x80808080, 0x80808080, 0x80808080, 0x80808080 };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
-
-/* { dg-final { scan-assembler {\mvgnb\M} } } */
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-5.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-5.c
deleted file mode 100644
index 1c3c3fa72c0..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-5.c
+++ /dev/null
@@ -1,71 +0,0 @@
-/* { dg-do run } */
-/* { dg-require-effective-target powerpc_future_hw } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
-unsigned long long int
-do_vec_gnb (vector unsigned int source, int stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 2);
-    case 3:
-      return vec_gnb (source, 3);
-    case 4:
-      return vec_gnb (source, 4);
-    case 5:
-      return vec_gnb (source, 5);
-    case 6:
-      return vec_gnb (source, 6);
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned int source_a = { 0, 0, 0, 0x88888888 };
-  vector unsigned int source_b = { 0, 0, 0x80808080, 0x80808080 };
-  vector unsigned int source_c = { 0, 0, 0x88888888, 0x88888888 };
-  vector unsigned int source_d =
-    { 0x80808080, 0x80808080, 0x80808080, 0x80808080 };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
-
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-6.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-6.c
deleted file mode 100644
index a6dc78a3e98..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-6.c
+++ /dev/null
@@ -1,71 +0,0 @@
-/* { dg-do compile } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
-unsigned long long int
-do_vec_gnb (vector unsigned long long int source, int stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 2);
-    case 3:
-      return vec_gnb (source, 3);
-    case 4:
-      return vec_gnb (source, 4);
-    case 5:
-      return vec_gnb (source, 5);
-    case 6:
-      return vec_gnb (source, 6);
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned long long int source_a = { 0, 0x8888888800000000ull };
-  vector unsigned long long int source_b = { 0, 0x8080808080808080ull };
-  vector unsigned long long int source_c = { 0, 0x8888888888888888ull };
-  vector unsigned long long int source_d = { 0x8080808080808080ull,
-					     0x8080808080808080ull };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
-
-/* { dg-final { scan-assembler {\mvgnb\M} } } */
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-7.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-7.c
deleted file mode 100644
index bbacff986a0..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-7.c
+++ /dev/null
@@ -1,71 +0,0 @@
-/* { dg-do run } */
-/* { dg-require-effective-target powerpc_future_hw } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
-unsigned long long int
-do_vec_gnb (vector unsigned long long int source, int stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 2);
-    case 3:
-      return vec_gnb (source, 3);
-    case 4:
-      return vec_gnb (source, 4);
-    case 5:
-      return vec_gnb (source, 5);
-    case 6:
-      return vec_gnb (source, 6);
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned long long int source_a = { 0, 0x8888888800000000ull };
-  vector unsigned long long int source_b = { 0, 0x8080808080808080ull };
-  vector unsigned long long int source_c = { 0, 0x8888888888888888ull };
-  vector unsigned long long int source_d = { 0x8080808080808080ull,
-					     0x8080808080808080ull };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
-
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-8.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-8.c
deleted file mode 100644
index 23c16e51d48..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-8.c
+++ /dev/null
@@ -1,75 +0,0 @@
-/* { dg-do compile } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
-unsigned long long int
-do_vec_gnb (vector unsigned __int128 source, int stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 2);
-    case 3:
-      return vec_gnb (source, 3);
-    case 4:
-      return vec_gnb (source, 4);
-    case 5:
-      return vec_gnb (source, 5);
-    case 6:
-      return vec_gnb (source, 6);
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned __int128 source_a =
-    { ((unsigned __int128) 0x8888888800000000ull) << 64 };
-  vector unsigned __int128 source_b =
-    { ((unsigned __int128) 0x8080808080808080ull) << 64 };
-  vector unsigned __int128 source_c =
-    { ((unsigned __int128) 0x8888888888888888ull) << 64 };
-  vector unsigned __int128 source_d =
-    { 0x8080808080808080ull |
-      ((unsigned __int128) 0x8080808080808080ull) << 64 };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
-
-/* { dg-final { scan-assembler {\mvgnb\M} } } */
diff --git a/gcc/testsuite/gcc.target/powerpc/vec-gnb-9.c b/gcc/testsuite/gcc.target/powerpc/vec-gnb-9.c
deleted file mode 100644
index 659e802d819..00000000000
--- a/gcc/testsuite/gcc.target/powerpc/vec-gnb-9.c
+++ /dev/null
@@ -1,74 +0,0 @@
-/* { dg-do run } */
-/* { dg-require-effective-target powerpc_future_hw } */
-/* { dg-options "-mdejagnu-cpu=future" } */
-
-#include <altivec.h>
-
-extern void abort (void);
-
-/* This test is replicated for every different vector type since
-   vec_gnb is polymorphic.  */
-unsigned long long int
-do_vec_gnb (vector unsigned __int128 source, int stride)
-{
-  switch (stride)
-    {
-    case 2:
-      return vec_gnb (source, 2);
-    case 3:
-      return vec_gnb (source, 3);
-    case 4:
-      return vec_gnb (source, 4);
-    case 5:
-      return vec_gnb (source, 5);
-    case 6:
-      return vec_gnb (source, 6);
-    case 7:
-      return vec_gnb (source, 7);
-
-    default:
-      /* Illegal value of stride */
-      abort ();
-      return 0;
-    }
-}
-
-int
-main (int argc, char *argv [])
-{
-  /* For result = 0xaaaa_0000_0000_0000, use:
-      stride = 2: binary 1x0x_1x0x_1x0x_... = 0x8888_8888_0000_0000, 0
-      stride = 4: binary 1xxx_0xxx_1xxx_0xxxx = 0x8080_8080_8080_8080, 0
-
-     For result = 0xaaaa_aaaa_0000_0000, use:
-      stride = 2: source = 0x8888_8888_8888_8888, 0x0 }
-      stride = 4: source = { 0x8080_8080_8080_8080, 0x8080_8080_8080_8080 }
-  */
-
-  /* The last array element appears in the left-most (first) bit
-     positions of the vector register.  */
-  vector unsigned __int128 source_a =
-    { ((unsigned __int128) 0x8888888800000000ull) << 64 };
-  vector unsigned __int128 source_b =
-    { ((unsigned __int128) 0x8080808080808080ull) << 64 };
-  vector unsigned __int128 source_c =
-    { ((unsigned __int128) 0x8888888888888888ull) << 64 };
-  vector unsigned __int128 source_d =
-    { 0x8080808080808080ull |
-      ((unsigned __int128) 0x8080808080808080ull) << 64 };
-
-  unsigned long long int results [] =
-    { 0xaaaa000000000000ull, 0xaaaa000000000000ull,
-      0xaaaaaaaa00000000ull, 0xaaaaaaaa00000000ull };
-
-  if (do_vec_gnb (source_a, 2) != results [0])
-    abort ();
-  if (do_vec_gnb (source_b, 4) != results [1])
-    abort ();
-  if (do_vec_gnb (source_c, 2) != results [2])
-    abort ();
-  if (do_vec_gnb (source_d, 4) != results [3])
-    abort ();
-
-  return 0;
-}
