Mercurial > hg > CbC > CbC_gcc
annotate libgomp/testsuite/libgomp.c/pr46886.c @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children |
rev | line source |
---|---|
111 | 1 /* { dg-do run } */ |
2 /* { dg-options "-O -ftree-parallelize-loops=4 -fno-tree-ch -fno-tree-dominator-opts" } */ | |
3 | |
4 void abort(void); | |
5 | |
6 int d[1024], e[1024]; | |
7 | |
8 int foo (void) | |
9 { | |
10 int s = 0; | |
11 int i; | |
12 for (i = 0; i < 1024; i++) | |
13 s += d[i] - e[i]; | |
14 return s; | |
15 } | |
16 | |
17 int main () | |
18 { | |
19 int i; | |
20 for (i = 0; i < 1024; i++) | |
21 { | |
22 d[i] = i * 2; | |
23 e[i] = i; | |
24 } | |
25 if (foo () != 1023 * 1024 / 2) | |
26 abort (); | |
27 return 0; | |
28 } |