]> granicus.if.org Git - clang/log
clang
8 years agoMake clang-format cleaner remove redundant commas in list and redundant colon in...
Eric Liu [Wed, 18 May 2016 08:02:56 +0000 (08:02 +0000)]
Make clang-format cleaner remove redundant commas in list and redundant colon in constructor initializer.

Summary: Make clang-format cleaner remove redundant commas/colons in constructor initializer list.

Reviewers: klimek, djasper

Subscribers: cfe-commits, klimek

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

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

8 years agoVarious improvements to the public IRGen interface.
John McCall [Wed, 18 May 2016 05:21:18 +0000 (05:21 +0000)]
Various improvements to the public IRGen interface.

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

8 years ago[Sema,CodeGen] Remove comment from SemaChecking about a builtin_shufflevector form...
Craig Topper [Wed, 18 May 2016 04:11:25 +0000 (04:11 +0000)]
[Sema,CodeGen] Remove comment from SemaChecking about a builtin_shufflevector form that it doesn't support. Remove CodeGen support for the same form since it could never have been used due to the missing support in Sema.

I couldn't find any documentation that this form existed either. Nor is there documentation for one of the remaining two forms, but there is a testcase that uses it.

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

8 years ago[X86] Add immediate range checks for many of the builtins.
Craig Topper [Wed, 18 May 2016 03:18:12 +0000 (03:18 +0000)]
[X86] Add immediate range checks for many of the builtins.

This time allow -128 to 255 for builtins that use a char type immediate."

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

8 years agoFix use-after-free ASan failures for modules / PCH files that deserialize abi_tag...
Richard Smith [Wed, 18 May 2016 00:16:51 +0000 (00:16 +0000)]
Fix use-after-free ASan failures for modules / PCH files that deserialize abi_tag or no_sanitize attributes.

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

8 years agoPR27754: CXXRecordDecl::data() needs to perform an update even if it's called
Richard Smith [Tue, 17 May 2016 22:44:15 +0000 (22:44 +0000)]
PR27754: CXXRecordDecl::data() needs to perform an update even if it's called
on a declaration that already knows the location of the DefinitionData object.

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

8 years ago[X86][SSE] Tidied up MMX/SSE/SSE2 builtin tests to the correct test file
Simon Pilgrim [Tue, 17 May 2016 22:03:31 +0000 (22:03 +0000)]
[X86][SSE] Tidied up MMX/SSE/SSE2 builtin tests to the correct test file

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

8 years agoRevert r269717. That change alone did not provide the intended benefit (which
Richard Smith [Tue, 17 May 2016 21:48:41 +0000 (21:48 +0000)]
Revert r269717. That change alone did not provide the intended benefit (which
would come from changing the type of ASTContext::DeclAttrs from
DenseMap<Decl*,AttrVec*> to DenseMap<Decl*,AttrVec>), and it turns out to be
impractical to avoid the allocation there, because we expose the address of the
attribute vector in ways that are hard to fix.

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

8 years agoDividied ASTMatcherTests into 4 files
Piotr Padlewski [Tue, 17 May 2016 19:22:57 +0000 (19:22 +0000)]
Dividied ASTMatcherTests into 4 files

fix for long compilation [20061]
http://reviews.llvm.org/D20210

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

8 years agoTeach clang to look for libcxx in /usr/local/include/c++ on Linux
Yaron Keren [Tue, 17 May 2016 19:01:16 +0000 (19:01 +0000)]
Teach clang to look for libcxx in /usr/local/include/c++ on Linux

As The default CMAKE install prefix is /usr/local ( https://cmake.org/cmake/help/v3.0/variable/CMAKE_INSTALL_PREFIX.html ),
sudo ninja install ends up installing clang, LLVM and libcxx under /usr/local.
In development scenario, when clang is run from the build location it will not
find libcxx at neither (build location)/../include/c++ nor /usr/include/c++.
This patch lets development clang find system installed libcxx without adding
-isystem /usr/local/include/c++. Also addresses the FIXME by explaining the
use-case for these include paths.

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

8 years agoNFC: simplify logic.
Manman Ren [Tue, 17 May 2016 18:04:38 +0000 (18:04 +0000)]
NFC: simplify logic.

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

8 years agoFix line numbers in calling convention test
Reid Kleckner [Tue, 17 May 2016 17:33:31 +0000 (17:33 +0000)]
Fix line numbers in calling convention test

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

8 years agoFix calling convention test
Reid Kleckner [Tue, 17 May 2016 16:54:40 +0000 (16:54 +0000)]
Fix calling convention test

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

8 years agoTentatively enable -Wcast-calling-convention by default
Reid Kleckner [Tue, 17 May 2016 16:50:45 +0000 (16:50 +0000)]
Tentatively enable -Wcast-calling-convention by default

In Chrome, this would have found two true positives around CreateThread
if we hadn't already fixed them while rolling out ASan. We didn't get
any other hits in Chrome. I'm curious to hear if this warning finds
anything in other projects.

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

8 years ago[PCH] Fixed bug with preamble invalidation when overridden files change
Cameron Desrochers [Tue, 17 May 2016 14:34:53 +0000 (14:34 +0000)]
[PCH] Fixed bug with preamble invalidation when overridden files change

When remapped files were changed, they would not always cause the preamble's PCH to be invalidated, because the remapped path didn't necessarily match the include path (e.g. slash direction -- this happens a lot on Windows). I fixed this by moving to a llvm::sys::fs::UniqueID-based map instead of comparing paths stringwise.

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

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

8 years agoRevert "[X86] Add immediate range checks for many of the builtins."
Filipe Cabecinhas [Tue, 17 May 2016 14:07:43 +0000 (14:07 +0000)]
Revert "[X86] Add immediate range checks for many of the builtins."

This reverts commit r269619.

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

8 years ago[Mips] Set mips32 as default CPU for MIPS32 Android
Petar Jovanovic [Tue, 17 May 2016 10:46:10 +0000 (10:46 +0000)]
[Mips] Set mips32 as default CPU for MIPS32 Android

Change default CPU for MIPS32 Android. Now it is mips32 (rev1).

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

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

8 years ago[OPENMP] Pass scalar firstprivate vars by value.
Alexey Bataev [Tue, 17 May 2016 08:55:33 +0000 (08:55 +0000)]
[OPENMP] Pass scalar firstprivate vars by value.

For better performance and to unify code with offloading part we pass
scalar firstprivate values by value, instead of by reference. It will
remove some extra copying operations.

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

8 years agoclang-format: [JS] simplify logic by parsing forward.
Martin Probst [Tue, 17 May 2016 06:29:33 +0000 (06:29 +0000)]
clang-format: [JS] simplify logic by parsing forward.

This also reduces complexity to O(n) from O(n^2) by avoiding backtracking
re-parses, and fixes length calculation.

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

8 years agoclang-format: [JS] fix template string width counting.
Martin Probst [Tue, 17 May 2016 06:29:29 +0000 (06:29 +0000)]
clang-format: [JS] fix template string width counting.

Summary:
Simply looking at the final text greatly simplifies the algorithm and also
fixes a reported issue. This requires duplicating the "actual encoding width"
logic, but that seems cleaner than the column acrobatics before.

Reviewers: djasper, bkramer

Subscribers: cfe-commits, klimek

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

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512F intrinsics. Remove leading...
Craig Topper [Tue, 17 May 2016 04:41:50 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512F intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512VL intrinsics. Remove leadin...
Craig Topper [Tue, 17 May 2016 04:41:48 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512VL intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512VLDQ intrinsics. Remove...
Craig Topper [Tue, 17 May 2016 04:41:46 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512VLDQ intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512VLBW intrinsics. Remove...
Craig Topper [Tue, 17 May 2016 04:41:42 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512VLBW intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512PF intrinsics. Remove leadin...
Craig Topper [Tue, 17 May 2016 04:41:40 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512PF intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512ER intrinsics. Remove leadin...
Craig Topper [Tue, 17 May 2016 04:41:38 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512ER intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512DQ intrinsics. Remove leadin...
Craig Topper [Tue, 17 May 2016 04:41:36 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512DQ intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Add parentheses around macro arguments in AVX512BW intrinsics. Remove leadin...
Craig Topper [Tue, 17 May 2016 04:41:33 +0000 (04:41 +0000)]
[AVX512] Add parentheses around macro arguments in AVX512BW intrinsics. Remove leading underscores from macro argument names. Add explicit typecasts to all macro arguments and return values. And finally reformat after all the adjustments.

This is a mostly mechanical change accomplished with a script. I tried to split out any changes to the typecasts that already existed into separate commits.

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

8 years ago[AVX512] Fix return types in several test cases to match the intrinsic they're testing.
Craig Topper [Tue, 17 May 2016 04:41:32 +0000 (04:41 +0000)]
[AVX512] Fix return types in several test cases to match the intrinsic they're testing.

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

8 years ago[AVX512] Correct types for scalar double precision FMA intrinsics and single precisio...
Craig Topper [Tue, 17 May 2016 04:41:29 +0000 (04:41 +0000)]
[AVX512] Correct types for scalar double precision FMA intrinsics and single precision getexp intrinsics.

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

8 years ago[X86] Fix a few intrinsic tests to use the return type that matches the intrinsic...
Craig Topper [Tue, 17 May 2016 03:42:37 +0000 (03:42 +0000)]
[X86] Fix a few intrinsic tests to use the return type that matches the intrinsic they're testing.

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

8 years ago[X86] Add a few missing typecasts to intrinsics. Found by playing with -fno-lax-vecto...
Craig Topper [Tue, 17 May 2016 03:42:31 +0000 (03:42 +0000)]
[X86] Add a few missing typecasts to intrinsics. Found by playing with -fno-lax-vector-conversions on the builtin tests.

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

8 years ago[AVX512] _m512_setzero_qi/hi should return __m512i.
Craig Topper [Tue, 17 May 2016 03:42:25 +0000 (03:42 +0000)]
[AVX512] _m512_setzero_qi/hi should return __m512i.

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

8 years ago[AVX512] Fix odd formatting in intrinsic header.
Craig Topper [Tue, 17 May 2016 03:42:15 +0000 (03:42 +0000)]
[AVX512] Fix odd formatting in intrinsic header.

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

8 years agoModules: set SystemHeader to true if we are building a system module.
Manman Ren [Tue, 17 May 2016 02:15:12 +0000 (02:15 +0000)]
Modules: set SystemHeader to true if we are building a system module.

If we are processing a #include from a module build, we should treat it
as a system header if we're building a system module. Passing an optional
flag to HeaderSearch::LookupFile.

Before this, the testing case will crash when accessing a freed FileEntry.

rdar://26214027

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

8 years agoLess broken fix for buildbot breakage.
Richard Smith [Mon, 16 May 2016 23:07:58 +0000 (23:07 +0000)]
Less broken fix for buildbot breakage.

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

8 years agoTry to make the buildbots green again: avoid the need for class Attr to be
Richard Smith [Mon, 16 May 2016 23:03:40 +0000 (23:03 +0000)]
Try to make the buildbots green again: avoid the need for class Attr to be
complete for users of AttrVec.

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

8 years agoDoxygen comments for avxintrin.h.
Ekaterina Romanova [Mon, 16 May 2016 22:54:45 +0000 (22:54 +0000)]
Doxygen comments for avxintrin.h.

Added doxygen comments to avxintrin.h's intrinsics. As of now, only around 50% of the intrinsics in this file are documented here. The patches for the other half will be sent out later.

Updated bmiintrin.h to fix an incorrect section name.
Updated f16cintrin.h to fix incorect parameter names.

The doxygen comments are automatically generated based on Sony's intrinsics document.

I got an OK from Eric Christopher to commit doxygen comments without prior code
review upstream.

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

8 years agoSwitch from SmallVector to TinyPtrVector for the list of attributes on a declaration...
Richard Smith [Mon, 16 May 2016 22:53:19 +0000 (22:53 +0000)]
Switch from SmallVector to TinyPtrVector for the list of attributes on a declaration. This removes a memory allocation for the common case where the declaration has only one attribute.

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

8 years agoAvoid O(n^2) string analysis when handling GNU __asm__ statements.
Richard Smith [Mon, 16 May 2016 22:52:23 +0000 (22:52 +0000)]
Avoid O(n^2) string analysis when handling GNU __asm__ statements.

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

8 years ago[PS4] Tighten up a test (noticed in passing)
Paul Robinson [Mon, 16 May 2016 21:25:15 +0000 (21:25 +0000)]
[PS4] Tighten up a test (noticed in passing)

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

8 years agoRevert "Reapply^2 "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC""
Vedant Kumar [Mon, 16 May 2016 21:04:19 +0000 (21:04 +0000)]
Revert "Reapply^2 "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC""

This reverts commit r269695. The llvm commit does not pass the MSVC bot.

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

8 years agoReapply^2 "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC"
Vedant Kumar [Mon, 16 May 2016 20:50:13 +0000 (20:50 +0000)]
Reapply^2 "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC"

Sync up with "(llvm) Use Error in InstrProf and Coverage".

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

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

8 years agoAdded support to the ASTImporter for C++ constructor initializers.
Sean Callanan [Mon, 16 May 2016 20:48:03 +0000 (20:48 +0000)]
Added support to the ASTImporter for C++ constructor initializers.
Also added named casts and propagation of "implicit" to fix the LLDB testsuite.
This is a fixed commit of r269546, which was reverted by r269575.

Thanks to Aleksei Sidorin for review and advice.

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

8 years ago[Lex] inferModuleFromLocation should do no work if there are no modules
David Majnemer [Mon, 16 May 2016 20:30:03 +0000 (20:30 +0000)]
[Lex] inferModuleFromLocation should do no work if there are no modules

getModuleContainingLocation ends up on the hot-path for typical C code
which can lead to calls to getFileIDSlow.

To speed this up, short circuit inferModuleFromLocation when there
aren't any modules, implicit or otherwise.

This shaves 4-5% build time when building the linux kernel.

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

8 years ago[Clang][AVX512] completing missing intrinsics for [vpabs] instruction set
Michael Zuckerman [Mon, 16 May 2016 18:57:24 +0000 (18:57 +0000)]
[Clang][AVX512] completing missing intrinsics for [vpabs] instruction set

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

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

8 years agoChange embed-bitcode linkage type
Steven Wu [Mon, 16 May 2016 18:54:58 +0000 (18:54 +0000)]
Change embed-bitcode linkage type

Embedded bitcode should have private linkage instead of appending or external.
Otherwise, it will cause link failure due to duplicated symbols.
Also add llvm.embedded.module and llvm.cmdline to llvm.compiler.used so they
don't get optimized out.

rdar://problem/21555860

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

8 years ago[ms] Reintroduce feature guards in intrinsic headers in Microsoft mode
Nico Weber [Mon, 16 May 2016 18:14:07 +0000 (18:14 +0000)]
[ms] Reintroduce feature guards in intrinsic headers in Microsoft mode

Visual Studio's C++ standard library headers include intrin.h, so the intrinsic
headers get included a lot more often in Microsoft mode than elsewhere. The
AVX512 intrinsics are a lot of code (0.7 MB, causing 30% compile time overhead
for small programs including e.g. <string> and 6% compile time overhead for
larger projects like e.g. v8). Since multiversioning can't be relied on in
Microsoft mode (cl.exe doesn't support it), having faster compiles seems like
the much better tradeoff until we have a better intrinsic story going forward
(which we'll need for e.g. PR19898).

Actually using intrinsics on Windows already requires the right /arch:
settings, so this patch should have no big behavior change.

See also thread "The intrinsics headers (especially avx512) are too big. What
to do about it?" on cfe-dev.

http://reviews.llvm.org/D20291

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

8 years ago[PS4] Change the names of some "environmental" things to what our
Paul Robinson [Mon, 16 May 2016 17:22:25 +0000 (17:22 +0000)]
[PS4] Change the names of some "environmental" things to what our
licensees actually see in the toolchain we deliver to them.  This will
reduce the set of local patches we have to maintain.  The triple is
not changing.  (The term ORBIS is an internal code name for PS4.)

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

8 years ago[OpenCL] Add supported OpenCL extensions to target info.
Yaxun Liu [Mon, 16 May 2016 17:06:34 +0000 (17:06 +0000)]
[OpenCL] Add supported OpenCL extensions to target info.

Add supported OpenCL extensions to target info. It serves as default values to save the users of the burden setting each supported extensions and optional core features in command line.

Re-commit after fixing build error due to missing override attribute.

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

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

8 years agoAdd the hasDynamicExceptionSpec() AST matcher to match function declarations that...
Aaron Ballman [Mon, 16 May 2016 16:49:01 +0000 (16:49 +0000)]
Add the hasDynamicExceptionSpec() AST matcher to match function declarations that have a dynamic exception specification.

Patch by Don Hinton.

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

8 years ago[Modules] Use vfs for (recursive) directory iteration
Bruno Cardoso Lopes [Mon, 16 May 2016 16:46:01 +0000 (16:46 +0000)]
[Modules] Use vfs for (recursive) directory iteration

Clang performs directory walk while searching headers inside modules by
using the ::sys::fs instead of ::vfs. This prevents any code that uses
the VFS (e.g, reproducer scripts) to actually find such headers, since
the VFS will never be searched for those.

Change these places to use vfs::recursive_directory_iterator and
vfs::directory_iterator instead.

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

rdar://problem/25880368

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

8 years ago[mips] Add test for the dynamic linker when using the mips64el-fedora-linux triple.
Vasileios Kalintiris [Mon, 16 May 2016 11:53:51 +0000 (11:53 +0000)]
[mips] Add test for the dynamic linker when using the mips64el-fedora-linux triple.

We should use the musl linker only when there's no environment specified and
the vendor is MTI. The new test verifies this behaviour and is a follow-up to
the r269411 commit that added the vendor field check.

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

8 years ago[Clang][AVX512] completing missing intrinsics [vsqrt|vrsqrt|vrcp14 ].
Michael Zuckerman [Mon, 16 May 2016 11:42:01 +0000 (11:42 +0000)]
[Clang][AVX512] completing missing intrinsics [vsqrt|vrsqrt|vrcp14 ].

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

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

8 years ago[X86] Add typecasts to remove most assumptions about what __m128i/__m256i is defined...
Craig Topper [Mon, 16 May 2016 06:38:42 +0000 (06:38 +0000)]
[X86] Add typecasts to remove most assumptions about what __m128i/__m256i is defined as. Add similar typecasts for the fp types as well.

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

8 years ago[AVX512] Add typecasts to some intrinsics to avoid doing operations on the __m512...
Craig Topper [Mon, 16 May 2016 06:38:36 +0000 (06:38 +0000)]
[AVX512] Add typecasts to some intrinsics to avoid doing operations on the __m512/__m512i/__m512d types.

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

8 years agoCodeGen: convert some const char * to StringRef
Saleem Abdulrasool [Mon, 16 May 2016 05:06:49 +0000 (05:06 +0000)]
CodeGen: convert some const char * to StringRef

Convert some use of const char * to StringRef.  NFC.

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

8 years agoMake this SourceLocation getter const LLVM_READONLY like others in the same file.
Nick Lewycky [Mon, 16 May 2016 02:46:07 +0000 (02:46 +0000)]
Make this SourceLocation getter const LLVM_READONLY like others in the same file.

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

8 years agoSimple visualization of expressions
Mike Spertus [Mon, 16 May 2016 01:36:09 +0000 (01:36 +0000)]
Simple visualization of expressions

While more could be done, showing the type is a lot better than what is there now.

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

8 years ago[AVX512] Use correct types in test case.
Craig Topper [Mon, 16 May 2016 01:09:19 +0000 (01:09 +0000)]
[AVX512] Use correct types in test case.

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

8 years ago[X86] Remove bad cast from the 'int' return type of __builtin_ia32_kortestchi to...
Craig Topper [Mon, 16 May 2016 01:09:16 +0000 (01:09 +0000)]
[X86] Remove bad cast from the 'int' return type of __builtin_ia32_kortestchi to '__mask16' before return in an 'int' intrinsic.

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

8 years ago[AVX512] Fix bad typecasts on return value for 512-bit integer byte/word compare...
Craig Topper [Mon, 16 May 2016 00:51:06 +0000 (00:51 +0000)]
[AVX512] Fix bad typecasts on return value for 512-bit integer byte/word compare builtins.

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

8 years ago[X86] Add immediate range checks for many of the builtins.
Craig Topper [Sun, 15 May 2016 22:18:00 +0000 (22:18 +0000)]
[X86] Add immediate range checks for many of the builtins.

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

8 years ago[AVX512] Immediate argument for PALIGNR builtin should be an ICE./
Craig Topper [Sun, 15 May 2016 22:17:57 +0000 (22:17 +0000)]
[AVX512] Immediate argument for PALIGNR builtin should be an ICE./

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

8 years ago[AVX512] Add intrinsics for 512-bit insertf32x8/insertf32x4/inserti32x4.
Craig Topper [Sun, 15 May 2016 21:26:20 +0000 (21:26 +0000)]
[AVX512] Add intrinsics for 512-bit insertf32x8/insertf32x4/inserti32x4.

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

8 years ago[AVX512] Mark some integer builtin arguments that go to immediates in final instructi...
Craig Topper [Sun, 15 May 2016 20:10:06 +0000 (20:10 +0000)]
[AVX512] Mark some integer builtin arguments that go to immediates in final instructions as an ICE.

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

8 years ago[AVX512] Move unary negations to the left side of typecasts to specific vector type...
Craig Topper [Sun, 15 May 2016 20:10:03 +0000 (20:10 +0000)]
[AVX512] Move unary negations to the left side of typecasts to specific vector type. The __m128/__m256/__m512 types should be treated more opaquely and not have any operations performed on them.

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

8 years ago[AVX512] Use the correct mask type in an intrinsic.
Craig Topper [Sun, 15 May 2016 20:10:00 +0000 (20:10 +0000)]
[AVX512] Use the correct mask type in an intrinsic.

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

8 years ago[AVX512] Fix an intrinsic that was passing -2 as a mask instead of -1.
Craig Topper [Sun, 15 May 2016 20:09:58 +0000 (20:09 +0000)]
[AVX512] Fix an intrinsic that was passing -2 as a mask instead of -1.

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

8 years ago[AVX512] Make the permd builtins take a 32-bit immediate to match the software spec.
Craig Topper [Sat, 14 May 2016 21:13:31 +0000 (21:13 +0000)]
[AVX512] Make the permd builtins take a 32-bit immediate to match the software spec.

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

8 years agoRevert r269546 "Added support to the ASTImporter for C++ constructor initializers...
Oleksiy Vyalov [Sat, 14 May 2016 19:07:13 +0000 (19:07 +0000)]
Revert r269546 "Added support to the ASTImporter for C++ constructor initializers." as it breaks TestDataFormatterSynthVal.DataFormatterSynthValueTestCase.test_with_run_command_dwarf test - http://lab.llvm.org:8011/builders/lldb-x86_64-ubuntu-14.04-cmake/builds/14699

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

8 years agoWarn when a reference is bound to an empty l-value (dereferenced null pointer).
Nick Lewycky [Sat, 14 May 2016 17:44:14 +0000 (17:44 +0000)]
Warn when a reference is bound to an empty l-value (dereferenced null pointer).

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

8 years ago[AVX512] Immediate for permd builtins should be an ICE.
Craig Topper [Sat, 14 May 2016 15:27:13 +0000 (15:27 +0000)]
[AVX512] Immediate for permd builtins should be an ICE.

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

8 years ago[mips] Enable IAS by default for 32-bit MIPS targets (O32).
Daniel Sanders [Sat, 14 May 2016 12:43:08 +0000 (12:43 +0000)]
[mips] Enable IAS by default for 32-bit MIPS targets (O32).

Summary:
The MIPS IAS can now pass 'ninja check-all', recurse, build a bootable linux
kernel, and pass a variety of LNT testing.

Unfortunately we can't enable it by default for 64-bit targets yet since the N32
ABI is still very buggy and this also means we can't enable it for N64 either
because we can't distinguish between N32 and N64 in the relevant code.

Reviewers: vkalintiris

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D18759
Differential Revision: http://reviews.llvm.org/D18761

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

8 years agoModuleMap.h: Fix a \param. [-Wdocumentation]
NAKAMURA Takumi [Sat, 14 May 2016 12:37:06 +0000 (12:37 +0000)]
ModuleMap.h: Fix a \param. [-Wdocumentation]

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

8 years agoMSVCToolChain.cpp: Make version.dll generic for win32.
NAKAMURA Takumi [Sat, 14 May 2016 08:12:37 +0000 (08:12 +0000)]
MSVCToolChain.cpp: Make version.dll generic for win32.

We may consider msvc features may be capable on mingw host, if it can.
Consider --host=mingw --target=msvc.

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

8 years agoMSVCToolChain.cpp: Use explicit constructor for SmallString from std::string, to...
NAKAMURA Takumi [Sat, 14 May 2016 08:09:12 +0000 (08:09 +0000)]
MSVCToolChain.cpp: Use explicit constructor for SmallString from std::string, to appease mingw-g++.

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

8 years agoUpdate identifiers as needed when loading macros from serialized ASTs.
Sean Callanan [Sat, 14 May 2016 06:24:14 +0000 (06:24 +0000)]
Update identifiers as needed when loading macros from serialized ASTs.

This is essential for iterating across macros properly, which LLDB does when
loading macros from modules.  A naiver version of this patch (without the
conditional) caused assertion failures in the testsuite, but this version should
be safe.

Thanks to Ben Langmuir for the refinement that made this work.

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

8 years agoFixed a bug where the ASTImporter didn't propagate builtin IDs at all.
Sean Callanan [Sat, 14 May 2016 06:11:19 +0000 (06:11 +0000)]
Fixed a bug where the ASTImporter didn't propagate builtin IDs at all.

IdentifierInfos are assigned builtin IDs during parsing, but Idents.get() does
not do that work.  So the ASTImporter needs to additionally set the builtin ID
for the newly-created IdentifierInfo.  This patch does that.

Currently ASTMerge tests only check syntax and the ASTMatchers don't check for
builtin IDs, so this is tricky to test, but LLDB will have a test for this.

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

8 years ago[X86] Change most 'void' pointers in builtin type lists to more correct types. Fix...
Craig Topper [Sat, 14 May 2016 06:03:13 +0000 (06:03 +0000)]
[X86] Change most 'void' pointers in builtin type lists to more correct types. Fix some unaligned load/store intrinsics to use a less aligned type in their pointer casts.

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

8 years agoHandle injected class names in the ASTImporter.
Sean Callanan [Sat, 14 May 2016 05:43:57 +0000 (05:43 +0000)]
Handle injected class names in the ASTImporter.

Every class as parsed by Clang has a forward declaration of itself as a member:

class A {
  class A;
  ...
}

but when the parser generates this it ensures that the RecordTypes for the two
are the same.  This makes (among other things) inheritance work.  This patch
fixes a bug where the ASTImporter generated two separate RecordTypes when
importing the class and the contained forward declaration, and adds a test case.

Thanks to Doug Gregor for advice on this.

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

8 years agoRevert "Reapply "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC""
Chandler Carruth [Sat, 14 May 2016 05:39:45 +0000 (05:39 +0000)]
Revert "Reapply "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC""

This reverts commit r269492 as the corresponding LLVM commit was
reverted due to lots of warnings. See the review thread for the original
LLVM commit (r269491) for details.

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

8 years agoAdded support to the ASTImporter for C++ constructor initializers.
Sean Callanan [Sat, 14 May 2016 05:20:31 +0000 (05:20 +0000)]
Added support to the ASTImporter for C++ constructor initializers.

Thanks to Aleksei Sidorin for review and advice.

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

8 years agoWhen typo-correcting a using-declaration, actually correct the name of the
Richard Smith [Sat, 14 May 2016 01:58:49 +0000 (01:58 +0000)]
When typo-correcting a using-declaration, actually correct the name of the
UsingDecl (so that redeclaration lookup can find it).

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

8 years agoFix some typos.
Richard Smith [Sat, 14 May 2016 01:21:40 +0000 (01:21 +0000)]
Fix some typos.

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

8 years ago[AVX512] Update pshufd type strings to match the backend. Also mark the immediate...
Craig Topper [Sat, 14 May 2016 00:49:36 +0000 (00:49 +0000)]
[AVX512] Update pshufd type strings to match the backend. Also mark the immediate as an ICE instead of marking the previous vector as const.

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

8 years ago[VFS] Add level() method to vfs::recursive_directory_iterator
Bruno Cardoso Lopes [Sat, 14 May 2016 00:00:18 +0000 (00:00 +0000)]
[VFS] Add level() method to vfs::recursive_directory_iterator

Unlike sys::fs::recursive_directory_iterator,
vfs::recursive_directory_iterator does not implement the level() method,
which tells how deep in the directory tree the current iterator is. This
is needed in the vfs::recursive_directory_iterator so that future
improvements to the crash reproducer will be able to properly access
header for umbrellas when looking into the VFS.

rdar://problem/25880368

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

8 years agoGet default -fms-compatibility-version from cl.exe's version
Adrian McCarthy [Fri, 13 May 2016 23:20:11 +0000 (23:20 +0000)]
Get default -fms-compatibility-version from cl.exe's version

-fms-compatibility-version was defaulting to 18 (VS 2013), which is a pain if your environment is pointing to version 19 (VS 2015) libraries.

If cl.exe can be found, this patch uses its version number as the default instead. It re-uses the existing code to find the Visual Studio binaries folder and WinAPI methods to check its version. You can still explicitly specify a compatibility version on the command line. If you don't have cl.exe, this should be a no-op and you'll get the old default of 18.

This affected the tests, which assumed that if you didn't specific a version, that it would default to 18, but this won't be true for all machines. So a couple test cases had to be eliminated and a couple others had to be tweaked to allow for various outputs.

Addresses: https://llvm.org/bugs/show_bug.cgi?id=27215

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

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

8 years ago[ModuleMap][CrashReproducer] Collect headers from inner frameworks
Bruno Cardoso Lopes [Fri, 13 May 2016 22:21:51 +0000 (22:21 +0000)]
[ModuleMap][CrashReproducer] Collect headers from inner frameworks

(1) Collect headers under inner frameworks (frameworks inside other
other frameworks).
(2) Make sure we also collect the right header files inside them.

More info on (2):

Consider a dummy framework module B, with header Frameworks/B/B.h. Now
consider that another framework A, with header Frameworks/A/A.h, has a
layout with a inner framework Frameworks/A/Frameworks/B/B.h, where the
"B/B.h" part is a symlink for Frameworks/B/B.h. Also assume that
Frameworks/A/A.h includes <B/B.h>.

When parsing header Frameworks/A/A.h, framework module lookup is
performed in search for B, and it happens that
"Frameworks/A/Frameworks/B/B.h" path is registered in the module instead
of real "Frameworks/B/B.h". This occurs because
"Frameworks/A/Frameworks/B/B.h" is scanned first by the FileManager,
when looking for inner framework modules under Frameworks/A/Frameworks.
This makes Frameworks/A/Frameworks/B/B.h the default cached named inside
the FileManager for the B.h file UID.

This leads to modules being built without consistent paths to underlying
header files. This is usually not a problem in regular compilation flow,
but it's an issue when running the crash reproducer. The issue is that
clangs collect "Frameworks/A/Frameworks/B/B.h" but not
"Frameworks/B/B.h" into the VFS, leading to err_mmap_umbrella_clash. So
make sure we also collect the original header.

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

rdar://problem/25880368

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

8 years agoReapply "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC"
Vedant Kumar [Fri, 13 May 2016 21:51:02 +0000 (21:51 +0000)]
Reapply "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC"

Sync up with "(llvm) Use Error in InstrProf and Coverage".

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

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

8 years agoARM-MachO: stop claiming to be EABI
Tim Northover [Fri, 13 May 2016 21:26:45 +0000 (21:26 +0000)]
ARM-MachO: stop claiming to be EABI

Embedded ARM MachO targets are AAPCS but not full EABI (we don't use
__aeabi_whatever and the functions are allowed to be hard-float).

Turns out there was already a test for this, but its original purpose had
become corrupted over the years.

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

8 years agoRevert "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC"
Vedant Kumar [Fri, 13 May 2016 20:10:22 +0000 (20:10 +0000)]
Revert "[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC"

This reverts commit r269463. It fails two llvm-profdata tests.

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

8 years ago[MS ABI] Delegating constructors should not assume they are most derived
David Majnemer [Fri, 13 May 2016 20:05:09 +0000 (20:05 +0000)]
[MS ABI] Delegating constructors should not assume they are most derived

A constructor needs to know whether or not it is most derived in order
to determine if it is responsible for virtual bases.  Delegating
constructors assumed they were most derived.

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

8 years ago[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC
Vedant Kumar [Fri, 13 May 2016 20:01:34 +0000 (20:01 +0000)]
[ProfileData] (clang) Use Error in InstrProf and Coverage, NFC

Sync up with "(llvm) Use Error in InstrProf and Coverage".

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

8 years agoAdd an AST matcher for CastExpr kind
Etienne Bergeron [Fri, 13 May 2016 19:36:55 +0000 (19:36 +0000)]
Add an AST matcher for CastExpr kind

Summary:
This AST matcher will match a given CastExpr kind.
It's an narrowing matcher on CastExpr.

Reviewers: klimek, alexfh, sbenza, aaron.ballman

Subscribers: Prazek, jroelofs, aaron.ballman, klimek, cfe-commits

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

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

8 years agoUse marginally more appropriate functions to detect if we should declare an
Richard Smith [Fri, 13 May 2016 18:48:05 +0000 (18:48 +0000)]
Use marginally more appropriate functions to detect if we should declare an
implicit copy constructor/assignment, and other minor cleanups. No
functionality change intended.

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

8 years agoFix module map typo in r269347.
Richard Smith [Fri, 13 May 2016 17:28:51 +0000 (17:28 +0000)]
Fix module map typo in r269347.

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

8 years agoRevert "[OpenCL] Add supported OpenCL extensions to target info."
Yaxun Liu [Fri, 13 May 2016 17:16:26 +0000 (17:16 +0000)]
Revert "[OpenCL] Add supported OpenCL extensions to target info."

Revert r269431 due to build failure caused by warning msg:

  llvm/tools/clang/lib/Basic/Targets.cpp:2090:9: error: 'setSupportedOpenCLOpts' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override]
   void setSupportedOpenCLOpts() {

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

8 years ago[OpenCL] Add supported OpenCL extensions to target info.
Yaxun Liu [Fri, 13 May 2016 15:44:37 +0000 (15:44 +0000)]
[OpenCL] Add supported OpenCL extensions to target info.

Add supported OpenCL extensions to target info. It serves as default values to save the users of the burden setting each supported extensions and optional core features in command line.

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

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

8 years agoPrune four superfluous ExternalSemaSource.h includes and one forward declaration...
Yaron Keren [Fri, 13 May 2016 14:53:19 +0000 (14:53 +0000)]
Prune four superfluous ExternalSemaSource.h includes and one forward declaration in Sema.h
where ExternalSemaSource.h was already included due to ExternalSemaSource:: member uses.

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