Commit Graph

14 Commits

Author SHA1 Message Date
Warren Hunt 30577e6c4f Fixed an assertion failure related to bitfield lowering.
When lowering a bitfield, CGRecordLowering would assign the wrong 
storage type to a bitfield in some cases and trigger an assertion.  In 
these cases the layout was still correct, just the bitfield info was 
wrong.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202562 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-01 00:38:40 +00:00
Ken Dyck f079b735d8 Retry r126357. Use CharUnits for the Size and DataSize calculations when
they are known to be exact multiples of the width of the char type. Add a
test case to CodeGen/union.c that would have caught the problem with the
previous attempt. No change in functionality intended.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126628 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-28 02:01:38 +00:00
Anders Carlsson 21fd7d7347 Fix an incorrect union layout assert. Fixes PR6164.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@94754 91177308-0d34-0410-b5e6-96231b3b80d8
2010-01-28 18:22:03 +00:00
Daniel Dunbar a5728872c7 Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.
- This is designed to make it obvious that %clang_cc1 is a "test variable"
   which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it
   can be useful to redefine what gets run as 'clang -cc1' (for example, to set
   a default target).

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91446 91177308-0d34-0410-b5e6-96231b3b80d8
2009-12-15 20:14:24 +00:00
Daniel Dunbar d7d5f0223b Rename clang to clang-cc.
Tests and drivers updated, still need to shuffle dirs.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67602 91177308-0d34-0410-b5e6-96231b3b80d8
2009-03-24 02:24:46 +00:00
Chris Lattner c8e9cd6e32 eliminate some random .ll file outputs
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63117 91177308-0d34-0410-b5e6-96231b3b80d8
2009-01-27 18:56:08 +00:00
Anders Carlsson 663388f2ea Fix invalid bit-field.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@60627 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-06 20:32:39 +00:00
Daniel Dunbar 2d6ca8d0f6 Update a number of CodeGen tests to not create .ll files in the test
directory.
 - Removed .ll from the svn:ignore lists to try and prevent this.
 - Added svn:ignore on test/Misc/Output


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55104 91177308-0d34-0410-b5e6-96231b3b80d8
2008-08-21 02:51:29 +00:00
Eli Friedman 1e86b34f15 Rearrange EmitLValueForField a bit to work properly for _Bool bitfields
in unions (we don't want to do the union-specific bitcast for 
bit-fields).



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51678 91177308-0d34-0410-b5e6-96231b3b80d8
2008-05-29 11:33:25 +00:00
Eli Friedman 0ac5957479 A small testcase; no patch, since it was a bug in a patch I never
committed.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51370 91177308-0d34-0410-b5e6-96231b3b80d8
2008-05-21 13:21:01 +00:00
Devang Patel 5cada6bd7f Begin handling union bitfields.
Note, this is just beginning.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@50835 91177308-0d34-0410-b5e6-96231b3b80d8
2008-05-07 22:28:29 +00:00
Devang Patel fe2419aac4 Match union field type when member expression is u->x
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44879 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-11 21:33:16 +00:00
Seo Sanghyeon 2de3b3a4ac Fix isStructureType and isUnionType to ignore typedefs, as stated
in the header. Patch by Cédric Venet.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44519 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-02 16:57:27 +00:00
Devang Patel abad06cfd0 Codegen union member references.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@43390 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-26 19:42:18 +00:00