summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [PECOFF][Writer] Fixed a bug that an empty section is emit to the section ↵Rui Ueyama2013-07-112-36/+34
| | | | | | header. llvm-svn: 186066
* Fix indentation. No functional change.Craig Topper2013-07-111-8/+8
| | | | llvm-svn: 186065
* Fix a warning.Nadav Rotem2013-07-111-2/+1
| | | | llvm-svn: 186064
* Consolidate more lit tests.Nadav Rotem2013-07-113-62/+54
| | | | llvm-svn: 186063
* Consolidate some of the lit tests.Nadav Rotem2013-07-114-75/+57
| | | | llvm-svn: 186062
* PR5066: If a declarator cannot have an identifier, and cannot possibly beRichard Smith2013-07-117-1/+59
| | | | | | | | | followed by an identifier, then diagnose an identifier as being a bogus part of the declarator instead of tripping over it. Improves diagnostics for cases like std::vector<const int *p> my_vec; llvm-svn: 186061
* Consolidate some of the lit tests.Nadav Rotem2013-07-115-61/+191
| | | | llvm-svn: 186060
* Documentation fixes - the rest of DeclCXX.h:James Dennett2013-07-111-114/+130
| | | | | | | | | * More \brief additions/fixes; * Fix some misleading comments about C++11's explicit conversion operators; * Mark up some \code examples; * Add \file documentation. llvm-svn: 186059
* SLPVectorizer: refactor the code that places extracts. Place the code that ↵Nadav Rotem2013-07-111-41/+131
| | | | | | decides where to put extracts in the build-tree phase. This allows us to take the cost of the extracts into account. llvm-svn: 186058
* Teach TailRecursionElimination to handle certain cases of nocapture escaping ↵Michael Gottesman2013-07-113-89/+171
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | allocas. Without the changes introduced into this patch, if TRE saw any allocas at all, TRE would not perform TRE *or* mark callsites with the tail marker. Because TRE runs after mem2reg, this inadequacy is not a death sentence. But given a callsite A without escaping alloca argument, A may not be able to have the tail marker placed on it due to a separate callsite B having a write-back parameter passed in via an argument with the nocapture attribute. Assume that B is the only other callsite besides A and B only has nocapture escaping alloca arguments (*NOTE* B may have other arguments that are not passed allocas). In this case not marking A with the tail marker is unnecessarily conservative since: 1. By assumption A has no escaping alloca arguments itself so it can not access the caller's stack via its arguments. 2. Since all of B's escaping alloca arguments are passed as parameters with the nocapture attribute, we know that B does not stash said escaping allocas in a manner that outlives B itself and thus could be accessed indirectly by A. With the changes introduced by this patch: 1. If we see any escaping allocas passed as a capturing argument, we do nothing and bail early. 2. If we do not see any escaping allocas passed as captured arguments but we do see escaping allocas passed as nocapture arguments: i. We do not perform TRE to avoid PR962 since the code generator produces significantly worse code for the dynamic allocas that would be created by the TRE algorithm. ii. If we do not return twice, mark call sites without escaping allocas with the tail marker. *NOTE* This excludes functions with escaping nocapture allocas. 3. If we do not see any escaping allocas at all (whether captured or not): i. If we do not have usage of setjmp, mark all callsites with the tail marker. ii. If there are no dynamic/variable sized allocas in the function, attempt to perform TRE on all callsites in the function. Based off of a patch by Nick Lewycky. rdar://14324281. llvm-svn: 186057
* Documentation cleanup for DeclCXX.h:James Dennett2013-07-111-179/+197
| | | | | | | | | * Fixing up \brief summaries (adding some, making some briefer); * Standardizing on \commands, not @commands; * Update C++0x references to C++11; * Fix typos and Doxygen warnings. llvm-svn: 186056
* clang/test/CodeGen/c11atomics.c: Fix testcase for -Asserts since r186054.NAKAMURA Takumi2013-07-111-1/+1
| | | | llvm-svn: 186055
* Fix build.Eli Friedman2013-07-111-2/+2
| | | | | | Sorry about that. llvm-svn: 186054
* Add a __builtin_addressof that performs the same functionality as the built-inRichard Smith2013-07-117-2/+71
| | | | | | | | | | | & operator (ignoring any overloaded operator& for the type). The purpose of this builtin is for use in std::addressof, to allow it to be made constexpr; the existing implementation technique (reinterpret_cast to some reference type, take address, reinterpert_cast back) does not permit this because reinterpret_cast between reference types is not permitted in a constant expression in C++11 onwards. llvm-svn: 186053
* Make CheckAddressOfOperand a member of Sema so it can be reused byRichard Smith2013-07-112-35/+36
| | | | | | __builtin_addressof. llvm-svn: 186052
* Move r186044 tests into CodeGen/X86Hal Finkel2013-07-112-4/+2
| | | | | | | | I had thought that these tests could be target-neutral, but in practice this is not the case (on some targets, like Hexagon and Darwin), they trigger an assert (a different assert than the one that r186044 fixes). llvm-svn: 186051
* Add a -remote-file option to “target create” to specify the location of ↵Jim Ingham2013-07-111-2/+15
| | | | | | the executable on a remote system (if debugging remotely using debugserver on the target system.) This gets us closer to being able to set up a remote debugging session from the lldb command line. llvm-svn: 186050
* Simplify atomic load/store IRGen.Eli Friedman2013-07-116-149/+71
| | | | | | Also fixes a couple minor bugs along the way; see testcases. llvm-svn: 186049
* Fix some grammar errors.Richard Smith2013-07-111-4/+4
| | | | llvm-svn: 186048
* Fix documentation:Richard Smith2013-07-111-5/+11
| | | | | | | | | | | | | | #if defined(__has_foo("X")) && __has_foo("X") is not a correct way to portably use __has_foo, because it is expanded to #if 0 && 0("X") ... which is ill-formed. Also add a missing ')'. llvm-svn: 186047
* Set REQUIRES shell on the test cases for r186044Hal Finkel2013-07-102-0/+2
| | | | | | Trying to fix the i686-mingw32 build. llvm-svn: 186046
* XFAIL the test cases for r186044 on HexagonHal Finkel2013-07-102-0/+2
| | | | | | | For some reason, the Hexagon backend does not reject these invalid static initializer expressions, but instead crashes in AsmPrinter::EmitGlobalConstant. llvm-svn: 186045
* Don't assert if we can't constant fold extract/insertvalueHal Finkel2013-07-103-8/+37
| | | | | | | | | | | | | | | A non-constant-foldable static initializer expression containing insertvalue or extractvalue had been causing an assert: Constants.cpp:1971: Assertion `FC && "ExtractValue constant expr couldn't be folded!"' failed. Now we report a more-sensible "Unsupported expression in static initializer" error instead. Fixes PR15417. llvm-svn: 186044
* Remove this test for now.Rafael Espindola2013-07-101-7/+0
| | | | | | | It is not reliable to depend on the output of llvm_unreachable. The original change will have proper tests when llvm-ar moves to lib/Object (soon). llvm-svn: 186043
* CommandLine.rst: remove tiny bit of bad mark-upHans Wennborg2013-07-101-1/+1
| | | | llvm-svn: 186042
* Find the symbol table on archives created on OS X.Rafael Espindola2013-07-102-3/+21
| | | | llvm-svn: 186041
* If we friend a declaration twice, that should not make it visible to nameRichard Smith2013-07-108-28/+66
| | | | | | | | | lookup in the surrounding context. Slightly rework how we handle friend declarations to inherit the visibility of the prior declaration, rather than setting a friend declaration to be visible whenever there was a prior declaration. llvm-svn: 186040
* Stop process monitor from ProcessPOSIX::FinalizeAndrew Kaylor2013-07-104-6/+17
| | | | llvm-svn: 186039
* Move tests from test/Archive to test/Object.Rafael Espindola2013-07-1018-46/+23
| | | | | | | | There is no lib/Archive anymore and some archive tests were in test/Archive and others in test/Object. Since archive is just one of the formats supported by lib/Object, test/Object is probably the best location. llvm-svn: 186038
* ObjC migrator: Improve on hueristics.Fariborz Jahanian2013-07-105-13/+57
| | | | | | | | | | | | migrate to 'copy attribute if Object class implements NSCopying otherwise assume implied 'strong'. Remove lifetime qualifier on property as it has moved to property's attribute. Added TODO comment for future work by poking into setter implementation. llvm-svn: 186037
* Add a comment.Adrian Prantl2013-07-101-0/+39
| | | | llvm-svn: 186035
* Put ELF COMDAT relocations into the relevant COMDAT group.Tim Northover2013-07-103-3/+39
| | | | | | | | Patch from Игорь Пашев (I do hope we support utf-8 commit messages; I also hope he'll forgive me for transliterating it as Igor Pashev in case things go horribly wrong). llvm-svn: 186034
* Add support for listing inferior thread names on Linux.Matt Kopec2013-07-107-36/+112
| | | | llvm-svn: 186033
* Remove trailing whitespacStephen Lin2013-07-101-2/+2
| | | | llvm-svn: 186032
* Add a testcase for r186014.Adrian Prantl2013-07-101-0/+139
| | | | llvm-svn: 186031
* Use a LexicalScope here since it is one and it will encapsulateEric Christopher2013-07-101-12/+2
| | | | | | the two sets of debug scope and cleanup scope. llvm-svn: 186030
* Don't crash in 'llvm -s' when an archive has no symtab.Rafael Espindola2013-07-103-22/+38
| | | | llvm-svn: 186029
* [analyzer] Remove bogus assert: in C++11, 'new' can do list-initialization.Jordan Rose2013-07-102-2/+10
| | | | | | | | | | | | | | Previously, we asserted that whenever 'new' did not include a constructor call, the type must be a non-record type. In C++11, however, uniform initialization syntax (braces) allow 'new' to construct records with list-initialization: "new Point{1, 2}". Removing this assertion should be perfectly safe; the code here matches what VisitDeclStmt does for regions allocated on the stack. <rdar://problem/14403437> llvm-svn: 186028
* Fix %t typo in Ocaml bindings test.Reid Kleckner2013-07-101-3/+3
| | | | llvm-svn: 186027
* [objc-arc] Changed 'mode: c++' => 'C++' at Nick Lewycky's suggestion. Also ↵Michael Gottesman2013-07-107-7/+7
| | | | | | removed unnecessary mode: c++ lines from .cpp files. llvm-svn: 186026
* Changed "mode: c++" => "C++" at the suggestion of Nick Lewycky.Michael Gottesman2013-07-101-1/+1
| | | | llvm-svn: 186025
* Add a hook RecursiveASTVisitor::TraverseLambdaBody, to enable visitors toJames Dennett2013-07-102-2/+42
| | | | | | | | | | | | | | | | use/maintain additional state from the LambdaExpr while visiting the body of a LambdaExpr. One use for this arises because Clang's AST currently holds lambda bodies in a form prior to their adjustment to refer to captured copies of local variables, and so some clients will need access to the lambda's closure type in order to query how to map VarDecl*s to the FieldDecls of their by-copy captures. This hook is sufficient for at least one such client; to do this without such a hook would require the client to re-implement the whole of TraverseLambdaExpr, which is non-trivial and would likely be more brittle. llvm-svn: 186024
* Adding a summary for ObjC blocksEnrico Granata2013-07-101-0/+7
| | | | llvm-svn: 186023
* Improved tests (and fixed a bug in the tests); thanks to Richard Smith for ↵Marshall Clow2013-07-101-2/+13
| | | | | | the suggestion llvm-svn: 186022
* Update doxygen comment to match renamed parameters.Benjamin Kramer2013-07-101-2/+2
| | | | | | Found by -Wdocumentation. llvm-svn: 186021
* Fixed an issue introduced with my last fix where the command and sequence ID ↵Greg Clayton2013-07-101-1/+1
| | | | | | extraction were moved causing them to be reversed. llvm-svn: 186020
* Offer typo suggestions for 'using' declarations.Kaelyn Uhrain2013-07-103-4/+152
| | | | | | Patch courtesy of Luke Zarko <zarko@google.com> llvm-svn: 186019
* MemoryBuffer::getFile handles zero sized files, no need to duplicate the test.Rafael Espindola2013-07-101-21/+2
| | | | llvm-svn: 186018
* Replacing an empty switch with its moral equivalent. No functional changes ↵Aaron Ballman2013-07-102-8/+2
| | | | | | intended. llvm-svn: 186017
* Use status to implement file_size.Rafael Espindola2013-07-103-36/+14
| | | | | | | | | | The status function is already using a syscall that returns the file size. Remember it and implement file_size as a simple wrapper. No functionally change, but clients that already use status now can avoid calling file_size. llvm-svn: 186016
OpenPOWER on IntegriCloud