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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.dg/] [graphite/] [interchange-7.c] - Blame information for rev 301

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 298 jeremybenn
/* { dg-require-effective-target size32plus } */
2
 
3
/* Formerly known as ltrans-8.c */
4
 
5
#define DEBUG 0
6
#if DEBUG
7
#include <stdio.h>
8
#endif
9
 
10
#define N 111
11
#define M 1111
12
 
13
static int __attribute__((noinline))
14
foo (double *a)
15
{
16
  int i,j;
17
  int r = 0;
18
 
19
  for (i = 0; i < N; ++i)
20
    for (j = 0; j < M; ++j)
21
      r += a[j * N + i];
22
 
23
  return r;
24
}
25
 
26
extern void abort ();
27
 
28
int
29
main (void)
30
{
31
  double A[N*M];
32
  int i, res;
33
 
34
  for (i = 0; i < N*M; i++)
35
    A[i] = 2;
36
 
37
  res = foo (A);
38
 
39
#if DEBUG
40
  fprintf (stderr, "res = %d \n", res);
41
#endif
42
 
43
  if (res != 246642)
44
    abort ();
45
 
46
  return 0;
47
}
48
 
49
/* { dg-final { scan-tree-dump-times "will be interchanged" 1 "graphite" } } */
50
/* { dg-final { cleanup-tree-dump "graphite" } } */

powered by: WebSVN 2.1.0

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