Commit 8881986b authored by Paul Eggert's avatar Paul Eggert
Browse files

* lisp.h (USE_STACK_STRING): Now true only if USE_STACK CONS.

On x86 platforms this works around GCC bug 63495
<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63495>,
and more generally should fix a portability problem in Emacs.
Problem reported by Stefan Monnier in:
http://lists.gnu.org/archive/html/emacs-devel/2014-10/msg00261.html
parent 32ade3f0
2014-10-09 Paul Eggert <eggert@cs.ucla.edu>
* lisp.h (USE_STACK_STRING): Now true only if USE_STACK CONS.
On x86 platforms this works around GCC bug 63495
<https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63495>,
and more generally should fix a portability problem in Emacs.
Problem reported by Stefan Monnier in:
http://lists.gnu.org/archive/html/emacs-devel/2014-10/msg00261.html
2014-10-08 Leo Liu <sdl.web@gmail.com>
 
Enhance terpri to allow conditionally output a newline. (Bug#18652)
......
......@@ -4615,13 +4615,16 @@ union Aligned_String
double d; intmax_t i; void *p;
};
/* True for stack-based cons and string implementations. */
/* True for stack-based cons and string implementations, respectively.
Use stack-based strings only if stack-based cons also works.
Otherwise, STACK_CONS would create heap-based cons cells that
could point to stack-based strings, which is a no-no. */
enum
{
USE_STACK_CONS = (USE_STACK_LISP_OBJECTS
&& alignof (union Aligned_Cons) % GCALIGNMENT == 0),
USE_STACK_STRING = (USE_STACK_LISP_OBJECTS
USE_STACK_STRING = (USE_STACK_CONS
&& alignof (union Aligned_String) % GCALIGNMENT == 0)
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment