URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Go to most recent revision |
Only display areas with differences |
Details |
Blame |
View Log
Rev 154 |
Rev 816 |
/* PR c++/26943 */
|
/* PR c++/26943 */
|
/* { dg-do run } */
|
/* { dg-do run } */
|
|
|
extern void abort (void);
|
extern void abort (void);
|
extern void omp_set_dynamic (int);
|
extern void omp_set_dynamic (int);
|
int n = 6;
|
int n = 6;
|
|
|
int
|
int
|
main (void)
|
main (void)
|
{
|
{
|
int i, x = 0;
|
int i, x = 0;
|
omp_set_dynamic (0);
|
omp_set_dynamic (0);
|
#pragma omp parallel for num_threads (16) firstprivate (n) lastprivate (n) \
|
#pragma omp parallel for num_threads (16) firstprivate (n) lastprivate (n) \
|
schedule (static, 1) reduction (+: x)
|
schedule (static, 1) reduction (+: x)
|
for (i = 0; i < 16; i++)
|
for (i = 0; i < 16; i++)
|
{
|
{
|
if (n != 6)
|
if (n != 6)
|
++x;
|
++x;
|
n = i;
|
n = i;
|
}
|
}
|
if (x || n != 15)
|
if (x || n != 15)
|
abort ();
|
abort ();
|
return 0;
|
return 0;
|
}
|
}
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.