111
|
1 /* { dg-do compile } */
|
|
2 /* { dg-require-effective-target vect_int } */
|
|
3
|
|
4 #include <stdarg.h>
|
|
5 #include "tree-vect.h"
|
|
6
|
|
7 #define N 16
|
|
8 struct test {
|
|
9 char ca[N];
|
|
10 };
|
|
11
|
|
12 extern struct test s;
|
|
13
|
|
14 __attribute__ ((noinline))
|
|
15 int main1 ()
|
|
16 {
|
|
17 int i;
|
|
18
|
|
19 for (i = 0; i < N; i++)
|
|
20 {
|
|
21 s.ca[i] = 5;
|
|
22 }
|
|
23
|
|
24 /* check results: */
|
|
25 for (i = 0; i < N; i++)
|
|
26 {
|
|
27 if (s.ca[i] != 5)
|
|
28 abort ();
|
|
29 }
|
|
30
|
|
31 return 0;
|
|
32 }
|
|
33
|
|
34 int main (void)
|
|
35 {
|
|
36 return main1 ();
|
|
37 }
|
|
38
|
|
39 /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
|
131
|
40 /* { dg-final { scan-tree-dump "Vectorizing an unaligned access" "vect" { target { { { ! powerpc*-*-* } && vect_hw_misalign } && { { ! vect64 } || vect_multiple_sizes } } xfail { ! vect_unaligned_possible } } } } */
|
111
|
41 /* { dg-final { scan-tree-dump "Alignment of access forced using peeling" "vect" { target { vector_alignment_reachable && { vect64 && {! vect_multiple_sizes} } } } } } */
|
|
42 /* { dg-final { scan-tree-dump-times "Alignment of access forced using versioning" 1 "vect" { target { { {! vector_alignment_reachable} || {! vect64} } && {! vect_hw_misalign} } } } } */
|