Debian Codegraph @

gcc/testsuite/gcc.dg/tree-ssa/ldist-27.c

raw
1 /* { dg-do run { target size32plus } } */
2 /* { dg-options "-O3 -ftree-loop-distribute-patterns -fdump-tree-ldist-details" } */
3 /* { dg-skip-if "too big data segment" { visium-*-* } } */
4
5 #define M (300)
6 #define N (200)
7
8 struct st
9 {
10 double a[M];
11 double b[M];
12 double c[M][N];
13 };
14
15 int __attribute__ ((noinline))
16 foo (struct st *s)
17 {
18 int i, j;
19 for (i = 0; i != M;)
20 {
21 s->a[i] = 0.0;
22 s->b[i] = 1.0;
23 for (j = 0; 1; ++j)
24 {
25 if (j == N) goto L2;
26 s->c[i][j] = 0.0;
27 }
28 L2:
29 ++i;
30 }
31 return 0;
32 }
33
34 struct st s;
35
36 int
37 main (void)
38 {
39 return foo (&s);
40 }
41
42 /* { dg-final { scan-tree-dump "distributed: split to " "ldist" } } */