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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [autopar/] [pr46194.c] - Rev 689

Compare with Previous | Blame | View Log

/* PR tree-optimization/46194 */
/* { dg-do compile } */
/* { dg-options "-O -ftree-parallelize-loops=2 -fdump-tree-parloops-details" } */
 
#define N 1000
int a[N];
 
int foo (void)
{
  int j;
  int i;
 
  /* This is not blocked as it is not profitable.  */
  for (i = 0; i < N; i++)
    for (j = 0; j < N; j++)
      a[j] = a[i] + 1;
 
  return a[0];
}
 
/* This loop cannot be parallelized due to a dependence.  */
 
/* { dg-final { scan-tree-dump-times "SUCCESS: may be parallelized" 0 "parloops" } } */
/* { dg-final { cleanup-tree-dump "parloops" } } */
 

Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

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