This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix PR middle-end/28862, losing user alignment for vectors


On Wed, 2006-09-06 at 20:24 -0700, Andrew Pinski wrote:
> ChangeLog:
> 
> 	* stor-layout.c (relayout_decl): Don't zero the alignment if it
> 	was set by the user.

I was thinking about a portable way to test this does not happen again
but all I could think of was looking at the asm but now I just
remembered about the alignof expressions.  Here is a testcase which
passes now but failed before the patch:
float x __attribute__((aligned(128),vector_size(8)));
int f[__alignof__(x) == 128?1:-1];

Thanks,
Andrew Pinski


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]