- Aug 15, 2011
-
-
Anna Zaks authored
MacOSKeychainAPIChecker: Use llvm::SmallString instead of std::string (as per code review for r137523). llvm-svn: 137633
-
- Aug 13, 2011
-
-
Ted Kremenek authored
Cleanup various declarations of 'Stmt*' to be 'Stmt *', etc. in libAnalyzer and libStaticAnalyzer[*]. It was highly inconsistent, and very ugly to look at. llvm-svn: 137537
-
Ted Kremenek authored
Having a notion of an actual ProgramPointTag will aid in introspection of the analyzer's behavior. For example, the GraphViz output of the analyzer will pretty-print the tags in a useful manner. llvm-svn: 137529
-
Anna Zaks authored
MacOSKeychainAPIChecker: If the allocated data address entered as an enclosing function parameter, skip it to avoid false positives. llvm-svn: 137526
-
- Aug 12, 2011
-
-
Anna Zaks authored
Report errors earlier: on checkDeadSymbols() and clear the state after the symbol we are tracking goes out of scope. Also, perform lazy error checking. Instead of forcing the paths to be split depending one the return value of the allocator, make the return symbol depend on the allocated data symbol, which prolongs its life span to the time when the allocated data symbol becomes dead. llvm-svn: 137523
-
Jordy Rose authored
time. One is cleanup, the other is me being OCD about enum group nesting. llvm-svn: 137517
-
Anna Zaks authored
MacOSKeychainAPIChecker: There is no need to use SymbolMetadata to represent the allocated data symbol, we can just use the symbol corresponding to the SymbolicRegion. This simplifies tracking of the symbol, for example, SymbolMetadata needs to go through extra hoops to stay alive. Make AllocationState internal to the MacOSKeychainAPIChecker class. llvm-svn: 137514
-
Ted Kremenek authored
[analyzer] Introduce new MemRegion, "TypedValueRegion", so that we can separate TypedRegions that implement getValueType() from those that don't. Patch by Olaf Krzikalla! llvm-svn: 137498
-
Anna Zaks authored
1) Change SymbolDependTy map to keep pointers as data. And other small tweaks like making the DenseMap smaller 64->16 elements; remove removeSymbolDependencies() as it will probably not be used. 2) Do not mark dependents live more then once. llvm-svn: 137401
-
- Aug 11, 2011
-
-
Anna Zaks authored
Analyzer Core: Adding support for user-defined symbol dependencies. (For example, the allocated resource symbol only needs to be freed if no error has been returned by the allocator, so a checker might want to make the lifespan of the error code symbol depend on the allocated resource symbol.) Note, by default, the map that holds the dependencies will get destroyed along with the SymbolManager at the end of function exploration. llvm-svn: 137309
-
Anna Zaks authored
Cleanup: remove CleanedSate member and GetState() wrapper from StmtNodeBuilder, not needed as of r137273. llvm-svn: 137284
-
Anna Zaks authored
llvm-svn: 137279
-
Anna Zaks authored
Analyzer Core: In checkDeadSymbols checker callback, provide the state in which the symbols are not yet deleted so that checkers could inspect them. Since we are now always creating a transition in ProcessStmt(), remove the logic for adding a transition when none was generated. TODO: the extra transitions will have to be removed; more cleanups; a checker that tests teh new fucntionality. llvm-svn: 137273
-
- Aug 06, 2011
-
-
Ted Kremenek authored
[analyzer] Start sketching out a new BugReporterVisitor that inspects branches and other expressions to generate interesting path events in diagnostics. llvm-svn: 137012
-
Ted Kremenek authored
[analyzer] Simplify logic for ExprEngine::VisitUnaryExprOrTypeTraitExpr to avoid recursion to subexpression. This exposed bugs in the live variables analysis, and a latent analyzer bug in the SymbolReaper. llvm-svn: 137006
-
Ted Kremenek authored
[analyzer] Change SymbolReaper to store region roots implied by the Environment, allowing it be queried when determining if symbols derived from regions are still live. llvm-svn: 137005
-
Anna Zaks authored
KeychainAPI checker: Track SymbolMetadata instead of MemRegion in checker state so that we could clear the state on evalDeadSymbols; also track the return value. llvm-svn: 137003
-
- Aug 05, 2011
-
-
Anna Zaks authored
KeychainAPI checker: Generate an error on double allocation. Pull out getAsPointeeMemoryRegion so that it could be reused. llvm-svn: 136952
-
- Aug 04, 2011
-
-
Anna Zaks authored
KeychainAPI checker: Track additional pair of SecKeychain APIs. Also, keep exploring the transition on which a call to allocator function failed (to be able to find errors in examples like ErrorCodesFromDifferentAPISDoNotInterfere). llvm-svn: 136930
-
Anna Zaks authored
KeychainAPI checker: Refactor to make it easier to add more allocator/deallocator API pairs. Add the allocator function ID to the checker state. Better comments. llvm-svn: 136889
-
Anna Zaks authored
llvm-svn: 136852
-
Anna Zaks authored
KeychainAPI checker: Add basic diagnostics. Track MemoryRegion istead of SymbolicRef since the address might not be a symbolic value in some cases, for example in fooOnlyFree() test. llvm-svn: 136851
-
Ted Kremenek authored
llvm-svn: 136849
-
Ted Kremenek authored
[analyzer] rename all experimental checker packages to have 'experimental' be the common root package. llvm-svn: 136835
-
- Aug 03, 2011
-
-
Ted Kremenek authored
[analyzer] Introduce MallocOverflowSecurityChecker, a simple flow-sensitive checker that may be useful for security auditing. This checker is currently too noisy to be on by default. llvm-svn: 136804
-
Anna Zaks authored
Static Analyzer diagnostics visualization: when the last location on a path is end of the function, the arrow should point to the closing brace, not the statement before it. Patch by Ted Kremenek. llvm-svn: 136761
-
- Aug 02, 2011
-
-
Ted Kremenek authored
[analyzer] Drastically simplify ExprEngine::VisitInitListExpr() by assuming all initializer expressions have already been evaluated. llvm-svn: 136706
-
Anna Zaks authored
KeychainAPI checker: only check the paths on which the allocator function returned noErr. (+ minor cleanup) llvm-svn: 136694
-
Anna Zaks authored
Add a skeleton for the Keychain Services API Checker. Register it as OSX experimental for now. Note, the checker still does not handle tracking of escaped values, taking into account the return value of the allocator functions, nor the actual bug reporting.. llvm-svn: 136659
-
- Jul 31, 2011
-
-
Benjamin Kramer authored
llvm-svn: 136581
-
- Jul 29, 2011
-
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitDeclStmt because it isn't needed anymore. llvm-svn: 136522
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitCompoundLiteralExpr because it isn't needed anymore. llvm-svn: 136521
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitCastExpr because it isn't needed anymore. llvm-svn: 136520
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitObjCForCollectionStmt because it isn't needed anymore. llvm-svn: 136519
-
Ted Kremenek authored
[analyzer] Remove explicit argument processing from ExprEngine::VisitObjCMessage() since it is no longer needed. llvm-svn: 136518
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitLValObjCIvarRefExpr because it isn't needed anymore. llvm-svn: 136517
-
Ted Kremenek authored
llvm-svn: 136516
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitObjCPropertyRefExpr because it isn't needed anymore. llvm-svn: 136515
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitCallExpr because it isn't needed anymore. llvm-svn: 136514
-
Ted Kremenek authored
[analyzer] Remove recursive visitation in ExprEngine::VisitMemberExpr because it isn't needed anymore. llvm-svn: 136513
-