- Mar 24, 2012
-
-
Jordy Rose authored
[analyzer] Add a clone() method to BugReporterVisitor, so that we'll be able to reset diagnostic generation. llvm-svn: 153368
-
- Mar 23, 2012
-
-
Ted Kremenek authored
Avoid applying retain/release effects twice in RetainCountChecker when a function call was inlined (i.e., we do not need to apply summaries in such cases). llvm-svn: 153309
-
- Mar 22, 2012
-
-
Ted Kremenek authored
"Teach" RetainCountChecker about dispatch_set_context, which can indirectly free its argument later. Fixes <rdar://problem/11059275>. llvm-svn: 153244
-
- Mar 21, 2012
-
-
Anna Zaks authored
So that others could use it as well. No functionality change. llvm-svn: 153211
-
- Mar 18, 2012
-
-
Jordy Rose authored
[analyzer] Use a FoldingSet to cache simple RetainSummary instances, rather than explicitly keeping DoNothing and StopTracking summaries and nothing else. I tried to test the effects of this change on memory usage and run time, but what I saw on retain-release.m was indistinguishable from noise (debug and release builds). Even so, some caveman profiling showed 101 cache hits that we would have generated new summaries for before (i.e. not default or stop summaries), and the more code we analyze, the more memory we should save. Maybe we should have a standard project for benchmarking the retain count checker's memory and time? llvm-svn: 153007
-
- Mar 17, 2012
-
-
Jordy Rose authored
[analyzer] Unify retain-count summary generation for class and instance methods. No functionality change. llvm-svn: 153001
-
Jordy Rose authored
The cocoa::deriveNamingConventions helper is just using method families anyway now, and the way RetainSummaryTemplate works means we're allocating an extra summary for every method with a relevant family. Also, fix RetainSummaryTemplate to do the right thing w/r/t annotating an /existing/ summary. This was probably the real cause of <rdar://problem/10824732> and the fix in r152448. llvm-svn: 152998
-
Jordy Rose authored
[analyzer] Don't claim an object was returned with +1 retain count before counting autoreleases. Fixes PR10376. (Also, 80-column violations.) llvm-svn: 152976
-
- Mar 11, 2012
-
-
David Blaikie authored
The member variable is always "LangOpts" and the member function is always "getLangOpts". Reviewed by Chris Lattner llvm-svn: 152536
-
- Mar 10, 2012
-
-
Ted Kremenek authored
Teach RetainCountChecker about mixing method families with explicit annotations. Fixes <rdar://problem/10824732>. llvm-svn: 152448
-
- Mar 09, 2012
-
-
Ted Kremenek authored
Essentially, a bug centers around a story for various symbols and regions. We should only include the path diagnostic events that relate to those symbols and regions. The pruning is done by associating a set of interesting symbols and regions with a BugReporter, which can be modified at BugReport creation or by BugReporterVisitors. This patch reduces the diagnostics emitted in several of our test cases. I've vetted these as having desired behavior. The only regression is a missing null check diagnostic for the return value of realloc() in test/Analysis/malloc-plist.c. This will require some investigation to fix, and I have added a FIXME to the test case. llvm-svn: 152361
-
- Mar 06, 2012
-
-
Ted Kremenek authored
llvm-svn: 152139
-
- Feb 28, 2012
- Feb 25, 2012
-
-
Ted Kremenek authored
RetainCountChecker: don't adjust the retain count when analyzing a ReturnStmt unless we are in the top-level call frame. We can do more later, but this makes the checker self-consistent (and fixes a crash). llvm-svn: 151426
-
- Feb 18, 2012
-
-
-
Ted Kremenek authored
Have conjured symbols depend on LocationContext, to add context sensitivity for functions called more than once. llvm-svn: 150849
-
- Feb 14, 2012
-
-
Anna Zaks authored
(In response of Ted's review of r150112.) This moves the logic which checked if a symbol escapes through a parameter to invalidateRegionCallback (instead of post CallExpr visit.) To accommodate the change, added a CallOrObjCMessage parameter to checkRegionChanges callback. llvm-svn: 150513
-
- Feb 07, 2012
-
-
Benjamin Kramer authored
llvm-svn: 149982
-
Ted Kremenek authored
llvm-svn: 149939
-
- Feb 05, 2012
-
-
Dylan Noblesmith authored
(I was going to fix the TODO about DenseMap too, but that would break self-host right now. See PR11922.) llvm-svn: 149799
-
Dylan Noblesmith authored
llvm-svn: 149798
-
- Feb 04, 2012
-
-
Benjamin Kramer authored
Fix all the transitive include users. llvm-svn: 149783
-
- Jan 26, 2012
-
-
Ted Kremenek authored
At this point this is largely cosmetic, but it opens the door to replace ProgramStateRef with a smart pointer that more eagerly acts in the role of reclaiming unused ProgramState objects. llvm-svn: 149081
-
- Jan 17, 2012
-
-
David Blaikie authored
Remove unreachable code in Clang. (replace with llvm_unreachable where appropriate or when GCC requires it) llvm-svn: 148292
-
David Blaikie authored
This allows -Wswitch-enum to find switches that need updating when these enums are modified. llvm-svn: 148281
-
- Jan 06, 2012
-
-
Ted Kremenek authored
(Stmt*,LocationContext*) pairs to SVals instead of Stmt* to SVals. This is needed to support basic IPA via inlining. Without this, we cannot tell if a Stmt* binding is part of the current analysis scope (StackFrameContext) or part of a parent context. This change introduces an uglification of the use of getSVal(), and thus takes two steps forward and one step back. There are also potential performance implications of enlarging the Environment. Both can be addressed going forward by refactoring the APIs and optimizing the internal representation of Environment. This patch mainly introduces the functionality upon when we want to build upon (and clean up). llvm-svn: 147688
-
- Jan 04, 2012
-
-
Ted Kremenek authored
llvm-svn: 147505
-
- Dec 22, 2011
-
-
Ted Kremenek authored
llvm-svn: 147139
-
- Dec 05, 2011
-
-
Anna Zaks authored
of relying on SymbolID. This way any expression can be printed (not only SymbolData). llvm-svn: 145829
-
- Dec 01, 2011
-
-
Anna Zaks authored
We are getting name of the called function or it's declaration in a few checkers. Refactor them to use the helper function in the CheckerContext. llvm-svn: 145576
-
- Nov 14, 2011
-
-
Ted Kremenek authored
[static analyzer] Tweak RetainCountChecker's diagnostics to correctly indicate if a message was due to a property access. This can potentially be refactored for other clients, and this is a regression from the refactoring of property acceses. llvm-svn: 144571
-
- Nov 01, 2011
-
-
Anna Zaks authored
Remove unnecessary calls to CheckerContext::getPredecessor() + Comments. llvm-svn: 143513
-
- Oct 26, 2011
- Oct 25, 2011
-
-
Anna Zaks authored
A step toward making sure that diagnostics report should only be generated though the CheckerContext and not though BugReporter or ExprEngine directly. llvm-svn: 142947
-
Anna Zaks authored
Remove dead members/parameters: ProgramState, respondsToCallback, autoTransition. Remove addTransition method since it's the same as generateNode. Maybe we should rename generateNode to genTransition (since a transition is always automatically generated)? llvm-svn: 142946
-
Anna Zaks authored
Get rid of the EndOfPathBuilder completely. Use the generic NodeBuilder to generate nodes. Enqueue the end of path frontier explicitly. llvm-svn: 142943
-
- Oct 19, 2011
-
-
Anna Zaks authored
ExprEngineBuilders is not used. llvm-svn: 142450
-
Anna Zaks authored
[analyzer] Node Builder refactoring: Introduce a simple Node Builder responsible for generating the node frontier. Currently we have a bunch of different node builders which provide some common functionality but are difficult to refactor. Each builder generates nodes of different kinds and calculates the frontier nodes, which should be propagated to the next step (after the builder dies). Introduce a new NodeBuilder which provides very basic node generation facilities but takes care of the second problem. The idea is that all the other builders will eventually use it. Use this builder in CheckerContext instead of StmtNodeBuilder (the way the frontier is propagated to the StmtBuilder is a hack and will be removed later on). llvm-svn: 142443
-