(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
vect/
costmodel/
ppc/
costmodel-slp-33.c
       1  /* { dg-require-effective-target vect_int } */
       2  
       3  #include <stdarg.h>
       4  #include "../../tree-vect.h"
       5  
       6  #define N 32
       7  
       8  struct s{
       9    short a;	/* aligned */
      10    char b[N-1];  /* unaligned (offset 2B) */
      11  };
      12   
      13  int main1 ()
      14  {  
      15    int i;
      16    struct s tmp;
      17  
      18    /* unaligned */
      19    for (i = 0; i < N/4; i++)
      20      {
      21        tmp.b[2*i] = 5;
      22        tmp.b[2*i+1] = 15;
      23      }
      24  
      25    /* check results:  */
      26    for (i = 0; i <N/4; i++)
      27      {
      28        if (tmp.b[2*i] != 5
      29            || tmp.b[2*i+1] != 15)
      30          abort ();
      31      }
      32  
      33    return 0;
      34  }
      35  
      36  int main (void)
      37  { 
      38    check_vect ();
      39    
      40    return main1 ();
      41  } 
      42  
      43  /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 0 "vect" { target { ! vect_hw_misalign } } } } */