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/] [20070725-1.c] - Blame information for rev 315

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

Line No. Rev Author Line
1 298 jeremybenn
/* This used to fail due to a ifcombine problem wrecking 64bit
2
   checks.  Fixed with rev. 126876.  */
3
/* { dg-do run } */
4
/* { dg-options "-O1" } */
5
 
6
struct tree_base
7
{
8
  unsigned code:16;
9
 
10
  unsigned side_effects_flag:1;
11
  unsigned constant_flag:1;
12
  unsigned addressable_flag:1;
13
  unsigned volatile_flag:1;
14
  unsigned readonly_flag:1;
15
  unsigned unsigned_flag:1;
16
  unsigned asm_written_flag:1;
17
  unsigned nowarning_flag:1;
18
 
19
  unsigned used_flag:1;
20
  unsigned nothrow_flag:1;
21
  unsigned static_flag:1;
22
  unsigned public_flag:1;
23
  unsigned private_flag:1;
24
  unsigned protected_flag:1;
25
  unsigned deprecated_flag:1;
26
  unsigned invariant_flag:1;
27
 
28
  unsigned lang_flag_0:1;
29
  unsigned lang_flag_1:1;
30
  unsigned lang_flag_2:1;
31
  unsigned lang_flag_3:1;
32
  unsigned lang_flag_4:1;
33
  unsigned lang_flag_5:1;
34
  unsigned lang_flag_6:1;
35
  unsigned visited:1;
36
 
37
  unsigned spare1:16;
38
  unsigned spare2:8;
39
  unsigned long  a;
40
};
41
 
42
int
43
foo (struct tree_base *rhs)
44
{
45
  if (({const struct tree_base* __t = (rhs);  __t;})->readonly_flag
46
      && (rhs)->static_flag)
47
    return 1;
48
 
49
  return 0;
50
}
51
 
52
extern void abort (void);
53
 
54
int
55
main ()
56
{
57
  struct tree_base t;
58
 
59
  t.readonly_flag = t.static_flag = 0;
60
  if (foo (&t))
61
    abort ();
62
 
63
  return 0;
64
}

powered by: WebSVN 2.1.0

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