]> granicus.if.org Git - clang/log
clang
10 years agoR600: Add processor type for Mullins
Tom Stellard [Sat, 26 Jul 2014 01:05:20 +0000 (01:05 +0000)]
R600: Add processor type for Mullins

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

10 years agoRevert new test from 213993.
Bob Wilson [Sat, 26 Jul 2014 00:51:28 +0000 (00:51 +0000)]
Revert new test from 213993.

It requires an arm backend and also writes output in the test directory.

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

10 years agoImprove -UNDEBUG binary size. We don't need a different assert fail message for
Richard Smith [Sat, 26 Jul 2014 00:47:13 +0000 (00:47 +0000)]
Improve -UNDEBUG binary size. We don't need a different assert fail message for
each different enum value here.

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

10 years agoUse -enable-global-merge option to match llvm r210639. <rdar://problem/17803206>
Bob Wilson [Sat, 26 Jul 2014 00:37:28 +0000 (00:37 +0000)]
Use -enable-global-merge option to match llvm r210639. <rdar://problem/17803206>

llvm revision 210639 renamed the -global-merge backend option to
-enable-global-merge. This change simply updates clang to match that.

Patch by Steven Wu!

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

10 years agoclang/test/CodeGenCXX/cxx1y-variable-template-linkage.cpp: Appease -Asserts build.
NAKAMURA Takumi [Sat, 26 Jul 2014 00:28:09 +0000 (00:28 +0000)]
clang/test/CodeGenCXX/cxx1y-variable-template-linkage.cpp: Appease -Asserts build.

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

10 years agoMS ABI: Ensure 'this' is first for byval+sret methods
Reid Kleckner [Sat, 26 Jul 2014 00:12:26 +0000 (00:12 +0000)]
MS ABI: Ensure 'this' is first for byval+sret methods

Previously we were building up the inalloca struct in the usual pattern
of return type followed by arguments.  However, on Windows, 'this'
always precedes the 'sret' parameter, so we need to insert it into the
struct first as a special case.

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

10 years agoAdd test case for fix of linkage bug that miscompiled variable templates instantiated...
Larisse Voufo [Fri, 25 Jul 2014 23:58:13 +0000 (23:58 +0000)]
Add test case for fix of linkage bug that miscompiled variable templates instantiated from similarly named local types (cf. r212233)

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

10 years agoFix my broken test case in NDEBUG :(
Reid Kleckner [Fri, 25 Jul 2014 21:52:11 +0000 (21:52 +0000)]
Fix my broken test case in NDEBUG  :(

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

10 years agoFix my busted FileCheck invocation
Reid Kleckner [Fri, 25 Jul 2014 21:48:10 +0000 (21:48 +0000)]
Fix my busted FileCheck invocation

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

10 years agoMS ABI: Don't push destructor cleanups for aggregate parameters in thunks
Reid Kleckner [Fri, 25 Jul 2014 21:39:46 +0000 (21:39 +0000)]
MS ABI: Don't push destructor cleanups for aggregate parameters in thunks

The target method of the thunk will perform the cleanup.  This can't be
tested in 32-bit x86 yet because passing something by value would create
an inalloca, and we refuse to generate broken code for that.

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

10 years agoNow that PIC generation on PPC32 is supported, hook up linking support
Joerg Sonnenberger [Fri, 25 Jul 2014 20:57:24 +0000 (20:57 +0000)]
Now that PIC generation on PPC32 is supported, hook up linking support
for NetBSD.

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

10 years agoRevert r213437
Warren Hunt [Fri, 25 Jul 2014 20:52:51 +0000 (20:52 +0000)]
Revert r213437
We no longer plan to use __except_hander3 and rather use custom
personality functions per __try block.

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

10 years agoObjective-C. Warn if protocol used in an @protocol
Fariborz Jahanian [Fri, 25 Jul 2014 19:45:01 +0000 (19:45 +0000)]
Objective-C. Warn if protocol used in an @protocol
expression is a forward declaration as this results
in undefined behavior. rdar://17768630

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

10 years agoReturn a StringRef in getDefaultUniversalArchName.
Rafael Espindola [Fri, 25 Jul 2014 19:22:51 +0000 (19:22 +0000)]
Return a StringRef in getDefaultUniversalArchName.

Patch by Stephen Drake.

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

10 years agoclang-cl: Add support for /Zp
David Majnemer [Fri, 25 Jul 2014 17:30:10 +0000 (17:30 +0000)]
clang-cl: Add support for /Zp

CL's /Zp flag is analogous to GCC's -fpack-struct, it controls the
default maximum alignment of records.

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

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

10 years ago[Driver][Mips] Remove "fp64" directories from the mips-mti-linux-gnu toolchain
Simon Atanasyan [Fri, 25 Jul 2014 11:20:21 +0000 (11:20 +0000)]
[Driver][Mips] Remove "fp64" directories from the mips-mti-linux-gnu toolchain
directories description. Released version of this toolchain has not separate
libraries for -mfp64 command line option.

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

10 years agoRevert part of r206963
James Molloy [Fri, 25 Jul 2014 10:19:47 +0000 (10:19 +0000)]
Revert part of r206963

Specifically the part where we removed a warning to be compatible with GCC, which has been widely regarded as a bad idea.

I'm not quite happy with how obtuse this warning is, especially in the fairly common case of a 32-bit integer literal, so I've got another patch awaiting review that adds a fixit to reduce confusion.

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

10 years ago[OPENMP] Improved codegen for outlined functions for 'parallel' directives.
Alexey Bataev [Fri, 25 Jul 2014 07:55:17 +0000 (07:55 +0000)]
[OPENMP] Improved codegen for outlined functions for 'parallel' directives.

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

10 years ago[OPENMP] Improved DSA processing of the loop control variables for loop directives.
Alexey Bataev [Fri, 25 Jul 2014 06:27:47 +0000 (06:27 +0000)]
[OPENMP] Improved DSA processing of the loop control variables for loop directives.

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

10 years ago[modules] Substantially improve handling of #undef:
Richard Smith [Fri, 25 Jul 2014 04:40:03 +0000 (04:40 +0000)]
[modules] Substantially improve handling of #undef:

 * Track override set across module load and save
 * Track originating module to allow proper re-export of #undef
 * Make override set properly transitive when it picks up a #undef

This fixes nearly all of the remaining macro issues with self-host.

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

10 years agoFix test/CodeGen/ms-inline-asm.c from r213916.
Ehsan Akhgari [Fri, 25 Jul 2014 02:39:33 +0000 (02:39 +0000)]
Fix test/CodeGen/ms-inline-asm.c from r213916.

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

10 years agoFix test/CodeGen/ms-inline-asm.cpp from r213916.
Ehsan Akhgari [Fri, 25 Jul 2014 02:35:50 +0000 (02:35 +0000)]
Fix test/CodeGen/ms-inline-asm.cpp from r213916.

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

10 years agoclang-cl: Merge adjacent single-line __asm blocks
Ehsan Akhgari [Fri, 25 Jul 2014 02:27:14 +0000 (02:27 +0000)]
clang-cl: Merge adjacent single-line __asm blocks

Summary:
This patch extends the __asm parser to make it keep parsing input tokens
as inline assembly if a single-line __asm line is followed by another line
starting with __asm too.  It also makes sure that we correctly keep
matching braces in such situations by separating the notions of how many
braces we are matching and whether we are in single-line asm block mode.

Reviewers: rnk

Subscribers: cfe-commits

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

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

10 years agoPR20445: Properly transform the initializer in a CXXNewExpr rather than running
Richard Smith [Fri, 25 Jul 2014 01:12:44 +0000 (01:12 +0000)]
PR20445: Properly transform the initializer in a CXXNewExpr rather than running
it through the normal TreeTransform logic for Exprs (which will strip off
implicit parts of the initialization and never re-create them).

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

10 years agoPass the PrintingPolicy when converting types to strings in template type
Richard Trieu [Fri, 25 Jul 2014 00:24:02 +0000 (00:24 +0000)]
Pass the PrintingPolicy when converting types to strings in template type
diffing.  This removes extra "struct"/"class" in the type names and gives
"bool" instead of "_Bool" for booleans.

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

10 years agoPrint "(default)" for default template template arguments to match the
Richard Trieu [Thu, 24 Jul 2014 23:14:16 +0000 (23:14 +0000)]
Print "(default)" for default template template arguments to match the
printing of other types.

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

10 years agoUse ELF in the clang-interpreter on windows.
Rafael Espindola [Thu, 24 Jul 2014 20:47:42 +0000 (20:47 +0000)]
Use ELF in the clang-interpreter on windows.

We don't support loading COFF files yet.

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

10 years agoPreserve libclang ABI compatibility with the 3.5 release
Reid Kleckner [Thu, 24 Jul 2014 18:22:15 +0000 (18:22 +0000)]
Preserve libclang ABI compatibility with  the 3.5 release

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

10 years agoAdd support for #pragma nounroll.
Mark Heffernan [Thu, 24 Jul 2014 18:09:38 +0000 (18:09 +0000)]
Add support for #pragma nounroll.

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

10 years agoAttempt at fixing the windows shared build.
Rafael Espindola [Thu, 24 Jul 2014 17:38:18 +0000 (17:38 +0000)]
Attempt at fixing the windows shared build.

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

10 years agoUse MCJIT.
Rafael Espindola [Thu, 24 Jul 2014 17:13:09 +0000 (17:13 +0000)]
Use MCJIT.

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

10 years agoRemove the last use of llvm::ExecutionEngine::create.
Rafael Espindola [Thu, 24 Jul 2014 15:54:23 +0000 (15:54 +0000)]
Remove the last use of llvm::ExecutionEngine::create.

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

10 years agoImproving the "integer constant too large" diagnostics based on post-commit feedback...
Aaron Ballman [Thu, 24 Jul 2014 14:51:23 +0000 (14:51 +0000)]
Improving the "integer constant too large" diagnostics based on post-commit feedback from Richard Smith. Amends r213657.

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

10 years agoSetting the documentation heading for #pragma unroll, which should not be with the...
Aaron Ballman [Thu, 24 Jul 2014 14:13:59 +0000 (14:13 +0000)]
Setting the documentation heading for #pragma unroll, which should not be with the heading for #pragma clang loop.

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

10 years ago[CMake] LexTests: Prune redundant libdep(s).
NAKAMURA Takumi [Thu, 24 Jul 2014 11:44:03 +0000 (11:44 +0000)]
[CMake] LexTests: Prune redundant libdep(s).

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

10 years agoMachO: use "arm64" as the triple name in modules.
Tim Northover [Thu, 24 Jul 2014 10:25:34 +0000 (10:25 +0000)]
MachO: use "arm64" as the triple name in modules.

Current versions of ld64 can't cope with "aarch64" being stored. I'm fixing
that, but in the transitionary period we'll need to still emit "arm64".

rdar://problem/17783765

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

10 years ago[OPENMP] Initial parsing and sema analysis for clause 'seq_cst' of 'atomic' directive.
Alexey Bataev [Thu, 24 Jul 2014 08:55:34 +0000 (08:55 +0000)]
[OPENMP] Initial parsing and sema analysis for clause 'seq_cst' of 'atomic' directive.

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

10 years ago[OPENMP] Initial parsing and sema analysis for clause 'capture' in 'atomic' directive.
Alexey Bataev [Thu, 24 Jul 2014 06:46:57 +0000 (06:46 +0000)]
[OPENMP] Initial parsing and sema analysis for clause 'capture' in 'atomic' directive.

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

10 years agoMS ABI: -fno-rtti-data wasn't data-free enough
David Majnemer [Thu, 24 Jul 2014 06:09:19 +0000 (06:09 +0000)]
MS ABI: -fno-rtti-data wasn't data-free enough

While -fno-rtti-data would correctly avoid referencing the RTTI complete
object locator in the VFTable itself, it would emit them anyway.

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

10 years agoAdd support for nullptr template arguments to template type diffing.
Richard Trieu [Thu, 24 Jul 2014 04:24:50 +0000 (04:24 +0000)]
Add support for nullptr template arguments to template type diffing.

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

10 years ago[modules] Slightly expand module semantics documentation.
Richard Smith [Thu, 24 Jul 2014 03:42:38 +0000 (03:42 +0000)]
[modules] Slightly expand module semantics documentation.

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

10 years agoSimplify MacroInfo lifetime management. We don't need three different functions
Richard Smith [Thu, 24 Jul 2014 03:25:00 +0000 (03:25 +0000)]
Simplify MacroInfo lifetime management. We don't need three different functions
to destroy one of these.

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

10 years ago[OPENMP] Fixed DSA detecting for function parameters: by default they must be private.
Alexey Bataev [Thu, 24 Jul 2014 02:33:58 +0000 (02:33 +0000)]
[OPENMP] Fixed DSA detecting for function parameters: by default they must be private.

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

10 years agoTake the canonical type when forming a canonical template argument with
Richard Smith [Thu, 24 Jul 2014 02:27:39 +0000 (02:27 +0000)]
Take the canonical type when forming a canonical template argument with
'nullptr' value. Fixes profiling of such template arguments to always give the
same value.

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

10 years agoRemove unused Prev pointer from MacroInfo chain.
Richard Smith [Thu, 24 Jul 2014 01:13:23 +0000 (01:13 +0000)]
Remove unused Prev pointer from MacroInfo chain.

Remove pointless MICache: it only ever contained up to 1 object, and was only
non-empty when recovering from an error. There's no performance or memory win
from maintaining this cache.

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

10 years agoReplace r213816's fix with a different one. It's not meaningful to call
Richard Smith [Wed, 23 Jul 2014 23:50:25 +0000 (23:50 +0000)]
Replace r213816's fix with a different one. It's not meaningful to call
isOnePastTheEnd on an invalid designator, so assert and push the check into the
one caller that wasn't already checking.

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

10 years agoSplit -Winvalid-command-line-argument into -Wignored-optimization-argument
Reid Kleckner [Wed, 23 Jul 2014 23:29:01 +0000 (23:29 +0000)]
Split -Winvalid-command-line-argument into -Wignored-optimization-argument

Reviewers: rsmith, nlewycky

Subscribers: cfe-commits

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

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

10 years agoAdd a missing Invalid check to SubobjectDesignator::isOnePastEnd()
Reid Kleckner [Wed, 23 Jul 2014 23:24:25 +0000 (23:24 +0000)]
Add a missing Invalid check to SubobjectDesignator::isOnePastEnd()

The class seems to have an invariant that Entries is non-empty if
Invalid is false.  It appears this method was previously private, and
all internal uses checked Invalid.  Now there is an external caller, so
check Invalid to avoid array OOB underflow.

Fixes PR20420.

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

10 years agoPR20228: don't retain a pointer to a vector element after the container has been...
Richard Smith [Wed, 23 Jul 2014 20:07:08 +0000 (20:07 +0000)]
PR20228: don't retain a pointer to a vector element after the container has been resized.

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

10 years agoRename metadata in test which was missed when renaming loop unroll metadata in r213771.
Mark Heffernan [Wed, 23 Jul 2014 17:59:07 +0000 (17:59 +0000)]
Rename metadata in test which was missed when renaming loop unroll metadata in r213771.

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

10 years agoIn unroll pragma syntax and loop hint metadata, change "enable" forms to a new form...
Mark Heffernan [Wed, 23 Jul 2014 17:31:31 +0000 (17:31 +0000)]
In unroll pragma syntax and loop hint metadata, change "enable" forms to a new form using the string "full".

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

10 years agoFix test/Driver/cl-x86-flags.c by providing explicit --target
Artyom Skrobov [Wed, 23 Jul 2014 17:09:26 +0000 (17:09 +0000)]
Fix test/Driver/cl-x86-flags.c by providing explicit --target

This isn't very neat, but we haven't found any better ways to
make this test work with non-X86 default target.

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

10 years agoAdd stopgap option -fmodule-implementation-of <name>
Ben Langmuir [Wed, 23 Jul 2014 15:30:23 +0000 (15:30 +0000)]
Add stopgap option -fmodule-implementation-of <name>

This flag specifies that we are building an implementation file of the
module <name>, preventing importing <name> as a module. This does not
consider this to be the 'current module' for the purposes of doing
modular checks like decluse or non-modular-include warnings, unlike
-fmodule-name.

This is needed as a stopgap until:
1) we can resolve relative includes to a VFS-mapped module (or can
   safely import a header textually and as part of a module)

and ideally
2) we can safely do incremental rebuilding when implementation files
   import submodules.

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

10 years agoPrevent assert in ASTMatchFinder.
Daniel Jasper [Wed, 23 Jul 2014 13:17:47 +0000 (13:17 +0000)]
Prevent assert in ASTMatchFinder.

If nodes without memoization data (e.g. TypeLocs) are bound to specific
names, that effectively prevents memoization as those elements cannot be
compared effectively. If it is tried anyway, this can lead to an assert
as demonstrated in the new test.

In the long term, the better solution will be to enable DynTypedNodes
without memoization data. For now, simply skip memoization instead.

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

10 years agoAArch64: use aarch64_be instead of arm64_be in all tests.
Tim Northover [Wed, 23 Jul 2014 12:57:31 +0000 (12:57 +0000)]
AArch64: use aarch64_be instead of arm64_be in all tests.

arm64_be doesn't really exist; it was useful for testing while AArch64 and
ARM64 were separate, but now the only real way to refer to the system is
aarch64_be.

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

10 years agoAArch64: update Clang for merged arm64/aarch64 triples.
Tim Northover [Wed, 23 Jul 2014 12:32:58 +0000 (12:32 +0000)]
AArch64: update Clang for merged arm64/aarch64 triples.

The main subtlety here is that the Darwin tools still need to be given "-arch
arm64" rather than "-arch aarch64". Fortunately this already goes via a custom
function to handle weird edge-cases in other architectures, and it tested.

I removed a few arm64_be tests because that really isn't an interesting thing
to worry about. No-one using big-endian is also referring to the target as
arm64 (at least as far as toolchains go). Mostly they date from when arm64 was
a separate target and we *did* need a parallel name simply to test it at all.
Now aarch64_be is sufficient.

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

10 years ago[mips] -mno-shared should only be given to the assembler when -fPIC/-fpic/-fPIE/...
Daniel Sanders [Wed, 23 Jul 2014 12:06:13 +0000 (12:06 +0000)]
[mips] -mno-shared should only be given to the assembler when -fPIC/-fpic/-fPIE/-fpie is not in effect.

This fixes compiler recursion on MIPS32r2.

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

10 years agoASTMatchers: Bound node results are always const, make selectFirst's template argumen...
Benjamin Kramer [Wed, 23 Jul 2014 11:41:44 +0000 (11:41 +0000)]
ASTMatchers: Bound node results are always const, make selectFirst's template argument implicitly const.

This avoids adding const to every user of selectFirst and also allows it to
match TypeLocs which BoundNodes doesn't use magic const removal specializations
for. No functionality change.

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

10 years ago[OPENMP] Initial parsing and sema analysis for 'update' clause of 'atomic' directive.
Alexey Bataev [Wed, 23 Jul 2014 10:25:33 +0000 (10:25 +0000)]
[OPENMP] Initial parsing and sema analysis for 'update' clause of 'atomic' directive.

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

10 years ago[Driver][Mips] Restore FIXME comment was removed accidentally.
Simon Atanasyan [Wed, 23 Jul 2014 09:27:10 +0000 (09:27 +0000)]
[Driver][Mips] Restore FIXME comment was removed accidentally.

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

10 years agoARM: Add doc for ACLE memory barrier intrinsics
Yi Kong [Wed, 23 Jul 2014 09:25:02 +0000 (09:25 +0000)]
ARM: Add doc for ACLE memory barrier intrinsics

Add documentations for ACLE memory barrier intrinsics, describing their motion
barrier characteristics.

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

10 years agoAdd module map entry for ARM ACLE header file
Yi Kong [Wed, 23 Jul 2014 09:00:21 +0000 (09:00 +0000)]
Add module map entry for ARM ACLE header file

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

10 years ago[OPENMP] Initial parsing an sema analysis for 'write' clause of 'atomic' directive.
Alexey Bataev [Wed, 23 Jul 2014 07:46:59 +0000 (07:46 +0000)]
[OPENMP] Initial parsing an sema analysis for 'write' clause of 'atomic' directive.

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

10 years agoImprove diagnostic on default-initializing const variables (PR20208).
Nico Weber [Wed, 23 Jul 2014 05:16:10 +0000 (05:16 +0000)]
Improve diagnostic on default-initializing const variables (PR20208).

This tweaks the diagnostic wording slighly, and adds a fixit on a note.
An alternative would be to add the fixit directly on the diagnostic, see
the review thread linked to from the bug for a few notes on that approach.

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

10 years agoAST printer: fix double space before base class with no access specifier.
Richard Smith [Wed, 23 Jul 2014 03:22:10 +0000 (03:22 +0000)]
AST printer: fix double space before base class with no access specifier.

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

10 years agoWhen pretty-printing a declaration of a pack, put the ellipsis before the name
Richard Smith [Wed, 23 Jul 2014 03:17:06 +0000 (03:17 +0000)]
When pretty-printing a declaration of a pack, put the ellipsis before the name
being declared, not at the end. When pretty-printing a non-type template
parameter, put the name of the parameter in the middle of the type, not at the
end.

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

10 years ago[OPENMP] Initial parsing and sema analysis for 'read' clause in 'atomic' directive.
Alexey Bataev [Wed, 23 Jul 2014 02:27:21 +0000 (02:27 +0000)]
[OPENMP] Initial parsing and sema analysis for 'read' clause in 'atomic' directive.

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

10 years agotest: add an explicit target triple
Saleem Abdulrasool [Wed, 23 Jul 2014 01:32:32 +0000 (01:32 +0000)]
test: add an explicit target triple

Now that we support WoA, this test fails on ARM build bots as __va_start has a
different signature on different architectures.

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

10 years agoPR14615: add (passing) tests for this already-fixed bug
Richard Smith [Tue, 22 Jul 2014 23:56:53 +0000 (23:56 +0000)]
PR14615: add (passing) tests for this already-fixed bug

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

10 years agoUse the correct from type in a SCS
Ehsan Akhgari [Tue, 22 Jul 2014 20:20:14 +0000 (20:20 +0000)]
Use the correct from type in a SCS

Summary:
If during constructing a standard conversion sequence, we resolve an
overload, we need to adjust the from type in the SCS according to the
resolved operator.

I found this bug when debugging PR20218.  This doesn't seem to be
observable, so there is no good way of testing it.

Reviewers: rsmith

Subscribers: cfe-commits

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

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

10 years agoremove hardcoded metadata numbers from tests
Robert Lytton [Tue, 22 Jul 2014 14:47:42 +0000 (14:47 +0000)]
remove hardcoded metadata numbers from tests

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

10 years agoImprove the checkUInt32Argument() helper function so that it diagnoses integer consta...
Aaron Ballman [Tue, 22 Jul 2014 14:09:34 +0000 (14:09 +0000)]
Improve the checkUInt32Argument() helper function so that it diagnoses integer constants larger than 32-bits.

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

10 years agoProvide extra information in the "integer constant is too large" diagnostic. This...
Aaron Ballman [Tue, 22 Jul 2014 14:08:09 +0000 (14:08 +0000)]
Provide extra information in the "integer constant is too large" diagnostic. This will be used to improve other diagnostics.

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

10 years agoAdding a heading to the loop hint attributes so that attribute documentation can...
Aaron Ballman [Tue, 22 Jul 2014 13:13:31 +0000 (13:13 +0000)]
Adding a heading to the loop hint attributes so that attribute documentation can be generated again.

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

10 years agoEscaping an RST character to correct a Sphinx warning.
Aaron Ballman [Tue, 22 Jul 2014 13:12:38 +0000 (13:12 +0000)]
Escaping an RST character to correct a Sphinx warning.

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

10 years agoDisallowing GNU-style attributes in new expressions, since they are prohibited by...
Aaron Ballman [Tue, 22 Jul 2014 12:44:22 +0000 (12:44 +0000)]
Disallowing GNU-style attributes in new expressions, since they are prohibited by GCC as well.

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

10 years ago[OPENMP] Tests for nesting of regions for 'atomic' directive.
Alexey Bataev [Tue, 22 Jul 2014 12:35:18 +0000 (12:35 +0000)]
[OPENMP] Tests for nesting of regions for 'atomic' directive.

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

10 years agoAVX-512: I added new headers to makefiles. It should resolve tests fail.
Elena Demikhovsky [Tue, 22 Jul 2014 12:08:25 +0000 (12:08 +0000)]
AVX-512: I added new headers to makefiles. It should resolve tests fail.
If it will not, I'm reverting the both commits.

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

10 years agoAVX-512: Added intrinsics to clang.
Elena Demikhovsky [Tue, 22 Jul 2014 11:31:39 +0000 (11:31 +0000)]
AVX-512: Added intrinsics to clang.
The set is small, that what I have right now.
Everybody is welcome to add more.

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

10 years ago[OPENMP] Initial parsing and sema analysis for 'atomic' directive.
Alexey Bataev [Tue, 22 Jul 2014 10:10:35 +0000 (10:10 +0000)]
[OPENMP] Initial parsing and sema analysis for 'atomic' directive.

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

10 years ago[OPENMP] Initial parsing and sema analysis for 'ordered' directive.
Alexey Bataev [Tue, 22 Jul 2014 06:45:04 +0000 (06:45 +0000)]
[OPENMP] Initial parsing and sema analysis for 'ordered' directive.

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

10 years agoFix '&' printing for template arguments in parentheses in template diffing.
Richard Trieu [Tue, 22 Jul 2014 04:42:15 +0000 (04:42 +0000)]
Fix '&' printing for template arguments in parentheses in template diffing.

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

10 years agoMore gracefully handle parentheses in templare arguments in template diffing.
Richard Trieu [Tue, 22 Jul 2014 04:06:54 +0000 (04:06 +0000)]
More gracefully handle parentheses in templare arguments in template diffing.

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

10 years agoFix a template diffing problem were an '&' is unexpectedly printed in
Richard Trieu [Tue, 22 Jul 2014 03:33:01 +0000 (03:33 +0000)]
Fix a template diffing problem were an '&' is unexpectedly printed in
a template argument.

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

10 years agoSema: correct handling for __va_start for WoA
Saleem Abdulrasool [Tue, 22 Jul 2014 02:01:04 +0000 (02:01 +0000)]
Sema: correct handling for __va_start for WoA

Windows ARM indicates __va_start as a variadic function.  However, the function
itself is treated as having 4 formal arguments:
  - (out) pointer to the va_list
  - (in) address of the last named argument
  - (in) slot size for the type of the last argument
  - address of the last named argument

The last argument does not seem to have any bearing on codegen, and thus is not
explicitly type checked at this point.

Unlike the previous handling for __va_start, it does not currently validate if
the parameter is the last named parameter (it seems that MSVC currently accepts
this).

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

10 years agoAvoid crash if default argument parsed with errors.
Serge Pavlov [Tue, 22 Jul 2014 01:54:49 +0000 (01:54 +0000)]
Avoid crash if default argument parsed with errors.

If function parameters have default values, and that of the second
parameter is parsed with errors, function declaration would have
a parameter without default value that follows a parameter with
that. Such declaration breaks logic of selecting overloaded
function. As a solution, put opaque object as default value in such case.

This patch fixes PR20055.

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

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

10 years ago-fms-extensions: Implement half of #pragma init_seg
Reid Kleckner [Tue, 22 Jul 2014 00:53:05 +0000 (00:53 +0000)]
-fms-extensions: Implement half of #pragma init_seg

Summary:
This pragma is very rare.  We could *hypothetically* lower some uses of
it down to @llvm.global_ctors, but given that GlobalOpt isn't able to
optimize prioritized global ctors today, there's really no point.

If we wanted to do this in the future, I would check if the section used
in the pragma started with ".CRT$XC" and had up to two characters after
it.  Those two characters could form the 16-bit initialization priority
that we support in @llvm.global_ctors.  We would have to teach LLVM to
lower prioritized global ctors on COFF as well.

This should let us compile some silly uses of this pragma in WebKit /
Blink.

Reviewers: rsmith, majnemer

Subscribers: cfe-commits

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

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

10 years agoclang-cl: ignore /showIncludes when combined with /E (PR20336)
Hans Wennborg [Mon, 21 Jul 2014 23:42:07 +0000 (23:42 +0000)]
clang-cl: ignore /showIncludes when combined with /E (PR20336)

Both /showIncludes and /E write to stdout. Allowing both results
in interleaved output and an error when double-closing the file
descriptor, intended to catch issues like this.

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

10 years agoRename metadata llvm.loop.vectorize.unroll to llvm.loop.vectorize.interleave.
Mark Heffernan [Mon, 21 Jul 2014 23:10:56 +0000 (23:10 +0000)]
Rename metadata llvm.loop.vectorize.unroll to llvm.loop.vectorize.interleave.

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

10 years agoclang-format vs plugin: set version number from cmake (PR20307)
Hans Wennborg [Mon, 21 Jul 2014 21:48:06 +0000 (21:48 +0000)]
clang-format vs plugin: set version number from cmake (PR20307)

Previously it was hard-coded to 1.0, which meant the installer would
not install the plugin over previous versions.

This commit makes us use LLVM's major.minor.patch version from cmake,
or whatever CLANG_FORMAT_VS_VERSION is set to when configuring the build.

It's pretty dirty to update a configuration file in the source directory
from the cmake build like this. However, the plugin build is already
dirty in this regard since it builds in the source dir when visual studio,
and then copies out the resulting vsix.

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

10 years agoRevert "Emit lifetime.start / lifetime.end markers for unnamed temporary objects."
Arnaud A. de Grandmaison [Mon, 21 Jul 2014 19:47:02 +0000 (19:47 +0000)]
Revert "Emit lifetime.start / lifetime.end markers for unnamed temporary objects."

This commit did break the sanitizer-x86 bot. Revert it while
investigating.

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

10 years agoFix build breakage caused by use of std::to_string(int). Replace with raw_string_ost...
Mark Heffernan [Mon, 21 Jul 2014 19:06:29 +0000 (19:06 +0000)]
Fix build breakage caused by use of std::to_string(int).  Replace with raw_string_ostream.

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

10 years agoEmit lifetime.start / lifetime.end markers for unnamed temporary objects.
Arnaud A. de Grandmaison [Mon, 21 Jul 2014 18:54:21 +0000 (18:54 +0000)]
Emit lifetime.start / lifetime.end markers for unnamed temporary objects.

This will give more information to the optimizers so that they can reuse stack slots.

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

10 years agoAdd support for '#pragma unroll'.
Mark Heffernan [Mon, 21 Jul 2014 18:08:34 +0000 (18:08 +0000)]
Add support for '#pragma unroll'.

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

10 years agoSema: Handle C11 atomics when diagnosing out of range comparisons
Justin Bogner [Mon, 21 Jul 2014 18:01:53 +0000 (18:01 +0000)]
Sema: Handle C11 atomics when diagnosing out of range comparisons

This fixes a couple of asserts when analyzing comparisons involving
C11 atomics that were uncovered by r205608 when we extended the
applicability of -Wtautological-constant-out-of-range-compare.

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

10 years ago[OPENMP] Initial parsing and sema analysis for 'flush' directive.
Alexey Bataev [Mon, 21 Jul 2014 11:26:11 +0000 (11:26 +0000)]
[OPENMP] Initial parsing and sema analysis for 'flush' directive.

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

10 years ago[OPENMP] Parsing/Sema of the OpenMP directive 'critical'.
Alexander Musman [Mon, 21 Jul 2014 09:42:05 +0000 (09:42 +0000)]
[OPENMP] Parsing/Sema of the OpenMP directive 'critical'.

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

10 years agoTrivial doc fixes: add missing whitespace, and s/overriden/overridden/g.
James Dennett [Mon, 21 Jul 2014 06:14:27 +0000 (06:14 +0000)]
Trivial doc fixes: add missing whitespace, and s/overriden/overridden/g.

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

10 years agoAdd clang::DesignatedInitExpr::designators() for range-based access,
James Dennett [Mon, 21 Jul 2014 06:03:12 +0000 (06:03 +0000)]
Add clang::DesignatedInitExpr::designators() for range-based access,
with overloads for designators_range and designators_const_range.

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

10 years agoAdd missing initialization found due to a valgrind false positive.
Richard Smith [Mon, 21 Jul 2014 05:27:31 +0000 (05:27 +0000)]
Add missing initialization found due to a valgrind false positive.
This field is never inspected in the object state initialized by this
constructor; however, initializing it seems reasonable, since it has
a meaningful value.

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