blob: c8a966f45e9b0180af01c8d5fe38d4865febec78 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
/* { dg-do link } */
/* { dg-options "-fipa-type-escape-analysis -fdump-ipa-type-escape-analysis -fprint-access-analysis " } */
#include <stdio.h>
struct astruct_s
{
_Bool a;
_Bool b;
_Bool c;
};
struct astruct_s *astruct;
int
main ()
{
astruct->a++;
astruct->a = 3;
}
// This says that only writes are happening even if astruct is a pointer
/* { dg-final { scan-wpa-ipa-dump "astruct_s.a = 0x0003" "type-escape-analysis" } } */
|