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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [vect/] [vect-119.c] - Blame information for rev 689

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 689 jeremybenn
/* { dg-do compile } */
2
 
3
#define OUTER 32
4
#define INNER 40
5
 
6
static unsigned int
7
bar (const unsigned int x[INNER][2], unsigned int sum)
8
{
9
  int i;
10
 
11
  for (i = 0; i < INNER; i++)
12
    sum += x[i][0] * x[i][0] + x[i][1] * x[i][1];
13
  return sum;
14
}
15
 
16
unsigned int foo (const unsigned int x[OUTER][INNER][2])
17
{
18
  int i;
19
  unsigned int sum;
20
 
21
  sum = 0.0f;
22
  for (i = 0; i < OUTER; i++)
23
    sum = bar (x[i], sum);
24
  return sum;
25
}
26
 
27
/* { dg-final { scan-tree-dump-times "Detected interleaving of size 2" 1 "vect" } } */
28
/* { dg-final { cleanup-tree-dump "vect" } } */

powered by: WebSVN 2.1.0

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