1  /* { dg-do compile } */
       2  /* { dg-require-effective-target vect_int } */
       3  
       4  #include "tree-vect.h"
       5  
       6  int a[1020];
       7  
       8  void __attribute__((noinline))
       9  foo ()
      10  {
      11    for (int i = 0; i < 1020; i += 5)
      12      {
      13        a[i] = i;
      14        a[i+1] = i;
      15        a[i+2] = i;
      16        a[i+3] = i;
      17        a[i+4] = i;
      18      }
      19  }
      20  
      21  int main ()
      22  {
      23    check_vect ();
      24  
      25    foo ();
      26  
      27    /* check results */
      28    for (int i = 0; i < 1020; ++i)
      29      if (a[i] != ((i + 4) / 5) * 5)
      30        abort ();
      31  
      32    return 0;
      33  }
      34  
      35  /* Make sure we are not triggering hybrid SLP due to the IV update.  */
      36  /* { dg-final { scan-tree-dump "Loop contains only SLP stmts" "vect" } } */
      37  /* { dg-final { scan-tree-dump "vectorized 1 loops" "vect" } } */