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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [gomp/] [clause-3.C] - Blame information for rev 818

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

Line No. Rev Author Line
1 693 jeremybenn
// { dg-do compile }
2
// { dg-require-effective-target tls }
3
 
4
#define p parallel
5
 
6
extern void bar (void);
7
extern char q[]; // { dg-error "has incomplete type" }
8
int t;
9
#pragma omp threadprivate (t)
10
 
11
void
12
foo (int x)
13
{
14
  char *p;
15
  struct S { int i; int j; } s;
16
  char a[32];
17
  double d;
18
  int i;
19
  const int c = 8;
20
#pragma omp p shared (x, x) // { dg-error "more than once" }
21
    ;
22
#pragma omp p private (x) private (x) // { dg-error "more than once" }
23
    ;
24
#pragma omp p shared (x) firstprivate (x) // { dg-error "more than once" }
25
    ;
26
#pragma omp p firstprivate (x, x) // { dg-error "more than once" }
27
    ;
28
#pragma omp p for shared (x) lastprivate (x) // { dg-error "more than once" }
29
  for (i = 0; i < 10; i++)
30
    ;
31
#pragma omp p for private (x) lastprivate (x) // { dg-error "more than once" }
32
  for (i = 0; i < 10; i++)
33
    ;
34
#pragma omp p for lastprivate (x, x) // { dg-error "more than once" }
35
  for (i = 0; i < 10; i++)
36
    ;
37
#pragma omp single private (x) copyprivate (x) // { dg-error "more than once" }
38
    ;
39
#pragma omp p shared (bar) // { dg-error "is not a variable" }
40
    ;
41
#pragma omp p private (bar) // { dg-error "is not a variable" }
42
    ;
43
#pragma omp p firstprivate (bar) // { dg-error "is not a variable" }
44
    ;
45
#pragma omp p reduction (+:p) // { dg-error "has invalid type for" }
46
    ;
47
#pragma omp p reduction (*:s) // { dg-error "has invalid type for" }
48
    ;
49
#pragma omp p reduction (-:a) // { dg-error "has invalid type for" }
50
    ;
51
  d = 0;
52
#pragma omp p reduction (*:d)
53
    ;
54
#pragma omp p reduction (|:d) // { dg-error "has invalid type for" }
55
    ;
56
#pragma omp p reduction (&&:d) // { dg-error "has invalid type for" }
57
    ;
58
#pragma omp p copyin (d) // { dg-error "must be 'threadprivate'" }
59
    ;
60
#pragma omp p copyin (x) // { dg-error "must be 'threadprivate'" }
61
    ;
62
#pragma omp p for firstprivate (x) lastprivate (x)
63
  for (i = 0; i < 10; i++)
64
    ;
65
#pragma omp p private (q) // { dg-error "unspecified bounds" }
66
    ;
67
#pragma omp p firstprivate (q) // { dg-error "unspecified bounds" }
68
    ;
69
#pragma omp p for lastprivate (q) // { dg-error "unspecified bounds" }
70
  for (i = 0; i < 10; i++)
71
    ;
72
#pragma omp p shared (t) // { dg-error "predetermined 'threadprivate'" }
73
    ;
74
#pragma omp p private (t) // { dg-error "predetermined 'threadprivate'" }
75
    ;
76
#pragma omp p firstprivate (t) // { dg-error "predetermined 'threadprivate'" }
77
    ;
78
#pragma omp p for lastprivate (t) // { dg-error "predetermined 'threadpriv" }
79
  for (i = 0; i < 10; i++)
80
    ;
81
#pragma omp p reduction (*:t) // { dg-error "predetermined 'threadprivate'" }
82
    ;
83
#pragma omp p shared (c) // { dg-error "predetermined 'shared'" }
84
    ;
85
#pragma omp p private (c) // { dg-error "predetermined 'shared'" }
86
    ;
87
#pragma omp p firstprivate (c)
88
    ;
89
#pragma omp p for lastprivate (c) // { dg-error "predetermined 'shared'" }
90
  for (i = 0; i < 10; i++)
91
    ;
92
#pragma omp p reduction (*:c) // { dg-error "predetermined 'shared'" }
93
    ;
94
}

powered by: WebSVN 2.1.0

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