aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/pr61572.c
blob: 345633393b6803f196c2f393bce0f3f66a338ff4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/* { dg-do compile } */
/* { dg-options "-O2" } */

struct autofs_sb_info
{
  int exp_timeout;
};
void *f;
int g;
static int fn1 (struct autofs_sb_info *p1)
{
  int a, b;
  a = (
       {
       register __typeof__(0) c
#if defined __x86_64__
       asm("rdx")
#endif
       ;
       b = c;
       int d;
       __typeof__(0) e;
       e = p1->exp_timeout / 1000;
       switch (0)
       default:
       asm("" : "=a"(d) : "0"(e), ""(0));
       d;
       });
  if (a)
    return 1;
  if (b)
    p1->exp_timeout = 0;
  return 0;
}

int fn2 ()
{
  struct autofs_sb_info *h = f;
  switch (g)
    {
      case 0 ?:
0 : return fn1 (h);
      default:
    return 0;
    }
}