PR tree-optimization/33562
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / pr23848-2.c
blob7b5be75bf8342cfabd349396709a166cb522703f
1 /* PR middle-end/23848 */
2 /* { dg-do compile } */
3 /* { dg-options "-O2 -fdump-tree-optimized" } */
4 /* { dg-require-effective-target alloca } */
6 void bar (char *, char *, char *, char *, int);
7 void foo (int size)
9 char temp[size];
10 temp[size-1] = '\0';
12 char temp2[size];
14 char temp3[size];
16 char temp4[size];
17 bar (temp, temp2, temp3, temp4, size);
20 bar (temp, temp2, (char *) 0, (char *) 0, size);
24 /* { dg-final { scan-tree-dump-times "__builtin_stack_save" 1 "optimized"} } */
25 /* { dg-final { scan-tree-dump-times "__builtin_stack_restore" 1 "optimized"} } */