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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [vect/] [O3-vect-pr34223.c] - Blame information for rev 801

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

Line No. Rev Author Line
1 689 jeremybenn
/* { dg-require-effective-target vect_int } */
2
 
3
#include "tree-vect.h"
4
 
5
#define M 10
6
#define N 3
7
 
8
void __attribute__((noinline))
9
foo (int n, int *ub, int *uc)
10
{
11
  int i, j, tmp1;
12
 
13
  for (i = 0; i < n; i++)
14
    {
15
      tmp1 = 0;
16
      for (j = 0; j < M; j++)
17
        {
18
          tmp1 += uc[i] * ((int)(j << N) / M);
19
        }
20
      ub[i] = tmp1;
21
    }
22
}
23
 
24
int main()
25
{
26
  int uc[16], ub[16];
27
  check_vect ();
28
  foo (16, uc, ub);
29
  return 0;
30
}
31
 
32
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" { target vect_int_mult } } } */
33
/* { 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.