]> granicus.if.org Git - clang/commit
[ms-abi] Change the way alignment is tracked
authorWarren Hunt <whunt@google.com>
Sat, 11 Jan 2014 01:16:40 +0000 (01:16 +0000)
committerWarren Hunt <whunt@google.com>
Sat, 11 Jan 2014 01:16:40 +0000 (01:16 +0000)
commitc3a5420a77b7b578f07cfbd8054612f45aa0c939
tree95cc10a99cab8425236156067e0fea670521e870
parent740314b86568cfaedf95425002bcfaf86dbdd3f8
[ms-abi] Change the way alignment is tracked

This patch more cleanly seperates the concepts of Preferred Alignment
and Required Alignment.  Most notable that changes to Required Alignment
do *not* impact preferred alignment until late in struct layout.  This
is observable when using pragma pack and non-virtual bases and the use
of tail padding when laying them out.

Test cases included.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@198988 91177308-0d34-0410-b5e6-96231b3b80d8
lib/AST/RecordLayoutBuilder.cpp
test/Layout/ms-x86-pack-and-align.cpp