Debian Codegraph @

gcc/testsuite/gcc.dg/vect/nodump-vect-opt-info-2.c

raw
1 /* { dg-do compile { target vect_int } } */
2 /* { dg-additional-options "-fopt-info-vec-all -O3" } */
3
4 extern void accumulate (int x, int *a);
5
6 int test_missing_function_defn (int *arr, int n) /* { dg-note "5: vectorized 0 loops in function" } */
7 /* { dg-prune-output "note: " } as we're not interested in matching any further
8 notes. */
9 {
10 int sum = 0;
11 for (int i = 0; i < n; ++i) /* { dg-missed "21: couldn't vectorize loop" } */
12 accumulate (arr[i], &sum); /* { dg-missed "5: statement clobbers memory: accumulate \\(.*\\);" } */
13 return sum;
14 }