Commit Graph

12 Commits

Author SHA1 Message Date
David Majnemer b58ea25263 Update test to account for r276604
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@276607 91177308-0d34-0410-b5e6-96231b3b80d8
2016-07-25 04:47:45 +00:00
Peter Collingbourne 6f43cc7050 Update clang for D20348
Differential Revision: http://reviews.llvm.org/D20339

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@272710 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-14 21:02:05 +00:00
Philip Reames bfeebd81de Adjust clang side tests effected by 239795 before reapplying said change
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@239848 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-16 20:24:06 +00:00
David Blaikie a6eaa6b50b Test case updates for explicit type parameter to the gep operator
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@232187 91177308-0d34-0410-b5e6-96231b3b80d8
2015-03-13 18:21:46 +00:00
David Majnemer 8fbf839d6c Sema: Permit an atomic type to be initialized by the same atomic type
We forgot a conversion step when initializing an atomic type with an
rvalue of the same type.

This fixes PR22043.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@224902 91177308-0d34-0410-b5e6-96231b3b80d8
2014-12-28 21:47:31 +00:00
David Majnemer 05db1e2826 CodeGen: ConstStructBuilder must verify packed constraints after padding
This reverts commit r220169 which reverted r220153.  However, it also
contains additional changes:
- We may need to add padding *after* we've packed the struct.  This
  occurs when the aligned next field offset is greater than the new
  field's offset.  When this occurs, we make the struct packed.
  *However*, once packed the next field offset might be less than the
  new feild's offset.  It is in this case that we might further pad the
  struct.
- We would pad structs which were perfectly sized!  This behavior is
  immensely old.  This behavior came from blindly subtracting
  NextFieldOffsetInChars from RecordSize.  This doesn't take into
  account the fact that the struct might have a greater overall
  alignment than the last field.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@220175 91177308-0d34-0410-b5e6-96231b3b80d8
2014-10-19 23:40:06 +00:00
Richard Smith 3a5597cce3 PR18097: Support initializing an _Atomic(T) from an object of C++ class type T
or a class derived from T. We already supported this when initializing
_Atomic(T) from T for most (and maybe all) other reasonable values of T.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@214390 91177308-0d34-0410-b5e6-96231b3b80d8
2014-07-31 06:31:19 +00:00
Stephen Lin 93ab6bf534 CHECK-LABEL-ify some code gen tests to improve diagnostic experience when tests fail.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188447 91177308-0d34-0410-b5e6-96231b3b80d8
2013-08-15 06:47:53 +00:00
Douglas Gregor 47bfcca2d6 Fix some i1/i8 confusion within _Atomic(bool) in IR generation, both
in general (such an atomic has boolean representation) and
specifically for IR generation of __c11_atomic_init. The latter also
means actually using initialization semantics for this initialization,
rather than just creating a store.

On a related note, make sure we actually put in non-atomic-to-atomic
conversions when performing an implicit conversion sequence. IR
generation is far too kind here, but we still want the ASTs to make
sense.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154612 91177308-0d34-0410-b5e6-96231b3b80d8
2012-04-12 20:42:30 +00:00
Richard Smith 944b5623c3 Update recently-added test to use new __c11_ form of atomic builtins.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154514 91177308-0d34-0410-b5e6-96231b3b80d8
2012-04-11 18:00:46 +00:00
David Chisnall 5d70cfddc8 Make __atomic_init() (soon to be __c11_atomic_init()) work with non-scalar types.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154507 91177308-0d34-0410-b5e6-96231b3b80d8
2012-04-11 17:24:05 +00:00
David Chisnall 3a3c9b26de Allow c++ initialisers to initialise _Atomic fields.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154499 91177308-0d34-0410-b5e6-96231b3b80d8
2012-04-11 15:29:15 +00:00