- Jun 19, 2012
-
-
Kaelyn Uhrain authored
because it expects a reference and receives a non-l-value. For example, given: int foo(int &); template<int x> void b() { foo(x); } clang will now print "expects an l-value for 1st argument" instead of "no known conversion from 'int' to 'int &' for 1st argument". The change in wording (and associated code to detect the case) was prompted by comment #5 in PR3104, and should be the last bit of work needed for the bug. llvm-svn: 158691
-
Ted Kremenek authored
the compiler predefines buffer. These are essentially part of the Objective-C language. llvm-svn: 158690
-
Jordan Rose authored
Per post-commit review, it's not appropriate to use ExtWarn in C++, because we can't prove that the inline function will actually be defined in more than one place (and thus we can't prove that this violates the ODR). This removes the warning entirely from uses in the main source file in C++. llvm-svn: 158689
-
Nuno Lopes authored
revert r158660, since Chris has some issues with this patch (namely using code to reprent information only used by the compiler) Original commit msg: add the 'alloc' metadata node to represent the size of offset of buffers pointed to by pointers. This metadata can be attached to any instruction returning a pointer llvm-svn: 158688
-
Michael J. Spencer authored
llvm-svn: 158687
-
Tanya Lattner authored
llvm-svn: 158686
-
David Blaikie authored
Based on review discussion of r158638 with Chandler Carruth, Tobias von Koch, and Duncan Sands and a -Wmaybe-uninitialized warning from GCC. llvm-svn: 158685
-
Manman Ren authored
This change is to be enabled in clang. rdar://9877866 llvm-svn: 158684
-
Jordan Rose authored
This includes treating anonymous namespaces like internal linkage, and allowing const variables to be used even if internal. The whole thing's been broken out into a separate function to avoid nested ifs. llvm-svn: 158683
-
- Jun 18, 2012
-
-
Jordan Rose authored
diag-build acts as a wrapper for 'diagtool show-enabled', in the same way that scan-build acts as a wrapper for the static analyzer. The common case is simple: use 'diag-build make' or 'diag-build xcodebuild' to list the warnings enabled for the first compilation command we see. Other build systems require you to manually specify "dry-run" and "use $CC and $CXX"; if there is a build system you are interested in, please add it to the switch statement. diag-build is fairly stupid right now, but it serves its basic purpose. Hopefully it can grow to meet any additional requirements. llvm-svn: 158682
-
Jordan Rose authored
llvm-svn: 158681
-
Hal Finkel authored
This patch changes the type used to hold the FU bitset from unsigned to uint64_t. This will be needed for some upcoming PowerPC itineraries. llvm-svn: 158679
-
Nick Kledzik authored
llvm-svn: 158678
-
Michael J. Spencer authored
Patch by Mikael Lyngvig! llvm-svn: 158677
-
Matt Beaumont-Gay authored
This simplifies the code a little bit, since these functions all took a SourceManager parameter and called a bunch of methods on it, and makes the functions available to other users. llvm-svn: 158676
-
Marshall Clow authored
llvm-svn: 158675
-
Jim Grosbach authored
The NOP, WFE, WFI, SEV and YIELD instructions are all hints w/ a different immediate value in bits [7,0]. Define a generic HINT instruction and refactor NOP, WFI, WFI, SEV and YIELD to be assembly aliases of that. rdar://11600518 llvm-svn: 158674
-
Jim Grosbach authored
When returning a 'cannot match due to missing CPU features' error code, if there are multiple potential matches with different feature sets, return the smallest set of missing features from the alternatives as that's most likely to be the one that's desired. llvm-svn: 158673
-
Simon Atanasyan authored
llvm-svn: 158670
-
Joerg Sonnenberger authored
This exploits the relative order of the arguments and/or checks already made in the functions. llvm-svn: 158669
-
James Dennett authored
* Escaped "::" where needed to prevent Doxygen trying to make links; * Updated one mention of C++0x to refer to C++11; * Fixed a \brief summary to make it somewhat concise. llvm-svn: 158667
-
Jordan Rose authored
This handles the very common case of people writing inline functions in their main source files and not tagging them as inline. These cases should still behave as the user intended. (The diagnostic is still emitted as an extension.) I'm reworking this code anyway to account for C++'s equivalent restriction in [basic.def.odr]p6, but this should get some bots back to green. llvm-svn: 158666
-
Fariborz Jahanian authored
// rdar://11676972 llvm-svn: 158665
-
Michael J. Spencer authored
Patch by Nikola Smiljanic! llvm-svn: 158664
-
rdar://problem/11634669Nuno Lopes authored
crash on invalid function decl with alloc_size attribute llvm-svn: 158663
-
Nuno Lopes authored
alloc_size attribute: there's nothing wrong with alloc_size(1,1). It just means the function allocates x^2 bytes. GCC also accepts this syntax llvm-svn: 158662
-
Alexis Hunt authored
Now, as long as the 'Namespaces' variable is correct inside Attr.td, the generated code will correctly admit a C++11 attribute only when it has the appropriate namespace(s). llvm-svn: 158661
-
Nuno Lopes authored
This metadata can be attached to any instruction returning a pointer llvm-svn: 158660
-
Joel Jones authored
when a compile time constant is known. This occurs when implicitly zero extending function arguments from 16 bits to 32 bits. The 8 bit case doesn't need to be handled, as the 8 bit constants are encoded directly, thereby not needing a separate load instruction to form the constant into a register. <rdar://problem/11481151> llvm-svn: 158659
-
Alexey Samsonov authored
llvm-svn: 158658
-
Alexey Samsonov authored
[TSan] kill some linux-specific code in favor of code in common runtime: reuse wrappers for mmap routines, ProcessMaps iterator, thread stack calculation llvm-svn: 158657
-
Chandler Carruth authored
temporarily reverted. This test is annoyingly overspecified, but I don't know of another way to thoroughly test the saving and restoring of the registers. While this will have to be adjusted even with the issue fixed in order to re-apply r158087, those adjustments should very clearly indicate that it is still correct (%esp getting restored prior to pops), whereas without it, this case can easily slip under the radar. Still, any suggestions for improvements are very welcome. All credit to Matt Beaumont-Gay for reducing this out of an insane Address Sanitizer crash to a reasonably small seg-faulting C program when built with -mstackrealign. I just reduced it to IR, which was much simpler. =] llvm-svn: 158656
-
Alexey Samsonov authored
llvm-svn: 158655
-
Chandler Carruth authored
This patch causes problems when both dynamic stack realignment and dynamic allocas combine in the same function. With this patch, we no longer build the epilog correctly, and silently restore registers from the wrong position in the stack. Thanks to Matt for tracking this down, and getting at least an initial test case to Chad. I'm going to try to check a variation of that test case in so we can easily track the fixes required. llvm-svn: 158654
-
Michael J. Spencer authored
__forceinline is a combination of the inline keyword and __attribute__((always_inline)) llvm-svn: 158653
-
Richard Smith authored
also deal with '>>>' (in CUDA), '>=', and '>>='. Fix the FixItHints logic to deal with cases where the token is followed by an adjacent '=', '==', '>=', '>>=', or '>>>' token, where a naive fix-it would result in a differing token stream on a re-lex. llvm-svn: 158652
-
Joerg Sonnenberger authored
the member expression is in parentheses. llvm-svn: 158651
-
- Jun 17, 2012
-
-
NAKAMURA Takumi authored
llvm-svn: 158650
-
NAKAMURA Takumi authored
llvm-svn: 158649
-
Benjamin Kramer authored
llvm-svn: 158648
-