diff options
author | Daniel Dunbar <daniel@zuster.org> | 2010-04-22 16:14:54 +0000 |
---|---|---|
committer | Daniel Dunbar <daniel@zuster.org> | 2010-04-22 16:14:54 +0000 |
commit | 684de63867fac4ffe2f4c97756a16bfcb2d8b54b (patch) | |
tree | 4e57d5e58e5cf58ab81372605b8792eaff4b610e /lib/Basic/Targets.cpp | |
parent | 52968a1c765e43000f904ecb27a6353b0185bcd6 (diff) |
ARM/APCS: Don't respect bit-field types when laying out structures.
- This fixes the last known ABI issues with ARM/APCS.
- I've run the first 1k ABITests with '--no-unsigned --no-vector --no-complex'
on {armv6, armv7} x {-mno-thumb, -mthumb}, and the first 10k tests for armv7
-mthumb, for both function return types and single argument calls. These all
pass now (they failed horribly before without --no-bitfield).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102070 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Basic/Targets.cpp')
-rw-r--r-- | lib/Basic/Targets.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Basic/Targets.cpp b/lib/Basic/Targets.cpp index b94f55bdfd..6624ed9d38 100644 --- a/lib/Basic/Targets.cpp +++ b/lib/Basic/Targets.cpp @@ -1418,6 +1418,10 @@ public: DoubleAlign = LongLongAlign = LongDoubleAlign = 32; SizeType = UnsignedLong; + // Do not respect the alignment of bit-field types when laying out + // structures. This corresponds to PCC_BITFIELD_TYPE_MATTERS in gcc. + UseBitFieldTypeAlignment = false; + if (IsThumb) { DescriptionString = ("e-p:32:32:32-i1:8:32-i8:8:32-i16:16:32-i32:32:32-" "i64:32:32-f32:32:32-f64:32:32-" |