From: Eli Zaretskii Date: Thu, 25 Sep 2014 17:49:02 +0000 (+0300) Subject: Don't use USE_STACK_LISP_OBJECTS on Windows with GCC older than 4.2. X-Git-Tag: emacs-25.0.90~2635^2~679^2~220 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=686b21966f812707e1d1c614ddd63d1d24fbdf18;p=emacs.git Don't use USE_STACK_LISP_OBJECTS on Windows with GCC older than 4.2. src/lisp.h (USE_STACK_LISP_OBJECTS): Default to false for 32-bit MinGW builds that use GCC before 4.2. Fixes: debbugs:18559 --- diff --git a/src/ChangeLog b/src/ChangeLog index 9c360e64de0..87d33121495 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,8 @@ 2014-09-25 Eli Zaretskii + * lisp.h (USE_STACK_LISP_OBJECTS): Default to false for 32-bit + MinGW builds that use GCC before 4.2. + Default to stack objects on DOS_NT platforms as well. * w32term.h (ALIGN_STACK) [__GNUC__]: Define to __attribute__((force_align_arg_pointer)) for GCC 4.2 and later. diff --git a/src/lisp.h b/src/lisp.h index 82a99fcca34..b1f793c7282 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -286,7 +286,13 @@ error !; http://lists.gnu.org/archive/html/emacs-devel/2014-09/msg00506.html. */ #ifndef USE_STACK_LISP_OBJECTS # if defined __GNUC__ && !defined __clang__ -# define USE_STACK_LISP_OBJECTS true + /* 32-bit MinGW builds need at least GCC 4.2 to support this. */ +# if defined __MINGW32__ && !defined _W64 \ + && __GNUC__ + (__GNUC_MINOR__ > 1) < 5 +# define USE_STACK_LISP_OBJECTS false +# else /* !(__MINGW32__ && __GNUC__ < 4.2) */ +# define USE_STACK_LISP_OBJECTS true +# endif # else # define USE_STACK_LISP_OBJECTS false # endif