This is the mail archive of the
mailing list for the GCC project.
r242208 - in /branches/ARM/sve-branch/gcc: doc/...
- From: rsandifo at gcc dot gnu dot org
- To: gcc-cvs at gcc dot gnu dot org
- Date: Fri, 11 Nov 2016 17:19:03 -0000
- Subject: r242208 - in /branches/ARM/sve-branch/gcc: doc/...
Date: Fri Nov 11 17:19:01 2016
New Revision: 242208
Let the target choose a vectorisation alignment
The vectoriser previously aligned vectors to TYPE_ALIGN
unconditionally, although there was also a hard-coded
assumption that this was equal to the type size. This was
inconvenient for SVE for two reasons:
- When compiling for a specific power-of-2 SVE vector length,
we generally want to align to a full vector. However, the
TYPE_ALIGN is governed by the ABI alignment, which is 16 bytes
regardless of size.
- For vector-length-agnostic code it doesn't make sense to try
to align, since the runtime vector length might not be a
power of two. Even for power of two sizes, there's no
guarantee that aligning to the previous 16 bytes will be
This patch therefore adds a target hook to control the preferred
vectoriser (as opposed to ABI) alignment.