diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/tree-ssa/tailcall-15.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/tree-ssa/tailcall-15.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/tailcall-15.c b/gcc/testsuite/gcc.dg/tree-ssa/tailcall-15.c new file mode 100644 index 0000000..bf24fd8 --- /dev/null +++ b/gcc/testsuite/gcc.dg/tree-ssa/tailcall-15.c @@ -0,0 +1,16 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -fdump-tree-tailc-details" } */ + +/* PR tree-optimization/67797 */ + +/* We should not get a tail call here since the + types don't match and we don't know how the argument + truncation will work. */ + +unsigned char my_func(int n) +{ + __builtin_memset((void*)0, 0, n); + return 0; +} + +/* { dg-final { scan-tree-dump-not "Found tail call" "tailc"} } */ |