aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/c-c++-common/gomp/scan-2.c
blob: 4f322ab65de658b22c6d3de64de06deffd8d360a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
int a, b;

void
f1 (int *c, int *d)
{
  int i;
  #pragma omp simd reduction (inscan, +: a)
  for (i = 0; i < 64; i++)
    {
      d[i] = a;
      #pragma omp scan exclusive (a)
      a += c[i];
    }
}