diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/ipa/ipa-ea-01-collect-global-pointers-to-record-0.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/ipa/ipa-ea-01-collect-global-pointers-to-record-0.c | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-ea-01-collect-global-pointers-to-record-0.c b/gcc/testsuite/gcc.dg/ipa/ipa-ea-01-collect-global-pointers-to-record-0.c new file mode 100644 index 00000000000..692daf9dc93 --- /dev/null +++ b/gcc/testsuite/gcc.dg/ipa/ipa-ea-01-collect-global-pointers-to-record-0.c @@ -0,0 +1,23 @@ +/* { dg-do link } */ +/* { dg-options "-fipa-type-escape-analysis -fdump-ipa-type-escape-analysis -fprint-escape-analysis" } */ + +#include <stddef.h> + +struct astruct_s +{ + _Bool a; + _Bool b; + _Bool c; +}; +struct astruct_s *astruct; + +int +main () +{ + astruct = NULL; +} + +// This is for the structure +/* { dg-final { scan-ipa-dump "collected: record astruct_s .boolean_type a.boolean_type b.boolean_type c.." "type-escape-analysis" } } */ +// This one has an extra dot to mark the * for the pointer +/* { dg-final { scan-ipa-dump "collected: record astruct_s .boolean_type a.boolean_type b.boolean_type c..." "type-escape-analysis" } } */ |