view gcc/testsuite/gcc.dg/Walloca-14.c @ 145:1830386684a0

gcc-9.2.0
author anatofuz
date Thu, 13 Feb 2020 11:34:05 +0900
parents 04ced10e8804
children
line wrap: on
line source

/* PR tree-optimization/80109 */
/* { dg-do compile } */
/* { dg-require-effective-target alloca } */
/* { dg-skip-if "small address space" { "pdp11-*-*" } } */
/* { dg-options "-O2 -Walloca-larger-than=126812070" } */

void
g (int *p)
{
  extern void f (void *);

  void *q = __builtin_alloca (p); /* { dg-warning "passing argument 1" } */
  /* { dg-warning "unbounded use of 'alloca'" "unbounded" { target *-*-* } .-1 } */
  f (q);
}