[cfe-commits] [PATCH] Set UseZeroLengthBitfieldAlignment for AAPCS

James Molloy james.molloy at arm.com
Fri Mar 9 02:07:04 PST 2012


Hi,

The attached patch sets the UseZeroLengthBitfieldAlignment flag when in
AAPCS mode on ARM. It is currently only enabled in APCS-GNU mode, but the
AAPCS 7.1.7 says : "The container type contributes to the alignment of the
containing aggregate in the same way a plain (not bit-field) member of that
type would, without exception for zero-sized or anonymous bit-fields."

As part of this and adding a regression test, I noticed that bitfield
alignment isn't really checked in AAPCS (it is slightly different to
APCS-GNU), so instead of creating a tiny new regression test I copied the
one for apcs-gnu and made it work for aapcs. That is why in the attached svn
diff, it looks like a modification of a file. It's not, I just svn cp'd
before modifying.

It's rather simple, is it OK to commit?

Cheers,

James
-------------- next part --------------
A non-text attachment was scrubbed...
Name: zerolength_bitfields_aapcs.diff
Type: application/octet-stream
Size: 5416 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120309/5443129d/attachment.obj>


More information about the cfe-commits mailing list