1 /* { dg-require-effective-target alloca } */ 2 3 /* This program tests a data flow bug that would cause constant propagation 4 to propagate constants through function calls. */ 5 foo(int * p)6foo (int *p) 7 { 8 *p = 10; 9 } 10 main()11main() 12 { 13 int *ptr = alloca (sizeof (int)); 14 *ptr = 5; 15 foo (ptr); 16 if (*ptr == 5) 17 abort (); 18 exit (0); 19 } 20