Commit Graph

52640 Commits

Author SHA1 Message Date
Renato Golin 230c5eb4bd Non-allocatable Global Named Register
This patch implements global named registers in Clang, lowering to the just
created intrinsics in LLVM (@llvm.read/write_register). A new type of LValue
had to be created (Register), which just adds support to carry the metadata
node containing the name of the register. Two new methods to emit loads and
stores interoperate with another to emit the named metadata node.

No guarantees are being made and only non-allocatable global variable named
registers are being supported. Local named register support is unchanged.

llvm-svn: 209149
2014-05-19 18:15:42 +00:00
Aaron Ballman 194cfa9b21 Removing an XFAIL which shouldn't apply. We no longer care about MSVC 9, and this test probably should not have been XFAILed everywhere regardless. The test passes on Windows with MSVC 12.
llvm-svn: 209148
2014-05-19 17:58:28 +00:00
Hans Wennborg 5161db61a9 test/CodeGenCXX/dllexport.cpp: -O2 and -disable-llvm-optzns aren't nedded
We only need them on the dllimport.cpp test to make sure that we emit code
for available_externaly functions, and don't inline the IR.

llvm-svn: 209145
2014-05-19 17:23:01 +00:00
Ben Langmuir caea13185e Don't refresh stat() info for pcm files
Follow-up fix for 209138.  Actually, since we already have this file
open, we don't want to refresh the stat() info, since that might be
newer than what we have open (bad!).

llvm-svn: 209143
2014-05-19 17:04:28 +00:00
Aaron Ballman 06c59e2598 This test doesn't need to be XFAILed anywhere; it just needed to be updated to the appropriate diagnostic wording.
llvm-svn: 209140
2014-05-19 16:35:00 +00:00
Ben Langmuir ca39214f4e Fix use-after-free and spurious error during module load
FileManager::invalidateCache is not safe to call when there may be
existing references to the file. What module load failure needs is
to refresh so stale stat() info isn't stored.

This may be the last user of invalidateCache; I'll take a look and
remove it if possible in a future commit.

This caused a use-after-free error as well as a spurious error message
that a module was "found in both 'X.pcm' and 'X.pcm'" in some cases.

llvm-svn: 209138
2014-05-19 16:13:45 +00:00
Anton Yartsev 45056dc50a [analyzer] Alpha and implicit checker lists, expand/collapse feature.
The list of alpha and the list of implicit checkers added. An ability to expand/collapse long texts added. Markup fixed.

http://reviews.llvm.org/D3457

llvm-svn: 209131
2014-05-19 15:04:55 +00:00
Aaron Ballman 9ae6c62161 This test is XFAILed on Windows, but I cannot see a reason as to why it should be failing. The original commit which XFAILed this was r111581, which suggested something was wrong with file remapping, but that may have been subsequently fixed.
Removing the XFAIL, but will watch the build bots to see if any go red because of this. Local testing on Windows succeeds.

llvm-svn: 209130
2014-05-19 15:02:10 +00:00
Aaron Ballman 857c7fb448 Fixing some comments in this test. No functional changes.
llvm-svn: 209128
2014-05-19 14:52:09 +00:00
Joey Gouly b1d23a8db3 [OpenCL] Reject reqd_work_group_size(X, Y, Z) where X, Y or Z == 0.
Patch by Pedro Ferreira!

llvm-svn: 209127
2014-05-19 14:41:38 +00:00
Oliver Stannard 9b2a7d4f2d Pass -gdwarf-N options to integrated assembler
llvm-svn: 209124
2014-05-19 13:39:13 +00:00
Oliver Stannard a3afc69b94 ARM: PCS non-compliance when struct is padded to avoid register/stack split, and requires internal padding
When we were padding a struct to avoid splitting it between registers and
the stack, we were throwing away the type which the argument should be coerced
to.

llvm-svn: 209122
2014-05-19 13:10:05 +00:00
Manuel Klimek fcfc213c3f Make the ARCMT tests self-contained.
This is necessary to reduce staging times on parallel build systems.

llvm-svn: 209120
2014-05-19 11:51:44 +00:00
Daniel Jasper 7f0c517168 clang-format: Don't force line breaks in ObjC calls with ColumnLimit 0.
Before:
  [self.x a:b c:d];

Got reformatted toi (with ColumnLimit set to 0):
  [self.x a:b
          c:d];

llvm-svn: 209114
2014-05-19 08:06:34 +00:00
Daniel Jasper 0dd5291e69 clang-format: [JS] Support ES6 destructuring assignments.
Before:
  var[a, b, c] = [1, 2, 3];

After:
  var [a, b, c] = [1, 2, 3];

llvm-svn: 209113
2014-05-19 07:37:07 +00:00
Daniel Jasper 78214397a3 clang-format: [JS] Support for EC6 arrow functions.
Before:
  var b = a.map((x) = > x + 1);

After:
  var b = a.map((x) => x + 1);

llvm-svn: 209112
2014-05-19 07:27:02 +00:00
Alp Toker 180e327f1c RAV reunification: MSPropertyRefExpr visitation
r179585 introduced different MSPropertyRefExpr visitation for RAV and DRAV that
appears to have been unintentional. Let's use the more complete one.

llvm-svn: 209101
2014-05-18 21:01:45 +00:00
Alp Toker b69030a8bd RAV reunification: merge r162133 (visit the TypeLoc when RecursiveASTVisitor visits a CompoundLiteralExpr)
llvm-svn: 209100
2014-05-18 21:00:44 +00:00
Alp Toker f66ed2d430 Ongoing RAV reunification
* Shuffle around code to reduce delta between the two RAVs.
 * Merge r189185 that was applied only to one of the RAVs and became apparent during the unification work.
 * Fix Enqueue data recursion typo.

Our delta is down to +-579!

llvm-svn: 209093
2014-05-18 18:38:28 +00:00
Alp Toker b67c67bbe0 Format the two RecursiveASTVisitors
Apply current ToT clang-format on the two RAVs to reduce delta and help
identify differences between the two.

We lose a little pretty formatting in the headers but that's the price to pay
so we can diff these two files effectively and look to a future where we don't
have to maintain two copies of this code.

Formatting and whitespace only.

llvm-svn: 209092
2014-05-18 18:38:19 +00:00
Alp Toker f3ce43e690 Begin RAV reunification: s/DataRecursiveASTVisitor/RecursiveASTVisitor/
Define a macro to reduce the delta between RecursiveASTVisitor and
DataRecursiveASTVisitor.

Some years ago, someone thought it was a good idea to copy the entire RAV to
support cursor visitation in libclang.

Since then the two have diverged needlessly and the rest is history.

This series of commits aims to reduce delta between the two so that we can
reason about their differences, apply bugfixes that were only made to one but
not the other, and ultimately find a way to unify two two chunks of code.

llvm-svn: 209091
2014-05-18 18:38:08 +00:00
Alp Toker 7755aff556 Remove historical Unicode TODOs
There's no immediate demand or plan to work on these.

llvm-svn: 209090
2014-05-18 18:37:59 +00:00
Benjamin Kramer f30d4460fc Remove unused diagnostic.
llvm-svn: 209087
2014-05-18 12:05:21 +00:00
Saleem Abdulrasool 6deb816c1c Driver: force restricted IT blocks for Windows on ARM
Windows on ARM expects ARMv8 (restricted IT) conditional instructions only.
Force enable the restricted IT mode via the backend option when targeting WoA.

llvm-svn: 209086
2014-05-18 06:42:02 +00:00
Craig Topper d2d442ca73 [C++11] Use 'nullptr'. Lex edition.
llvm-svn: 209083
2014-05-17 23:10:59 +00:00
Rafael Espindola 234405bd0f Update for llvm api change.
llvm-svn: 209077
2014-05-17 21:30:14 +00:00
Rafael Espindola 6172277e9f Update for llvm api change.
llvm-svn: 209074
2014-05-17 19:58:16 +00:00
Craig Topper 210e1aded7 [C++11] Use 'nullptr'. ASTMatchers edition.
llvm-svn: 209070
2014-05-17 18:49:24 +00:00
Craig Topper 92fc2dfa6f [C++11] Use 'nullptr'. Driver edition.
llvm-svn: 209069
2014-05-17 16:56:41 +00:00
Saleem Abdulrasool b9081f4490 CodeGen: remove MinGW and Cygwin legacy entries
These are now treated as environments.  Remove references to these enumeration
values in order to clean up the unused enumeration entries in LLVM.  The target
normalisation prior to tool invocation should ensure that the old values
continue to function properly.

llvm-svn: 209068
2014-05-17 15:46:59 +00:00
Alp Toker 2d57cea256 Provide and use a safe Token::getRawIdentifier() accessor
llvm-svn: 209061
2014-05-17 04:53:25 +00:00
Richard Smith ec2748a8ad More fixes for isBetterOverloadCandidate not being a strict weak ordering. The
bug was obvious from inspection, figuring out a way to test it was... less so.

llvm-svn: 209060
2014-05-17 04:36:39 +00:00
Argyrios Kyrtzidis d4d5534034 [objcmt] Don't wrap a PCH generation action with a ObjCMigrateAction one, it messes up the PCH file.
rdar://16941811

llvm-svn: 209059
2014-05-17 04:35:12 +00:00
Richard Smith 9516eee2f2 Switch to a more efficient expression of this check.
llvm-svn: 209055
2014-05-17 02:21:47 +00:00
Richard Smith 6fdeaabda9 Correct incoherent function versus function template partial ordering for conversion operators (the comparison could claim that two conversion operators are both better than each other). Actually implement DR495, rather than passing its test by chance because the declarations happened to be in the "lucky" order.
llvm-svn: 209054
2014-05-17 01:58:45 +00:00
Alp Toker b0869036c1 Tweak diagnostic wording for init list narrowing
The conventional form is '<action> to silence this warning'.

Also call the diagnostic an 'issue' rather than a 'message' because the latter
term is more widely used with reference to message expressions.

llvm-svn: 209052
2014-05-17 01:13:18 +00:00
Richard Smith fdcd710199 Add missed file from r209046.
llvm-svn: 209047
2014-05-16 23:16:06 +00:00
Richard Smith 053f6c6c9e If a declaration is loaded, and then a module import adds a redeclaration, then
ensure that querying the first declaration for its most recent declaration
checks for redeclarations from the imported module.

This works as follows:
 * The 'most recent' pointer on a canonical declaration grows a pointer to the
   external AST source and a generation number (space- and time-optimized for
   the case where there is no external source).
 * Each time the 'most recent' pointer is queried, if it has an external source,
   we check whether it's up to date, and update it if not.
 * The ancillary data stored on the canonical declaration is allocated lazily
   to avoid filling it in for declarations that end up being non-canonical.
   We'll still perform a redundant (ASTContext) allocation if someone asks for
   the most recent declaration from a decl before setPreviousDecl is called,
   but such cases are probably all bugs, and are now easy to find.

Some finessing is still in order here -- in particular, we use a very general
mechanism for handling the DefinitionData pointer on CXXRecordData, and a more
targeted approach would be more compact.

Also, the MayHaveOutOfDateDef mechanism should now be expunged, since it was
addressing only a corner of the full problem space here. That's not covered
by this patch.

Early performance benchmarks show that this makes no measurable difference to 
Clang performance without modules enabled (and fixes a major correctness issue
with modules enabled). I'll revert if a full performance comparison shows any
problems.

llvm-svn: 209046
2014-05-16 23:01:30 +00:00
Rafael Espindola 0fcad8837b Use getAliasee instead of getAliasedGlobal.
No functionality change.

llvm-svn: 209038
2014-05-16 22:20:18 +00:00
Eric Christopher e76eee4638 Missed a ! in the if statement when these were being set and the options
are inverted in clang and llvm.

I'll attempt to get a testcase for this that doesn't involve compiling to .s,
but it's unlikely.

llvm-svn: 209017
2014-05-16 20:46:14 +00:00
Rafael Espindola b2633b9793 Update for llvm api change.
Now that llvm cannot represent alias cycles, we have to diagnose erros just
before trying to close the cycle. This degrades the errors a bit. The real
solution is what it was before: if we want to provide good errors for these
cases, we have to be able to find a clang level decl given a mangled name
and produce the error from Sema.

llvm-svn: 209008
2014-05-16 19:35:48 +00:00
Joey Gouly 0d9a2b2205 [ASTMatchers] Move the 'isImplicit' matcher from CXXConstructorDecl to Decl.
llvm-svn: 209006
2014-05-16 19:31:08 +00:00
Alp Toker 2e9ce4c565 Merge a couple of copy-and-pasted functions
No change in functionality.

llvm-svn: 209005
2014-05-16 18:59:21 +00:00
Alp Toker 6ac2cd01d2 Rename SourceManager::createFileIDForMemBuffer()
It makes more sense to just overload createFileID().

Gardening only.

llvm-svn: 209002
2014-05-16 17:23:01 +00:00
Alp Toker 77273fc52a Tooling: use stderr, not stdout for missing command line messages
Matches other tooling output that use stderr.

llvm-svn: 208988
2014-05-16 13:45:29 +00:00
Rafael Espindola 9750ce7ebd Update for llvm API change.
llvm-svn: 208984
2014-05-16 13:34:28 +00:00
Sylvestre Ledru 3cbaa468c2 Improve a scan-build message
llvm-svn: 208951
2014-05-16 07:03:15 +00:00
Duncan P. N. Exon Smith 540c3cd817 InstrProf: Look for the PIC-version of the profile runtime
If `-shared` is specified, pull in a PIC-version of the profile runtime,
which was added to compiler-rt in r208947.  I'm hoping this will get the
bots on my side.

llvm-svn: 208948
2014-05-16 04:09:41 +00:00
Richard Smith debcd500a0 Push implicitly-declared allocation functions into the IdResolver. Otherwise,
declaration merging in modules is unable to find them and we get bogus errors
and even crashes.

llvm-svn: 208944
2014-05-16 02:14:42 +00:00
Richard Smith ee390436b9 Replace a fake enum class with the real thing.
llvm-svn: 208943
2014-05-16 01:56:53 +00:00
Ben Langmuir 5bf828dd34 Switch another write_escaped to yaml::escape
I missed one in r206443.

llvm-svn: 208941
2014-05-16 01:38:59 +00:00
Duncan P. N. Exon Smith 9121220804 InstrProf: Set profile data to visibility hidden
Shared objects are fairly broken for InstrProf right now -- a follow-up
commit in compiler-rt will fix the rest of this.

The main problem here is that at link time, profile data symbols in the
shared object might get used instead of symbols from the main
executable, creating invalid profile data sections.

<rdar://problem/16918688>

llvm-svn: 208939
2014-05-16 01:24:00 +00:00
Hans Wennborg 4e43fef3e5 test/CodeGenCXX/dllexport.cpp: we already correctly emit b() even when
it's not used, because CodeGenModule::EmitGlobal consults
ASTContext::DeclMustBeEmitted via CodeGenModule::MayDeferGeneration.

llvm-svn: 208936
2014-05-16 00:09:31 +00:00
Reid Kleckner 966abe7614 MS ABI: Use musttail for thunk IR generation
This allows us to perfectly forward non-trivial arguments that use
inalloca.

We still can't forward non-trivial arguments through thunks when we have
a covariant return type with a non-trivial adjustment.  This would
require emitting an extra copy, which is non-conforming anyway.

llvm-svn: 208927
2014-05-15 23:01:46 +00:00
Alp Toker 1761f11801 Eliminate DefaultImageName from the Driver constructor
All callers were passing in "a.out" or garbage so a sensible default works fine
here as a cleanup.

This also brings about the possibility of adapting the value based on the
driver's compatibility mode in future.

The setting can still be changed via Driver::DefaultImageName as needed.

llvm-svn: 208926
2014-05-15 22:26:36 +00:00
Hans Wennborg b0f2f146bb Allow dllimport/dllexport on inline functions and adjust the linkage.
This is a step towards handling these attributes on classes (PR11170).

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

llvm-svn: 208925
2014-05-15 22:07:49 +00:00
DeLesley Hutchins 03efd41bc0 Thread Safety Analysis: fixes to SExpr pretty printing.
llvm-svn: 208924
2014-05-15 22:07:41 +00:00
Aaron Ballman 130a3b0504 Refactoring another for loop to use a range-based for loop instead. Also cleaned up a bit of formatting. No functional changes intended.
llvm-svn: 208918
2014-05-15 20:58:55 +00:00
Aaron Ballman e519522343 Refactoring some for loops to use range-based for loops instead. No functional changes intended.
llvm-svn: 208915
2014-05-15 20:50:47 +00:00
Ben Langmuir ef914b89b4 Use the virtual name of headers when searching for a module
When using the VFS, we want the virtual header location when searching
for a framework module, since that will be the one in the correct
directory structure for the module.

I'll add a regression test once I finish reducing the larger one I have.

llvm-svn: 208901
2014-05-15 16:20:33 +00:00
Daniel Jasper c0be7604cf clang-format: Fix Sphinx build error.
Patch by Adam Strzelecki, thank you!

llvm-svn: 208882
2014-05-15 13:55:19 +00:00
Alexander Musman cb7f9c40f8 C++11 - Use nullptr in lib/Sema/SemaOpenMP.cpp and some reformatting (no functional changes).
llvm-svn: 208879
2014-05-15 13:04:49 +00:00
Tim Northover fb33438115 ARM64: update tests now that we print "mov" & "mvn".
llvm-svn: 208875
2014-05-15 12:11:10 +00:00
Tim Northover 0f9355b3b0 AArch64: update test after LLVM CodeGen change
llvm-svn: 208868
2014-05-15 11:21:39 +00:00
David Majnemer c3d0733cf8 AST: Remove dead-code/update reference to standard
GetGVALinkageForFunction handles TSK_ExplicitInstantiationDeclaration
twice, remove the redundant code trying to handle it again.

While we are here, update the reference we make to the standard.  It
seems like another paragraph was added causing this text to get
renumbered.

llvm-svn: 208850
2014-05-15 06:25:57 +00:00
Argyrios Kyrtzidis 884337f427 [libclang] Introduce clang_Module_isSystem(), which returns non-zero if the given CXModule is a system one.
llvm-svn: 208846
2014-05-15 04:44:25 +00:00
Richard Smith aba8b36abf Replace completely bogus ambiguous-compound-literal-in-C++ code with something
that isn't always wrong.

llvm-svn: 208844
2014-05-15 02:51:15 +00:00
Richard Smith 87e11a426d PR19748: Make sure we don't lose colon protection after the parenthesized type-id in a cast-expression.
llvm-svn: 208843
2014-05-15 02:43:47 +00:00
Alp Toker c3f36af8d0 Fix typos
llvm-svn: 208838
2014-05-15 01:35:53 +00:00
Reid Kleckner d355ca77a9 Revert Itanium parts of "Don't copy objects with trivial, deleted copy ctors"
This undoes half of r208786.

It had problems with lazily declared special members in cases like this:
  struct A {
    A();
    A &operator=(A &&o);
    void *p;
  };
  void foo(A);
  void bar() {
    foo({});
  }

In this case, the copy and move constructors are implicitly deleted.
However, Clang doesn't eagerly declare the copy ctor in the AST, so we
pass the struct in registers.  Furthermore, GCC passes this in registers
even though this class should be uncopyable.

Revert this for now until the dust settles.

llvm-svn: 208836
2014-05-15 01:26:32 +00:00
Eric Christopher 7e72a0932b Fill in the options in the MCOptions struct directly like the other
options.

llvm-svn: 208834
2014-05-15 01:21:56 +00:00
DeLesley Hutchins f4b5e7c60f Thread Safety Analysis: add new node types to thread safety TIL.
This fills in a few missing gaps in functionality.

llvm-svn: 208830
2014-05-15 00:50:36 +00:00
Richard Smith 082b0035b9 PR19742: cv-qualifiers and ref-qualifiers aren't allowed on functions within
pointer and reference types, even if those types are produced by template
instantiation.

llvm-svn: 208825
2014-05-14 23:23:27 +00:00
Richard Trieu 161132b95b When an overloaded comparison operator returns a reference, do not consider
it for -Wunused-comparion warnings.  This fixes PR19724.

llvm-svn: 208824
2014-05-14 23:22:10 +00:00
Argyrios Kyrtzidis f6d49c36b2 [liblang] Introduce clang_getModuleForFile, which given a CXFile header file, returns the module that contains it, if one exists.
llvm-svn: 208822
2014-05-14 23:14:37 +00:00
Jonathan Roelofs becce11112 Make verbose clang builds also build compiler_rt verbosely
llvm-svn: 208821
2014-05-14 23:07:16 +00:00
Aaron Ballman 9ee54d119c Converting some for loops to use range-based for loops. No functional changes intended.
llvm-svn: 208810
2014-05-14 20:42:13 +00:00
Hans Wennborg 1a3a07471f Rename CodeGenModule::getLLVMLinkageforDeclarator -> getLLVMLinkageForDeclarator
No functionality change.

llvm-svn: 208808
2014-05-14 19:54:53 +00:00
Aaron Ballman 59a72b93a2 Amending r208783 based on a suggestion by David Blaikie.
llvm-svn: 208800
2014-05-14 18:32:59 +00:00
John McCall a16fc89206 When we generate a redeclaration for an
elaborated-type-specifier, place it in the correct
context.

llvm-svn: 208799
2014-05-14 18:31:48 +00:00
Reid Kleckner 47c2f84c9d clang-cl: Fall back immediately if /GR and /fallback were both passed
None of our tests use /fallback, so this lets us gradually add RTTI
support without breaking projects using /fallback.

llvm-svn: 208787
2014-05-14 16:03:05 +00:00
Reid Kleckner cf87e10f9d Don't copy objects with trivial, deleted copy ctors
This affects both the Itanium and Microsoft C++ ABIs.

This is in anticipation of a change to the Itanium C++ ABI, and should
match GCC's current behavior.  The new text will likely be:

"""
Pass an object of class type by value if every copy constructor and
move constructor is deleted or trivial and at least one of them is not
deleted, and the destructor is trivial.
"""
http://sourcerytools.com/pipermail/cxx-abi-dev/2014-May/002728.html

On x86 Windows, we can mostly use the same logic, where we use inalloca
instead of passing by address.  However, on Win64, there are register
parameters, and we have to do what MSVC does.  MSVC ignores the presence
of non-trivial move constructors and only considers the presence of
non-trivial or deleted copy constructors.  If a non-trivial or deleted
copy ctor is present, it passes the argument indirectly.

This change fixes bugs and makes us more ABI compatible with both GCC
and MSVC.

Fixes PR19668.

Reviewers: rsmith

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

llvm-svn: 208786
2014-05-14 16:02:09 +00:00
Aaron Ballman 42f9a8a7f9 Replacing some manual iterations with standard algorithms. No functional changes intended.
llvm-svn: 208783
2014-05-14 15:01:43 +00:00
Aaron Ballman 2f3fc6badd Formatting and style changes; no functional changes intended.
llvm-svn: 208774
2014-05-14 13:03:55 +00:00
Alexey Bataev 301a2d9249 [OPENMP] Fix warning in Release builds.
llvm-svn: 208768
2014-05-14 10:40:54 +00:00
Daniel Jasper 2e8600c02b clang-format: Add clang-format-diff usage examples for SVN.
llvm-svn: 208766
2014-05-14 09:36:11 +00:00
Daniel Jasper 17605d3961 clang-format: Add option to allow short blocks on a single line.
With AllowShortBlocksOnASingleLine, clang-format allows:
  if (a) { return; }

Based on patch by Gonzalo BG, thank you!

llvm-svn: 208765
2014-05-14 09:33:35 +00:00
Hao Liu 9f9492b657 [ARM64]Fix the bug right shift uint64_t by 64 generates incorrect result.
llvm-svn: 208761
2014-05-14 08:59:30 +00:00
NAKAMURA Takumi 5182b5ae0c Sema::FindAllocationFunctions(): Fix \param. [-Wdocumentation]
llvm-svn: 208758
2014-05-14 08:07:56 +00:00
John McCall 2976f8b011 Create a redeclaration when an elaborated type specifier
resolves to an existing declaration if there are attributes
present.

This gives us something to apply the attributes to.

llvm-svn: 208756
2014-05-14 07:54:17 +00:00
David Blaikie aabde05da1 DebugInfo: Avoid creating DILexicalScopeFiles when the filename in the current scope has not changed.
This looks like the right way for this check to work, but there is
another semi-obvious bug, I would think: why is CurLoc not zero'd out
between functions? The possibility for it to bleed between them seems
problematic. (& indeed I caused tests to fail when I fixed this a
different way, by setting CurLoc to SourceLocation() and the end of
EmitFunctionEnd... )

The changes to debug-info-blocks.m are due to a mismatch between the
source manager's file naming and CGDebugInfo's default handling when no
-main-file-name is specified. This actually reveals somewhat of a bug in
the debug info when using source files from standard in, too. See the
comment in CGDebugInfo::CreateCompileUnit for more details.

llvm-svn: 208742
2014-05-14 00:29:00 +00:00
Reid Kleckner 40ca913727 Push record return type classification into CGCXXABI
In the Microsoft C++ ABI, instance methods always return records
indirectly via the second hidden parameter.  This was implemented in
X86_32ABIInfo, but not WinX86_64ABIInfo.

Rather than exposing a handful of boolean methods in the CGCXXABI
interface, we can expose a single method that applies C++ ABI return
value classification rules.

llvm-svn: 208733
2014-05-13 22:05:45 +00:00
Eric Christopher 83fcaa8c66 Make this test target independent.
llvm-svn: 208725
2014-05-13 20:16:43 +00:00
Richard Smith d6f9e73527 PR19729: Delete a bunch of bogus code in Sema::FindAllocationOverload. This
caused us to perform copy-initialization for the parameters of an allocation
function called by a new-expression multiple times, resulting in us rejecting
allocations that passed non-copyable parameters (and much worse things in
MSVC compat mode, where we potentially called this function multiple times).

llvm-svn: 208724
2014-05-13 19:56:21 +00:00
Eric Christopher 4d7f2108e4 Add a requires for the arm-registered-target needed by this test as
well.

llvm-svn: 208722
2014-05-13 19:52:18 +00:00
Joerg Sonnenberger cc1edb5a45 Add __ARM_DWARF_EH__ to signify the use of Itanium ABI for unwind
instructions.

llvm-svn: 208719
2014-05-13 18:58:36 +00:00
Joerg Sonnenberger 4645b44fc6 Test preprocessor defines for NetBSD/ARM.
llvm-svn: 208718
2014-05-13 18:58:00 +00:00
Rafael Espindola ee076a27ce Update for llvm API change.
llvm-svn: 208717
2014-05-13 18:45:53 +00:00
Aaron Ballman 8063c3b80c Fix the AST printer for attributed statements so that it does not print duplicate attribute introducers. Eg) [[clang::fallthrough]] instead of [[[[clang::fallthrough]]]]
llvm-svn: 208706
2014-05-13 16:12:14 +00:00
Aaron Ballman fd7da7690b Updated the test case to show that no diagnostics are expected, and not require emitting the AST until after the AST printing for statement attributes is updated.
llvm-svn: 208703
2014-05-13 15:14:59 +00:00