]> granicus.if.org Git - clang/log
clang
10 years agoFix typos in carries_dependency docs
Reid Kleckner [Wed, 30 Apr 2014 18:50:03 +0000 (18:50 +0000)]
Fix typos in carries_dependency docs

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

10 years agoSema: Implement DR477
David Majnemer [Wed, 30 Apr 2014 18:24:01 +0000 (18:24 +0000)]
Sema: Implement DR477

Summary: Friend declarations shouldn't mention explicit or virtual.

Reviewers: rsmith

Subscribers: cfe-commits

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

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

10 years agoWhen typo-correcting a member using declaration, don't exclude member templates.
Richard Smith [Wed, 30 Apr 2014 18:15:00 +0000 (18:15 +0000)]
When typo-correcting a member using declaration, don't exclude member templates.

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

10 years agoWhen typo-correcting a member using-declaration, only consider members of base classes.
Richard Smith [Wed, 30 Apr 2014 18:03:21 +0000 (18:03 +0000)]
When typo-correcting a member using-declaration, only consider members of base classes.

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

10 years agoFix crash if typo correction corrects a member using-declaration to a
Richard Smith [Wed, 30 Apr 2014 17:40:35 +0000 (17:40 +0000)]
Fix crash if typo correction corrects a member using-declaration to a
non-member declaration. Patch by Dinesh Dwivedi!

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

10 years ago__thread: Move constant init check to CheckCompleteVariableDeclaration
Reid Kleckner [Wed, 30 Apr 2014 17:10:18 +0000 (17:10 +0000)]
__thread: Move constant init check to CheckCompleteVariableDeclaration

We were emitting dynamic initializers for __thread variables if there
was no explicit initializer, as in this test case:

struct S { S(); };
__thread S s;

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

10 years ago-Wunused-parameter: Don't fire on defaulted or deleted functions
Reid Kleckner [Wed, 30 Apr 2014 16:31:28 +0000 (16:31 +0000)]
-Wunused-parameter: Don't fire on defaulted or deleted functions

Patch by Dinesh Dwivedi!

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

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

10 years agoAndroid uses -fpic for arm64 as well.
Logan Chien [Wed, 30 Apr 2014 12:18:12 +0000 (12:18 +0000)]
Android uses -fpic for arm64 as well.

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

10 years agoAdd a test for big-endian NEON on ARM64.
James Molloy [Wed, 30 Apr 2014 12:12:45 +0000 (12:12 +0000)]
Add a test for big-endian NEON on ARM64.

The enabled test #includes <arm_neon.h>, which is sufficient to test all
the code in r207624.

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

10 years ago[ARM64] Port remaining relevant AArch64 clang tests over to ARM64
Bradley Smith [Wed, 30 Apr 2014 10:52:05 +0000 (10:52 +0000)]
[ARM64] Port remaining relevant AArch64 clang tests over to ARM64

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

10 years ago[ARM64] Add arm64_be where it was accidentally missed from a bunch of if-conditions.
James Molloy [Wed, 30 Apr 2014 10:11:40 +0000 (10:11 +0000)]
[ARM64] Add arm64_be where it was accidentally missed from a bunch of if-conditions.

I think this is the last commit for ARM64 big endian in clang. This commit makes
arm_neon.h compile correctly.

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

10 years agoSimplify test. No functional change intended.
Andrea Di Biagio [Wed, 30 Apr 2014 10:04:58 +0000 (10:04 +0000)]
Simplify test. No functional change intended.

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

10 years agoAdd a triple to new test.
Nico Weber [Wed, 30 Apr 2014 04:54:42 +0000 (04:54 +0000)]
Add a triple to new test.

NULL is just 0 on Windows, so the Wsentinel part of the test doesn't pass there.

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

10 years agoLet stddef.h respect __need_{wchar_t, size_t, NULL, ptrdiff_t, wint_t}.
Nico Weber [Wed, 30 Apr 2014 04:35:09 +0000 (04:35 +0000)]
Let stddef.h respect __need_{wchar_t, size_t, NULL, ptrdiff_t, wint_t}.

glibc expects that stddef.h only defines a single thing if either of these
defines is set.  For example, before this change, a C file containing

  #include <stdlib.h>
  int ptrdiff_t = 0;

would compile with gcc but not with clang. Now it compiles with clang too.

This also fixes PR12997, where older versions of the Linux headers would define
NULL incorrectly, and glibc would define __need_NULL and expect stddef.h to
redefine NULL with the correct definition.

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

10 years agoDefer loading any pending update records until we've finished deserializing.
Richard Smith [Wed, 30 Apr 2014 02:24:17 +0000 (02:24 +0000)]
Defer loading any pending update records until we've finished deserializing.
This fixes a bug where an update record causes us to load an entity that refers
to an entity we've not finished loading yet, resulting in badness.

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

10 years agoDrop non-cfi assembly support from clang.
Rafael Espindola [Wed, 30 Apr 2014 02:22:09 +0000 (02:22 +0000)]
Drop non-cfi assembly support from clang.

After this patch clang will ignore -fdwarf2-cfi-asm and -ffno-dwarf2-cfi-asm and
always print assembly that uses cfi directives.

In llvm, MC itself supports cfi since the end of 2010 (support started
in r119972, is reported in the 2.9 release notes).

In binutils the support has been around for much longer. It looks like
support started to be added in May 2003. It is available in 2.15
(31-Aug-2011, 2.14 is from 12-Jun-2003).

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

10 years agoAdd test case for revision 207575 to verify that on Windows, clang doesn't
Andrea Di Biagio [Tue, 29 Apr 2014 20:19:13 +0000 (20:19 +0000)]
Add test case for revision 207575 to verify that on Windows, clang doesn't
crash with an assertion failure when 'nul' is passed in input.

Modified clang/test/lit.py to add feature 'system-windows' if
`platform.system()` returns 'Windows'.

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

10 years agoscanf analysis: handle scanlists that start with ^] (PR19559)
Hans Wennborg [Tue, 29 Apr 2014 19:42:27 +0000 (19:42 +0000)]
scanf analysis: handle scanlists that start with ^] (PR19559)

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

10 years ago[PCH/Modules] Don't tie TargetOptions::LinkerVersion to a module/PCH, it's a driver...
Argyrios Kyrtzidis [Tue, 29 Apr 2014 18:45:01 +0000 (18:45 +0000)]
[PCH/Modules] Don't tie TargetOptions::LinkerVersion to a module/PCH, it's a driver only thing and doesn't affect any language/preprocessor/etc. semantics.

rdar://16714526

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

10 years agoAndroid uses -fpic for aarch64.
Logan Chien [Tue, 29 Apr 2014 18:18:58 +0000 (18:18 +0000)]
Android uses -fpic for aarch64.

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

10 years ago[analyzer] Improve test from r207486.
Jordan Rose [Tue, 29 Apr 2014 17:08:17 +0000 (17:08 +0000)]
[analyzer] Improve test from r207486.

The constructor that comes right before a variable declaration in the CFG might
not be the initialization of that variable. Previously, we just checked that
the variable's initializer expression was different from the construction
expression, but forgot to see whether the variable had an initializer expression
at all.

Thanks for the prompting, David.

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

10 years ago[analyzer] Don't assert when combining using .* on a temporary.
Jordan Rose [Tue, 29 Apr 2014 17:08:12 +0000 (17:08 +0000)]
[analyzer] Don't assert when combining using .* on a temporary.

While we don't model pointer-to-member operators yet (neither .* nor ->*),
CallAndMessageChecker still checks to make sure the 'this' object is not
null or undefined first. However, it also expects that the object should
always have a valid MemRegion, something that's generally important elsewhere
in the analyzer as well. Ensure this is true ahead of time, just like we do
for member access.

PR19531

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

10 years agoReapply r207477 and r207479 without cyclic dependency
Ben Langmuir [Tue, 29 Apr 2014 16:25:26 +0000 (16:25 +0000)]
Reapply r207477 and r207479 without cyclic dependency

Fixed by moving ProcessWarningOptions from Frontend into Basic. All of
the dependencies for ProcessWarningOptions were already in Basic, so
this was a small change.

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

10 years agoObjective-C. Improve diagnosis of bridging types.
Fariborz Jahanian [Tue, 29 Apr 2014 16:12:56 +0000 (16:12 +0000)]
Objective-C. Improve diagnosis of bridging types.
// rdar://16737117

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

10 years agoclang-format: Don't bin-pack text-proto-formatted options.
Daniel Jasper [Tue, 29 Apr 2014 15:54:14 +0000 (15:54 +0000)]
clang-format: Don't bin-pack text-proto-formatted options.

Before:
  repeated double value = 1
      [(aaaaaaa.aaaaaaaaa) = {aaaaaaaaaaaaaaaaAAAAAAAAAA,
                              bbbbbbb: BBBB, bbbb: BBB}];

After:
  repeated double value = 1
      [(aaaaaaa.aaaaaaaaa) = {aaaaaaaaaaaaaaaaAAAAAAAAAA,
                              bbbbbbb: BBBB,
                              bbbb: BBB}];

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

10 years agoclang-format: Remove accidentally added debug output.
Daniel Jasper [Tue, 29 Apr 2014 15:35:28 +0000 (15:35 +0000)]
clang-format: Remove accidentally added debug output.

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

10 years agoclang-format: Allow single-line function in WebKit style.
Daniel Jasper [Tue, 29 Apr 2014 14:05:20 +0000 (14:05 +0000)]
clang-format: Allow single-line function in WebKit style.

Before:
  void f() {
      return; }

After:
  void f() { return; }

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

10 years agoAdd comments regarding isPIEDefault usage for r207520
Alexey Volkov [Tue, 29 Apr 2014 12:07:34 +0000 (12:07 +0000)]
Add comments regarding isPIEDefault usage for r207520

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

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

10 years agoPass -pie to linker when generating executable on Android
Alexey Volkov [Tue, 29 Apr 2014 10:25:20 +0000 (10:25 +0000)]
Pass -pie to linker when generating executable on Android
This fixes problem with LTO on Android.

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

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

10 years agoAST: Fix visibility calculation for VarTemplateSpecializationDecl
David Majnemer [Tue, 29 Apr 2014 07:32:26 +0000 (07:32 +0000)]
AST: Fix visibility calculation for VarTemplateSpecializationDecl

It is possible that a variable template specialization might not have a
VisibilityAttr attached to it while the template that it specializes
does, in fact, have one.

We should consider the template in such cases.

This fixes PR19597.

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

10 years agoRevert r207477 (and r207479), "Check -Werror options during module validation"
NAKAMURA Takumi [Tue, 29 Apr 2014 06:58:59 +0000 (06:58 +0000)]
Revert r207477 (and r207479), "Check -Werror options during module validation"

It tried to introduce cyclic dependencies. Serialization shouldn't depend on Frontend, since Frontend depends on Serialization.

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

10 years agoCodeGen: Reference temporaries inherit visibility
David Majnemer [Tue, 29 Apr 2014 06:18:53 +0000 (06:18 +0000)]
CodeGen: Reference temporaries inherit visibility

Reference temporaries inherited many properties from the variable that
they correspond to but visibility wasn't one of them.

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

10 years agoMake test independent of label. Thanks to Richard Smith for catching this!
Adrian Prantl [Tue, 29 Apr 2014 02:27:33 +0000 (02:27 +0000)]
Make test independent of label. Thanks to Richard Smith for catching this!

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

10 years agoRun this test through instnamer to stop it failing on non-asserts clang builds.
Richard Smith [Tue, 29 Apr 2014 02:18:35 +0000 (02:18 +0000)]
Run this test through instnamer to stop it failing on non-asserts clang builds.

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

10 years ago[analyzer] Don't crash when a construction is followed by an uninitialized variable.
Jordan Rose [Tue, 29 Apr 2014 01:56:12 +0000 (01:56 +0000)]
[analyzer] Don't crash when a construction is followed by an uninitialized variable.

This could happen due to unfortunate CFG coincidences.

PR19579

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

10 years agoscan-build: Don't use realpath when the user provides an explicit path.
Jordan Rose [Tue, 29 Apr 2014 01:37:19 +0000 (01:37 +0000)]
scan-build: Don't use realpath when the user provides an explicit path.

PR19583

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

10 years agoRevert r207482; I fail at reading IRC.
Nico Weber [Tue, 29 Apr 2014 01:25:49 +0000 (01:25 +0000)]
Revert r207482; I fail at reading IRC.

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

10 years agoLet stddef.h redefine NULL if __need_NULL is set, as needed by glibc, PR12997.
Nico Weber [Tue, 29 Apr 2014 01:19:21 +0000 (01:19 +0000)]
Let stddef.h redefine NULL if __need_NULL is set, as needed by glibc, PR12997.

See the bug and the cfe-commits thread "[patch] Let stddef.h redefine NULL if
__need_NULL is set" for discussion.

Fixes PR12997 and is similar to the __need_wint_t bits already in this file.

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

10 years agoDebug info: Improve line table for functions with cleanups an early exit
Adrian Prantl [Tue, 29 Apr 2014 01:07:59 +0000 (01:07 +0000)]
Debug info: Improve line table for functions with cleanups an early exit
and no return expr at the end of the function.
The "function has only simple returns" check in FinishFunction tests
whether the number of simple return exprs equals the number of return
exprs, but so far a fallthrough at the end of a function was not counted
as a return, which would result in cleanup code being associated with the
wrong source line.

rdar://problem/16733984.

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

10 years agoAdd missing triple to make -isysroot work
Ben Langmuir [Tue, 29 Apr 2014 01:04:34 +0000 (01:04 +0000)]
Add missing triple to make -isysroot work

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

10 years ago[analyzer] Clean up the lists of current and potential checkers.
Jordan Rose [Tue, 29 Apr 2014 00:46:17 +0000 (00:46 +0000)]
[analyzer] Clean up the lists of current and potential checkers.

Patch by Anton Yartsev, modified by me.

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

10 years agoCheck -Werror options during module validation
Ben Langmuir [Tue, 29 Apr 2014 00:36:53 +0000 (00:36 +0000)]
Check -Werror options during module validation

This patch checks whether the diagnostic options that could lead to
errors (principally -Werror) are consistent between when a module was
built and when it is loaded.  If there are new -Werror flags, then the
module is rebuilt.  In order to canonicalize the options we do this
check at the level of the constructed DiagnosticsEngine, which contains
the final set of diag to diagnostic level mappings.  Currently we only
rebuild with the new diagnostic options, but we intend to refine this in
the future to include the union of the new and old flags, since we know
the old ones did not cause errors.  System modules are only rebuilt when
-Wsystem-headers is enabled.

One oddity is that unlike checking language options, we don’t perform
this diagnostic option checking when loading from a precompiled header.
The reason for this is that the compiler cannot rebuild the PCH, so
anything that requires it to be rebuilt effectively leaks into the build
system.  And in this case, that would mean the build system
understanding the complex relationship between diagnostic options and
the underlying diagnostic mappings, which is unreasonable.  Skipping the
check is safe, because these options do not affect the generated AST.
You simply won’t get new build errors due to changed -Werror options
automatically, which is also true for non-module cases.

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

10 years agoLLVM supports TLS on Windows and we can use it from Clang
Reid Kleckner [Tue, 29 Apr 2014 00:11:30 +0000 (00:11 +0000)]
LLVM supports TLS on Windows and we can use it from Clang

Patch by Martell Malone!

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

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

10 years agoWhen Driver::generateCompilationDiagnostics is filtering the list of
Paul Robinson [Mon, 28 Apr 2014 22:24:44 +0000 (22:24 +0000)]
When Driver::generateCompilationDiagnostics is filtering the list of
inputs to the preprocessor, check for invalid types first because not
all linker inputs have an option value to retrieve.

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

10 years agoMove all CUDA testing inputs to Inputs/ subdirectory inside the tests.
Eli Bendersky [Mon, 28 Apr 2014 22:21:28 +0000 (22:21 +0000)]
Move all CUDA testing inputs to Inputs/ subdirectory inside the tests.

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

10 years agoCodeGen: Fix linkage of reference temporaries
David Majnemer [Mon, 28 Apr 2014 22:17:59 +0000 (22:17 +0000)]
CodeGen: Fix linkage of reference temporaries

Summary:
A reference temporary should inherit the linkage of the variable it
initializes.  Otherwise, we may hit cases where a reference temporary
wouldn't have the same value in all translation units.

Reviewers: rsmith

Subscribers: cfe-commits

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

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

10 years ago[cleanup] Fix an 80-column violation
Justin Bogner [Mon, 28 Apr 2014 20:58:58 +0000 (20:58 +0000)]
[cleanup] Fix an 80-column violation

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

10 years ago[driver] Disable the slp vectorizer at -O0, -O1, and -Oz. This mirrors the
Chad Rosier [Mon, 28 Apr 2014 19:30:57 +0000 (19:30 +0000)]
[driver] Disable the slp vectorizer at -O0, -O1, and -Oz.  This mirrors the
behavior of the loop vectorizer, which is enabled at -O2, -O3, -O4, -Ofast
and -Os.
PR19568

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

10 years agoRemove unused using statement.
Nico Weber [Mon, 28 Apr 2014 17:54:37 +0000 (17:54 +0000)]
Remove unused using statement.

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

10 years agoRenaming range-based for loop variables so they don't appear iterator-like.
Aaron Ballman [Mon, 28 Apr 2014 14:56:59 +0000 (14:56 +0000)]
Renaming range-based for loop variables so they don't appear iterator-like.

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

10 years ago[C++11] Converting to range-based for loops. No functional changes intended.
Aaron Ballman [Mon, 28 Apr 2014 13:01:32 +0000 (13:01 +0000)]
[C++11] Converting to range-based for loops. No functional changes intended.

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

10 years agoclang-format: Improve binary operator detection.
Daniel Jasper [Mon, 28 Apr 2014 09:19:28 +0000 (09:19 +0000)]
clang-format: Improve binary operator detection.

Before:
  *(int *)(p &~3UL) = 0;

After:
  *(int *)(p & ~3UL) = 0;

This fixes llvm.org/PR19464.

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

10 years agoclang-format: Fixes spaces in case statements.
Daniel Jasper [Mon, 28 Apr 2014 07:48:36 +0000 (07:48 +0000)]
clang-format: Fixes spaces in case statements.

This fixes llvm.org/PR19482.

Before:
  switch (a) {
    case(B) :
      return;
  }

After:
  switch (a) {
    case (B):
      return;
  }

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

10 years ago[ARM64]Fix a bug cannot select UQSHL/SQSHL with constant i64 shift amount.
Hao Liu [Mon, 28 Apr 2014 07:36:12 +0000 (07:36 +0000)]
[ARM64]Fix a bug cannot select UQSHL/SQSHL with constant i64 shift amount.

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

10 years agoclang-format: Don't wrap after @interface.
Daniel Jasper [Mon, 28 Apr 2014 07:34:48 +0000 (07:34 +0000)]
clang-format: Don't wrap after @interface.

This fixes llvm.org/PR19450.

Before:
  @interface
  BookmarkHomeHandsetViewController ()<BookmarkAllCollectionViewDelegate,
                                       BookmarkFolderCollectionViewDelegate,
                                       BookmarkMenuViewControllerDelegate,
                                       BookmarkSearchViewControllerDelegate> {
  }

After:
  @interface aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa ()<
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
      aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa> {
  }

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

10 years agoFollow-up to r207071: Let newFrontendActionFactory() return a unique_ptr.
Nico Weber [Mon, 28 Apr 2014 04:57:14 +0000 (04:57 +0000)]
Follow-up to r207071: Let newFrontendActionFactory() return a unique_ptr.

This exposed a leak, fix that.

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

10 years agolibclang: split out the documentation comment API
Alp Toker [Mon, 28 Apr 2014 02:39:27 +0000 (02:39 +0000)]
libclang: split out the documentation comment API

It's possible that the "comment AST" may be replaced or split out in the
midterm, any anyway this makes the headers easier to read.

Developers don't currently need to include "clang-c/Documentation.h" explicitly
and there's no macro to test for availability yet.

The raw comment and brief comment accessors have been kept in Index.h though
brief support may also move here as a separate proposal.

This is not a deprecation, just a gentle separation of concerns as we look to
simplify the built-in representation of comment nodes and support external
comment processors.

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

10 years ago[objcmt] Revert r191796, it's not needed anymore.
Argyrios Kyrtzidis [Mon, 28 Apr 2014 02:38:51 +0000 (02:38 +0000)]
[objcmt] Revert r191796, it's not needed anymore.

rdar://16223810

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

10 years agoCodeGen: remove an unused variable
Saleem Abdulrasool [Mon, 28 Apr 2014 02:29:11 +0000 (02:29 +0000)]
CodeGen: remove an unused variable

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

10 years ago[SemaCXX] Silence -Wconstant-logical-operand if the operand is a 0/1 from a macro.
Argyrios Kyrtzidis [Mon, 28 Apr 2014 00:20:16 +0000 (00:20 +0000)]
[SemaCXX] Silence -Wconstant-logical-operand if the operand is a 0/1 from a macro.

Libraries specify enabled/disabled features using macro defs of 0/1, in such cases the -Wconstant-logical-operand
is noise.

rdar://15410291

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

10 years ago[Index/DocComments] When cloning a full comment, pick the template parameters from...
Argyrios Kyrtzidis [Sun, 27 Apr 2014 22:53:03 +0000 (22:53 +0000)]
[Index/DocComments] When cloning a full comment, pick the template parameters from the original FullComment,
if the parameters are not already set (e.g. because it is a typedef).

Fixes crash of rdar://16128173

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

10 years agoremove less relevant information + about packaging/Mac OS X + link to cfe-dev
Sylvestre Ledru [Sun, 27 Apr 2014 15:17:15 +0000 (15:17 +0000)]
remove less relevant information + about packaging/Mac OS X + link to cfe-dev

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

10 years agoRemove no longer relevant information in the gcc/llvm comparison page + minor updates
Sylvestre Ledru [Sun, 27 Apr 2014 15:02:05 +0000 (15:02 +0000)]
Remove no longer relevant information in the gcc/llvm comparison page + minor updates

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

10 years agoremove useless code
Sylvestre Ledru [Sun, 27 Apr 2014 14:57:31 +0000 (14:57 +0000)]
remove useless code

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

10 years agoRemove deprecated information about performances:
Sylvestre Ledru [Sun, 27 Apr 2014 14:54:11 +0000 (14:54 +0000)]
Remove deprecated information about performances:
* It is better if we leave third parties to do "independent" benchmark.
* We compare Clang (version unspecified) with gcc 4.0 or 4.2.
* The graphs have not been updated for a while.
* Clang is well known now. I don't think we still need to explain why
Clang is great.

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

10 years agoclang-format: Fix bug when aligning trailing /**/-comments in macros.
Daniel Jasper [Sun, 27 Apr 2014 10:03:19 +0000 (10:03 +0000)]
clang-format: Fix bug when aligning trailing /**/-comments in macros.

Previously this could lead to a column limit violation with the
required escaped newlines.

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

10 years agoFix the method len of the CompletionString object. Patch by Christopher Greene
Sylvestre Ledru [Sun, 27 Apr 2014 04:42:55 +0000 (04:42 +0000)]
Fix the method len of the CompletionString object. Patch by Christopher Greene

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

10 years agoc-arcmt-test/Makefile: Update USEDLIBS for -static.
NAKAMURA Takumi [Sun, 27 Apr 2014 03:40:51 +0000 (03:40 +0000)]
c-arcmt-test/Makefile: Update USEDLIBS for -static.

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

10 years ago[SemaObjC] Fix ObjCInterfaceDecl::inheritsDesignatedInitializers(), if there are no
Argyrios Kyrtzidis [Sat, 26 Apr 2014 21:28:41 +0000 (21:28 +0000)]
[SemaObjC] Fix ObjCInterfaceDecl::inheritsDesignatedInitializers(), if there are no
designated initializers in the super class hierarchy then it should return false.

rdar://16692535

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

10 years ago[Sema] Adjust Sema::getCurBlock()/getCurLambda() to take into account that we may...
Argyrios Kyrtzidis [Sat, 26 Apr 2014 18:29:13 +0000 (18:29 +0000)]
[Sema] Adjust Sema::getCurBlock()/getCurLambda() to take into account that we may have
switch CurContext due to class template instantiation.

Fixes crash of the included test case.
rdar://16527205

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

10 years agolibclang: remove 'CXDiagnostic_Remark'
Alp Toker [Sat, 26 Apr 2014 14:43:53 +0000 (14:43 +0000)]
libclang: remove 'CXDiagnostic_Remark'

The change was landed without review or test cases.

It trivially broke almost any stable application checking for Severity >=
CXDiagnostic_Error or indeed any other kind of severity comparison upon
encountering a 'remark'.

Mapped to CXDiagnostic_Warning until a workable solution is proposed to the
list that preserves API stability.

(It's also not clear why the rest of r202475 wasn't simply implemented as a
modifier to the existing 'warning' level.)

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

10 years agoAdd mangling for attribute enable_if. The demangling patch for libcxxabi is still...
Nick Lewycky [Sat, 26 Apr 2014 00:14:00 +0000 (00:14 +0000)]
Add mangling for attribute enable_if. The demangling patch for libcxxabi is still in review.

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

10 years agoFixed Assert In CGRecordLowering
Warren Hunt [Fri, 25 Apr 2014 21:56:30 +0000 (21:56 +0000)]
Fixed Assert In CGRecordLowering
Prior to this patch, CGRecordLower assumed that virtual bases could not
be placed before the nvsize of an object.  This isn't true in Itanium
mode, virtual bases are placed at dsize rather than vnsize and in the
case of zero sized non-virtual bases nvsize can be larger than dsize.
This patch fixes CGRecordLowering to avoid an assert and to clip
bitfields properly in this case.  A test case is included.

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

10 years agoCodeGen: add __yield intrinsic for ARM
Saleem Abdulrasool [Fri, 25 Apr 2014 21:13:29 +0000 (21:13 +0000)]
CodeGen: add __yield intrinsic for ARM

The __yield intrinsic generates a hint instruction to indicate that the thread
is not performing any useful operations at the moment.  This is for
compatibility with MSVC, although, the intrinsic is also part of the ACLE, and
is enabled globally as a result.

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

10 years agoMake test pass on 32 bit architectures.
Benjamin Kramer [Fri, 25 Apr 2014 20:49:10 +0000 (20:49 +0000)]
Make test pass on 32 bit architectures.

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

10 years agoPrint detailed vector type information on diagnostics.
Benjamin Kramer [Fri, 25 Apr 2014 20:41:38 +0000 (20:41 +0000)]
Print detailed vector type information on diagnostics.

We never aka vector types because our attributed syntax for it is less
comprehensible than the typedefs. This leaves the user in the dark when
the typedef isn't named that well.

Example:
  v2s v; v4f w;
  w = v;

The naming in this cases isn't even that bad, but the error we give is
useless without looking up the actual typedefs.
t.c:6:5: error: assigning to 'v4f' from incompatible type 'v2s'

Now:
t.c:6:5: error: assigning to 'v4f' (vector of 4 'float' values) from
    incompatible type 'v2s' (vector of 2 'int' values)

We do this for all diagnostics that print a vector type.

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

10 years agoFix leak of GlobalModuleIndex::IdentifierIndex, found by LSan.
Nico Weber [Fri, 25 Apr 2014 19:45:23 +0000 (19:45 +0000)]
Fix leak of GlobalModuleIndex::IdentifierIndex, found by LSan.

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

10 years agoPR19558: don't produce an "unused variable" warning for a variable template partial...
Richard Smith [Fri, 25 Apr 2014 19:21:40 +0000 (19:21 +0000)]
PR19558: don't produce an "unused variable" warning for a variable template partial specialization.

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

10 years agoCodeGen: replace use of @llvm.arm.sevl with @llvm.arm.hint
Saleem Abdulrasool [Fri, 25 Apr 2014 17:25:46 +0000 (17:25 +0000)]
CodeGen: replace use of @llvm.arm.sevl with @llvm.arm.hint

Use the new generic @llvm.arm.hint hint intrinsic rather than the specialised
@llvm.arm.sevl hint instruction.

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

10 years agoCodeGen: Cleanup variable linkage calculation
David Majnemer [Fri, 25 Apr 2014 17:08:41 +0000 (17:08 +0000)]
CodeGen: Cleanup variable linkage calculation

Almost all linkage calculation for VarDecls occured inside of
GetLLVMLinkageVarDefinition except for static data members.  Centralize
the logic so that it can be more readily reused.

No functionality change.

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

10 years agoCodeGen: Refactor linkage/visibility calculation
David Majnemer [Fri, 25 Apr 2014 17:07:16 +0000 (17:07 +0000)]
CodeGen: Refactor linkage/visibility calculation

It turns out that linkage and visibility have rather similar logic for
both functions and non-variable globals.  Split the calculation out so
that both sides may share this code.

No functionality change.

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

10 years agoPush unique_ptr ownership of ASTUnits further back into their factories.
David Blaikie [Fri, 25 Apr 2014 17:01:33 +0000 (17:01 +0000)]
Push unique_ptr ownership of ASTUnits further back into their factories.

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

10 years agoclang-cl: /fallback only applies to C or C++ files
Hans Wennborg [Fri, 25 Apr 2014 16:44:17 +0000 (16:44 +0000)]
clang-cl: /fallback only applies to C or C++ files

We would previously hit an assert if using /fallback with an .ll file.

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

10 years agoclang-cl: pass -debug flag to the linker when compiling with debug info
Hans Wennborg [Fri, 25 Apr 2014 16:24:19 +0000 (16:24 +0000)]
clang-cl: pass -debug flag to the linker when compiling with debug info

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

10 years agoImprove ownership of ASTUnits in libTooling by using std::unique_ptr.
David Blaikie [Fri, 25 Apr 2014 14:49:37 +0000 (14:49 +0000)]
Improve ownership of ASTUnits in libTooling by using std::unique_ptr.

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

10 years agoRevert "Reland r206934 with a hopefully fixed test"
Rafael Espindola [Fri, 25 Apr 2014 13:29:03 +0000 (13:29 +0000)]
Revert "Reland r206934 with a hopefully fixed test"

This reverts commit r207155.
The test was still failing.

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

10 years agofix a test-only leak found by lsan, PR19521
Kostya Serebryany [Fri, 25 Apr 2014 12:58:42 +0000 (12:58 +0000)]
fix a test-only leak found by lsan, PR19521

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

10 years agoCodeGen: Avoid instrumenting implicit Decls more effectively
Justin Bogner [Fri, 25 Apr 2014 07:20:05 +0000 (07:20 +0000)]
CodeGen: Avoid instrumenting implicit Decls more effectively

We don't assign counters for implicit Decls, but we were emitting code
to increment the (non-existent) counters and adding empty counter
lists in the output. This fixes the checks in assignRegionCounters and
emitInstrumentationData to do the right thing, and adds an assert for
the pathological case of emitting zero counters.

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

10 years agobindings: expose C++ access specifiers
Saleem Abdulrasool [Fri, 25 Apr 2014 02:58:03 +0000 (02:58 +0000)]
bindings: expose C++ access specifiers

Expose the enum CX_CXXAccessSpecifier in the python bindings as a property of
the cursor.  If access specifier is not applicable to the node, return the
INVALID specifier rather than raising an exception.

Patch by Tamás Szeli!

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

10 years agoReland r206934 with a hopefully fixed test
Reid Kleckner [Thu, 24 Apr 2014 23:06:17 +0000 (23:06 +0000)]
Reland r206934 with a hopefully fixed test

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

10 years agoIf we see an explicit instantiation declaration or definition of a function
Richard Smith [Thu, 24 Apr 2014 22:45:46 +0000 (22:45 +0000)]
If we see an explicit instantiation declaration or definition of a function
after we've already instantiated a definition for the function, pass it to the
ASTConsumer again so that it knows the specialization kind has changed and can
update the function's linkage.

This only matters if we instantiate the definition of the function before we
reach the end of the TU; this can happen in at least three different ways:
C++11 constexpr functions, C++14 deduced return types, and functions
instantiated within modules.

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

10 years agoMicrosoftVTableContext: Don't leak VPtrInfos. Found by LSan, PR19522.
Nico Weber [Thu, 24 Apr 2014 19:52:12 +0000 (19:52 +0000)]
MicrosoftVTableContext: Don't leak VPtrInfos. Found by LSan, PR19522.

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

10 years agoFix a tiny test-only leak, found by LSan.
Nico Weber [Thu, 24 Apr 2014 19:04:10 +0000 (19:04 +0000)]
Fix a tiny test-only leak, found by LSan.

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

10 years agoIntrin.h: remove __rdtsc and __rdtscp declarations
Hans Wennborg [Thu, 24 Apr 2014 18:40:06 +0000 (18:40 +0000)]
Intrin.h: remove __rdtsc and __rdtscp declarations

Since r207132, these are defined in ia32intrin.h.

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

10 years ago[X86] Add Clang support for intrinsics __rdtsc and __rdtscp.
Andrea Di Biagio [Thu, 24 Apr 2014 18:26:35 +0000 (18:26 +0000)]
[X86] Add Clang support for intrinsics __rdtsc and __rdtscp.

This patch:
 1. Adds a definition for two new GCCBuiltins in BuiltinsX86.def:
   __builtin_ia32_rdtsc;
   __builtin_ia32_rdtscp;

 2. Replaces the already existing definition of intrinsic __rdtsc in
    ia32intrin.h with a simple call to the new GCC builtin __builtin_ia32_rdtsc.

 3. Adds a definition for the new intrinsic __rdtscp in ia32intrin.h

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

10 years agoSquelch leak found by LSan by handling missing switch case.
Jordan Rose [Thu, 24 Apr 2014 17:27:18 +0000 (17:27 +0000)]
Squelch leak found by LSan by handling missing switch case.

Also, use the enum type in the switch so this doesn't happen again.

PR19523

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

10 years ago[mips] Support 128-bit int in N32 ABI by overriding TargetInfo::hasInt128Type()
Daniel Sanders [Thu, 24 Apr 2014 16:05:26 +0000 (16:05 +0000)]
[mips] Support 128-bit int in N32 ABI by overriding TargetInfo::hasInt128Type()

Summary: The condition in the base class is rather strange. It says a target has the 128-bit integer type if the size of a pointer is >= 64-bits. N32 has 32-bit pointers but 64-bit integers. I'm a bit reluctant to change this for all targets so this patch makes the method virtual and overrides it for MIPS64.

Reviewers: atanasyan

Reviewed By: atanasyan

Subscribers: llvm-commits

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

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

10 years agoAArch64: update tests to new way of printing NEON lists.
Tim Northover [Thu, 24 Apr 2014 14:06:31 +0000 (14:06 +0000)]
AArch64: update tests to new way of printing NEON lists.

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

10 years agoCommentToXMLConverter: Don't use "default" to method(s). It is unavailable in msc17.
NAKAMURA Takumi [Thu, 24 Apr 2014 12:44:34 +0000 (12:44 +0000)]
CommentToXMLConverter: Don't use "default" to method(s). It is unavailable in msc17.

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

10 years ago[mips] Correct size_t and ptrdiff_t for N32.
Daniel Sanders [Thu, 24 Apr 2014 09:58:52 +0000 (09:58 +0000)]
[mips] Correct size_t and ptrdiff_t for N32.

Summary:
Correct size_t to be unsigned int and ptrdiff_t to be signed long. The types were the correct size before this change but
the exact type matters for name mangling and exception handling in C++.

Reviewers: atanasyan

Reviewed By: atanasyan

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

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