diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/pr118947-1.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/pr118947-1.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/pr118947-1.c b/gcc/testsuite/gcc.dg/pr118947-1.c new file mode 100644 index 0000000..8733e8d --- /dev/null +++ b/gcc/testsuite/gcc.dg/pr118947-1.c @@ -0,0 +1,15 @@ +/* PR tree-optimization/118947 */ +/* { dg-do compile { target size32plus } } */ +/* { dg-options "-O2 -fdump-tree-forwprop1-details" } */ +/* { dg-final { scan-tree-dump-times "after previous" 1 "forwprop1" } } */ + +void* aaa(); +void* bbb() +{ + char buf[1025] = {}; + /* Tha call to aaa should not matter and clobber buf. */ + void* ret = aaa(); + __builtin_memcpy(ret, buf, sizeof(buf)); + return ret; +} + |