(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
pr109230.c
       1  /* PR tree-optimization/109230 */
       2  /* { dg-do run } */
       3  /* { dg-options "-O2 -Wno-psabi" } */
       4  
       5  #if __SIZEOF_FLOAT__ == __SIZEOF_INT__
       6  typedef float V __attribute__((vector_size (4 * sizeof (float))));
       7  typedef int VI __attribute__((vector_size (4 * sizeof (float))));
       8  
       9  __attribute__((noipa)) V
      10  foo (V x, V y)
      11  {
      12    V a = x - y;
      13    V b = y + x;
      14    return __builtin_shuffle (b, a, (VI) { 0, 5, 2, 3 });
      15  }
      16  
      17  int
      18  main ()
      19  {
      20    V a = (V) { 1.0f, 2.0f, 3.0f, 4.0f };
      21    V b = (V) { 8.0f, 9.0f, 10.0f, 11.0f };
      22    V c = foo (a, b);
      23    if (c[0] != 9.0f || c[1] != -7.0f || c[2] != 13.0f || c[3] != 15.0f)
      24      __builtin_abort ();
      25  }
      26  #else
      27  int
      28  main ()
      29  {
      30  }
      31  #endif