diff options
author | Andreas Schwab <schwab@linux-m68k.org> | 2018-08-12 11:03:36 +0200 |
---|---|---|
committer | Andreas Schwab <schwab@linux-m68k.org> | 2018-08-12 11:12:27 +0200 |
commit | 3d0a0ca7ca58cdb8f07be63df28ad30e4367167d (patch) | |
tree | dc694b1eea3a83f134c5dddc0f079c3bdf6d58ad /src | |
parent | 3fc948a36c0f70f73d2e8eb688b1599fa6b73036 (diff) | |
download | emacs-3d0a0ca7ca58cdb8f07be63df28ad30e4367167d.tar.gz emacs-3d0a0ca7ca58cdb8f07be63df28ad30e4367167d.tar.bz2 emacs-3d0a0ca7ca58cdb8f07be63df28ad30e4367167d.zip |
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.
Diffstat (limited to 'src')
-rw-r--r-- | src/lisp.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/lisp.h b/src/lisp.h index dcc157e0b96..96256386218 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -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; |