]> granicus.if.org Git - clang/log
clang
9 years agoRevert r246214 and r246213
Steven Wu [Fri, 28 Aug 2015 07:14:10 +0000 (07:14 +0000)]
Revert r246214 and r246213

These two commits causes llvm LTO bootstrap to hang in ScalarEvolution.

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

9 years ago[OPENMP 4.0] Codegen for array sections.
Alexey Bataev [Fri, 28 Aug 2015 06:09:05 +0000 (06:09 +0000)]
[OPENMP 4.0] Codegen for array sections.
Added codegen for array section in 'depend' clause of 'task' directive. It emits to pointers, one for the begin of array section and another for the end of array section. Size of the section is calculated as (end + 1 - start) * sizeof(basic_element_type).

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

9 years agoPR24597: Fix in-place evaluation of call expressions to provide a proper "this"
Richard Smith [Fri, 28 Aug 2015 02:43:42 +0000 (02:43 +0000)]
PR24597: Fix in-place evaluation of call expressions to provide a proper "this"
pointer to an RVO construction of a returned object.

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

9 years agoInstead of duplicating code, call the base implementation.
Eric Christopher [Fri, 28 Aug 2015 02:14:00 +0000 (02:14 +0000)]
Instead of duplicating code, call the base implementation.

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

9 years agoMerge the two feature map setting functions into a single function
Eric Christopher [Fri, 28 Aug 2015 02:13:58 +0000 (02:13 +0000)]
Merge the two feature map setting functions into a single function
and replace all callers.

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

9 years agoFix macro backtrace printing.
Richard Trieu [Thu, 27 Aug 2015 23:38:45 +0000 (23:38 +0000)]
Fix macro backtrace printing.

Sometimes, a macro that expands to another macro name will not be printed in
the macro backtrace.  This patch finds the missed macro expansions and prints
them.  Fixes PR16799

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

9 years agoCGDebugInfo: Instead of uniquing RetainedTypes, just refrain from retaining
Adrian Prantl [Thu, 27 Aug 2015 22:56:46 +0000 (22:56 +0000)]
CGDebugInfo: Instead of uniquing RetainedTypes, just refrain from retaining
them more than once. (NFC)

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

9 years ago[X86] Bump Darwin MaxVectorAlign to 64 when AVX512 is enabled.
Ahmed Bougacha [Thu, 27 Aug 2015 22:42:12 +0000 (22:42 +0000)]
[X86] Bump Darwin MaxVectorAlign to 64 when AVX512 is enabled.

Without this, 64-byte vector types (__m512), specified to be 64-byte
aligned in the AVX512 draft SysV ABI, will only be 32-byte aligned.

This is analoguous to AVX, for which we accept 32-byte max alignment.

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

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

9 years ago[X86] Conditionalize Darwin MaxVectorAlign on the presence of AVX.
Ahmed Bougacha [Thu, 27 Aug 2015 22:30:38 +0000 (22:30 +0000)]
[X86] Conditionalize Darwin MaxVectorAlign on the presence of AVX.

There's no point in using a larger alignment if we have no instructions
that would benefit from it.

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

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

9 years ago[X86] Use AVX features instead of ABI to init. SimdDefaultAlign.
Ahmed Bougacha [Thu, 27 Aug 2015 22:24:56 +0000 (22:24 +0000)]
[X86] Use AVX features instead of ABI to init. SimdDefaultAlign.

The ABI string only exists to communicate with TargetCodeGenInfo.
Concretely, since we only used "avx*" ABI strings on x86_64 (as AVX
doesn't affect the i386 ABIs), this meant that, when initializing
SimdDefaultAlign, we would ignore AVX/AVX512 on i386, for no good
reason.

Instead, directly check the features. A similar change for
MaxVectorAlign will follow.

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

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

9 years agoUse an explicit assignment.
Eric Christopher [Thu, 27 Aug 2015 22:20:03 +0000 (22:20 +0000)]
Use an explicit assignment.

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

9 years ago[X86][3DNow] Added debug codegen test for 3DNow! intrinsics
Simon Pilgrim [Thu, 27 Aug 2015 22:18:09 +0000 (22:18 +0000)]
[X86][3DNow] Added debug codegen test for 3DNow! intrinsics

Part of PR24590

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

9 years agoDon't call a member function on a null pointer.
Richard Smith [Thu, 27 Aug 2015 21:38:25 +0000 (21:38 +0000)]
Don't call a member function on a null pointer.

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

9 years agoAssume loads fix #2
Piotr Padlewski [Thu, 27 Aug 2015 21:35:41 +0000 (21:35 +0000)]
Assume loads fix #2

There was linker problem, and it turns out that it is not always safe
to refer to vtable. If the vtable is used, then we can refer to it
without any problem, but because we don't know when it will be used or
not, we can only check if vtable is external or it is safe to to emit it
speculativly (when class it doesn't have any inline virtual functions).
It should be fixed in the future.

http://reviews.llvm.org/D12385

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

9 years agoGenerating assumption loads of vptr after ctor call (fixed)
Piotr Padlewski [Thu, 27 Aug 2015 21:35:37 +0000 (21:35 +0000)]
Generating assumption loads of vptr after ctor call (fixed)

Generating call assume(icmp %vtable, %global_vtable) after constructor
call for devirtualization purposes.

For more info go to:
http://lists.llvm.org/pipermail/cfe-dev/2015-July/044227.html

Edit:
Fixed version because of PR24479.

http://reviews.llvm.org/D11859

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

9 years ago[X86][XOP] Added debug codegen test for XOP intrinsics
Simon Pilgrim [Thu, 27 Aug 2015 21:32:03 +0000 (21:32 +0000)]
[X86][XOP] Added debug codegen test for XOP intrinsics

Part of PR24590

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

9 years agoCGDebugInfo: Factor out a getOrCreateStandaloneType() method.
Adrian Prantl [Thu, 27 Aug 2015 21:21:19 +0000 (21:21 +0000)]
CGDebugInfo: Factor out a getOrCreateStandaloneType() method.

Usually debug info is created on the fly while during codegen.
With this API it becomes possible to create standalone debug info
for types that are not referenced by any code, such as emitting debug info
for a clang module or for implementing something like -gfull.
Because on-the-fly debug info generation may still insert retained types
on top of them, all RetainedTypes are uniqued in CGDebugInfo::finalize().

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

9 years ago[X86][FMA4] Added debug codegen test for FMA4 intrinsics
Simon Pilgrim [Thu, 27 Aug 2015 20:41:45 +0000 (20:41 +0000)]
[X86][FMA4] Added debug codegen test for FMA4 intrinsics

Part of PR24590

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

9 years ago[X86][F16C] Added debug codegen test for F16C intrinsics
Simon Pilgrim [Thu, 27 Aug 2015 20:34:02 +0000 (20:34 +0000)]
[X86][F16C] Added debug codegen test for F16C intrinsics

Part of PR24590

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

9 years agoRemove a dead assert, we'd have gotten the case above.
Eric Christopher [Thu, 27 Aug 2015 20:32:24 +0000 (20:32 +0000)]
Remove a dead assert, we'd have gotten the case above.

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

9 years ago[X86] Add __builtin_ia32_undef* intrinsics to test
Simon Pilgrim [Thu, 27 Aug 2015 20:29:13 +0000 (20:29 +0000)]
[X86] Add __builtin_ia32_undef* intrinsics to test

Minor tweak to rL246083

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

9 years agoTarget attribute syntax compatibility fix - gcc uses no- rather than mno-.
Eric Christopher [Thu, 27 Aug 2015 20:05:48 +0000 (20:05 +0000)]
Target attribute syntax compatibility fix - gcc uses no- rather than mno-.

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

9 years agoRename this file to have a processor suffix to help identify.
Eric Christopher [Thu, 27 Aug 2015 20:05:46 +0000 (20:05 +0000)]
Rename this file to have a processor suffix to help identify.

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

9 years agoRewrite the code generation handling for function feature and cpu attributes.
Eric Christopher [Thu, 27 Aug 2015 19:59:34 +0000 (19:59 +0000)]
Rewrite the code generation handling for function feature and cpu attributes.

A couple of changes here:

a) Do less work in the case where we don't have a target attribute on the
function. We've already canonicalized the attributes for the function -
no need to do more work.

b) Use the newer canonicalized feature adding functions from TargetInfo
to do the work when we do have a target attribute. This enables us to diagnose
some warnings in the case of conflicting written attributes (only ppc does
this today) and also make sure to get all of the features for a cpu that's
listed rather than just change the cpu.

Updated all testcases accordingly and added a new testcase to verify that we'll
error out on ppc if we have some incompatible options using the existing diagnosis
framework there.

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

9 years ago[CUDA] Check register names on appropriate side of cuda compilation only.
Artem Belevich [Thu, 27 Aug 2015 19:54:21 +0000 (19:54 +0000)]
[CUDA] Check register names on appropriate side of cuda compilation only.

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

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

9 years agoAdd a -gmodules option to the driver and a -dwarf-ext-refs to cc1
Adrian Prantl [Thu, 27 Aug 2015 19:46:20 +0000 (19:46 +0000)]
Add a -gmodules option to the driver and a -dwarf-ext-refs to cc1
to enable the use of external type references in the debug info
(a.k.a. module debugging).

The driver expands -gmodules to "-g -fmodule-format=obj -dwarf-ext-refs"
and passes that to cc1. All this does at the moment is set a flag
codegenopts.

http://reviews.llvm.org/D11958

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

9 years agoImprove options printed on vectorization analysis diagnostics.
Tyler Nowicki [Thu, 27 Aug 2015 18:58:34 +0000 (18:58 +0000)]
Improve options printed on vectorization analysis diagnostics.

The LLVM patch changes the analysis diagnostics produced when loops with
floating-point recurrences or memory operations are identified. The new messages
say "cannot prove it is safe to reorder * operations; allow reordering by
specifying #pragma clang loop vectorize(enable)". Depending on the type of
diagnostic the message will include additional options such as ffast-math or
__restrict__.

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

9 years ago[Static Analyzer] BugReporter.cpp:2869: Assertion failed: !RemainingNodes.empty(...
Gabor Horvath [Thu, 27 Aug 2015 18:57:00 +0000 (18:57 +0000)]
[Static Analyzer] BugReporter.cpp:2869: Assertion failed: !RemainingNodes.empty() && "No error node found in the trimmed graph"

The assertion is caused by reusing a “filler” ExplodedNode as an error node.
The “filler” nodes are only used for intermediate processing and are not
essential for analyzer history, so they can be reclaimed when the
ExplodedGraph is trimmed by the “collectNode” function. When a checker finds a
bug, they generate a new transition in the ExplodedGraph. The analyzer will
try to reuse the existing predecessor node. If it cannot, it creates a new
ExplodedNode, which always has a tag to uniquely identify the creation site.
The assertion is caused when the analyzer reuses a “filler” node.

In the test case, some “filler” nodes were reused and then reclaimed later
when the ExplodedGraph was trimmed. This caused an assertion because the node
was needed to generate the report. The “filler” nodes should not be reused as
error nodes. The patch adds a constraint to prevent this happening, which
solves the problem and makes the test cases pass.

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

Patch by Ying Yi!

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

9 years ago[Tests] Modified Lit Tests to be C++11 compatibile
Charles Li [Thu, 27 Aug 2015 18:49:15 +0000 (18:49 +0000)]
[Tests] Modified Lit Tests to be C++11 compatibile

This 2nd patch should not change the test results, but it is useful if clang's
default C++ language is ever changed from gnu++98.

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

9 years ago[Static Analyzer] Make NonNullParamChecker emit implicit null dereference events.
Gabor Horvath [Thu, 27 Aug 2015 18:49:07 +0000 (18:49 +0000)]
[Static Analyzer] Make NonNullParamChecker emit implicit null dereference events.

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

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

9 years agoconst-ify TargetInfo::handleUserFeatures.
Eric Christopher [Thu, 27 Aug 2015 18:42:57 +0000 (18:42 +0000)]
const-ify TargetInfo::handleUserFeatures.

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

9 years ago[CUDA] Improve CUDA compilation pipeline creation.
Artem Belevich [Thu, 27 Aug 2015 18:10:41 +0000 (18:10 +0000)]
[CUDA] Improve CUDA compilation pipeline creation.

Current implementation tries to guess which Action will result in a
job which needs to incorporate device-side GPU binaries. The guessing
was attempting to work around the fact that multiple actions may be
combined into a single compiler invocation. If CudaHostAction ends up
being combined (and thus bypassed during action list traversal) no
device-side actions it pointed to were processed. The guessing worked
for most of the usual cases, but fell apart when external assembler
was used.

This change removes the guessing and makes sure we create and pass
device-side jobs regardless of how the jobs get combined.

* CudaHostAction is always inserted either at Compile phase or the
  FinalPhase of current compilation, whichever happens first.
* If selectToolForJob combines CudaHostAction with other actions, it
  passes info about CudaHostAction up to the caller
* When it sees that CudaHostAction got combined with other actions
  (and hence will never be passed to BuildJobsForActions),
  BuildJobsForActions creates device-side jobs the same way they would
  be created if CudaHostAction was passed to BuildJobsForActions
  directly.
* Added two more test cases to make sure GPU binaries are passed to
  correct jobs.

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

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

9 years agoclang-format: Don't let a leading "template <..>" lead to wrapped initializers.
Daniel Jasper [Thu, 27 Aug 2015 11:59:31 +0000 (11:59 +0000)]
clang-format: Don't let a leading "template <..>" lead to wrapped initializers.

Before:
  Constructor() : initializer(0) {}

  template <typename T>
  Constructor()
      : initializer(0) {}

After:
  Constructor() : initializer(0) {}

  template <typename T>
  Constructor() : initializer(0) {}

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

9 years agoPass in a cpu to initDefaultFeatures so that we can share this code
Eric Christopher [Thu, 27 Aug 2015 00:05:52 +0000 (00:05 +0000)]
Pass in a cpu to initDefaultFeatures so that we can share this code
with multiple uses of feature map construction.

Note: We could make this a static function on TargetInfo if we
fix the x86 port needing to check the triple in an isolated case.

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

9 years agoconst-ify X86TargetInfo::getCPUKind.
Eric Christopher [Thu, 27 Aug 2015 00:05:50 +0000 (00:05 +0000)]
const-ify X86TargetInfo::getCPUKind.

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

9 years ago[modules] The key to a DeclContext name lookup table is not actually a
Richard Smith [Wed, 26 Aug 2015 23:55:49 +0000 (23:55 +0000)]
[modules] The key to a DeclContext name lookup table is not actually a
DeclarationName (because all ctor names are considered the same, and so on).
Reflect this in the type used as the lookup table key. As a side-effect, remove
one copy of the duplicated code used to compute the hash of the key.

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

9 years agoPull out cpu string -> enum parsing for x86 as a separate function,
Eric Christopher [Wed, 26 Aug 2015 23:42:18 +0000 (23:42 +0000)]
Pull out cpu string -> enum parsing for x86 as a separate function,
this is going to see use shortly in unifying feature set construction.

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

9 years ago[Static Analyzer] Checks to catch nullability related issues.
Gabor Horvath [Wed, 26 Aug 2015 23:17:43 +0000 (23:17 +0000)]
[Static Analyzer] Checks to catch nullability related issues.

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

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

9 years agoDI: Update DISubprogram testcases after LLVM r246098
Duncan P. N. Exon Smith [Wed, 26 Aug 2015 22:50:48 +0000 (22:50 +0000)]
DI: Update DISubprogram testcases after LLVM r246098

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

9 years agoDI: Clarify meaning of createTempFunctionFwdDecl() arg, NFC
Duncan P. N. Exon Smith [Wed, 26 Aug 2015 22:21:09 +0000 (22:21 +0000)]
DI: Clarify meaning of createTempFunctionFwdDecl() arg, NFC

I stared at `false /*declaration*/` for quite some time before giving up
and checking the actual function to see what it meant.  Replacing with
`/* isDefinition = */ false` to save myself effort later.

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

9 years ago[ARM] Mark mcr/mrc builtin operands as required-immediate.
Ahmed Bougacha [Wed, 26 Aug 2015 22:21:07 +0000 (22:21 +0000)]
[ARM] Mark mcr/mrc builtin operands as required-immediate.

An early error message is better than the "cannot select" alternative.

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

9 years agoCorrected 3 typos. NFC
Charles Li [Wed, 26 Aug 2015 22:13:30 +0000 (22:13 +0000)]
Corrected 3 typos. NFC

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

9 years ago[ms-inline-asm] Add field access to MS inline asm identifier lookup
Reid Kleckner [Wed, 26 Aug 2015 21:57:20 +0000 (21:57 +0000)]
[ms-inline-asm] Add field access to MS inline asm identifier lookup

Now we can parse code like this:
  struct A {
    int field;
  };
  int f(A o) {
    __asm mov eax, o.field
  }

Fixes PR19117.

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

9 years ago[X86][SSE] Add _mm_undefined_* intrinsics
Simon Pilgrim [Wed, 26 Aug 2015 21:17:12 +0000 (21:17 +0000)]
[X86][SSE] Add _mm_undefined_* intrinsics

Added missing SSE/AVX 'undefined' intrinsics (PR24040):

_mm_undefined_pd, _mm_undefined_ps + _mm_undefined_si128
_mm256_undefined_pd, _mm256_undefined_ps + _mm256_undefined_si256
_mm512_undefined, _mm512_undefined_ps, _mm512_undefined_pd + _mm512_undefined_epi32

Added builtin intrinsicss:

__builtin_ia32_undef128, __builtin_ia32_undef256 + __builtin_ia32_undef512

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

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

9 years ago[ARM] Error out if float-ab=hard and abi=apcs-gnu on macho platforms.
Akira Hatanaka [Wed, 26 Aug 2015 19:00:11 +0000 (19:00 +0000)]
[ARM] Error out if float-ab=hard and abi=apcs-gnu on macho platforms.

Error out if -mfloat-abi=hard or -mhard-float is specified on the command
line and the target ABI is APCS. Previously clang issued no warnings or
errors and just passed the option to the backend, which had no effect on
code generation for targets using APCS.

This commit corrects the patch commited in r245866, which didn't take into
account the fact that not all darwin targets use APCS.

rdar://problem/22257950

http://reviews.llvm.org/D12344

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

9 years agoChange Native Client x86 usr include and link path to match SDK expectations
Derek Schuff [Wed, 26 Aug 2015 17:14:08 +0000 (17:14 +0000)]
Change Native Client x86 usr include and link path to match SDK expectations

GNU multilib style uses x86_64-nacl/include and x86_64-nacl/usr/include
but the SDK expects i686-nacl/usr/include for its files. Change the driver
to use this.

Fixes https://code.google.com/p/nativeclient/issues/detail?id=4108

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

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

9 years ago[ASTMatchers] Add type matcher for SubstTemplateTypeParmType.
Samuel Benzaquen [Wed, 26 Aug 2015 16:15:59 +0000 (16:15 +0000)]
[ASTMatchers] Add type matcher for SubstTemplateTypeParmType.

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

9 years agoConvert a bunch of loops to ranged-for and clean up accordingly.
Eric Christopher [Wed, 26 Aug 2015 08:21:55 +0000 (08:21 +0000)]
Convert a bunch of loops to ranged-for and clean up accordingly.

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

9 years agoMake FileManager::getFileSystemOptions consistent with CompilerInstance::getFileSyste...
Yaron Keren [Wed, 26 Aug 2015 08:10:22 +0000 (08:10 +0000)]
Make FileManager::getFileSystemOptions consistent with CompilerInstance::getFileSystemOpts
and CompilerInvocation::getFileSystemOpts by renaming it to getFileSystemOpts,
marking the const-returning access method const and adding a non-const version,
making the function prototypes identical to CompilerInstance::getFileSystemOpts.

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

9 years agoGroup some of the inline assembly related function prototypes near
Eric Christopher [Wed, 26 Aug 2015 07:29:58 +0000 (07:29 +0000)]
Group some of the inline assembly related function prototypes near
each other.

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

9 years agoRemove dead code associated with parsing and setting ABI based on
Eric Christopher [Wed, 26 Aug 2015 07:01:33 +0000 (07:01 +0000)]
Remove dead code associated with parsing and setting ABI based on
string name.

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

9 years agoRemove a TODO that isn't going to get fixed in this way.
Eric Christopher [Wed, 26 Aug 2015 07:01:30 +0000 (07:01 +0000)]
Remove a TODO that isn't going to get fixed in this way.

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

9 years ago[Sema] Don't assume CallExpr::getDirectCallee will succeed
David Majnemer [Wed, 26 Aug 2015 05:13:19 +0000 (05:13 +0000)]
[Sema] Don't assume CallExpr::getDirectCallee will succeed

We tried to provide a very nice diagnostic when diagnosing an assignment
to a const int & produced by a function call.  However, we cannot always
determine what function was called.

This fixes PR24568.

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

9 years agoUpdate file comment to more accurately describe what's implemented.
Eric Christopher [Wed, 26 Aug 2015 04:23:11 +0000 (04:23 +0000)]
Update file comment to more accurately describe what's implemented.

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

9 years agoModify DeclaratorChuck::getFunction to be passed an Exception Specification SourceRange
Nathan Wilson [Wed, 26 Aug 2015 04:19:36 +0000 (04:19 +0000)]
Modify DeclaratorChuck::getFunction to be passed an Exception Specification SourceRange

Summary:
- Store the exception specification range's begin and end SourceLocation in DeclaratorChuck::FunctionTypeInfo. These SourceLocations can be used in a FixItHint Range.
- Add diagnostic; function concept having an exception specification.

Reviewers: hubert.reinterpretcast, fraggamuffin, faisalv, aaron.ballman, rsmith

Subscribers: cfe-commits

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

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

9 years agoAdd missing newline.
Ted Kremenek [Wed, 26 Aug 2015 03:11:31 +0000 (03:11 +0000)]
Add missing newline.

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

9 years ago[Headers] Require x86-registered for r245987 codegen tests.
Ahmed Bougacha [Tue, 25 Aug 2015 23:42:55 +0000 (23:42 +0000)]
[Headers] Require x86-registered for r245987 codegen tests.

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

9 years ago[Headers][X86] Add -O0 assembly tests for avx2 intrinsics.
Ahmed Bougacha [Tue, 25 Aug 2015 23:09:05 +0000 (23:09 +0000)]
[Headers][X86] Add -O0 assembly tests for avx2 intrinsics.

We agreed for r245605 that, as long as we don't affect -O0 codegen
too much, it's OK to use native constructs rather than intrinsics.
Let's test that, starting with AVX2 here.

See PR24580.

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

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

9 years agoMake sure that we evaluate __attribute__((enable_if)) on a method with no overloads...
Nick Lewycky [Tue, 25 Aug 2015 22:33:16 +0000 (22:33 +0000)]
Make sure that we evaluate __attribute__((enable_if)) on a method with no overloads. Patch by Ettore Speziale!

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

9 years agoClarify the error message when the reason the conversion is not viable is because...
Nick Lewycky [Tue, 25 Aug 2015 22:18:46 +0000 (22:18 +0000)]
Clarify the error message when the reason the conversion is not viable is because the returned value does not match the function return type.

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

9 years ago[X86] Remove unnecessary MMX declarations from Intrin.h
Simon Pilgrim [Tue, 25 Aug 2015 21:27:46 +0000 (21:27 +0000)]
[X86] Remove unnecessary MMX declarations from Intrin.h

As discussed in PR23648 - the intrinsics _m_from_int, _m_to_int and _m_prefetch are defined in mmintrin.h and prfchwintrin.h so we don't need to in Intrin.h

Added tests for _m_from_int and _m_to_int

D11338 already added a test for _m_prefetch

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

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

9 years agoRevert r245879. Speculative, might have caused crbug.com/524604
Nico Weber [Tue, 25 Aug 2015 18:43:32 +0000 (18:43 +0000)]
Revert r245879. Speculative, might have caused crbug.com/524604

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

9 years ago[Sema] Handle leading and trailing __ for GNU attributes
David Majnemer [Tue, 25 Aug 2015 16:44:38 +0000 (16:44 +0000)]
[Sema] Handle leading and trailing __ for GNU attributes

GNU attributes can have a leading and trailing __ appended/prepended to
the attribute name.  While the parser and AttributeList::getKind did the
right thing, AttributeList::getAttributeSpellingListIndex did not.

This fixes PR24565.

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

9 years ago[Static Analyzer] Fix tests to reflect the change in the diagnostic message.
Gabor Horvath [Tue, 25 Aug 2015 16:38:05 +0000 (16:38 +0000)]
[Static Analyzer] Fix tests to reflect the change in the diagnostic message.

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

9 years ago[Static Analyzer] Fixed a typo in a diagnostic message.
Gabor Horvath [Tue, 25 Aug 2015 16:27:03 +0000 (16:27 +0000)]
[Static Analyzer] Fixed a typo in a diagnostic message.

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

9 years agoConvert SampleProfile pass into a Module pass.
Diego Novillo [Tue, 25 Aug 2015 15:25:13 +0000 (15:25 +0000)]
Convert SampleProfile pass into a Module pass.

Eventually, we will need sample profiles to be incorporated into the
inliner's cost models.  To do this, we need the sample profile pass to
be a module pass.

This patch makes no functional changes beyond the mechanical adjustments
needed to run SampleProfile as a module pass.

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

9 years agoFix possible crash on null base or type for array elements.
Alexey Bataev [Tue, 25 Aug 2015 15:15:12 +0000 (15:15 +0000)]
Fix possible crash on null base or type for array elements.

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

9 years ago[OPENMP 4.0] Initial support for array sections.
Alexey Bataev [Tue, 25 Aug 2015 14:24:04 +0000 (14:24 +0000)]
[OPENMP 4.0] Initial support for array sections.

Adds parsing/sema analysis/serialization/deserialization for array sections in OpenMP constructs (introduced in OpenMP 4.0).
Currently it is allowed to use array sections only in OpenMP clauses that accepts list of expressions.
Differential Revision: http://reviews.llvm.org/D10732

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

9 years agoRewrite the PPC target feature handling to more resemble other targets.
Eric Christopher [Tue, 25 Aug 2015 13:45:28 +0000 (13:45 +0000)]
Rewrite the PPC target feature handling to more resemble other targets.

This involved specializing handleUserFeatures so that we could perform
diagnostics on -only- user supplied features and migrating the rest of
the initialization functions to set features based on enabling and disabling
full feature sets. No functional change intended.

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

9 years agoExtract handling of user defined features into a function so we can
Eric Christopher [Tue, 25 Aug 2015 13:45:24 +0000 (13:45 +0000)]
Extract handling of user defined features into a function so we can
specialize it on the targets.

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

9 years agoclang-format: Add space before member function reference qualifiers.
Daniel Jasper [Tue, 25 Aug 2015 13:40:51 +0000 (13:40 +0000)]
clang-format: Add space before member function reference qualifiers.

Before:
  SomeType MemberFunction(const Deleted &)&;

After:
  SomeType MemberFunction(const Deleted &) &;

Seems to be much more common.

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

9 years agoRevert r245923 since it breaks mingw.
Michael Kuperstein [Tue, 25 Aug 2015 11:42:31 +0000 (11:42 +0000)]
Revert r245923 since it breaks mingw.

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

9 years ago[X86] Expose the various _rot intrinsics on non-MS platforms
Michael Kuperstein [Tue, 25 Aug 2015 07:21:33 +0000 (07:21 +0000)]
[X86] Expose the various _rot intrinsics on non-MS platforms

_rotl, _rotwl and _lrotl (and their right-shift counterparts) are official x86
intrinsics, and should be supported regardless of environment. This is in contrast
to _rotl8, _rotl16, and _rotl64 which are MS-specific.

Note that the MS documentation for _lrotl is different from the Intel
documentation. Intel explicitly documents it as a 64-bit rotate, while for MS,
since sizeof(unsigned long) for MSVC is always 4, a 32-bit rotate is implied.

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

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

9 years ago[ARM NEON] Remove the old AArch64 vset_lane tests. NFC.
Ahmed Bougacha [Tue, 25 Aug 2015 01:00:05 +0000 (01:00 +0000)]
[ARM NEON] Remove the old AArch64 vset_lane tests. NFC.

They are now properly tested, since r245901.

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

9 years agoReimplement the PPC explicit option checking to be a bit more obvious
Eric Christopher [Tue, 25 Aug 2015 00:59:11 +0000 (00:59 +0000)]
Reimplement the PPC explicit option checking to be a bit more obvious
that we're looking for conflicting options and give an explanation.

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

9 years ago[clang-cl] Only respect /Oy- for x86_32
David Majnemer [Tue, 25 Aug 2015 00:46:45 +0000 (00:46 +0000)]
[clang-cl] Only respect /Oy- for x86_32

The /Oy- flag should have no effect for 64-bit X86, it has reliable
unwind tables.

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

9 years agoRevert "broken test. uses system ld.gold"
Derek Schuff [Mon, 24 Aug 2015 23:53:30 +0000 (23:53 +0000)]
Revert "broken test. uses system ld.gold"
We should check in a basic_nacl_tree that works and also fix --sysroot

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

9 years agobroken test. uses system ld.gold
Derek Schuff [Mon, 24 Aug 2015 23:53:28 +0000 (23:53 +0000)]
broken test. uses system ld.gold

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

9 years agoUse GetLinkerPath utility function to find linker for NaCl toolchain
Derek Schuff [Mon, 24 Aug 2015 23:53:25 +0000 (23:53 +0000)]
Use GetLinkerPath utility function to find linker for NaCl toolchain

Summary:
This is more consistent with other targets and also makes the -fuse-ld
flag work.

Reviewers: jvoung

Subscribers: llvm-commits

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

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

9 years ago[ARM NEON] Use CGF cached Types instead of llvm::Type::get. NFC.
Ahmed Bougacha [Mon, 24 Aug 2015 23:47:29 +0000 (23:47 +0000)]
[ARM NEON] Use CGF cached Types instead of llvm::Type::get. NFC.

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

9 years ago[ARM NEON] Replace redundant code with a new GetFloatNeonType. NFC.
Ahmed Bougacha [Mon, 24 Aug 2015 23:41:31 +0000 (23:41 +0000)]
[ARM NEON] Replace redundant code with a new GetFloatNeonType. NFC.

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

9 years ago[ARM NEON] Add missing AArch64 vget tests.
Ahmed Bougacha [Mon, 24 Aug 2015 23:34:25 +0000 (23:34 +0000)]
[ARM NEON] Add missing AArch64 vget tests.

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

9 years ago[modules] Remove unnecessary deserialization of fully-external HeaderFileInfos for...
Richard Smith [Mon, 24 Aug 2015 21:59:32 +0000 (21:59 +0000)]
[modules] Remove unnecessary deserialization of fully-external HeaderFileInfos for all files we've seen in this compilation.

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

9 years ago[MS ABI] Don't emit stackrestore in cleanups
David Majnemer [Mon, 24 Aug 2015 21:34:21 +0000 (21:34 +0000)]
[MS ABI] Don't emit stackrestore in cleanups

The stackrestore intrinsic isn't meaningful inside of a cleanup funclet.

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

9 years agoRevert r245866.
Akira Hatanaka [Mon, 24 Aug 2015 20:30:57 +0000 (20:30 +0000)]
Revert r245866.

This commit was causing buildbot failures.

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

9 years ago[libclang] For convenience to clients, make sure that nullability and __kindof annota...
Argyrios Kyrtzidis [Mon, 24 Aug 2015 19:50:45 +0000 (19:50 +0000)]
[libclang] For convenience to clients, make sure that nullability and __kindof annotations do not hide
the underlying type.

rdar://22063577

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

9 years ago[ARM] Error out on apple darwin platforms if float-abi is "hard".
Akira Hatanaka [Mon, 24 Aug 2015 19:50:35 +0000 (19:50 +0000)]
[ARM] Error out on apple darwin platforms if float-abi is "hard".

Error out if the user tries to use float-abi="hard" since it isn't
supported on darwin platforms. Previously clang issued no warnings or
erros and just passed the option to the backend, which had no effect on
code generation for targets using apcs.

rdar://problem/22257950

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

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

9 years agoFixing some copy-pasta comments; NFC.
Aaron Ballman [Mon, 24 Aug 2015 18:50:01 +0000 (18:50 +0000)]
Fixing some copy-pasta comments; NFC.

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

9 years agoclang-format: Always allow break after leading annotations.
Daniel Jasper [Mon, 24 Aug 2015 15:10:01 +0000 (15:10 +0000)]
clang-format: Always allow break after leading annotations.

Before:
  DEPRECATED("Use NewClass::NewFunction instead.") int OldFunction(
  const string &parameter) {}

Could not be formatted at all, as clang-format would both require and
disallow the break before "int".

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

9 years agoclang-format: Make formatting of member function reference qualifiers
Daniel Jasper [Mon, 24 Aug 2015 14:28:08 +0000 (14:28 +0000)]
clang-format: Make formatting of member function reference qualifiers
more consistent.

Before:
  SomeType MemberFunction(const Deleted &)&&;
  SomeType MemberFunction(const Deleted &) && { ... }

After:
  SomeType MemberFunction(const Deleted &)&&;
  SomeType MemberFunction(const Deleted &)&& { ... }

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

9 years agoclang-format: Properly handle braced lists in macros.
Daniel Jasper [Mon, 24 Aug 2015 13:23:37 +0000 (13:23 +0000)]
clang-format: Properly handle braced lists in macros.

Before:
  #define A    \
      { a, a } \
      ,

After:
  #define A {a, a},

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

9 years ago[AArch64] Define the macro __ARM_FP16_ARGS
Keith Walker [Mon, 24 Aug 2015 10:11:14 +0000 (10:11 +0000)]
[AArch64] Define the macro __ARM_FP16_ARGS

The ACLE (ARM C Language Extensions) 2.0 defines that the predefined macro
__ARM_FP16_ARGS should be defined if __fp16 can be used as an argument and
result.

The support for __fp16 to be used as an argument and result is already
implemented for AArch64 so this change is just adding the missing macro.

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

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

9 years ago[OPENMP] Info about OpenMP Support in Users Manual, NFC.
Alexey Bataev [Mon, 24 Aug 2015 05:31:10 +0000 (05:31 +0000)]
[OPENMP] Info about OpenMP Support in Users Manual, NFC.
Differential Revision: http://reviews.llvm.org/D12152

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

9 years ago[modules] If local submodule visibility is disabled, don't bother checking
Richard Smith [Mon, 24 Aug 2015 03:38:11 +0000 (03:38 +0000)]
[modules] If local submodule visibility is disabled, don't bother checking
whether the owning module of a hidden declaration is visible -- it can't be.

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

9 years ago[modules] Stop updating all identifiers when writing a module. This is
Richard Smith [Mon, 24 Aug 2015 03:33:22 +0000 (03:33 +0000)]
[modules] Stop updating all identifiers when writing a module. This is
unnecessary in C++ modules (where we don't need the identifiers for their
Decls) and expensive.

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

9 years ago[test] Fix typos in a few tests (NFC)
Vedant Kumar [Sun, 23 Aug 2015 18:53:59 +0000 (18:53 +0000)]
[test] Fix typos in a few tests (NFC)

Patch by Kai Zhao!

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

9 years agoAdded missing tests for SSE41 pmovsx/pmovzx extension intrinsics
Simon Pilgrim [Sun, 23 Aug 2015 16:19:38 +0000 (16:19 +0000)]
Added missing tests for SSE41 pmovsx/pmovzx extension intrinsics

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

9 years agoAdd a missing 'classof' to AST Node TypoExpr to identify its 'Kind'.
Faisal Vali [Sun, 23 Aug 2015 13:14:42 +0000 (13:14 +0000)]
Add a missing 'classof' to AST Node TypoExpr to identify its 'Kind'.

I'm not sure why TypoExpr had its classof left out - but I expect every AST node should fulfill the 'contract of classof' (http://llvm.org/docs/HowToSetUpLLVMStyleRTTI.html).

There should be no functionality change.  I just happened to notice it was missing, while messing around with something else.

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

9 years agoChanges missed from r245810
Serge Pavlov [Sun, 23 Aug 2015 11:09:40 +0000 (11:09 +0000)]
Changes missed from r245810

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

9 years agoInstantiate function declarations in instantiated functions.
Serge Pavlov [Sun, 23 Aug 2015 10:22:28 +0000 (10:22 +0000)]
Instantiate function declarations in instantiated functions.

If a function declaration is found inside a template function as in:

    template<class T> void f() {
      void g(int x = T::v) except(T::w);
    }

it must be instantiated along with the enclosing template function,
including default arguments and exception specification.

Together with the patch committed in r240974 this implements DR1484.

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

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