From dd787b0c00f8c10239b08685826946433fc40f22 Mon Sep 17 00:00:00 2001 From: Rainer Orth Date: Tue, 14 May 2013 13:11:25 +0000 Subject: [PATCH] Use __builtin_alloca in gcc.dg/fstack-protector-strong.c * gcc.dg/fstack-protector-strong.c: Don't include . (alloca): Remove declaration. (foo9): Replace alloca by __builtin_alloca. From-SVN: r198883 --- gcc/testsuite/ChangeLog | 6 ++++++ gcc/testsuite/gcc.dg/fstack-protector-strong.c | 5 +---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 410739b13f9..966280ad9c2 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2013-05-14 Rainer Orth + + * gcc.dg/fstack-protector-strong.c: Don't include . + (alloca): Remove declaration. + (foo9): Replace alloca by __builtin_alloca. + 2013-05-14 Joern Rennecke * testsuite/gcc.c-torture/compile/limits-externdecl.c [target avr-*-*]: diff --git a/gcc/testsuite/gcc.dg/fstack-protector-strong.c b/gcc/testsuite/gcc.dg/fstack-protector-strong.c index 6d5dd0f8c4b..7c232fff243 100644 --- a/gcc/testsuite/gcc.dg/fstack-protector-strong.c +++ b/gcc/testsuite/gcc.dg/fstack-protector-strong.c @@ -4,9 +4,6 @@ /* { dg-options "-O2 -fstack-protector-strong" } */ #include -#include - -extern void *alloca(__SIZE_TYPE__); extern int g0; extern int* pg0; @@ -112,7 +109,7 @@ foo8 () int foo9 () { - char* p = alloca (100); + char* p = __builtin_alloca (100); return goo ((int *)(p + 50)); } -- 2.30.2