(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.target/
powerpc/
pr104015-1.c
       1  /* { dg-require-effective-target powerpc_p9vector_ok } */
       2  /* { dg-options "-mdejagnu-cpu=power9 -O2 -ftree-vectorize -fno-vect-cost-model -fdump-tree-vect-details" } */
       3  
       4  /* As PR104015, we don't expect vectorizer will re-try some vector modes
       5     for epilogues on Power9, since Power9 doesn't support partial vector
       6     by defaut.  */
       7  
       8  #include <stdarg.h>
       9  #define N 200
      10  
      11  void __attribute__((noinline))
      12  foo (unsigned short *__restrict__ pInput, unsigned short *__restrict__ pOutput)
      13  {
      14    unsigned short i, a, b, c;
      15  
      16    for (i = 0; i < N / 3; i++)
      17      {
      18         a = *pInput++;
      19         b = *pInput++;
      20         c = *pInput++;
      21  
      22         *pOutput++ = a + b + c + 3;
      23         *pOutput++ = a + b + c + 12;
      24         *pOutput++ = a + b + c + 1;
      25      }
      26  }
      27  
      28  /* { dg-final { scan-tree-dump-not "Re-trying epilogue analysis with vector mode" "vect" } } */