1 /* { dg-do compile } */
2 /* { dg-require-effective-target alloca } */
3 /* { dg-options "-Walloca-larger-than=2000 -O2" } */
9 // Warn when there is an alloca bound, but it is an unknown bound.
16 p
= __builtin_alloca (n
); // { dg-warning "may be too large" }
18 p
= __builtin_malloc (n
);
22 // Similar to the above, but do not get confused by the upcast.
24 unsigned short SHORT_LIMIT
;
30 p
= __builtin_alloca (n
); // { dg-warning "may be too large" }
32 p
= __builtin_malloc (n
);