1 /* { dg-require-effective-target vect_int } */
2 /* { dg-additional-options "--param vect-max-peeling-for-alignment=0 -fdump-tree-optimized-details-blocks" } */
8 #define NINTS (VECTOR_BITS / 32)
15 /* Keep execution time down. */
28 struct s a
; /* array a.n is unaligned */
31 struct s e
[N
]; /* array e.n is aligned */
34 /* Avoid big local temporaries. */
39 __attribute__ ((noinline
))
47 for (i
= 0; i
< OUTERN
; i
++)
48 for (j
= NINTS
- 1; j
< N
- NINTS
+ 1; j
++)
50 tmp1
.e
[i
].n
[1][2][j
] = 8;
54 for (i
= 0; i
< OUTERN
; i
++)
56 for (j
= NINTS
- 1; j
< N
- NINTS
+ 1; j
++)
58 if (tmp1
.e
[i
].n
[1][2][j
] != 8)
62 /* not consecutive, will use strided stores */
63 for (i
= 0; i
< OUTERN
; i
++)
64 for (j
= NINTS
- 1; j
< N
- NINTS
+ 1; j
++)
66 tmp1
.e
[j
].n
[1][2][j
] = 8;
70 for (i
= 0; i
< OUTERN
; i
++)
72 for (j
= NINTS
- 1; j
< N
- NINTS
+ 1; j
++)
74 if (tmp1
.e
[j
].n
[1][2][j
] != 8)
88 /* { dg-final { scan-tree-dump-times "vectorized 2 loops" 1 "vect" } } */
89 /* { dg-final { scan-tree-dump-times "Alignment of access forced using versioning" 1 "vect" {target {{! vector_alignment_reachable} && {! vect_hw_misalign} } } } } */
90 /* { dg-final { scan-tree-dump-not "Invalid sum" "optimized" } } */