diff options
author | DJ Delorie <dj@redhat.com> | 2001-03-06 18:26:32 +0000 |
---|---|---|
committer | DJ Delorie <dj@redhat.com> | 2001-03-06 18:26:32 +0000 |
commit | 25ee9ae28513c5cee6ade2c1cdc12984c8639491 (patch) | |
tree | 448c00162154ec1d0f3d8454bbcc0f252cbe27c4 /include/libiberty.h | |
parent | bf11a54f54d43142f3b05258239a1964bf4693cc (diff) | |
download | cygnal-25ee9ae28513c5cee6ade2c1cdc12984c8639491.tar.gz cygnal-25ee9ae28513c5cee6ade2c1cdc12984c8639491.tar.bz2 cygnal-25ee9ae28513c5cee6ade2c1cdc12984c8639491.zip |
merge from gcc
Diffstat (limited to 'include/libiberty.h')
-rw-r--r-- | include/libiberty.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/include/libiberty.h b/include/libiberty.h index 64d072be3..e4fc2af20 100644 --- a/include/libiberty.h +++ b/include/libiberty.h @@ -206,6 +206,20 @@ extern int vasprintf PARAMS ((char **, const char *, va_list)) #define ARRAY_SIZE(a) (sizeof (a) / sizeof ((a)[0])) +/* Drastically simplified alloca configurator. If we're using GCC, + we use __builtin_alloca; otherwise we use the C alloca. The C + alloca is always available. You can override GCC by defining + USE_C_ALLOCA yourself. */ +extern PTR C_alloca PARAMS((size_t)); +#undef alloca +#if GCC_VERSION >= 2000 && !defined USE_C_ALLOCA +# define alloca(x) __builtin_alloca(x) +#else +# define alloca(x) C_alloca(x) +# undef USE_C_ALLOCA +# define USE_C_ALLOCA 1 +#endif + #ifdef __cplusplus } #endif |