gcc/testsuite/gcc.dg/vect/vect-alias-check-6.c
raw| 1 | /* { dg-do compile } */ |
| 2 | /* { dg-require-effective-target vect_int } */ |
| 3 | |
| 4 | #define N 16 |
| 5 | |
| 6 | struct s { int x[N]; }; |
| 7 | |
| 8 | void |
| 9 | f1 (struct s *a, struct s *b) |
| 10 | { |
| 11 | for (int i = 0; i < N - 1; ++i) |
| 12 | a->x[i + 1] += b->x[i]; |
| 13 | } |
| 14 | |
| 15 | /* { dg-final { scan-tree-dump {checking that [^\n]* and [^\n]* have different addresses} "vect" } } */ |
| 16 | /* { dg-final { scan-tree-dump "LOOP VECTORIZED" "vect" } } */ |