[PATCH] Microsoft Record Layout Required Alignment
whunt at google.com
Wed Nov 27 15:26:52 PST 2013
Hi majnemer, rsmith, rnk,
Support MS-ABI's concept of "Required Alignment" imposed by __declspec(align())
This patch implements required alignment in a way that makes __declspec(align()) and #pragma pack play correctly together. In the MS-ABI, __declspec(align()) is a hard rule and cannot be overridden by #pragma pack. This cases each record to have two interesting alignments "preferred alignment" (which matches Itanium's concept of alignment) and "required alignment" which is an alignment that must never be violated, even in the case of #pragma pack. This patch introduces the concept of Required Alignment to the record builder and tracks/uses it appropriately. Test cases are included.
This patch should address the following bugs:
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 15717 bytes
Desc: not available
More information about the cfe-commits