* gcc.dg/torture/stackalign/builtin-apply-2.c: Fix skip-if syntax.
[official-gcc.git] / gcc / testsuite / gcc.dg / graphite / block-5.c
blob97bf410dcf6fb018bfb43b51bd88371c1a5c6dfc
1 /* { dg-require-effective-target size32plus } */
3 #define DEBUG 0
4 #if DEBUG
5 #include <stdio.h>
6 #endif
8 #define N 200
10 int a[N][N];
11 int b[N][N];
13 static int __attribute__((noinline))
14 foo (void)
16 int i, j;
17 int res = 0;
19 /* This loop nest should be blocked. */
20 for (j = 1; j < N; j++)
21 for (i = 0; i < N; i++)
22 a[i][j] = a[i][j-1] + b[i][j];
24 for (i = 0; i < N; i++)
25 res += a[i][i];
27 return res;
30 extern void abort ();
32 int
33 main (void)
35 int i, j, res;
37 for (i = 0; i < N; i++)
38 for (j = 0; j < N; j++)
40 a[i][j] = i + j;
41 b[i][j] = i - j;
44 res = foo ();
46 #if DEBUG
47 fprintf (stderr, "res = %d \n", res);
48 #endif
50 if (res != 1333300)
51 abort ();
53 return 0;
56 /* { dg-final { scan-tree-dump "tiled by" "graphite" } } */