]> granicus.if.org Git - clang/log
clang
8 years ago[MS ABI] Allow a member pointers' converted type to change
David Majnemer [Tue, 26 Jan 2016 19:30:26 +0000 (19:30 +0000)]
[MS ABI] Allow a member pointers' converted type to change

Member pointers in the MS ABI are tricky for a variety of reasons.
The size of a member pointer is indeterminate until the program reaches
a point where the representation is required to be known.  However,
*pointers* to member pointers may exist without knowing the pointee
type's representation.  In these cases, we synthesize an opaque LLVM
type for the pointee type.

However, we can be in a situation where the underlying member pointer's
representation became known mid-way through the program.  To account for
this, we attempted to manicure CodeGen's type-cache so that we can
replace the opaque member pointer type with the real deal while leaving
the pointer types unperturbed.  This, unfortunately, is a problematic
approach to take as we will violate CodeGen's invariants.

These violations are mostly harmless but let's do the right thing
instead: invalidate the type-cache if a member pointer's LLVM
representation changes.

This fixes PR26313.

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

8 years agoFix Clang-tidy modernize-use-nullptr warnings; other minor fixes.
Eugene Zelenko [Tue, 26 Jan 2016 19:01:06 +0000 (19:01 +0000)]
Fix Clang-tidy modernize-use-nullptr warnings; other minor fixes.

Differential revision: http://reviews.llvm.org/D16567

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

8 years agoClass Property: parse property attribute (class).
Manman Ren [Tue, 26 Jan 2016 18:52:43 +0000 (18:52 +0000)]
Class Property: parse property attribute (class).

This is the third patch in a series of patches to support class properties
in addition to instance properties in objective-c.

rdar://23891898

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

8 years ago[OpenMP] Parsing + sema for target parallel directive.
Arpith Chacko Jacob [Tue, 26 Jan 2016 18:48:41 +0000 (18:48 +0000)]
[OpenMP] Parsing + sema for target parallel directive.

Summary:
This patch adds parsing + sema for the target parallel directive and its clauses along with testcases.

Reviewers: ABataev

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

Rebased to current trunk and updated test cases.

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

8 years agoUse instance_properties instead of properties. NFC.
Manman Ren [Tue, 26 Jan 2016 18:05:23 +0000 (18:05 +0000)]
Use instance_properties instead of properties. NFC.

All current properties are instance properties.

This is the second patch in a series of patches to support class properties
in addition to instance properties in objective-c.

rdar://23891898

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

8 years ago[CUDA] Add -fcuda-allow-variadic-functions.
Justin Lebar [Tue, 26 Jan 2016 17:47:20 +0000 (17:47 +0000)]
[CUDA] Add -fcuda-allow-variadic-functions.

Summary:
Turns out the variadic function checking added in r258643 was too strict
for some existing users; give them an escape valve.  When
-fcuda-allow-variadic-functions is passed, the front-end makes no
attempt to disallow C-style variadic functions.  Calls to va_arg are
still not allowed.

Reviewers: tra

Subscribers: cfe-commits, jhen, echristo, bkramer

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

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

8 years ago[OpenMP] Parsing + sema for defaultmap clause.
Arpith Chacko Jacob [Tue, 26 Jan 2016 16:37:23 +0000 (16:37 +0000)]
[OpenMP] Parsing + sema for defaultmap clause.

Summary:
This patch adds parsing + sema for the defaultmap clause associated with the target directive (among others).

Reviewers: ABataev

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

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

8 years agoRevert "[Driver] Make sure -fno-math-builtin option is being passed by the driver."
Chad Rosier [Tue, 26 Jan 2016 16:16:53 +0000 (16:16 +0000)]
Revert "[Driver] Make sure -fno-math-builtin option is being passed by the driver."

This reverts commit r258814.

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

8 years ago[Driver] Make sure -fno-math-builtin option is being passed by the driver.
Chad Rosier [Tue, 26 Jan 2016 15:52:05 +0000 (15:52 +0000)]
[Driver] Make sure -fno-math-builtin option is being passed by the driver.

Support for the -fno-math-builtin option was added in r186899.  The codegen side
is being tested in test/CodeGen/nomathbuiltin.c.  The missing part was just
passing the option through the driver.

PR26317

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

8 years ago[Driver] Update FIXME comment now that PR4941 has been addressed.
Chad Rosier [Tue, 26 Jan 2016 15:46:29 +0000 (15:46 +0000)]
[Driver] Update FIXME comment now that PR4941 has been addressed.

The actual fix should be addressed by someone who can test on Darwin.

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

8 years ago[OPENMP 4.5] Allow arrays in 'reduction' clause.
Alexey Bataev [Tue, 26 Jan 2016 12:20:39 +0000 (12:20 +0000)]
[OPENMP 4.5] Allow arrays in 'reduction' clause.
OpenMP 4.5, alogn with array sections, allows to use variables of array type in reductions.

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

8 years agoAMDGPU: Add amdgcn cube builtins
Matt Arsenault [Tue, 26 Jan 2016 06:37:54 +0000 (06:37 +0000)]
AMDGPU: Add amdgcn cube builtins

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

8 years agoRecommit: R258773 [OpenCL] Pipe builtin functions
Xiuli Pan [Tue, 26 Jan 2016 04:03:48 +0000 (04:03 +0000)]
Recommit: R258773 [OpenCL] Pipe builtin functions
Fix arc patch fuzz error.
Summary:
Support for the pipe built-in functions for OpenCL 2.0.
The pipe builtin functions may have infinite kinds of element types, one approach
would be to just generate calls that would always use generic types such as void*.
This patch is based on bader's opencl support patch on SPIR-V branch.

Reviewers: Anastasia, pekka.jaaskelainen

Subscribers: keryell, bader, cfe-commits

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

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

8 years agoFix -Wnull-conversion for long macros.
Richard Trieu [Tue, 26 Jan 2016 02:51:55 +0000 (02:51 +0000)]
Fix -Wnull-conversion for long macros.

Move the function to get a macro name from DiagnosticRenderer.cpp to Lexer.cpp
so that other files can use it.  Lexer now has two functions to get the
immediate macro name, the newly added one is better for diagnostic purposes.
Make -Wnull-conversion use this function for better NULL macro detection.

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

8 years agoRecommit the test for r258720 using -###
Ehsan Akhgari [Tue, 26 Jan 2016 02:23:05 +0000 (02:23 +0000)]
Recommit the test for r258720 using -###

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

8 years agoRevert "[OpenCL] Pipe builtin functions"
David Majnemer [Tue, 26 Jan 2016 02:22:31 +0000 (02:22 +0000)]
Revert "[OpenCL] Pipe builtin functions"

This reverts commit r258773, it broke the build bots:
http://bb.pgr.jp/builders/cmake-clang-x86_64-linux/builds/43853

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

8 years ago[OpenCL] Pipe builtin functions
Xiuli Pan [Tue, 26 Jan 2016 02:06:04 +0000 (02:06 +0000)]
[OpenCL] Pipe builtin functions

Summary:
Support for the pipe built-in functions for OpenCL 2.0.
The pipe builtin functions may have infinite kinds of element types, one approach
would be to just generate calls that would always use generic types such as void*.
This patch is based on bader's opencl support patch on SPIR-V branch.

Reviewers: Anastasia, pekka.jaaskelainen

Subscribers: keryell, bader, cfe-commits

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

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

8 years agoRevert the test for r258720 temporarily
Ehsan Akhgari [Tue, 26 Jan 2016 01:51:47 +0000 (01:51 +0000)]
Revert the test for r258720 temporarily

This test is failing on a bot for reasons that are unclear to me.
Reverting for now...

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

8 years ago[Sema] Remove stray semicolons.
David Majnemer [Tue, 26 Jan 2016 01:39:17 +0000 (01:39 +0000)]
[Sema] Remove stray semicolons.

No functional change is intended.

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

8 years ago[Sema] Incomplete types are OK for covariant returns
David Majnemer [Tue, 26 Jan 2016 01:37:01 +0000 (01:37 +0000)]
[Sema] Incomplete types are OK for covariant returns

Per C++14 [class.virtual]p8, it is OK for the return type's class type
to be incomplete so long as the return type is the same between the base
and complete classes.

This fixes PR26297.

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

8 years ago[MS Compat] Don't crash if __GetExceptionInfo is in global scope
David Majnemer [Tue, 26 Jan 2016 01:12:17 +0000 (01:12 +0000)]
[MS Compat] Don't crash if __GetExceptionInfo is in global scope

__GetExceptionInfo triggered Sema::LazilyCreateBuiltin which tries to
create a non-templated function decl.  This is unnecessary and
ill-advised, there is no need for us to create a declaration for such a
builtin.

This fixes PR26298.

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

8 years agoFix use of constexpr std::pair that's not in C++11.
Evgeniy Stepanov [Mon, 25 Jan 2016 23:45:37 +0000 (23:45 +0000)]
Fix use of constexpr std::pair that's not in C++11.

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

8 years ago[cfi] Cross-DSO CFI diagnostic mode (clang part)
Evgeniy Stepanov [Mon, 25 Jan 2016 23:34:52 +0000 (23:34 +0000)]
[cfi] Cross-DSO CFI diagnostic mode (clang part)

* Runtime diagnostic data for cfi-icall changed to match the rest of
  cfi checks
* Layout of all CFI diagnostic data changed to put Kind at the
  beginning. There is no ABI stability promise yet.
* Call cfi_slowpath_diag instead of cfi_slowpath when needed.
* Emit __cfi_check_fail function, which dispatches a CFI check
  faliure according to trap/recover settings of the current module.
* A tiny driver change to match the way the new handlers are done in
  compiler-rt.

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

8 years ago[CUDA] Add -target to cuda-constructor-alias.cu test so it doesn't fail on Mac.
Justin Lebar [Mon, 25 Jan 2016 22:52:31 +0000 (22:52 +0000)]
[CUDA] Add -target to cuda-constructor-alias.cu test so it doesn't fail on Mac.

The test was checking that we passed -mconstructor-alias to host
compilation, but that explicitly shouldn't happen on Mac.

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

8 years agoUpdate comments to match the implementation.
Manman Ren [Mon, 25 Jan 2016 22:37:47 +0000 (22:37 +0000)]
Update comments to match the implementation.

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

8 years ago[CUDA] Don't generate aliases for static extern "C" functions.
Justin Lebar [Mon, 25 Jan 2016 22:36:37 +0000 (22:36 +0000)]
[CUDA] Don't generate aliases for static extern "C" functions.

Summary:
These aliases are done to support inline asm, but there's nothing we can
do: NVPTX doesn't support aliases.

Reviewers: tra

Subscribers: cfe-commits, jhen, echristo

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

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

8 years ago[CUDA] Disable ctor/dtor aliases in device code.
Justin Lebar [Mon, 25 Jan 2016 22:36:35 +0000 (22:36 +0000)]
[CUDA] Disable ctor/dtor aliases in device code.

Summary: NVPTX doesn't support aliases, so don't generate them.

Reviewers: tra

Subscribers: cfe-commits, jhen, echristo

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

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

8 years agoMove ObjCPropertyDecl to before ObjCContainerDecl.
Manman Ren [Mon, 25 Jan 2016 21:52:26 +0000 (21:52 +0000)]
Move ObjCPropertyDecl to before ObjCContainerDecl.

After we add ObjCPropertyDecl::isClassProperty, we can use it in
ObjCContainerDecl to define filter to iterate over instance properties
and class properties.

This is the first patch in a series of patches to support class properties
in addition to instance properties in objective-c.

rdar://23891898

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

8 years ago[MSVC Compat] Only warn for unknown clang-cl arguments
Ehsan Akhgari [Mon, 25 Jan 2016 21:14:52 +0000 (21:14 +0000)]
[MSVC Compat] Only warn for unknown clang-cl arguments

Summary:
MSVC's driver accepts all unknown arguments but warns about them.  clang
by default rejects all unknown arguments.  This causes issues
specifically with build systems such as autoconf which liberally pass
things such as $LDFLAGS to the compiler and expect everything to work.
This patch teaches clang-cl to ignore unknown driver arguments.

Reviewers: rnk

Subscribers: cfe-commits

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

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

8 years agoLTO via the gold plugin needs to be told about debugger tuning.
Paul Robinson [Mon, 25 Jan 2016 19:46:40 +0000 (19:46 +0000)]
LTO via the gold plugin needs to be told about debugger tuning.

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

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

8 years agoPass --wrap=pthread_create to linker for -fsplit-stack.
Rafael Espindola [Mon, 25 Jan 2016 18:29:16 +0000 (18:29 +0000)]
Pass --wrap=pthread_create to linker for -fsplit-stack.

From

https://gcc.gnu.org/ml/gcc-patches/2010-09/msg01807.html

-fsplit-stack should pass --wrap=pthread_create to linker for -fsplit-stack
It is needed to initialize the stack guard.  This fixes PR 20148.

Patch by H.J Lu!

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

8 years agoFix printing of types in initializers with suppressed tags.
Benjamin Kramer [Mon, 25 Jan 2016 10:34:06 +0000 (10:34 +0000)]
Fix printing of types in initializers with suppressed tags.

Tag and specifier printing can be suppressed in Decl::printGroup, but these suppressions leak into the initializers. Thus
    int *x = ((void *)0), *y = ((void *)0);
gets printed as
    int *x = ((void *)0), *y = ((*)0);
And
    struct { struct Z z; } z = {(struct Z){}};
gets printed as
    struct { struct Z z; } z = {(){}};
The stops the suppressions from leaking into the initializers.

Patch by Nick Sumner!

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

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

8 years ago[Sema] Improve constness
Daniel Marjamaki [Mon, 25 Jan 2016 09:29:38 +0000 (09:29 +0000)]
[Sema] Improve constness

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

8 years agoAllow capture typedefs/type aliases for VLAs in lambdas/captured statements chain.
Alexey Bataev [Mon, 25 Jan 2016 07:06:23 +0000 (07:06 +0000)]
Allow capture typedefs/type aliases for VLAs in lambdas/captured statements chain.
Previous it was allowed to capture VLAs/types with arrays of runtime bounds only inside the first lambda/capture statement in stack. Patch allows to capture these typedefs implicitly in chains of lambdas/captured statements.

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

8 years agoFixed processing of GNU extensions to C99 designated initializers
Alexey Bataev [Mon, 25 Jan 2016 05:14:03 +0000 (05:14 +0000)]
Fixed processing of GNU extensions to C99 designated initializers
Clang did not handles correctly inner parts of arrays/structures initializers in GNU extensions to C99 designated initializers.

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

8 years ago[PGO] Windows buildbot failure fix. [NFC]
Betul Buyukkurt [Sun, 24 Jan 2016 00:56:19 +0000 (00:56 +0000)]
[PGO] Windows buildbot failure fix. [NFC]

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

8 years agoClang changes for value profiling
Betul Buyukkurt [Sat, 23 Jan 2016 22:50:44 +0000 (22:50 +0000)]
Clang changes for value profiling

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

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

8 years ago[CUDA] Disallow variadic functions other than printf in device code.
Justin Lebar [Sat, 23 Jan 2016 21:28:17 +0000 (21:28 +0000)]
[CUDA] Disallow variadic functions other than printf in device code.

Reviewers: tra

Subscribers: cfe-commits, echristo, jhen

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

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

8 years ago[CUDA] Make printf work.
Justin Lebar [Sat, 23 Jan 2016 21:28:14 +0000 (21:28 +0000)]
[CUDA] Make printf work.

Summary:
The code in CGCUDACall is largely based on a patch written by Eli
Bendersky:
http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20140324/210218.html

That patch implemented an LLVM pass lowering printf to vprintf; this
one does something similar, but in Clang codegen.

Reviewers: echristo

Subscribers: cfe-commits, jhen, tra, majnemer

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

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

8 years ago[CUDA] Reject the alias attribute in CUDA device code.
Justin Lebar [Sat, 23 Jan 2016 21:28:10 +0000 (21:28 +0000)]
[CUDA] Reject the alias attribute in CUDA device code.

Summary: CUDA (well, strictly speaking, NVPTX) doesn't support aliases.

Reviewers: echristo

Subscribers: cfe-commits, jhen, tra

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

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

8 years ago[CUDA] Use Triple::isNVPTX() instead of enumerating nvptx && nvptx64.
Justin Lebar [Sat, 23 Jan 2016 21:28:08 +0000 (21:28 +0000)]
[CUDA] Use Triple::isNVPTX() instead of enumerating nvptx && nvptx64.

Summary: No functional changes.

Subscribers: tra, echristo, jhen, cfe-commits

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

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

8 years agoImproving documentation for the isMoveAssignmentOperator AST matcher.
Aaron Ballman [Sat, 23 Jan 2016 17:49:18 +0000 (17:49 +0000)]
Improving documentation for the isMoveAssignmentOperator AST matcher.

Patch by Jonathan Coe.

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

8 years agoSemaOpenMP.cpp: Fix a warning in r258543. [-Wunused-variable]
NAKAMURA Takumi [Sat, 23 Jan 2016 01:38:20 +0000 (01:38 +0000)]
SemaOpenMP.cpp: Fix a warning in r258543. [-Wunused-variable]

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

8 years ago[cfi] Do not emit bit set entry for available_externally vtables.
Evgeniy Stepanov [Sat, 23 Jan 2016 01:20:18 +0000 (01:20 +0000)]
[cfi] Do not emit bit set entry for available_externally vtables.

In the Itanium ABI, vtable may be emitted speculatively as an
available_externally global. Such vtable may not be present at the
link time and should not have a corresponding CFI bit set entry.

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

8 years ago[analyzer] SATestBuild.py: Remove html and log when producing reference results.
Devin Coughlin [Sat, 23 Jan 2016 01:09:07 +0000 (01:09 +0000)]
[analyzer] SATestBuild.py: Remove html and log when producing reference results.

The html reports are huge -- every issue in a given file results in a separate
copy of the source code, in HTML form, for the file. This gets very large
quickly and it doesn't make sense to check this into a reference repository.
Also remove the log when generating reference results because it can leak
absolute path names. We still keep both the html and the log around when
producing non-reference results.

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

8 years ago[analyzer] Fixup r258572 Utility to match function calls.
Anna Zaks [Sat, 23 Jan 2016 00:45:37 +0000 (00:45 +0000)]
[analyzer] Fixup r258572 Utility to match function calls.

Initialize the IdentifierInfo pointer. Hope this fixes the buildbot breakage.

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

8 years agoModule Debugging: Canonicalize the file names used as PCH module names
Adrian Prantl [Fri, 22 Jan 2016 23:30:56 +0000 (23:30 +0000)]
Module Debugging: Canonicalize the file names used as PCH module names
by stripping the path. Follow-up to r258555.

This is safe because only one PCH per CU is currently supported for
module debugging.

rdar://problem/24301262

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

8 years agoProperly encode the < entity; it was missing the semicolon. Regenerating the AST...
Aaron Ballman [Fri, 22 Jan 2016 23:15:00 +0000 (23:15 +0000)]
Properly encode the < entity; it was missing the semicolon. Regenerating the AST matcher reference after fixing the issue. Thanks to Richard for noticing the issue and bringing it to my attention!

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

8 years agoAdd am AST matcher for isMoveAssignmentOperator.
Aaron Ballman [Fri, 22 Jan 2016 22:37:09 +0000 (22:37 +0000)]
Add am AST matcher for isMoveAssignmentOperator.

Patch by Jonathan Coe.

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

8 years ago[analyzer] Utility to match function calls.
Gabor Horvath [Fri, 22 Jan 2016 22:32:46 +0000 (22:32 +0000)]
[analyzer] Utility to match function calls.

This patch adds a small utility to match function calls. This utility abstracts away the mutable keywords and the lazy initialization and caching logic of identifiers from the checkers. The SimpleStreamChecker is ported over this utility within this patch to show the reduction of code and to test this change.

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

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

8 years agoAMDGPU: Add barrier builtin
Matt Arsenault [Fri, 22 Jan 2016 21:56:30 +0000 (21:56 +0000)]
AMDGPU: Add barrier builtin

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

8 years agoAMDGPU: Rename builtins to use amdgcn prefix
Matt Arsenault [Fri, 22 Jan 2016 21:30:53 +0000 (21:30 +0000)]
AMDGPU: Rename builtins to use amdgcn prefix

Keep the ones still used by libclc around for now.

Emit the new amdgcn intrinsic name if not targeting r600,
in which case the old AMDGPU name is still used.

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

8 years agoModule debugging: Create a parent DIModule with the PCH name for types
Adrian Prantl [Fri, 22 Jan 2016 21:14:41 +0000 (21:14 +0000)]
Module debugging: Create a parent DIModule with the PCH name for types
emitted into a precompiled header to mirror the debug info emitted for
object files importing the PCH.

rdar://problem/24290667

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

8 years ago[OpenMP] Remove '#if 1' hanging in target_map_messages.cpp.
Samuel Antao [Fri, 22 Jan 2016 20:52:54 +0000 (20:52 +0000)]
[OpenMP] Remove '#if 1' hanging in target_map_messages.cpp.

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

8 years ago[OpenMP] Update map clause SEMA to support OpenMP 4.5 possible list items.
Samuel Antao [Fri, 22 Jan 2016 20:21:36 +0000 (20:21 +0000)]
[OpenMP] Update map clause SEMA to support OpenMP 4.5 possible list items.

Summary:
Extend support in the map clause SEMA for the expressions supported in the OpenMP 4.5 specification, namely member expressions.

Fix some bugs in the previous implementation of SEMA related with expressions that do not consist of single variable references.

Fix bug in parsing when the expression in the map clause do not start with an identifier: accept any expression in the map clause and check for validity in SEMA instead of just ignoring it.

Reviewers: hfinkel, kkwli0, arpith-jacob, carlo.bertolli, ABataev

Subscribers: cfe-commits, fraggamuffin, caomhin

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

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

8 years agoFix the build by using the correct suffix for 64 bit literals
Adrian Prantl [Fri, 22 Jan 2016 19:29:41 +0000 (19:29 +0000)]
Fix the build by using the correct suffix for 64 bit literals

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

8 years ago[MSVC Compat] Accept elided commas in macro function arguments
Ehsan Akhgari [Fri, 22 Jan 2016 19:26:44 +0000 (19:26 +0000)]
[MSVC Compat] Accept elided commas in macro function arguments

Summary:
This fixes PR25875.  When the trailing comma in a macro argument list is
elided, we need to treat it similarly to the case where a variadic macro
misses one actual argument.

Reviewers: rnk, rsmith

Subscribers: cfe-commits

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

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

8 years agoRephrase this test to help debug a buildbot issue
Adrian Prantl [Fri, 22 Jan 2016 19:14:24 +0000 (19:14 +0000)]
Rephrase this test to help debug a buildbot issue

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

8 years agoMerge templated static member variables, fixes http://llvm.org/pr26179.
Yaron Keren [Fri, 22 Jan 2016 19:03:27 +0000 (19:03 +0000)]
Merge templated static member variables, fixes http://llvm.org/pr26179.

Patch by Vassil Vassilev!
Reviewed by Richard Smith.

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

8 years agoFix a typo in r258507 and change the PCH dwoid constant to ~1UL.
Adrian Prantl [Fri, 22 Jan 2016 18:46:45 +0000 (18:46 +0000)]
Fix a typo in r258507 and change the PCH dwoid constant to ~1UL.

rdar://problem/24290667

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

8 years agoFix 80-column violations.
Adrian Prantl [Fri, 22 Jan 2016 18:46:40 +0000 (18:46 +0000)]
Fix 80-column violations.

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

8 years ago[analyzer] SATestBuild.py: Handle spaces in path passed to --use-analyzer.
Devin Coughlin [Fri, 22 Jan 2016 18:45:22 +0000 (18:45 +0000)]
[analyzer] SATestBuild.py: Handle spaces in path passed to --use-analyzer.

I missed this one in r258493.

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

8 years agoModule Debugging: Use a nonzero DWO id for precompiled headers.
Adrian Prantl [Fri, 22 Jan 2016 17:43:43 +0000 (17:43 +0000)]
Module Debugging: Use a nonzero DWO id for precompiled headers.
PCH files don't have a module signature and LLVM uses a nonzero DWO id as
an indicator for skeleton / module CUs. This change pins the DWO id for PCH
files to a known constant value.
The correct long-term solution here is to implement a module signature
that is an actual dterministic hash (at the moment module signatures are
just random nonzero numbers) and then enable this for PCH files as well.

<rdar://problem/24290667>

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

8 years ago[MSVC Compat] Don't provide /volatile:ms semantics to types > pointer
David Majnemer [Fri, 22 Jan 2016 16:36:44 +0000 (16:36 +0000)]
[MSVC Compat] Don't provide /volatile:ms semantics to types > pointer

Volatile loads of type wider than a pointer get split by MSVC because
the base x86 ISA doesn't provide loads which are wider than pointer
width.  LLVM assumes that it can emit an cmpxchg8b but this is
problematic if the memory is in a CONST memory segment.

Instead, provide behavior compatible with MSVC: split loads wider than a
pointer.

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

8 years agoTry to pacify MSVC.
Nico Weber [Fri, 22 Jan 2016 15:49:53 +0000 (15:49 +0000)]
Try to pacify MSVC.

I'm not sure why it needs these braces, but they help locally.

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

8 years agoChange of UserLabelPrefix default value from "_" to ""
Andrey Bokhanko [Fri, 22 Jan 2016 15:24:34 +0000 (15:24 +0000)]
Change of UserLabelPrefix default value from "_" to ""

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

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

8 years agoLet RecursiveASTVisitor visit array index VarDecls
Nico Weber [Fri, 22 Jan 2016 15:11:54 +0000 (15:11 +0000)]
Let RecursiveASTVisitor visit array index VarDecls

An implicit copy ctor creates loop VarDecls that hang off CXXCtorInitializer.
RecursiveASTVisitor used to not visit them, so that they didn't show up in the
parent map used by ASTMatchers, causing asserts() when the implicit
DeclRefExpr() in a CXXCtorInitializer referred to one of these VarDecls.

Fixes PR26227.
http://reviews.llvm.org/D16413

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

8 years ago[OpenMP] Sema for depend clause on target exit data directive.
Arpith Chacko Jacob [Fri, 22 Jan 2016 14:58:21 +0000 (14:58 +0000)]
[OpenMP] Sema for depend clause on target exit data directive.

Summary:
Accept depend clause on target exit data directive in sema and add test cases.

Reviewers: ABataev

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

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

8 years agoReplace some tabs with spaces.
Nico Weber [Fri, 22 Jan 2016 14:12:44 +0000 (14:12 +0000)]
Replace some tabs with spaces.

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

8 years ago[OPENMP] Generalize codegen for 'sections'-based directive.
Alexey Bataev [Fri, 22 Jan 2016 08:56:50 +0000 (08:56 +0000)]
[OPENMP] Generalize codegen for 'sections'-based directive.
If 'sections' directive has only one sub-section, the code for 'single'-based directive was emitted. Removed this codegen, because it causes crashes in different cases.

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

8 years ago[analyzer] Update SATestBuild.py to handle spaces in paths.
Devin Coughlin [Fri, 22 Jan 2016 07:08:06 +0000 (07:08 +0000)]
[analyzer] Update SATestBuild.py to handle spaces in paths.

The Jenkins workspace on the new Green Dragon builder for the static analyzer has spaces
in its path.

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

8 years ago2 missing intrinsics _cvtss_sh and _mm_cvtps_ph were added to the intrinsics header...
Ekaterina Romanova [Fri, 22 Jan 2016 06:50:50 +0000 (06:50 +0000)]
2 missing intrinsics _cvtss_sh and _mm_cvtps_ph were added to the intrinsics header f16intrin.h
Differential Revision: http://reviews.llvm.org/D16177

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

8 years ago[Docs] Slightly update LSan documentation.
Alexey Samsonov [Fri, 22 Jan 2016 01:35:45 +0000 (01:35 +0000)]
[Docs] Slightly update LSan documentation.

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

8 years ago[OpenMP] Sema for depend clause on target enter data directive.
Arpith Chacko Jacob [Fri, 22 Jan 2016 01:09:37 +0000 (01:09 +0000)]
[OpenMP] Sema for depend clause on target enter data directive.

Summary:
Accept depend clause on target enter data directive in sema and add test cases.

Reviewers: ABataev

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

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

8 years ago[analyzer] Suppress nullability warning for defensive super initializer idiom.
Devin Coughlin [Fri, 22 Jan 2016 01:01:11 +0000 (01:01 +0000)]
[analyzer] Suppress nullability warning for defensive super initializer idiom.

A common idiom in Objective-C initializers is for a defensive nil-check on the
result of a call to a super initializer:
  if (self = [super init]) {
     ...
  }
  return self;

To avoid warning on this idiom, the nullability checker now suppress diagnostics
for returns of nil on syntactic 'return self' even in initializers with non-null
return types.

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

8 years ago[OpenMP] Sema for depend clause on target directive.
Arpith Chacko Jacob [Fri, 22 Jan 2016 00:49:21 +0000 (00:49 +0000)]
[OpenMP] Sema for depend clause on target directive.

Summary:
Accept depend clause on target directive in sema and add test cases.

Reviewers: ABataev

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

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

8 years ago[OpenMP] Parsing + Sema for nowait clause on target exit data directive.
Arpith Chacko Jacob [Fri, 22 Jan 2016 00:22:05 +0000 (00:22 +0000)]
[OpenMP] Parsing + Sema for nowait clause on target exit data directive.

Summary:
Accept nowait clause on target exit data directive in sema and add test cases.

Reviewers: ABataev

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

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

8 years ago[OpenMP] Parsing + Sema for nowait clause on target enter data directive.
Arpith Chacko Jacob [Fri, 22 Jan 2016 00:03:50 +0000 (00:03 +0000)]
[OpenMP] Parsing + Sema for nowait clause on target enter data directive.

Summary:
Accept nowait clause on target enter data directive in sema and add test cases.

Reviewers: ABataev

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

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

8 years ago[MSVC Compat] Don't omit frame pointers if /Oy- is specified before /O2
David Majnemer [Thu, 21 Jan 2016 23:01:11 +0000 (23:01 +0000)]
[MSVC Compat] Don't omit frame pointers if /Oy- is specified before /O2

Microsoft's documentation states that specifying
/Oy- after the /O[12x] options disables frame-pointer omission.
What it does *not* state is that it also disables frame-pointer omission
if /Oy- is specified before /O[12x].

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

8 years ago[OpenMP] Parsing + Sema for nowait clause on target directive
Arpith Chacko Jacob [Thu, 21 Jan 2016 22:18:28 +0000 (22:18 +0000)]
[OpenMP] Parsing + Sema for nowait clause on target directive

Summary:
Allow nowait clause on target directive in sema and add test cases.

Reviewers: ABataev

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

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

8 years ago[driver] Enable some static analyzer "unix" checkers on Windows.
Devin Coughlin [Thu, 21 Jan 2016 20:09:49 +0000 (20:09 +0000)]
[driver] Enable some static analyzer "unix" checkers on Windows.

Many of the "unix" checkers are not actually unix-specific and would be valuable
to run on Windows. This commit explicitly enables those checkers on
Windows.

A patch by Alexander Riccio!

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

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

8 years ago[OpenMP] Check for at least one map clause on target data directive.
Arpith Chacko Jacob [Thu, 21 Jan 2016 19:57:55 +0000 (19:57 +0000)]
[OpenMP] Check for at least one map clause on target data directive.

Summary:
Adds the following restriction in the OpenMP specifications.

OpenMP [2.10.1, Restrictions, p. 97]
At least one map clause must appear on the directive.

Reviewers: ABataev

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

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

8 years ago[Coverage] Reduce complexity of adding function mapping records
Vedant Kumar [Thu, 21 Jan 2016 19:25:35 +0000 (19:25 +0000)]
[Coverage] Reduce complexity of adding function mapping records

Replace a string append operation in addFunctionMappingRecord with a
vector append. The existing behavior is quadratic in the worst case:
this patch makes it linear.

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

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

8 years agoAdd an isVirtualAsWritten AST matcher.
Nico Weber [Thu, 21 Jan 2016 17:56:24 +0000 (17:56 +0000)]
Add an isVirtualAsWritten AST matcher.

http://reviews.llvm.org/D16394

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

8 years agoWhen dumping documentation for AST matchers, do something more useful with \see doxyg...
Aaron Ballman [Thu, 21 Jan 2016 15:18:25 +0000 (15:18 +0000)]
When dumping documentation for AST matchers, do something more useful with \see doxygen commands. Ideally this would link to the target of \see, but for now it translates \see into "See also: "

Regenerate the AST documentation for this new functionality.

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

8 years agoFix crash for typedefs for arrays of runtime bounds in Lambdas/Captured Statements...
Alexey Bataev [Thu, 21 Jan 2016 12:54:48 +0000 (12:54 +0000)]
Fix crash for typedefs for arrays of runtime bounds in Lambdas/Captured Statements, used in sizeof() expression only.

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

8 years ago[OPENMP] Fix crash on reduction for complex variables.
Alexey Bataev [Thu, 21 Jan 2016 12:35:58 +0000 (12:35 +0000)]
[OPENMP] Fix crash on reduction for complex variables.
reworked codegen for reduction operation for complex types to avoid crash

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

8 years agoRegister the isCopyAssignmentOperator AST matcher so that it can be used dynamically.
Aaron Ballman [Wed, 20 Jan 2016 20:47:58 +0000 (20:47 +0000)]
Register the isCopyAssignmentOperator AST matcher so that it can be used dynamically.

Path by Jonathan Coe.

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

8 years agoclang-format-diff: Replace hard-code default for clang-format binary with flag.
Daniel Jasper [Wed, 20 Jan 2016 18:55:57 +0000 (18:55 +0000)]
clang-format-diff: Replace hard-code default for clang-format binary with flag.

Patch by Kwasi Mensah, thank you.

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

8 years agoAdd AST matcher support for FunctionDecls with the hasBody matcher.
Aaron Ballman [Wed, 20 Jan 2016 16:26:48 +0000 (16:26 +0000)]
Add AST matcher support for FunctionDecls with the hasBody matcher.

Patch by Aleksei Sidorin.

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

8 years agoAdd AST matcher for paren expressions.
Aaron Ballman [Wed, 20 Jan 2016 16:17:39 +0000 (16:17 +0000)]
Add AST matcher for paren expressions.

Patch by Adrian ZgorzaƂek.

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

8 years agoSilencing several -Wcast-qual warnings; NFC.
Aaron Ballman [Wed, 20 Jan 2016 15:25:30 +0000 (15:25 +0000)]
Silencing several -Wcast-qual warnings; NFC.

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

8 years ago[OPENMP 4.0] Fix for codegen of 'cancel' directive within 'sections' directive.
Alexey Bataev [Wed, 20 Jan 2016 12:29:47 +0000 (12:29 +0000)]
[OPENMP 4.0] Fix for codegen of 'cancel' directive within 'sections' directive.
Allow to emit code for 'cancel' directive within 'sections' directive with single sub-section.

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

8 years ago[OPENMP 4.5] Allow to use non-static data members in non-static member functions...
Alexey Bataev [Wed, 20 Jan 2016 09:07:54 +0000 (09:07 +0000)]
[OPENMP 4.5] Allow to use non-static data members in non-static member functions in 'private' clause.
OpenMP 4.5 allows to use non-static members of current class in non-static member functions in 'private' clause. Patch adds initial support for privatizing data members.

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

8 years agoFix infinite loop when ::new or ::delete are found in member initializer list, by...
Alexey Bataev [Wed, 20 Jan 2016 05:25:51 +0000 (05:25 +0000)]
Fix infinite loop when ::new or ::delete are found in member initializer list, by Denis Zobnin
Fix for an infinite loop on parsing ::new or ::delete in member initializer list, found by fuzzing PR23057, comment #33. Skip the rest of the member initializers if the previous initializer was invalid.
Differential Revision: http://reviews.llvm.org/D16216

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

8 years agoModule Debugging: Fine-tune the condition that determines whether a type
Adrian Prantl [Wed, 20 Jan 2016 01:29:34 +0000 (01:29 +0000)]
Module Debugging: Fine-tune the condition that determines whether a type
can be found in a module.

There are externally visible anonymous types that can be found:
  typedef struct { } s; // I can be found via the typedef.
There are anonymous internal types that can be found:
  namespace { struct s {}; } // I can be found by name.

rdar://problem/24199640

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

8 years ago[CUDA] Bail, rather than crash, on va_arg in device code.
Justin Lebar [Wed, 20 Jan 2016 00:27:00 +0000 (00:27 +0000)]
[CUDA] Bail, rather than crash, on va_arg in device code.

Reviewers: tra

Subscribers: echristo, jhen, cfe-commits

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

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

8 years ago[CUDA] Only allow __global__ on free functions and static member functions.
Justin Lebar [Wed, 20 Jan 2016 00:26:57 +0000 (00:26 +0000)]
[CUDA] Only allow __global__ on free functions and static member functions.

Summary:
Warn for NVCC compatibility if you declare a static member function or
inline function as __global__.

Reviewers: tra

Subscribers: jhen, echristo, cfe-commits

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

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

8 years agoReference the updated function name /NFC
Xinliang David Li [Wed, 20 Jan 2016 00:24:52 +0000 (00:24 +0000)]
Reference the updated function name /NFC

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

8 years agoModule Debugging: Add Objective-C testcases for anonymous tag decls. (NFC)
Adrian Prantl [Tue, 19 Jan 2016 23:42:56 +0000 (23:42 +0000)]
Module Debugging: Add Objective-C testcases for anonymous tag decls. (NFC)

rdar://problem/24199640

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