Commit Graph

106749 Commits

Author SHA1 Message Date
Douglas Gregor 522d5eb7c3 Diagnose the condition in C++ [temp.expl.spec]p16 that prohibits
specializing a member of an unspecialized template, and recover from
such errors without crashing. Fixes PR10024 / <rdar://problem/9509761>.

llvm-svn: 132677
2011-06-06 15:22:55 +00:00
Eli Friedman bd375f1a3f PR10077: fix fast-isel of extractvalue of aggregate constants.
llvm-svn: 132676
2011-06-06 05:46:34 +00:00
Francois Pichet 7df6805d76 ok now, let's fix that MSVC warning for real.
llvm-svn: 132675
2011-06-06 02:57:59 +00:00
Francois Pichet a5276ec598 Fix MSVC warning:
"unsafe mix of type 'int' and type 'bool' in operation"

llvm-svn: 132674
2011-06-06 02:42:06 +00:00
Chandler Carruth d50f169098 Richard Smith was correct about how the sets should be computed for
this. My suggestion assumed a viable erase method for iterators on
SmallPtrSet.

This patch restores his original pattern.

llvm-svn: 132673
2011-06-05 23:36:55 +00:00
Richard Smith 998a591e32 Fix PR10053: Improve diagnostics and error recovery for code which some compilers incorrectly accept due to a lack of proper support for two-phase name lookup.
llvm-svn: 132672
2011-06-05 22:42:48 +00:00
Benjamin Kramer 59652d36a5 Harden tests for windows path separators.
llvm-svn: 132671
2011-06-05 18:20:05 +00:00
Benjamin Kramer f90b5de834 Toolchain support for Ubuntu Oneiric. Patch by Michael Wild!
llvm-svn: 132669
2011-06-05 16:08:59 +00:00
Benjamin Kramer 440c3b7306 Use path API for path concatenation.
llvm-svn: 132668
2011-06-05 14:36:47 +00:00
Sebastian Redl d201edf1fc Drop most of InitializationSequence::SequenceKind's values. They didn't really contain any information that the step array didn't contain too. This makes debugging dumps a bit less informative, but probably not significantly so. The advantage is that the redundancy is gone, so the code is easier to understand.
ReferenceBinding is still there, because it is used in some unclear code.

llvm-svn: 132667
2011-06-05 13:59:11 +00:00
Sebastian Redl 724bfe18b7 Remove more references to FailedSequence.
llvm-svn: 132666
2011-06-05 13:59:05 +00:00
Howard Hinnant 32208bde75 Move nullptr_t to unversioned namespace: Sean Hunt
llvm-svn: 132665
2011-06-05 13:00:46 +00:00
Sebastian Redl c7ca587512 Remove all references to InitializationSequence::FailedSequence from outside SemaInit.cpp. Replace them with the boolean conversion or the new Failed() function. This is a first step towards removing InitializationSequence::SequenceKind. No functionality change.
llvm-svn: 132664
2011-06-05 12:23:28 +00:00
Sebastian Redl f08872fb29 More std::initializer_list tests.
llvm-svn: 132663
2011-06-05 12:23:21 +00:00
Sebastian Redl 3da3489e49 Parse C++0x generalized initializers.
llvm-svn: 132662
2011-06-05 12:23:16 +00:00
Sebastian Redl 144857f4cc Expand on braced init list tests.
llvm-svn: 132661
2011-06-05 12:23:08 +00:00
Douglas Gregor 377c109f21 Identity and non-identity standard conversion sequences can be
compared even when one is a reference binding and the other is not
(<rdar://problem/9173984>), but the definition of an identity sequence
does not involve lvalue-to-rvalue adjustments (PR9507). Fix both
inter-related issues.

llvm-svn: 132660
2011-06-05 06:15:20 +00:00
Douglas Gregor c507db4f70 Add name mangling for expr .* expr. Fixes PR9983 / <rdar://problem/9486332>.
llvm-svn: 132659
2011-06-05 05:27:58 +00:00
Douglas Gregor 7f139d8103 Allow block returns in C++ with the form
return <expression> ;

in blocks with a 'void' result type, so long as <expression> has type
'void'. This follows the rules for C++ functions.

llvm-svn: 132658
2011-06-05 05:14:41 +00:00
Douglas Gregor 0aa91e0a66 When inferring the result type of a block based on a return statement
with a type-dependent expression, infer the placeholder type
'Context.DependentTy' to indicate that this is just a
placeholder. Fixes PR9982 / <rdar://problem/9486685>.

llvm-svn: 132657
2011-06-05 05:04:23 +00:00
Rafael Espindola 1134ab23df Basic support for macros with explicit arguments.
We still don't handle

* default values
* :req
* :vararg
* \()

llvm-svn: 132656
2011-06-05 02:43:45 +00:00
Rafael Espindola 940a0ee5ca Produce an undefined reference to _GLOBAL_OFFSET_TABLE_ if we have a
VK_GOTOFF reloc. This matches as' behavior, but it is not clear why the linker
might need this, so I added a FIXME.

I could test this by duplicating test/MC/ELF/got.s, but it doesn't look
worthwhile.

llvm-svn: 132655
2011-06-05 01:20:06 +00:00
Jakob Stoklund Olesen 38080e8700 Fix a test that keeps breaking when allocation orders change.
Who said FileCheck couldn't handle arbitrarily complex conditions?

llvm-svn: 132654
2011-06-04 23:34:40 +00:00
Rafael Espindola d1ca71a294 Fix cmake build.
llvm-svn: 132653
2011-06-04 23:22:38 +00:00
Howard Hinnant bd0c160078 noexcept for <stack>. This completes noexcept for Chapter 23 [containers].
llvm-svn: 132652
2011-06-04 22:09:19 +00:00
Richard Smith c2ed270c0f Remove the old implementation of -verify, which has been dead code since r88750.
llvm-svn: 132651
2011-06-04 21:35:57 +00:00
Howard Hinnant 6971d82668 noexcept for <queue>.
llvm-svn: 132650
2011-06-04 21:32:33 +00:00
Nadav Rotem 06bd6d304e TypeLegalizer: Add support for passing of vector-promoted types in registers (copyFromParts/copyToParts).
llvm-svn: 132649
2011-06-04 20:58:08 +00:00
Nadav Rotem 78d19bebe6 TypeLegalizer: Fix a bug in the promotion of elements of integer vectors.
(only happens when using the -promote-elements option).

The correct legalization order is to first try to promote element. Next, we try
to widen vectors.

llvm-svn: 132648
2011-06-04 20:32:01 +00:00
Howard Hinnant 557da866a3 noexcept for <unordered_set>.
llvm-svn: 132647
2011-06-04 20:18:37 +00:00
Howard Hinnant 3714107ed6 noexcept for <unordered_map>.
llvm-svn: 132646
2011-06-04 18:54:24 +00:00
Nick Lewycky 2176cdc98c Refactor parsing of variable names (ie., %foo and @foo) since they have the same
rules. Also refactor "read string until quote" into its own function. No
functionality change!

llvm-svn: 132645
2011-06-04 18:16:26 +00:00
Nick Lewycky 6fde150697 Add more tests for cxa_guard methods. This includes our first two tests using
actual threads!

There's no build file for libcxxabi, so I'll tell you that I built it with this:
$ g++-4.6 -pthread -std=gnu++0x test_guard.cpp ../src/cxa_guard.o -o test_guard

llvm-svn: 132644
2011-06-04 18:01:24 +00:00
Nick Lewycky 34fa1684e7 Add support for @GOTPTOFF in i386 mode.
llvm-svn: 132643
2011-06-04 17:38:07 +00:00
Howard Hinnant e691351098 Made more implementation details of [multi]map/set noexcept.
llvm-svn: 132642
2011-06-04 17:10:24 +00:00
Hans Wennborg 8f7edbf84a Cast unused parameter to void.
llvm-svn: 132641
2011-06-04 16:00:19 +00:00
Howard Hinnant 0e9f71c13f noexcept for <set>. Plus a few fixes to noexcept for <map>.
llvm-svn: 132640
2011-06-04 15:22:34 +00:00
Howard Hinnant 1052ee39cb noexcept for <map>.
llvm-svn: 132639
2011-06-04 14:31:57 +00:00
Bill Wendling 4f163dfed1 If the block that we're threading through is jumped to by an indirect branch,
then we don't want to set the destination in the indirect branch to the
destination. This is because the indirect branch needs its destinations to have
had their block addresses taken. This isn't so of the new critical edge that's
split during this process. If it turns out that the destination block has only
one predecessor, and that being a BB with an indirect branch, then it won't be
marked as 'used' and may be removed.
PR10072

llvm-svn: 132638
2011-06-04 09:42:04 +00:00
Nick Lewycky 7574774874 Revert r132630. GCC passes everything down, we aren't trying to replicate that.
llvm-svn: 132637
2011-06-04 09:06:25 +00:00
Jakob Stoklund Olesen 25b753bb3f Drop a RecordKeeper reference that wasn't necessary.
llvm-svn: 132636
2011-06-04 07:49:55 +00:00
Roman Divacky 5e300b82e2 Adjust the linker for PowerPC64/-m32 on FreeBSD too.
llvm-svn: 132635
2011-06-04 07:40:24 +00:00
Roman Divacky 00859c29bf Make -m32 work on FreeBSD/PowerPC64.
llvm-svn: 132634
2011-06-04 07:37:31 +00:00
Dan Gohman baf1afb289 Add a testcase to demonstrate the problem where phi translation is
ignored for clobbering partial-alias loads.

llvm-svn: 132633
2011-06-04 07:05:05 +00:00
Dan Gohman adf80ae9e4 Reapply r131781, now that the GVN bug with partially-aliasing loads
is disabled.

llvm-svn: 132632
2011-06-04 06:50:18 +00:00
Dan Gohman a471751c24 Disable the main feature of 130180, the elimination of loads that are
redundant with partially-aliasing loads.

When computing what portion of a clobbering load value is needed,
it doesn't consider phi-translation which may have occurred
between the clobbing load and the redundant load.

llvm-svn: 132631
2011-06-04 06:48:50 +00:00
Nick Lewycky 6d92b72e70 GCC passes -z foo directly through to the linker (and yes -z=foo becomes
"-z =foo"). Do the same thing in clang.

llvm-svn: 132630
2011-06-04 06:48:26 +00:00
Nick Lewycky 97864dac76 On linux, -nostdlib was causing a --start-group with no --end-group to be passed
to the linker.

llvm-svn: 132629
2011-06-04 06:27:06 +00:00
Dan Gohman 43efe1c8bd Remove this test, which should have been reverted along with r131781.
llvm-svn: 132628
2011-06-04 06:21:23 +00:00
Roman Divacky 35c669708d Use processor name in the target triple. This fixes PowerPC64 to generate
64bit code for example.

llvm-svn: 132627
2011-06-04 06:15:42 +00:00