Mercurial > hg > CbC > CbC_gcc
annotate gcc/testsuite/gcc.dg/pr54782.c @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | 04ced10e8804 |
children |
rev | line source |
---|---|
111 | 1 /* { dg-do compile } */ |
2 /* { dg-require-effective-target pthread } */ | |
3 /* { dg-options "-O -ffast-math -ftree-parallelize-loops=2 -g" } */ | |
4 | |
5 struct S | |
6 { | |
7 int n; | |
8 float *a; | |
9 }; | |
10 | |
11 int | |
12 foo (struct S *s) | |
13 { | |
14 float sum = 0; | |
15 int i; | |
16 for (i = 0; i < s->n; i++) | |
17 sum += s->a[i]; | |
18 return sum; | |
19 } |