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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [vect/] [vect-89.c] - Blame information for rev 853

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

Line No. Rev Author Line
1 149 jeremybenn
/* { dg-require-effective-target vect_int } */
2
 
3
#include <stdarg.h>
4
#include "tree-vect.h"
5
 
6
#define N 16
7
 
8
struct tmp_struct
9
{
10
  int x;
11
  int y[N];
12
};
13
 
14
int main1 ()
15
{
16
  int i, *q;
17
  struct tmp_struct tmp, *p;
18
 
19
  p = &tmp;
20
  q = p->y;
21
 
22
  for (i = 0; i < N; i++)
23
    {
24
      *q++ = 5;
25
    }
26
 
27
  /* check results: */
28
  for (i = 0; i < N; i++)
29
    {
30
      if (p->y[i] != 5)
31
        {
32
          abort ();
33
        }
34
    }
35
 
36
  return 0;
37
}
38
 
39
int main (void)
40
{
41
  check_vect ();
42
 
43
  return main1 ();
44
}
45
 
46
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
47
/* { dg-final { scan-tree-dump-times "Vectorizing an unaligned access" 0 "vect" } } */
48
/* { dg-final { scan-tree-dump-times "Alignment of access forced using peeling" 1 "vect" } } */
49
/* { 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.