summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/ipa/ipa-structreorg-54-csmith-3.c
blob: 0b4e981deb423eed199fd4027d02e1f4e996d9dd (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
/* { dg-do run } */
/* { dg-options  "-w -flto -fipa-type-escape-analysis -fdump-ipa-type-escape-analysis " } */

#include <stdint.h>
// TODO: So, our analysis says that we are deleting a field "a".
// And that the field "a" is contained in struct "b".
// However, we are doing is_interesting_struct("c") == yes
// is_interesting_field("a") == yes
// and so we delete field a from struct c.
struct
{
  uint64_t a
} b[];
struct
{
  unsigned : 5;
  unsigned a
} c;
d ()
{
  uint16_t e = b;
  int8_t f = c.a;
}
main () {}