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

Subversion Repositories openrisc

[/] [openrisc/] [tags/] [gnu-src/] [gcc-4.5.1/] [gcc-4.5.1-or32-1.0rc1/] [gcc/] [testsuite/] [g++.dg/] [gomp/] [pr29965-10.C] - Diff between revs 301 and 338

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 301 Rev 338
// PR middle-end/29965
// PR middle-end/29965
// Test that OpenMP construct bodies which never return don't cause ICEs.
// Test that OpenMP construct bodies which never return don't cause ICEs.
// This is invalid code, but we don't emit diagnostics for it, nevertheless
// This is invalid code, but we don't emit diagnostics for it, nevertheless
// we test that we don't ICE on it.
// we test that we don't ICE on it.
// { dg-do compile }
// { dg-do compile }
// { dg-options "-O2 -fopenmp" }
// { dg-options "-O2 -fopenmp" }
void
void
foo1 ()
foo1 ()
{
{
  int i;
  int i;
#pragma omp for schedule (static)
#pragma omp for schedule (static)
  for (i = 0; i < 2834; i++)
  for (i = 0; i < 2834; i++)
    throw 0;
    throw 0;
}
}
void
void
foo2 ()
foo2 ()
{
{
  int i;
  int i;
#pragma omp parallel for schedule (static)
#pragma omp parallel for schedule (static)
  for (i = 0; i < 2834; i++)
  for (i = 0; i < 2834; i++)
    throw 0;
    throw 0;
}
}
 
 

powered by: WebSVN 2.1.0

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