clang-cl: Better error message when trying to compile stdin (PR18640)

We should suggest using /Tc or /Tp to set the input type, instead of
erroneously suggesting -x, which isn't a clang-cl flag.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200362 91177308-0d34-0410-b5e6-96231b3b80d8
Extensively comment bitfield layout, rearrange some
code for legibility, and fix a bug with bitfields in packed
ms_structs.

rdar://15926990

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200379 91177308-0d34-0410-b5e6-96231b3b80d8
Short-circuit a couple of queries (and avoid corrupting
the linkage cache) when type-checking static local
variables.

There's a very deep problem here where the linkage of
a declaration can suddenly massively change as soon as
it's given a typedef name; these fixes, while optimizations
in their own right, are really just targeted workarounds.

rdar://15928125

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200380 91177308-0d34-0410-b5e6-96231b3b80d8
Fix crash on unmatched #endif's.

The following snippet would crash:
  #endif
  #if A

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200381 91177308-0d34-0410-b5e6-96231b3b80d8
Cortex-M3 and Cortex-M4 should not enable hwdiv-arm (committing again, with an updated test)

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200385 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: Fix formatting of custom proto options.

Before:
  repeated double value = 1 [(aaaaaaa.aaaaaaaaa) = {
                              aaaaaaaaaaaaaaaaa : AAAAAAAA
                            }];

After:
  repeated double value = 1
      [(aaaaaaa.aaaaaaaaa) = {aaaaaaaaaaaaaaaaa : AAAAAAAA}];

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200405 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: More custom option fixes for protocol buffer files.

Before:
  repeated double value = 1 [(aaaaaaa.aaaaaaaaa) = {
                               aaaaaaaaaaaaaaaa : AAAAAAAAAA,
                               bbbbbbbbbbbbbbbb : BBBBBBBBBB
                             }];

After:
  repeated double value = 1
      [(aaaaaaa.aaaaaaaaa) = {aaaaaaaaaaaaaaaa : AAAAAAAAAA,
                              bbbbbbbbbbbbbbbb : BBBBBBBBBB}];

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200406 91177308-0d34-0410-b5e6-96231b3b80d8
Sema: Diagnose improper application of inheritance keywords

We would previously allow inappropriate inheritance keywords to appear
on class declarations.  We would also allow inheritance keywords on
templates which were not fully specialized; this was divergent from
MSVC.

Differential Revision: http://llvm-reviews.chandlerc.com/D2585


git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200423 91177308-0d34-0410-b5e6-96231b3b80d8
Consolidating several table-generated files containing parser-related string switches into a single file. This reduces build-related complexity by replacing four separate projects (and table-gen instantiations) with a single one.

No functional changes intended.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200424 91177308-0d34-0410-b5e6-96231b3b80d8
Objective-C [IRGen]. Generator a tail call to objc_getProperty() in 
synthesized getters for performance improvement. 
// rdar://15884113


git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200430 91177308-0d34-0410-b5e6-96231b3b80d8
Use an Itanium triple in DWARF debug info tests

This should fix the clang part of the breakage in r200340.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200435 91177308-0d34-0410-b5e6-96231b3b80d8
Actually test that the local static variable from my
test in r200380 gets linkonce_odr linkage.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200437 91177308-0d34-0410-b5e6-96231b3b80d8
Diagnose typedef names for linkage purposes that would change
a previously-computed linkage as an unsupportable error condition.

Per discussion on cfe-commits, this appears to be a
difficult-to-resolve flaw in our implementation approach;
we may pursue this as a language defect, but for now it's
better to diagnose it as unsupported than to produce
inconsistent results (or assertions).  Anything that we can
do to limit how often this diagnostic fires, such as the
changes in r200380, is probably for the best, though.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200438 91177308-0d34-0410-b5e6-96231b3b80d8
SPARCv9 supports atomic operations up to 64 bits.

Patch by Roman Divacky!

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200452 91177308-0d34-0410-b5e6-96231b3b80d8
Update debugging visualizers section.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200460 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: Support ObjC's NS_ENUMs.

Before:
  typedef NS_ENUM(NSInteger, MyType) {
      /// Information about someDecentlyLongValue.
      someDecentlyLongValue,
      /// Information about anotherDecentlyLongValue.
      anotherDecentlyLongValue,
      /// Information about aThirdDecentlyLongValue.
      aThirdDecentlyLongValue};

After:
  typedef NS_ENUM(NSInteger, MyType) {
    /// Information about someDecentlyLongValue.
    someDecentlyLongValue,
    /// Information about anotherDecentlyLongValue.
    anotherDecentlyLongValue,
    /// Information about aThirdDecentlyLongValue.
    aThirdDecentlyLongValue
  };

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200469 91177308-0d34-0410-b5e6-96231b3b80d8
ARM & AArch64: share the BI__builtin_neon enum defs.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200470 91177308-0d34-0410-b5e6-96231b3b80d8
ARM & AArch64: fully share NEON implementation of permutation intrinsics

As a starting point, this moves the CodeGen for NEON permutation
instructions (vtrn, vzip, vuzp) into a new shared function.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200471 91177308-0d34-0410-b5e6-96231b3b80d8
ARM & AArch64: extend shared NEON implementation to first block.

This extends the refactoring to the whole of the first block of
trivial correspondences (as a fairly arbitrary boundary).

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200472 91177308-0d34-0410-b5e6-96231b3b80d8
Fix assertion failures on annot_* tokens in clang -E

In particular, #pragma clang __debug, and #include implicitly changed
into @import were causing assertion failures.

git-svn-id: http://llvm.org/svn/llvm-project/cfe/trunk@200475 91177308-0d34-0410-b5e6-96231b3b80d8