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

Subversion Repositories openrisc

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

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// { dg-do compile }
2
 
3
struct A { int a; };
4
struct B { B(); };
5
struct C { C(); C(const C&); };
6
struct D { D& operator=(const D&); };
7
 
8
class E { private: E(); public: E(int); };      // { dg-error "private" }
9
class F { private: F(const F&); public: F(); };   // { dg-error "private" }
10
class G { private: G& operator=(const G&); };        // { dg-error "private" }
11
 
12
void bar();
13
void foo()
14
{
15
  A a; B b; C c; D d; E e(0); F f; G g;
16
 
17
  #pragma omp parallel shared(a, b, c, d, e, f, g)
18
    bar();
19
 
20
  #pragma omp parallel private(a, b, c, d, f, g)
21
    bar();
22
  #pragma omp parallel private(e)               // { dg-error "context" }
23
    bar();
24
 
25
  #pragma omp parallel firstprivate(a, b, c, d, e, g)
26
    bar();
27
  #pragma omp parallel firstprivate(f)          // { dg-error "context" }
28
    bar();
29
 
30
  #pragma omp parallel sections lastprivate(a, b, d, c, f)
31
    { bar(); }
32
  #pragma omp parallel sections lastprivate(e)  // { dg-error "context" }
33
    { bar(); }
34
  #pragma omp parallel sections lastprivate(g)  // { dg-error "context" }
35
    { bar(); }
36
  #pragma omp parallel sections firstprivate(e) lastprivate(e)
37
    { bar(); }
38
}

powered by: WebSVN 2.1.0

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