1  /* PR target/94509 */
       2  /* { dg-do run { target avx512bw } } */
       3  /* { dg-options "-O2 -mavx512bw" } */
       4  
       5  #define AVX512BW
       6  #include "avx512f-helper.h"
       7  
       8  typedef unsigned short __attribute__ ((__vector_size__ (64))) V;
       9  
      10  __attribute__((noipa)) V
      11  foo (V x)
      12  {
      13    return __builtin_shuffle (x, (V) { 0, 0, 0, 0, 0, 0, 0, 0,
      14  				     15, 15, 15, 15, 15, 15, 15, 15,
      15  				     0, 0, 0, 0, 0, 0, 0, 0,
      16  				     15, 15, 15, 15, 15, 15, 15, 15 });
      17  }
      18  
      19  static void
      20  TEST (void)
      21  {
      22    V v = foo ((V) { 1, 2, 3, 4, 5, 6, 7, 8,
      23  		   9, 10, 11, 12, 13, 14, 15, 16,
      24  		   17, 18, 19, 20, 21, 22, 23, 24,
      25  		   25, 26, 27, 28, 29, 30, 31, 32 });
      26    unsigned int i;
      27    for (i = 0; i < sizeof (v) / sizeof (v[0]); i++)
      28      if (v[i] != ((i & 8) ? 16 : 1))
      29        abort ();
      30  }