- Mar 17, 2012
-
-
Anna Zaks authored
Do not display the standard "Returning from 'foo'", when a stack hint is available. llvm-svn: 152964
-
Bill Wendling authored
llvm-svn: 152963
-
Anna Zaks authored
The symbol-aware stack hint combines the checker-provided message with the information about how the symbol was passed to the callee: as a parameter or a return value. For malloc, the generated messages look like this : "Returning from 'foo'; released memory via 1st parameter" "Returning from 'foo'; allocated memory via 1st parameter" "Returning from 'foo'; allocated memory returned" "Returning from 'foo'; reallocation of 1st parameter failed" (We are yet to handle cases when the symbol is a field in a struct or an array element.) llvm-svn: 152962
-
Anna Zaks authored
llvm-svn: 152961
-
Anna Zaks authored
number of steps in the work list. llvm-svn: 152960
-
- Mar 16, 2012
-
-
Benjamin Kramer authored
% is a common character in IR so we'd crash on almost any malformed IR. The diagnostic formatter expects a formatting directive when it sees an unescaped %. llvm-svn: 152956
-
Matt Beaumont-Gay authored
llvm-svn: 152955
-
Bill Wendling authored
store to 1. This allows code-gen to select a more appropriate alignment. If left to zero, an alignment greater than the alignment of the pointer may be selected, causing code-gen to use instructions which require an alignment greater than the pointer guarantees. <rdar://problem/11043589> llvm-svn: 152951
-
Fariborz Jahanian authored
llvm-svn: 152950
-
Fariborz Jahanian authored
// rdar://11063663 llvm-svn: 152949
-
David Blaikie authored
For "int i = NULL;" we would produce: null.cpp:5:11: warning: implicit conversion of NULL constant to integer [-Wconversion] int i = NULL; ~ ^~~~ null.cpp:1:14: note: expanded from macro 'NULL' \#define NULL __null ^~~~~~ But we really shouldn't trace that macro expansion back into the header, yet we still want macro back traces for code like this: \#define FOO NULL int i = FOO; or \#define FOO int i = NULL; FOO While providing appropriate tagging at different levels of the expansion, etc. The included test case exercises these cases & does some basic validation (to ensure we don't have macro expansion notes where we shouldn't, and do where we should) - but doesn't go as far as to validate the source location/ranges used in those notes and warnings. llvm-svn: 152940
-
Nick Lewycky authored
This fixes g++.dg/parse/friend5.C. llvm-svn: 152938
-
Argyrios Kyrtzidis authored
After r150615, which tablegens the group of a diagnostic as an index into the *.inc file, all diagnostic *.inc files depend on all other diagnostic *.td files, because a diagnostic group can be introduced at any of the diagnostic *.td files. llvm-svn: 152937
-
Fariborz Jahanian authored
llvm-svn: 152931
-
David Chisnall authored
This fixes PR 4307. Patch by Eitan Adler! llvm-svn: 152918
-
Axel Naumann authored
Enable incremental parsing by the Preprocessor, where more code can be provided after an EOF. It mainly prevents the tearing down of the topmost lexer. To be used like this: PP.enableIncrementalProcessing(); while (getMoreSource()) { while (Parser.ParseTopLevelDecl(ADecl)) {...} } PP.enableIncrementalProcessing(false); llvm-svn: 152914
-
Richard Smith authored
Reintroduce lazy name lookup table building, ensuring that the lazy building step produces the same lookup table that would be built by the eager step. Avoid building a lookup table for the translation unit outside C++, even in cases where we can't recover the contents of the table from the declaration chain on the translation unit, since we're not going to perform qualified lookup into it anyway. Continue to support lazily building such lookup tables for now, though, since ASTMerge uses them. In my tests, this performs very similarly to ToT with r152608 backed out, for C, Obj-C and C++, and does not suffer from PR10447. llvm-svn: 152905
-
Ted Kremenek authored
llvm-svn: 152900
-
NAKAMURA Takumi authored
test/Driver/linker-opts.c: Mark as XFAIL:cygming, using gcc linker driver. It should be aware of LIBRARY_PATH. llvm-svn: 152896
-
-
Ted Kremenek authored
llvm-svn: 152893
-
Eli Friedman authored
Don't try to create "store atomic" instructions of non-integer types; they aren't supported at the moment. PR12040. llvm-svn: 152891
-
Ted Kremenek authored
Don't know if it is an anathema to include '#' in the warning name. I'm fine with changing it, but this was the most obvious name. llvm-svn: 152886
-
Argyrios Kyrtzidis authored
rdar://10673816 llvm-svn: 152879
-
-
Fariborz Jahanian authored
statements. llvm-svn: 152875
-
Eli Friedman authored
When a variable has a specified asm name, but isn't using the register storage class, the asm name doesn't specify a register. PR12244. llvm-svn: 152873
-
Chad Rosier authored
llvm-svn: 152872
-
Ted Kremenek authored
llvm-svn: 152871
-
- Mar 15, 2012
-
-
Jordy Rose authored
llvm-svn: 152868
-
Fariborz Jahanian authored
llvm-svn: 152867
-
Chad Rosier authored
the behavior of gcc with respect to the -fno-inline and -fno-inline-functions flags. llvm-svn: 152861
-
Ted Kremenek authored
llvm-svn: 152859
-
Ted Kremenek authored
llvm-svn: 152858
-
Ted Kremenek authored
llvm-svn: 152857
-
Jordy Rose authored
[analyzer] Remove AggExprVisitor, a dead class that assisted in visiting C++ expressions with a "base object", because the CFG is now linearized. The only use of AggExprVisitor was in #if 0 code (the analyzer's incomplete C++ support), so there is no actual behavioral change anyway. llvm-svn: 152856
-
Sebastian Redl authored
llvm-svn: 152848
-
Ted Kremenek authored
llvm-svn: 152839
-
Bill Wendling authored
It was pointed out that a checking version of strdup isn't needed. So much for late-night hacking. :) llvm-svn: 152838
-
Anna Zaks authored
BugVisitor DiagnosticPieces. When checkers create a DiagnosticPieceEvent, they can supply an extra string, which will be concatenated with the call exit message for every call on the stack between the diagnostic event and the final bug report. (This is a simple version, which could be/will be further enhanced.) For example, this is used in Malloc checker to produce the ", which allocated memory" in the following example: static char *malloc_wrapper() { // 2. Entered call from 'use' return malloc(12); // 3. Memory is allocated } void use() { char *v; v = malloc_wrapper(); // 1. Calling 'malloc_wrappers' // 4. Returning from 'malloc_wrapper', which allocated memory } // 5. Memory is never released; potential memory leak llvm-svn: 152837
-