]> granicus.if.org Git - clang/log
clang
9 years agoclang-format: [ObjC] Make IndentWrappedFunctionNames work with ObjC functions
Daniel Jasper [Wed, 13 May 2015 09:38:25 +0000 (09:38 +0000)]
clang-format: [ObjC] Make IndentWrappedFunctionNames work with ObjC functions

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

9 years agoclang-format: Prefer formatting local lambdas like functions.
Daniel Jasper [Wed, 13 May 2015 08:47:16 +0000 (08:47 +0000)]
clang-format: Prefer formatting local lambdas like functions.

Before:
  auto my_lambda =
      [](const string &some_parameter) { return some_parameter.size(); };

After:
  auto my_lambda = [](const string &some_parameter) {
    return some_parameter.size();
  };

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

9 years agoclang-format: Support column layout with comment after {.
Daniel Jasper [Wed, 13 May 2015 08:16:00 +0000 (08:16 +0000)]
clang-format: Support column layout with comment after {.

Before:
  vector<int> iiiiiiiiiiiiiii = {                      //
      11111111112222222222333333333334444444444, //
      1111111112222222223333333333444444444,     //
      111111112222222233333333344444444};

After:
  vector<int> iiiiiiiiiiiiiii = {                      //
      11111111112222222222333333333334444444444, //
      111111111,  222222222,  3333333333,  444444444,  //
      11111111,   22222222,   333333333,   44444444};

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

9 years agoHave '__have_extension(cxx_variadic_templates)' return true for any C++ standard.
Eric Fiselier [Tue, 12 May 2015 22:37:23 +0000 (22:37 +0000)]
Have '__have_extension(cxx_variadic_templates)' return true for any C++ standard.

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

9 years agoAdd missing #includes, found by modules build.
Richard Smith [Tue, 12 May 2015 21:48:00 +0000 (21:48 +0000)]
Add missing #includes, found by modules build.

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

9 years agoAdd a new error for unexpected semi-colon before closing delimiter.
Richard Trieu [Tue, 12 May 2015 21:36:35 +0000 (21:36 +0000)]
Add a new error for unexpected semi-colon before closing delimiter.

Previously, if a semi-colon is unexpectedly added before a closing ')', ']' or
'}', two errors and one note would emitted, and the parsing would get confused
to which scope it was in.  This change consumes the semi-colon, recovers
parsing better, and emits only one error with a fix-it.

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

9 years agoInstrProf: Update name of compiler-rt routine for setting filename
Justin Bogner [Tue, 12 May 2015 21:23:16 +0000 (21:23 +0000)]
InstrProf: Update name of compiler-rt routine for setting filename

Patch by Teresa Johnson.

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

9 years agoclang-format AllocateTarget. NFC
Douglas Katzman [Tue, 12 May 2015 21:18:10 +0000 (21:18 +0000)]
clang-format AllocateTarget. NFC

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

9 years agoList Alexey Bataev as code owner for Clang's OpenMP support, as discussed offline.
Richard Smith [Tue, 12 May 2015 20:29:41 +0000 (20:29 +0000)]
List Alexey Bataev as code owner for Clang's OpenMP support, as discussed offline.

Thanks for all your hard work getting us OpenMP feature-complete, Alexey!

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

9 years agoFixed double-free in case of module loading error.
Artem Belevich [Tue, 12 May 2015 17:44:15 +0000 (17:44 +0000)]
Fixed double-free in case of module loading error.

GetOutputStream() owns the stream it returns pointer to and the
pointer should never be freed by us. When we fail to load and exit
early, unique_ptr still holds the pointer and frees it which leads to
compiler crash when CompilerInstance attempts to free it again.

Added regression test for failed bitcode linking.

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

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

9 years agoChanged renaming of local symbols by inserting a dot vefore the numeric suffix
Sunil Srivastava [Tue, 12 May 2015 16:48:43 +0000 (16:48 +0000)]
Changed renaming of local symbols by inserting a dot vefore the numeric suffix
details in http://reviews.llvm.org/D9483
goes with llvm checkin r237150

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

9 years agoFix clang-format build from the solution; the underlying path has changed to include...
Manuel Klimek [Tue, 12 May 2015 14:41:39 +0000 (14:41 +0000)]
Fix clang-format build from the solution; the underlying path has changed to include the VS directory structure.

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

9 years agoRemove superfluous SmallString cast.
Yaron Keren [Tue, 12 May 2015 12:47:05 +0000 (12:47 +0000)]
Remove superfluous SmallString cast.

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

9 years agoFix misleading parameter name for PPCallbacks::FileSkipped.
Nikola Smiljanic [Tue, 12 May 2015 11:48:05 +0000 (11:48 +0000)]
Fix misleading parameter name for PPCallbacks::FileSkipped.

Patch thanks to Vladimir Voskresensky.

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

9 years agoclang-format: Make member introduced in r237108 const.
Daniel Jasper [Tue, 12 May 2015 11:14:06 +0000 (11:14 +0000)]
clang-format: Make member introduced in r237108 const.

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

9 years agoChange TargetParser enum names to avoid macro conflicts (clang)
Renato Golin [Tue, 12 May 2015 10:34:10 +0000 (10:34 +0000)]
Change TargetParser enum names to avoid macro conflicts (clang)

sys/time.h on Solaris (and possibly other systems) defines "SEC" as "1"
using a cpp macro.  The result is that this fails to compile.

Fixes https://llvm.org/PR23482

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

9 years agoclang-format: Fix */& detection for lambdas in macros.
Daniel Jasper [Tue, 12 May 2015 10:20:32 +0000 (10:20 +0000)]
clang-format: Fix */& detection for lambdas in macros.

Before:
  #define MACRO() [](A * a) { return 1; }

After:
  #define MACRO() [](A *a) { return 1; }

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

9 years agoclang-format: Fix hanging nested blocks in macros.
Daniel Jasper [Tue, 12 May 2015 10:16:02 +0000 (10:16 +0000)]
clang-format: Fix hanging nested blocks in macros.

Before:
  #define MACRO()                     \
    Debug(aaa, /* force line break */ \
          {                           \
      int i;                          \
      int j;                          \
          })

After:
  #define MACRO()                     \
    Debug(aaa, /* force line break */ \
          {                           \
            int i;                    \
            int j;                    \
          })

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

9 years agoRefactor clang-format's formatter.
Manuel Klimek [Tue, 12 May 2015 09:23:57 +0000 (09:23 +0000)]
Refactor clang-format's formatter.

Summary:
a) Pull out a class LevelIndentTracker whose responsibility is to keep track
   of the indent of levels across multiple annotated lines.
b) Put all responsibility for merging lines into the LineJoiner; make the
   LineJoiner iterate over the lines so we never operate on a line that might
   be merged later; this makes the interface safer to use.
c) Move formatting of the end-of-file whitespace into formatFirstToken.

Fix bugs that became obvious after the refactoring:
1. We would not format lines with offsets correctly inside nested blocks if
   only the outer expression was affected:
   int x = s({ // clang-format only this line
     class X {
       public:
    // ^ this starts at the non-modified indnent level; previously we would
    //   not fix this, now we correctly outdent it.
       void f();
     };
   });
2. We would incorrectly align comments across lines that do not have comments
   for lines with nested blocks:
   int expression; // with comment
   int x = s({
     int y; // comment
     int z; // we would incorrectly align this comment with the comment on
            // 'expression'
   });

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

9 years ago[OPENMP] Allow using of threadprivate variables as loop-control variables in lop...
Alexey Bataev [Tue, 12 May 2015 09:02:07 +0000 (09:02 +0000)]
[OPENMP] Allow using of threadprivate variables as loop-control variables in lop based directives.

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

9 years ago[OPENMP] Fixed support for 'schedule' clause with non-constant chunk size.
Alexey Bataev [Tue, 12 May 2015 08:35:28 +0000 (08:35 +0000)]
[OPENMP] Fixed support for 'schedule' clause with non-constant chunk size.

'schedule' clause for combined directives requires additional processing. Special helper variable is generated, that is captured in the outlined parallel region for 'parallel for' region. This captured variable is used to store chunk expression from the 'schedule' clause in this 'parallel for' region.

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

9 years agoDriver: Fix a -Wshadow issue from r237091
Justin Bogner [Tue, 12 May 2015 06:30:48 +0000 (06:30 +0000)]
Driver: Fix a -Wshadow issue from r237091

The MachO toolchain has an isTargetIOSBased method, but it isn't
virtual so it isn't very meaningful to call it. After thinking about
this, I guess that putting this logic in the MachO class is a bit of a
layering violation anyway. Do this more like how we handle
AddLinkRuntimeLibArgs instead.

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

9 years agoRe-apply "Driver: Make profiling flags work with -nostdlib on Darwin"
Justin Bogner [Tue, 12 May 2015 05:44:36 +0000 (05:44 +0000)]
Re-apply "Driver: Make profiling flags work with -nostdlib on Darwin"

This time without a stray "true" in an argument list.

This reverts r237077, restoring r237074.

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

9 years agorevert r237081 -- bad idea (-lcrypt may not be present)
Kostya Serebryany [Tue, 12 May 2015 03:10:42 +0000 (03:10 +0000)]
revert r237081 -- bad idea (-lcrypt may not be present)

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

9 years agoadd -lcrypto to clang and clang-format fuzzers (lib/Fuzzer will soon require it)
Kostya Serebryany [Tue, 12 May 2015 01:29:04 +0000 (01:29 +0000)]
add -lcrypto to clang and clang-format fuzzers (lib/Fuzzer will soon require it)

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

9 years agoRemove the code that pulled soft float attributes out of the feature
Eric Christopher [Tue, 12 May 2015 01:26:21 +0000 (01:26 +0000)]
Remove the code that pulled soft float attributes out of the feature
strings and remove the setting of TargetOptions::UseSoftFloat to
match the code change in llvm r237079.

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

9 years agoRevert "Driver: Make profiling flags work with -nostdlib on Darwin"
Justin Bogner [Tue, 12 May 2015 01:04:33 +0000 (01:04 +0000)]
Revert "Driver: Make profiling flags work with -nostdlib on Darwin"

This revert r237074. These tests are failing all over the place.

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

9 years agoDriver: Make profiling flags work with -nostdlib on Darwin
Justin Bogner [Tue, 12 May 2015 00:31:33 +0000 (00:31 +0000)]
Driver: Make profiling flags work with -nostdlib on Darwin

Compiler-rt's Profiling library isn't part of the stdlib, so -nostdlib
shouldn't prevent it from being linked. This makes Darwin behave like
other toolchains, and link in the profile runtime irrespective of
-nostdlib, since the resulting program can't be run unless you link
this.

I've also added a test to show that other toolchains already behave
like this.

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

9 years agoAllow empty assembly string literal with -fno-gnu-inline-asm
Steven Wu [Tue, 12 May 2015 00:16:37 +0000 (00:16 +0000)]
Allow empty assembly string literal with -fno-gnu-inline-asm

Empty assembly string will not introduce assembly code in the output
binary and it is often used as a trick in the header to disable
optimizations. It doesn't conflict with the purpose of the option so it
is allowed with -fno-gnu-inline-asm flag.

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

9 years agoUpdate initialization of a class variable and comment.
Eric Christopher [Tue, 12 May 2015 00:04:20 +0000 (00:04 +0000)]
Update initialization of a class variable and comment.

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

9 years agoTypo fix: s/initialzier/initializer/ in a doc comment.
James Dennett [Mon, 11 May 2015 23:25:54 +0000 (23:25 +0000)]
Typo fix: s/initialzier/initializer/ in a doc comment.

No functional change.

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

9 years agoPR20625: Instantiate static constexpr member function of a local struct in a function...
Richard Smith [Mon, 11 May 2015 23:09:06 +0000 (23:09 +0000)]
PR20625: Instantiate static constexpr member function of a local struct in a function template earlier.

This is necessary in order to allow the use of a constexpr member function, or
a member function with deduced return type, of a local class within a
surrounding instantiated function template specialization.

Patch by Michael Park!

This re-commits r236063, which was reverted in r236134, along with a fix for a
delayed template parsing bug that was exposed by this change.

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

9 years agoMove sanitizer parser and group expander from Driver to Basic.
Peter Collingbourne [Mon, 11 May 2015 21:39:20 +0000 (21:39 +0000)]
Move sanitizer parser and group expander from Driver to Basic.

No functional change.

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

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

9 years agoUnify sanitizer kind representation between the driver and the rest of the compiler.
Peter Collingbourne [Mon, 11 May 2015 21:39:14 +0000 (21:39 +0000)]
Unify sanitizer kind representation between the driver and the rest of the compiler.

No functional change.

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

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

9 years agoAllow AsmLabel with -fno-gnu-inline-asm
Steven Wu [Mon, 11 May 2015 21:14:09 +0000 (21:14 +0000)]
Allow AsmLabel with -fno-gnu-inline-asm

Summary:
AsmLabel is heavily used in system level and firmware to redirect
function and access platform specific labels. They are also extensively
used in system headers which makes this option unusable for many
users. Since AsmLabel doesn't introduce any assembly code into the
output binary, it shouldn't be considered as inline-asm.

Reviewers: bob.wilson, rnk

Reviewed By: rnk

Subscribers: cfe-commits

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

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

9 years ago[cuda] Fixed test case failure on s390x
Artem Belevich [Mon, 11 May 2015 18:35:58 +0000 (18:35 +0000)]
[cuda] Fixed test case failure on s390x

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

9 years agoRevert "Allow -target= and --target options"
Richard Barton [Mon, 11 May 2015 17:05:05 +0000 (17:05 +0000)]
Revert "Allow -target= and --target options"

After mailing list discussion on 11-13 March we would prefer to stick to a
single spelling of the long option.

This reverts commit 30035fe1a7c759c89ee62eb46efce6b3790fcc08.

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

9 years ago[Sparc] Add support for 'sparcel' to clang.
Douglas Katzman [Mon, 11 May 2015 15:21:44 +0000 (15:21 +0000)]
[Sparc] Add support for 'sparcel' to clang.

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

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

9 years agoclang-format: Support aligning ObjC string literals.
Daniel Jasper [Mon, 11 May 2015 15:15:48 +0000 (15:15 +0000)]
clang-format: Support aligning ObjC string literals.

Before:
  NSString s = @"aaaa"
      @"bbbb";

After:
  NSString s = @"aaaa"
               @"bbbb";

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

9 years agoDisable __has_cpp_attribute when not compiling in C++ mode. As this feature test...
Aaron Ballman [Mon, 11 May 2015 14:09:50 +0000 (14:09 +0000)]
Disable __has_cpp_attribute when not compiling in C++ mode. As this feature test macro only supports C++ style attributes, it doesn't apply to code compiled as C code, and can lead to diagnostics when given a scoped attribute.

This addresses PR23435.

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

9 years agoclang-format: Appease the buildbots by including climits.
Daniel Jasper [Mon, 11 May 2015 13:52:13 +0000 (13:52 +0000)]
clang-format: Appease the buildbots by including climits.

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

9 years agoclang-format: Improve column layout.
Daniel Jasper [Mon, 11 May 2015 13:35:40 +0000 (13:35 +0000)]
clang-format: Improve column layout.

Specifically, calculate the deviation between the shortest and longest
element (which is used to prevent excessive whitespace) per column, not
overall. This automatically handles the corner cases of a single column
and a single row so that the actualy implementation becomes simpler.

Before:
  vector<int> x = {1,
                   aaaaaaaaaaaaaaaaaaaaaa,
                   2,
                   bbbbbbbbbbbbbbbbbbbbbb,
                   3,
                   cccccccccccccccccccccc};

After:
  vector<int> x = {1, aaaaaaaaaaaaaaaaaaaaaa,
                   2, bbbbbbbbbbbbbbbbbbbbbb,
                   3, cccccccccccccccccccccc};

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

9 years agoclang-format: Don't merge subsequent lines into _asm blocks.
Daniel Jasper [Mon, 11 May 2015 11:59:46 +0000 (11:59 +0000)]
clang-format: Don't merge subsequent lines into _asm blocks.

Before:
  _asm {
  } int i;

After:
  _asm {
  }
  int i;

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

9 years agoclang-format: [JS] Clean up export declaration parsing.
Daniel Jasper [Mon, 11 May 2015 09:14:50 +0000 (09:14 +0000)]
clang-format: [JS] Clean up export declaration parsing.

NFC intended.

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

9 years agoAVX-512: Changed CC parameter in "cmp" intrinsic
Elena Demikhovsky [Mon, 11 May 2015 09:03:41 +0000 (09:03 +0000)]
AVX-512: Changed CC parameter in "cmp" intrinsic
from i8 to i32 according to the Intel Spec

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

9 years agoclang-format: [JS] Parse exported functions as free-standing.
Daniel Jasper [Mon, 11 May 2015 09:03:10 +0000 (09:03 +0000)]
clang-format: [JS] Parse exported functions as free-standing.

Before:
  export function foo() {} export function bar() {}

After:
  export function foo() {
  }
  export function bar() {
  }

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

9 years agoRefactor MacroInfo so range for loops can be used to iterate its tokens.
Daniel Marjamaki [Mon, 11 May 2015 08:25:54 +0000 (08:25 +0000)]
Refactor MacroInfo so range for loops can be used to iterate its tokens.

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

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

9 years agoRefactor the formatter of clang-format.
Manuel Klimek [Mon, 11 May 2015 08:21:35 +0000 (08:21 +0000)]
Refactor the formatter of clang-format.

Pull various parts of the UnwrappedLineFormatter into their own
abstractions. NFC.

There are two things left for subsequent changes (to keep this
reasonably small)
- the UnwrappedLineFormatter now has a bad name
- the UnwrappedLineFormatter::format function is still too large

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

9 years agoGive isCompatibleWithMSVC a better interface
David Majnemer [Mon, 11 May 2015 03:57:49 +0000 (03:57 +0000)]
Give isCompatibleWithMSVC a better interface

We now use an enum which maps the marketing name (almost always a year)
to the major version number.

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

9 years ago[MS ABI] Import move assignment operators
David Majnemer [Mon, 11 May 2015 03:00:22 +0000 (03:00 +0000)]
[MS ABI] Import move assignment operators

MSVC 2015 changed behavior from 2013; it imports move assignment
operators.

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

9 years agoFix indentation problem introduced in r236964. NFC
Jonathan Roelofs [Mon, 11 May 2015 02:13:24 +0000 (02:13 +0000)]
Fix indentation problem introduced in r236964. NFC

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

9 years agoFix formatting of a few code blocks. NFC
Jonathan Roelofs [Mon, 11 May 2015 02:05:20 +0000 (02:05 +0000)]
Fix formatting of a few code blocks. NFC

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

9 years ago[MS ABI] Form member pointers from virtual funcs overriding vbases
David Majnemer [Sun, 10 May 2015 21:48:08 +0000 (21:48 +0000)]
[MS ABI] Form member pointers from virtual funcs overriding vbases

We didn't supporting taking the address of virtual member functions
which overrode a method in a virtual base.  We simply need to encode the
virtual base index in the member pointer.

This fixes PR23452.

N.B.  There is no data member pointer side to this change because taking
the address of a virtual bases' data member gives you a member pointer
whose type is derived from the virtual bases' type, not the most derived
type.

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

9 years ago[MS ABI] Update EH emission for MSVC 2015 compatibility
David Majnemer [Sun, 10 May 2015 21:38:26 +0000 (21:38 +0000)]
[MS ABI] Update EH emission for MSVC 2015 compatibility

MSVC 2015 renamed the symbol found by name lookup for 'std::terminate'
so we cannot rely on using '?terminate@@YAXXZ'.  Furthermore, it seems
that 2015 will be the first release of MSVC which permits inlining a
function which is noexcept into a function which isn't.  This is
implemented by creating a cleanup for the invoker which jumps to
__std_terminate.  Clang's implementation of this aspect of the MSVC
scheme is slightly less efficient in this respect because we use a
catch handler configured as a catch-all handler instead.

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

9 years agoclang-format: Improve wrapping of << operators.
Daniel Jasper [Sun, 10 May 2015 21:15:07 +0000 (21:15 +0000)]
clang-format: Improve wrapping of << operators.

Before:
  llvm::errs() << aaaaaaaaaaaaaaaaaaaaaaaaaaaaa(
                     aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
                      aaaaaaaaaaaaaaaa) << aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;

After:
  llvm::errs() << aaaaaaaaaaaaaaaaaaaaaaaaaaaaa(
                      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
                      aaaaaaaaaaaaaaaa)
               << aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;

Also, cleanup and simplify the operator wrapping logic.

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

9 years agoDe-virtualize some const versions of getCanonicalDecl by redirecting to the non-const...
Craig Topper [Sun, 10 May 2015 18:40:12 +0000 (18:40 +0000)]
De-virtualize some const versions of getCanonicalDecl by redirecting to the non-const version. Most of the Decl hierarchy already did it this way this just makes the rest consistent.

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

9 years agoclang-format: Preserve line break before } in __asm { ... }.
Daniel Jasper [Sun, 10 May 2015 08:42:04 +0000 (08:42 +0000)]
clang-format: Preserve line break before } in __asm { ... }.

Some compilers ignore everything after a semicolon in such inline asm
blocks and thus, the closing brace must not be moved to the previous
line.

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

9 years agoclang-format: Fix bug in escaped newline calculation.
Daniel Jasper [Sun, 10 May 2015 08:00:25 +0000 (08:00 +0000)]
clang-format: Fix bug in escaped newline calculation.

This prevents clang-format from inadvertently joining stuff into macro
definitions as reported in llvm.org/PR23466.

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

9 years agoReapply r236854 and fixed r236867.
Daniel Jasper [Sun, 10 May 2015 07:47:19 +0000 (07:47 +0000)]
Reapply r236854 and fixed r236867.

Makes emacs show a different message when clang-format encountered a
syntax error.

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

9 years agoPrune trailing LF.
NAKAMURA Takumi [Sat, 9 May 2015 21:10:13 +0000 (21:10 +0000)]
Prune trailing LF.

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

9 years agoRevert r236879, "Do not emit thunks with available_externally linkage in comdats"
NAKAMURA Takumi [Sat, 9 May 2015 21:10:07 +0000 (21:10 +0000)]
Revert r236879, "Do not emit thunks with available_externally linkage in comdats"

It broke pecoff, at least i686-cygwin.

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

9 years agoFactor out Hexagon code to build args.
Ikhlas Ajbar [Sat, 9 May 2015 02:13:25 +0000 (02:13 +0000)]
Factor out Hexagon code to build args.

This patch factor out the code in hexagon::Link::ConstructJob to be reused
in other functions. No functionality change intended.

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

9 years agoRevert "Make emacs show when clang-format encountered a syntax error."
Tobias Grosser [Fri, 8 May 2015 21:34:09 +0000 (21:34 +0000)]
Revert "Make emacs show when clang-format encountered a syntax error."

This reverts commit 236854, which caused clang-format to always print
'{ "IncompleteFormat": false }' at the top of an incompletely formatted file.
This output causes problems e.g. in Polly's automatic formatting checks. Daniel
tried to fix this in 236867, but this fix had to be reverted due to buildbot
failures. I revert this change as well for now as it is Friday night and
unlikely to be fixed immediately.

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

9 years agoUsing ARMTargetParser in Clang
Renato Golin [Fri, 8 May 2015 21:04:50 +0000 (21:04 +0000)]
Using ARMTargetParser in Clang

This is a starting point for using the TargetParser in Clang, in a simple
enough part of the code that can be used without disrupting the crazy
platform support that we need to be compatible with other toolchains.

Also adding a few FIXME on obvious places that need replacing, but those
cases will indeed break a few of the platform assumptions, as arch/cpu names
change multiple times in the driver.

Finally, I'm changing the "neon-vfpv3" behaviour to match standard NEON, since
-mfpu=neon implies vfpv3 by default in both Clang and LLVM. That option
string is still supported as an alias to "neon".

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

9 years agoFix BackendConsumer::EmitOptimizationMessage()
Diego Novillo [Fri, 8 May 2015 20:59:56 +0000 (20:59 +0000)]
Fix BackendConsumer::EmitOptimizationMessage()

Patch from Geoff Berry <gberry@codeaurora.org>

Fix BackendConsumer::EmitOptimizationMessage() to check if the
DiagnosticInfoOptimizationBase object has a valid location before
calling getLocation() to avoid dereferencing a null pointer inside
getLocation() when no debug info is present.

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

9 years agoAdd the test case from PR 14044 to ensure it doesn't regress.
Kaelyn Takata [Fri, 8 May 2015 17:39:48 +0000 (17:39 +0000)]
Add the test case from PR 14044 to ensure it doesn't regress.

The test started working at some point, presumably fixed through the
delayed typo correction work.

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

9 years agoRevert "clang-format: Only output IncompleteFormat if -cursor is given."
Renato Golin [Fri, 8 May 2015 17:05:24 +0000 (17:05 +0000)]
Revert "clang-format: Only output IncompleteFormat if -cursor is given."

This reverts commit r236867, as it was breaking multiple buildbots. Daniel
will look into it later.

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

9 years agoDo not emit thunks with available_externally linkage in comdats
Derek Schuff [Fri, 8 May 2015 16:47:21 +0000 (16:47 +0000)]
Do not emit thunks with available_externally linkage in comdats

Functions with available_externally linkage will not be emitted to object
files (they will just be undefined symbols), so it does not make sense to
put them in comdats.

Creates a second overload of maybeSetTrivialComdat that uses the GlobalObject
instead of the Decl, and uses that in several places that had the faulty
logic.

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

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

9 years agoRevert "Allow case-insensitive values for -mcpu for ARM and AArch64"
Renato Golin [Fri, 8 May 2015 15:44:36 +0000 (15:44 +0000)]
Revert "Allow case-insensitive values for -mcpu for ARM and AArch64"

This reverts commit r236859, as it broke multiple builds. I'll investigate
and reapply when safe.

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

9 years agoclang-format: Only output IncompleteFormat if -cursor is given.
Daniel Jasper [Fri, 8 May 2015 15:36:30 +0000 (15:36 +0000)]
clang-format: Only output IncompleteFormat if -cursor is given.

This is only for editor integrations.

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

9 years agoAllow case-insensitive values for -mcpu for ARM and AArch64
Renato Golin [Fri, 8 May 2015 14:50:32 +0000 (14:50 +0000)]
Allow case-insensitive values for -mcpu for ARM and AArch64

GCC allows case-insensitive values for -mcpu, -march and -mtune options.
This patch implements the same behaviour for the -mcpu option.

Patch by Gabor Ballabas.

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

9 years agoMake emacs show when clang-format encountered a syntax error.
Manuel Klimek [Fri, 8 May 2015 13:59:15 +0000 (13:59 +0000)]
Make emacs show when clang-format encountered a syntax error.

Propagate the 'incomplete-format' state back through clang-format's command
line interace and adapt the emacs integration to show a better result.

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

9 years agoclang-format: Several improvements around formatting braced lists.
Daniel Jasper [Fri, 8 May 2015 13:51:14 +0000 (13:51 +0000)]
clang-format: Several improvements around formatting braced lists.

In particular:
* If the difference between the longest and shortest element, we copped
  out of column format completely. Now, we instead allow to arrange
  these in a single column, essentially enforcing a one-per-line format.
* Allow column layout even if there are braced lists. Especially, if
  there are many short lists, this can be beneficial. The bad case,
  where there is a long nested init list is usually caught as we now
  limit the length difference of the longest and shortest element.

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

9 years agoFix for bug 23429.
Nemanja Ivanovic [Fri, 8 May 2015 13:07:48 +0000 (13:07 +0000)]
Fix for bug 23429.

The macros for gcc atomic compare and swaps are defined for Power8 CPU's since
the functionality is provided in the back end.

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

9 years ago[ARM] Give an error on invalid -march values
John Brawn [Fri, 8 May 2015 12:52:18 +0000 (12:52 +0000)]
[ARM] Give an error on invalid -march values

llvm::Triple::getARMCPUForArch now returns nullptr for invalid -march
values, instead of silently translating it to arm7tdmi. Use this to
give an error message, which is consistent with how gcc behaves.

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

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

9 years ago[OPENMP] Fixed atomic construct with non-integer expressions.
Alexey Bataev [Fri, 8 May 2015 11:47:16 +0000 (11:47 +0000)]
[OPENMP] Fixed atomic construct with non-integer expressions.
Do not emit 'atomicrmw' instruction for simple atomic constructs with non-integer expressions.

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

9 years ago[OPENMP] Code cleanup for capturing of variables in OpenMP regions.
Alexey Bataev [Fri, 8 May 2015 10:41:21 +0000 (10:41 +0000)]
[OPENMP] Code cleanup for capturing of variables in OpenMP regions.

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

9 years agoclang-format: [JS] Avoid bad line-warp around "function".
Daniel Jasper [Fri, 8 May 2015 08:38:52 +0000 (08:38 +0000)]
clang-format: [JS] Avoid bad line-warp around "function".

Before:
  someLooooooooongFunction(
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa, function(
                                              aaaaaaaaaaaaaaaaaaaaaaaaaaaaa) {
        // code
      });

After:
  someLooooooooongFunction(
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
      function(aaaaaaaaaaaaaaaaaaaaaaaaaaaaa) {
        // code
      });

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

9 years agoclang-format: [JS] Fix regex literal detection.
Daniel Jasper [Fri, 8 May 2015 07:55:13 +0000 (07:55 +0000)]
clang-format: [JS] Fix regex literal detection.

Before:
  var regex = /= / ;

After:
  var regex = /=/;

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

9 years agoRevert "Fix path separator issue on Windows."
Nikola Smiljanic [Fri, 8 May 2015 06:02:37 +0000 (06:02 +0000)]
Revert "Fix path separator issue on Windows."

This reverts commit 9242ff16b0460b488691fd70b42a2bf81a531e3a.

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

9 years agoFix path separator issue on Windows.
Nikola Smiljanic [Fri, 8 May 2015 03:26:15 +0000 (03:26 +0000)]
Fix path separator issue on Windows.

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

9 years agoUpdate docs for SanitizerCoverage.
Alexey Samsonov [Thu, 7 May 2015 23:04:19 +0000 (23:04 +0000)]
Update docs for SanitizerCoverage.

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

9 years ago[SanitizerCoverage] Implement user-friendly -fsanitize-coverage= flags.
Alexey Samsonov [Thu, 7 May 2015 22:34:06 +0000 (22:34 +0000)]
[SanitizerCoverage] Implement user-friendly -fsanitize-coverage= flags.

Summary:
Possible coverage levels are:
  * -fsanitize-coverage=func - function-level coverage
  * -fsanitize-coverage=bb - basic-block-level coverage
  * -fsanitize-coverage=edge - edge-level coverage

Extra features are:
  * -fsanitize-coverage=indirect-calls - coverage for indirect calls
  * -fsanitize-coverage=trace-bb - tracing for basic blocks
  * -fsanitize-coverage=trace-cmp - tracing for cmp instructions
  * -fsanitize-coverage=8bit-counters - frequency counters

Levels and features can be combined in comma-separated list, and
can be disabled by subsequent -fno-sanitize-coverage= flags, e.g.:
  -fsanitize-coverage=bb,trace-bb,8bit-counters -fno-sanitize-coverage=trace-bb
is equivalient to:
  -fsanitize-coverage=bb,8bit-counters

Original semantics of -fsanitize-coverage flag is preserved:
  * -fsanitize-coverage=0 disables the coverage
  * -fsanitize-coverage=1 is a synonym for -fsanitize-coverage=func
  * -fsanitize-coverage=2 is a synonym for -fsanitize-coverage=bb
  * -fsanitize-coverage=3 is a synonym for -fsanitize-coverage=edge
  * -fsanitize-coverage=4 is a synonym for -fsanitize-coverage=edge,indirect-calls

Driver tries to diagnose invalid flag usage, in particular:
  * At most one level (func,bb,edge) must be specified.
  * "trace-bb" and "8bit-counters" features require some level to be specified.

See test case for more examples.

Test Plan: regression test suite

Reviewers: kcc

Subscribers: cfe-commits

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

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

9 years ago[MS ABI] Make sure we number thread_local statics seperately
David Majnemer [Thu, 7 May 2015 21:19:06 +0000 (21:19 +0000)]
[MS ABI] Make sure we number thread_local statics seperately

The thread_local variables need their own numbers, they can't share with
the other static local variables.

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

9 years agoFixed test failure on machines with 32-bit size_t.
Artem Belevich [Thu, 7 May 2015 21:06:03 +0000 (21:06 +0000)]
Fixed test failure on machines with 32-bit size_t.

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

9 years ago[cuda] Include GPU binary into host object file and generate init/deinit code.
Artem Belevich [Thu, 7 May 2015 19:34:16 +0000 (19:34 +0000)]
[cuda] Include GPU binary into host object file and generate init/deinit code.

- added -fcuda-include-gpubinary option to incorporate results of
  device-side compilation into host-side one.
- generate code to register GPU binaries and associated kernels
  with CUDA runtime and clean-up on exit.
- added test case for init/deinit code generation.

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

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

9 years agoReplace the broken LambdaCapture::isInitCapture API.
James Dennett [Thu, 7 May 2015 18:48:18 +0000 (18:48 +0000)]
Replace the broken LambdaCapture::isInitCapture API.

A LambdaCapture does not have sufficient information
to correctly determine whether it is an init-capture or not.
Doing so requires knowledge held in the LambdaExpr itself.

It the case of a nested capture of an init-capture it is not
sufficient to check (as LambdaCapture::isInitCapture did)
whether the associated VarDecl was from an init-capture.

This patch moves isInitCapture to LambdaExpr and updates
Capture->isInitCapture() to Lambda->isInitCapture(Capture).

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

9 years ago[SanitizerCoverage] Give clang-cc1 the power to precisly specify needed sanitizier...
Alexey Samsonov [Thu, 7 May 2015 18:31:29 +0000 (18:31 +0000)]
[SanitizerCoverage] Give clang-cc1 the power to precisly specify needed sanitizier coverage mode.

Summary:
The next step is to add user-friendly control over these options
to driver via -fsanitize-coverage= option.

Test Plan: regression test suite

Reviewers: kcc

Subscribers: cfe-commits

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

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

9 years ago[opaque pointer type] Correctly pass the pointee type when creating a GEP constant...
David Blaikie [Thu, 7 May 2015 17:27:56 +0000 (17:27 +0000)]
[opaque pointer type] Correctly pass the pointee type when creating a GEP constant expression

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

9 years agoUpdate the subversion link to http://subversion.apache.org/packages.html.
Yaron Keren [Thu, 7 May 2015 15:15:16 +0000 (15:15 +0000)]
Update the subversion link to http://subversion.apache.org/packages.html.

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

9 years agoFix clang getting started guide to require VC2013 instead of VS2012.
Yaron Keren [Thu, 7 May 2015 15:12:30 +0000 (15:12 +0000)]
Fix clang getting started guide to require VC2013 instead of VS2012.

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

9 years agoAdding new AST matcher: gnuNullExpr
Szabolcs Sipos [Thu, 7 May 2015 14:24:22 +0000 (14:24 +0000)]
Adding new AST matcher: gnuNullExpr

It matches GNU __null expression.

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

9 years agoclang-format: Improve r236597, Properly indent method calls without inputs.
Daniel Jasper [Thu, 7 May 2015 14:19:59 +0000 (14:19 +0000)]
clang-format: Improve r236597, Properly indent method calls without inputs.

Before:
  [aaaaaaaaaaaa(aaaaaa)
          aaaaaaaaaaaaaaaaaaaa];

After:
  [aaaaaaaaaaaa(aaaaaa)
      aaaaaaaaaaaaaaaaaaaa];

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

9 years agoImplements a way to retrieve information about whether some lines were not formatted...
Manuel Klimek [Thu, 7 May 2015 12:26:30 +0000 (12:26 +0000)]
Implements a way to retrieve information about whether some lines were not formatted due to syntax errors.

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

9 years agoAVX-512: FP compare intrinsics - changed type of CC parameter from i8 to i32 accordin...
Elena Demikhovsky [Thu, 7 May 2015 11:26:36 +0000 (11:26 +0000)]
AVX-512: FP compare intrinsics - changed type of CC parameter from i8 to i32 according to the spec.
Added FP compare intrinsics for SKX.

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

9 years agoMark clang/test/CodeGenCXX/microsoft-abi-thread-safe-statics.cpp as REQUIRES:asserts...
NAKAMURA Takumi [Thu, 7 May 2015 10:11:27 +0000 (10:11 +0000)]
Mark clang/test/CodeGenCXX/microsoft-abi-thread-safe-statics.cpp as REQUIRES:asserts. It relies on label names.

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

9 years agoFix some glitches in the MSVCCompatibility document
David Majnemer [Thu, 7 May 2015 07:48:16 +0000 (07:48 +0000)]
Fix some glitches in the MSVCCompatibility document

- Fix the formatting of the "Exceptions and SEH" section.
- Make the "Complete" text for "Thread-safe initialization of local
  statics" green.

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

9 years agoFix for http://llvm.org/PR23392: magick/feature.c from ImageMagick-6.9.1-2 ICEs.
Alexey Bataev [Thu, 7 May 2015 06:28:46 +0000 (06:28 +0000)]
Fix for http://llvm.org/PR23392: magick/feature.c from ImageMagick-6.9.1-2 ICEs.
Fix for codegen of static variables declared inside of captured statements. Captured statements are actually a transparent DeclContexts, so we have to skip them when trying to get a mangled name for statics.
Differential Revision: http://reviews.llvm.org/D9522

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

9 years agoNote that we support 'throw' for the MS ABI.
David Majnemer [Thu, 7 May 2015 06:16:03 +0000 (06:16 +0000)]
Note that we support 'throw' for the MS ABI.

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

9 years ago[MS ABI] Implement thread-safe initialization using the MSVC 2015 ABI
David Majnemer [Thu, 7 May 2015 06:15:46 +0000 (06:15 +0000)]
[MS ABI] Implement thread-safe initialization using the MSVC 2015 ABI

The MSVC 2015 ABI utilizes a rather straightforward adaptation of the
algorithm found in the appendix of N2382.  While we are here, implement
support for emitting cleanups if an exception is thrown while we are
intitializing a static local variable.

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