diff options
author | H.J. Lu <hongjiu.lu@intel.com> | 2014-12-17 14:22:57 +0000 |
---|---|---|
committer | H.J. Lu <hjl@gcc.gnu.org> | 2014-12-17 06:22:57 -0800 |
commit | 239711f6afe3070a11c4f1d9266588e8db1217ee (patch) | |
tree | 5ed4b6970db156cc051eed382941098982ed6791 /gcc/doc/invoke.texi | |
parent | 52c691fbfb8c78220816b0f72d8d7af71d2b5261 (diff) | |
download | gcc-239711f6afe3070a11c4f1d9266588e8db1217ee.tar.gz |
Add -malign-data={abi|compat|cachineline}
Add -malign-data={abi|compat,cachineline} to control how GCC aligns
variables. "compat" uses increased alignment value compatible with
GCC 4.8 and earlier, "abi" uses alignment value as specified by the
psABI, and "cacheline" uses increased alignment value to match the
cache line size. "compat" is the default.
gcc/
PR target/61296
* config/i386/i386-opts.h (ix86_align_data): New enum.
* config/i386/i386.c (ix86_data_alignment): Return the ABI
alignment value for -malign-data=abi, the cachine line size
for -malign-data=cachineline and the older GCC compatible
alignment value for for -malign-data=compat.
* config/i386/i386.opt (malign-data=): New.
* doc/invoke.texi: Document -malign-data=.
gcc/testsuite/
PR target/61296
* gcc.target/i386/pr61296-2.c: New.
* gcc.target/i386/pr61296-2.c: Likewise.
* gcc.target/i386/pr61296-3.c: Likewise.
* gcc.target/i386/pr61296-4.c: Likewise.
* gcc.target/i386/pr61296-5.c: Likewise.
* gcc.target/i386/pr61296-6.c: Likewise.
* gcc.target/i386/pr61296-7.c: Likewise.
Co-Authored-By: Jakub Jelinek <jakub@redhat.com>
Co-Authored-By: Uros Bizjak <ubizjak@gmail.com>
From-SVN: r218818
Diffstat (limited to 'gcc/doc/invoke.texi')
-rw-r--r-- | gcc/doc/invoke.texi | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 19422d78cd1..15068da33e4 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -701,7 +701,7 @@ Objective-C and Objective-C++ Dialects}. -m32 -m64 -mx32 -m16 -mlarge-data-threshold=@var{num} @gol -msse2avx -mfentry -mrecord-mcount -mnop-mcount -m8bit-idiv @gol -mavx256-split-unaligned-load -mavx256-split-unaligned-store @gol --mstack-protector-guard=@var{guard}} +-malign-data=@var{type} -mstack-protector-guard=@var{guard}} @emph{i386 and x86-64 Windows Options} @gccoptlist{-mconsole -mcygwin -mno-cygwin -mdll @gol @@ -15682,6 +15682,14 @@ as well as modifying the function calling convention for functions taking @code{long double}. Hence they are not binary-compatible with code compiled without that switch. +@item -malign-data=@var{type} +@opindex malign-data +Control how GCC aligns variables. Supported values for @var{type} are +@samp{compat} uses increased alignment value compatible uses GCC 4.8 +and earlier, @samp{abi} uses alignment value as specified by the +psABI, and @samp{cacheline} uses increased alignment value to match +the cache line size. @samp{compat} is the default. + @item -mlarge-data-threshold=@var{threshold} @opindex mlarge-data-threshold When @option{-mcmodel=medium} is specified, data objects larger than |