OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [libgomp/] [testsuite/] [libgomp.c/] [pr43893.c] - Blame information for rev 859

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 273 jeremybenn
/* PR c/43893 */
2
/* { dg-do run } */
3
 
4
extern void abort (void);
5
 
6
int
7
main ()
8
{
9
  int c;
10
  unsigned int i;
11
  int j;
12
  c = 0;
13
#pragma omp parallel for reduction(+:c)
14
  for (i = 0; i < 1; i++)
15
    c++;
16
  if (c != 1)
17
    abort ();
18
  c = 0;
19
#pragma omp parallel for reduction(+:c)
20
  for (i = 0; i <= 0; i++)
21
    c++;
22
  if (c != 1)
23
    abort ();
24
  c = 0;
25
#pragma omp parallel for reduction(+:c)
26
  for (j = - __INT_MAX__ - 1; j < - __INT_MAX__; j++)
27
    c++;
28
  if (c != 1)
29
    abort ();
30
  c = 0;
31
#pragma omp parallel for reduction(+:c)
32
  for (j = - __INT_MAX__ - 1; j <= - __INT_MAX__ - 1; j++)
33
    c++;
34
  if (c != 1)
35
    abort ();
36
  c = 0;
37
#pragma omp parallel for reduction(+:c)
38
  for (i = 2U * __INT_MAX__ + 1; i > 2U * __INT_MAX__; i--)
39
    c++;
40
  if (c != 1)
41
    abort ();
42
  c = 0;
43
#pragma omp parallel for reduction(+:c)
44
  for (i = 2U * __INT_MAX__ + 1; i >= 2U * __INT_MAX__ + 1; i--)
45
    c++;
46
  if (c != 1)
47
    abort ();
48
  c = 0;
49
#pragma omp parallel for reduction(+:c)
50
  for (j = __INT_MAX__; j > __INT_MAX__ - 1; j--)
51
    c++;
52
  if (c != 1)
53
    abort ();
54
  c = 0;
55
#pragma omp parallel for reduction(+:c)
56
  for (j = __INT_MAX__; j >= __INT_MAX__; j--)
57
    c++;
58
  if (c != 1)
59
    abort ();
60
  return 0;
61
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.