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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.target/] [powerpc/] [pr48053-2.c] - Blame information for rev 691

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 691 jeremybenn
/* Test for ICE arising from VSX code generation.  */
2
/* { dg-do compile } */
3
/* { dg-options "-O3 -mcpu=power7" } */
4
/* { dg-require-effective-target powerpc_vsx_ok } */
5
 
6
struct timeval
7
{
8
  long tv_sec;
9
  long tv_usec;
10
};
11
 
12
extern char *bar (struct timeval *);
13
int *error;
14
 
15
void
16
foo (void *ptr)
17
{
18
  struct timeval tm;
19
  long n1, n2;
20
 
21
  if (!ptr)
22
    {
23
      *error = 1;
24
      n1 = -1;
25
      n2 = -1;
26
    }
27
  else
28
    {
29
      n1 = 0;
30
      n2 = *error;
31
    }
32
 
33
  tm.tv_sec = n1;
34
  tm.tv_usec = n2;
35
 
36
  if (*error)
37
    bar (&tm);
38
}

powered by: WebSVN 2.1.0

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