summaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGRecordLayoutBuilder.cpp
Commit message (Collapse)AuthorAge
* Baby steps towards fixing PR5589. If a class needs a vtable pointer, add one.Anders Carlsson2009-12-16
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91545 91177308-0d34-0410-b5e6-96231b3b80d8
* No need to add tail padding if the resulting LLVM struct type will have the ↵Anders Carlsson2009-12-08
| | | | | | same size as the final record size. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90820 91177308-0d34-0410-b5e6-96231b3b80d8
* Have ASTRecordLayout keep track of the key function, in preparation of ↵Anders Carlsson2009-11-30
| | | | | | fixing a synthetic ctor/dtor bug. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90168 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixup key function calculations.Mike Stump2009-11-20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89412 91177308-0d34-0410-b5e6-96231b3b80d8
* This doesn't work yet.Mike Stump2009-11-19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89307 91177308-0d34-0410-b5e6-96231b3b80d8
* Prevent a code gen. crash on empty unions - pr5408.Fariborz Jahanian2009-11-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86287 91177308-0d34-0410-b5e6-96231b3b80d8
* Store the key function of a record decl inside CGRecordLayout.Anders Carlsson2009-10-12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83900 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove tabs, and whitespace cleanups.Mike Stump2009-09-09
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81346 91177308-0d34-0410-b5e6-96231b3b80d8
* If the alignment of the chosen field in a union is greater than the ↵Anders Carlsson2009-09-03
| | | | | | alignment of the union, we need to use a packed LLVM struct. Fixes <rdar://problem/7184250>. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80964 91177308-0d34-0410-b5e6-96231b3b80d8
* Packed unions should be packed. Fixes an assert Daniel reported.Anders Carlsson2009-09-02
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80808 91177308-0d34-0410-b5e6-96231b3b80d8
* More work towards zero-initializing structs that contain member pointers in ↵Anders Carlsson2009-08-23
| | | | | | constant expressions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@79805 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove the PaddingFields member from CGRecordLayout, it wasn't used anyway.Anders Carlsson2009-08-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@79799 91177308-0d34-0410-b5e6-96231b3b80d8
* Update for LLVM API change.Owen Anderson2009-08-13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78946 91177308-0d34-0410-b5e6-96231b3b80d8
* Take #pragma pack into account when laying out structs. Fixes ↵Anders Carlsson2009-08-08
| | | | | | rdar://problem/7095436. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78490 91177308-0d34-0410-b5e6-96231b3b80d8
* Introduce a new PragmaPack attribute, and use it for #pragma pack. The ↵Anders Carlsson2009-08-08
| | | | | | | | | PackedAttr now only represents __attribute__((packed)). This is necessary because #pragma pack and __attribute__((packed)) have different semantics. No functionality change yet, but this lays the groundwork for fixing a record layout bug. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78483 91177308-0d34-0410-b5e6-96231b3b80d8
* Assert that the LLVM type has the same size as the RecordDecl size.Anders Carlsson2009-08-08
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78481 91177308-0d34-0410-b5e6-96231b3b80d8
* Update for LLVM API change.Owen Anderson2009-08-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78259 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify alignment handling in the record builder.Anders Carlsson2009-08-04
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78069 91177308-0d34-0410-b5e6-96231b3b80d8
* No longer need to keep base class offsets in the offsetFariborz Jahanian2009-07-29
| | | | | | | table as it has its own place now. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@77491 91177308-0d34-0410-b5e6-96231b3b80d8
* More CGRecordLayoutBuilder cleanup.Anders Carlsson2009-07-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@77335 91177308-0d34-0410-b5e6-96231b3b80d8
* Some minor changes toward support of dataFariborz Jahanian2009-07-27
| | | | | | | member access in the presense of non-virtual bases. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@77246 91177308-0d34-0410-b5e6-96231b3b80d8
* Enable the new struct type builder now that the constant struct builder ↵Anders Carlsson2009-07-27
| | | | | | works. (The old code will still be there until we know that everything works well. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@77190 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a tail padding bug in the record layout builder code. The bug was found ↵Anders Carlsson2009-07-27
| | | | | | by an existing test. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@77189 91177308-0d34-0410-b5e6-96231b3b80d8
* Check in a half finished new constant struct builder (Obviously not used yet).Anders Carlsson2009-07-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76969 91177308-0d34-0410-b5e6-96231b3b80d8
* Get rid of the size parameter to AppendField. No functionality change.Anders Carlsson2009-07-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76931 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't just store the field/bit field info one field, do it for all fields in ↵Anders Carlsson2009-07-23
| | | | | | the union. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76907 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix another thinko.Anders Carlsson2009-07-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76903 91177308-0d34-0410-b5e6-96231b3b80d8
* Correct a thinko in bitfield layout code. Fixes PR4611.Anders Carlsson2009-07-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76898 91177308-0d34-0410-b5e6-96231b3b80d8
* We don't need to keep track of the packed alignment, just whether the struct ↵Anders Carlsson2009-07-23
| | | | | | is packed or not. Fixes PR4610. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76884 91177308-0d34-0410-b5e6-96231b3b80d8
* Move the LLVM field number for bit fields into the BitFieldInfo structure, ↵Anders Carlsson2009-07-23
| | | | | | since it's meaning is completely different than for non-bit fields. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76882 91177308-0d34-0410-b5e6-96231b3b80d8
* Set field info for unions.Anders Carlsson2009-07-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76856 91177308-0d34-0410-b5e6-96231b3b80d8
* Handle zero width bit fields in unions correctly (by ignoring them).Anders Carlsson2009-07-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76847 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement union layout support.Anders Carlsson2009-07-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76846 91177308-0d34-0410-b5e6-96231b3b80d8
* Check in CGRecordLayoutBuilder which is a reimplementation of the record ↵Anders Carlsson2009-07-23
layout code. (Yay, no more packed structs unless absolutely necessary). We currently don't use the layouts being built but that will change when the new code is mature enough :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@76845 91177308-0d34-0410-b5e6-96231b3b80d8