[OPENMP] Fixed test for '#pragma omp parallel' codegen


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208086 91177308-0d34-0410-b5e6-96231b3b80d8
[OPENMP] Another one fix for codegen test '#pragma omp parallel'


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208087 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: [JS] Don't indent in goog.scope blocks.

Before:
  goog.scope(function() {
    var x = a.b;
    var y = c.d;
  });  // goog.scope

After:
  goog.scope(function() {
  var x = a.b;
  var y = c.d;
  });  // goog.scope

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208088 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: [JS] Keep space between 'return' and '['.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208090 91177308-0d34-0410-b5e6-96231b3b80d8
clang-format: [JS] Keep space after closure style comments.

Before:
  var x = /** @type {foo} */ (bar);

After:
  var x = /** @type {foo} */(bar);

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208093 91177308-0d34-0410-b5e6-96231b3b80d8
Update comment for ObjCImplementationDecl's handling of instance variables.

No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208099 91177308-0d34-0410-b5e6-96231b3b80d8
Add driver support for AArch64 Fedora.

Reviewed by Eric Christopher.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208105 91177308-0d34-0410-b5e6-96231b3b80d8
Revert "DebugInfo: Emit the definition of enums when the definition preceeds the declaration and initial use."

This is breaking the compiler-rt build. Reverting while I
investigate/fix.

This reverts commit r208065.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208106 91177308-0d34-0410-b5e6-96231b3b80d8
Fix a leak found by LSan: ConsumedBlockInfo owns its StateMapsArray entries.

(I tried converting StateMapsArray to a vector<unique_ptr> and changing the
types of getInfo() and addInfo() to take unique_ptrs.  This mostly worked,
except for the three-argument form of addInfo() which I found confusing enough
that I went with this simpler fix for now.)


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208108 91177308-0d34-0410-b5e6-96231b3b80d8
Fix leak in ObjCSelfInitChecker, found by LSan.

BugReport doesn't take ownership of the bug type, so let the checker own the
the bug type.  (Requires making the bug type mutable, which is icky, but which
is also what other checkers do.)


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208110 91177308-0d34-0410-b5e6-96231b3b80d8
Reapply: DebugInfo: Emit the definition of enums when the definition preceeds the declaration and initial use.

Reverting r208106 to reapply r208065 with a fix for the regression. The
issue was that the enum tried to be built even if the declaration hadn't
been constructed for debug info - presenting problems for enum templates
and typedefs of enums with names for linkage purposes.

Original commit message:

This regressed a little further 208055 though it was already a little
broken.

While the requiresCompleteType optimization should be implemented here.
Future (possibly near future) work.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208114 91177308-0d34-0410-b5e6-96231b3b80d8
Include translation unit filename in global ctor symbol names.

This makes it easier to see where a global ctor comes from, and it also makes
ASan's init order analyzer output easier to understand.  gcc does this too,
but only in -fPIC mode for some reason.  Don't do this for constructors with
explicit init priority.

Also prepend "sub_" before the 'I', that way regular constructors stay
lexicographically after symbols with init priority (because
ord('s') > ord('I')).  gold seems to ignore the name of constructor symbols,
and ld only looks at the symbol if it includes an init priority, which this
patch doesn't change.

Before: __GLOBAL_I_a
Now: __GLOBAL_sub_I_myfile.cc


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208128 91177308-0d34-0410-b5e6-96231b3b80d8
tblgen: Modularize the diagnostic emitter

Replace a large monolitic function, with per-table functions which all nicely
fit on my screen. I also added documentation to each function that describes
what kind of tables are generated and which information is contained and
switched to range based for loops. Finally, I run clang-format over the moved
code.

I spent a significant amount of time to understand this code when reasoning
about possible extensions to the diagnostic interface to support 'remark'
diagnostics. This change will definitely help such an implementation, but
already by itself it will save other people a lot of time when trying to
understand this functionality.

Even though the patch touches the full function, it is mostly mechanical. No
functional change intended. The generated tblgen files are identical.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208136 91177308-0d34-0410-b5e6-96231b3b80d8
Add testcase for r208062.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208138 91177308-0d34-0410-b5e6-96231b3b80d8
AST: Update reference temporary mangling

Summary:
Update our mangling to match the discussion on cxx-abi-dev.

This involves using a seq-id instead of an optional number.

Reviewers: rsmith

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D3631

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208140 91177308-0d34-0410-b5e6-96231b3b80d8
Rename "secondary initializer" -> "convenience initializer" in the warnings, which is a more correct and consistent term.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208142 91177308-0d34-0410-b5e6-96231b3b80d8
Try harder to ensure a strict weak ordering of overload candidates that
have arity mismatches.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208146 91177308-0d34-0410-b5e6-96231b3b80d8
Clean up some existing keyword tests in the test/Lexer directory by using the
pre-defined __is_identifier() macro.

Differential Revision: http://reviews.llvm.org/D3460



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208147 91177308-0d34-0410-b5e6-96231b3b80d8
If an instantiation of a template is required to be a complete type, check
whether the definition of the template is visible rather than checking whether
the instantiated definition happens to be in an imported module.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208150 91177308-0d34-0410-b5e6-96231b3b80d8
[analyzer] Functions marked __attribute__((const)) don't modify any memory.

This applies to __attribute__((pure)) as well, but 'const' is more interesting
because many of our builtins are marked 'const'.

PR19661

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