PR middle-end/77357 - strlen of constant strings not folded
[official-gcc.git] / gcc / testsuite / gcc.dg / vect / pr66636.c
blobc0733ffa5a3bbc05cd971d29f0f02bab6248afb8
1 /* { dg-additional-options "-mavx2" { target avx_runtime } } */
3 #include "tree-vect.h"
5 extern void abort (void);
7 struct X { double x; double y; };
9 void __attribute__((noinline,noclone))
10 foo (struct X *x, double px, int s)
12 int i;
13 for (i = 0; i < 256; ++i)
15 x[i*s].x = px;
16 x[i*s].y = i + px;
20 int main()
22 struct X x[512];
23 int i;
24 check_vect ();
25 foo (x, 1., 2);
26 if (x[0].x != 1. || x[0].y != 1.
27 || x[510].x != 1. || x[510].y != 256.)
28 abort ();
29 return 0;