mirror of
git://git.sv.gnu.org/emacs.git
synced 2026-02-05 23:21:22 -08:00
Avoid padding after union vectorlike_header
The PSEUDOVECTORSIZE macro requires that the first member after union vectorlike_header has the same offset in all pseudo vector structures. * src/lisp.h (GCALIGNMENT) [!USE_LSB_TAG]: Use alignment of Lisp_Object.
This commit is contained in:
parent
3fc948a36c
commit
3d0a0ca7ca
1 changed files with 5 additions and 3 deletions
|
|
@ -276,15 +276,17 @@ error !;
|
|||
|
||||
/* Minimum alignment requirement for Lisp objects, imposed by the
|
||||
internal representation of tagged pointers. It is 2**GCTYPEBITS if
|
||||
USE_LSB_TAG, 1 otherwise. It must be a literal integer constant,
|
||||
for older versions of GCC (through at least 4.9). */
|
||||
USE_LSB_TAG, otherwise the alignment of Lisp_Object to avoid
|
||||
padding after union vectorlike_header. It must be a literal
|
||||
integer constant, for older versions of GCC (through at least
|
||||
4.9). */
|
||||
#if USE_LSB_TAG
|
||||
# define GCALIGNMENT 8
|
||||
# if GCALIGNMENT != 1 << GCTYPEBITS
|
||||
# error "GCALIGNMENT and GCTYPEBITS are inconsistent"
|
||||
# endif
|
||||
#else
|
||||
# define GCALIGNMENT 1
|
||||
# define GCALIGNMENT alignof (Lisp_Object)
|
||||
#endif
|
||||
|
||||
#define GCALIGNED_UNION char alignas (GCALIGNMENT) gcaligned;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue