PR tree-optimization/84740
[official-gcc.git] / gcc / testsuite / gcc.dg / vect / pr25413.c
blobe80d6970933e675b6056e5d119c6eb0e817a40f9
1 /* { dg-require-effective-target vect_double } */
3 #include <stdarg.h>
4 #include "tree-vect.h"
6 #define N 8
8 struct
10 char c;
11 double d[N];
12 } a;
14 __attribute__ ((noinline))
15 int main1()
17 int i;
18 for ( i=0; i<N; ++i )
19 a.d[i]=1;
20 return 0;
23 int main (void)
25 int i;
26 check_vect ();
28 main1 ();
29 for (i=0; i<N; i++)
30 if (a.d[i] != 1)
31 abort ();
32 return 0;
35 /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { target vector_alignment_reachable_for_64bit } } } */
36 /* { dg-final { scan-tree-dump-times "vectorized 1 loops" 0 "vect" { target { {! vector_alignment_reachable_for_64bit} && {! vect_hw_misalign} } } } } */
37 /* { dg-final { scan-tree-dump-times "vector alignment may not be reachable" 1 "vect" { target { {! vector_alignment_reachable_for_64bit} && {! vect_hw_misalign} } } } } */
38 /* { dg-final { scan-tree-dump-times "not vectorized: unsupported unaligned store" 1 "vect" { target { {! vector_alignment_reachable_for_64bit} && {! vect_hw_misalign} } } } } */