| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
a BugReporter&. This paves the way for pulling some of the retain/release checker into a "Checker" class.
llvm-svn: 85971
|
|
|
|
|
|
| |
from CFRefCount.cpp to ASTContext.h. These functions are likely to be generally useful.
llvm-svn: 85886
|
|
|
|
| |
llvm-svn: 85867
|
|
|
|
|
| |
Fixes: <rdar://problem/7358899>
llvm-svn: 85864
|
|
|
|
|
|
|
| |
before '_' when determining Cocoa fundamental rule.
Fixes: <rdar://problem/7265711>
llvm-svn: 84569
|
|
|
|
|
|
| |
are updated.
llvm-svn: 84447
|
|
|
|
| |
llvm-svn: 84436
|
|
|
|
| |
llvm-svn: 84342
|
|
|
|
| |
llvm-svn: 84341
|
|
|
|
|
|
|
|
| |
touched by StoreManager::InvalidateRegion().
This fixes <rdar://problem/7257223> and <rdar://problem/7283470>.
llvm-svn: 84223
|
|
|
|
|
|
| |
This fixes <rdar://problem/7306898>
llvm-svn: 84213
|
|
|
|
|
|
| |
summaries. No functionality change.
llvm-svn: 84210
|
|
|
|
| |
llvm-svn: 84157
|
|
|
|
|
|
|
|
|
|
| |
'CVPixelBufferCreateWithPlanarBytes()' and
'CVPixelBufferCreateWithBytes' (Core Video API) can indirectly release
a pixel buffer object via a callback.
This fixes <rdar://problem/7283567>.
llvm-svn: 84064
|
|
|
|
|
|
|
|
| |
the data argument) should not be tracked further until we support full IPA.
(fixes <rdar://problem/7299394>)
llvm-svn: 84047
|
|
|
|
| |
llvm-svn: 83204
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
<rdar://problem/6914474> checker doesn't realize that variable might
have been assigned if a pointer to that variable was passed to another
function via a structure
The problem here was the RegionStoreManager::InvalidateRegion didn't
invalidate the bindings of invalidated regions. This required a
rewrite of this method using a worklist.
As part of this fix, changed ValueManager::getConjuredSymbolVal() to
require a 'void*' SymbolTag argument. This tag is used to
differentiate two different symbols created at the same location.
llvm-svn: 82920
|
|
|
|
|
|
| |
(via integer) to function call not invalidated
llvm-svn: 82523
|
|
|
|
|
|
|
|
|
|
|
| |
Several of the existing methods were identical to their respective
specializations, and so have been removed entirely. Several more 'leaf'
optimizations were introduced.
The getAsFoo() methods which imposed extra conditions, like
getAsObjCInterfacePointerType(), have been left in place.
llvm-svn: 82501
|
|
|
|
|
|
| |
to a noreturn or panic function
llvm-svn: 81803
|
|
|
|
|
|
| |
local node information.
llvm-svn: 81433
|
|
|
|
| |
llvm-svn: 81346
|
|
|
|
|
|
|
| |
objects that are not automatically garbage collected. This fixes
<rdar://problem/7174400>.
llvm-svn: 80387
|
|
|
|
| |
llvm-svn: 80294
|
|
|
|
|
|
| |
greatly simplifying the logic of the analyzer in many places. We now only distinguish between block-level expressions and subexpressions in Environment::RemoveDeadBindings and GRState pretty-printing.
llvm-svn: 80194
|
|
|
|
|
|
|
| |
Now AnalysisManager is the only place we can get CodeDecl.
This leads to an API change: GRState::bindExpr() now takes the CFG argument.
llvm-svn: 79980
|
|
|
|
| |
llvm-svn: 79973
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SelfRegion represented the object bound to 'self' (when analyzing Objective-C
methods) upon entry to a method. Having this region stored on the side ignores
the current stack frame that we might be analyzing (among other things), and is
a problem for interprocedural analysis.
For RegionStoreManager, the value for SelfRegion is just lazily created.
For BasicStoreManager, the value for SelfRegion is bound eagerly to 'self', but
no explicit tracking of SelfRegion on the side is made.
As part of this change, remove the restriction in BasicStoreManager that we only
track ivars for 'self'. This shouldn't actually change anything in terms of
precision, and simplifies the logic.
llvm-svn: 79694
|
|
|
|
|
|
| |
just as if it behaved like an init function. This fixes <rdar://problem/7129086>.
llvm-svn: 79515
|
|
|
|
|
|
|
| |
fixing <rdar://problem/7152619>. Along the way, merge test cases in
'test/Analysis/rdar-6539791.c' into 'test/Analysis/retain-release.m'.
llvm-svn: 79499
|
|
|
|
| |
llvm-svn: 79328
|
|
|
|
|
|
|
| |
which is either a stack frame context of the function or a local scope
context.
llvm-svn: 79072
|
|
|
|
|
|
| |
Some Builders need further cleanup.
llvm-svn: 78301
|
|
|
|
|
|
|
| |
and their impl base classes. This can greatly simply some code of the core
analysis engine. This patch merges ExplodedNodeImpl into ExplodedNode.
llvm-svn: 78270
|
|
|
|
| |
llvm-svn: 78230
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Type::getAsReferenceType() -> Type::getAs<ReferenceType>()
Type::getAsRecordType() -> Type::getAs<RecordType>()
Type::getAsPointerType() -> Type::getAs<PointerType>()
Type::getAsBlockPointerType() -> Type::getAs<BlockPointerType>()
Type::getAsLValueReferenceType() -> Type::getAs<LValueReferenceType>()
Type::getAsRValueReferenceType() -> Type::getAs<RValueReferenceType>()
Type::getAsMemberPointerType() -> Type::getAs<MemberPointerType>()
Type::getAsReferenceType() -> Type::getAs<ReferenceType>()
Type::getAsTagType() -> Type::getAs<TagType>()
And remove Type::getAsReferenceType(), etc.
This change is similar to one I made a couple weeks ago, but that was partly
reverted pending some additional design discussion. With Doug's pending smart
pointer changes for Types, it seemed natural to take this approach.
llvm-svn: 77510
|
|
|
|
|
|
| |
we don't care about ElementRegions layered on top of a base region.
llvm-svn: 77484
|
|
|
|
|
|
|
|
|
|
|
|
| |
Educate GRExprEngine::VisitGraph() about 'PreStmt'.
Mark the constructor of 'PostStmt' to be explicit, preventing implicit
conversions and the selection of the wrong 'generateNode' method in
GRStmtNodeBuilder.
Constify a bunch of arguments, which falls out of the changes to ProgramPoint.
llvm-svn: 76809
|
|
|
|
|
|
|
| |
poisoning changes to DenseMap. We were using an iterator after it had been
invalidated by an insertion into the DenseMap.
llvm-svn: 76677
|
|
|
|
|
|
|
|
|
| |
until Doug Gregor's Type smart pointer code lands (or more discussion occurs).
These methods just call the new Type::getAs<XXX> methods, so we still have
reduced implementation redundancy. Having explicit getAsXXXType() methods makes
it easier to set breakpoints in the debugger.
llvm-svn: 76193
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This method is intended to eventually replace the individual
Type::getAsXXXType<> methods.
The motivation behind this change is twofold:
1) Reduce redundant implementations of Type::getAsXXXType() methods. Most of
them are basically copy-and-paste.
2) By centralizing the implementation of the getAs<Type> logic we can more
smoothly move over to Doug Gregor's proposed canonical type smart pointer
scheme.
Along with this patch:
a) Removed 'Type::getAsPointerType()'; now clients use getAs<PointerType>.
b) Removed 'Type::getAsBlockPointerTypE()'; now clients use getAs<BlockPointerType>.
llvm-svn: 76098
|
|
|
|
|
|
| |
Convert all clients to use the new predicate on Type.
llvm-svn: 76076
|
|
|
|
|
|
|
|
|
|
|
|
| |
The idea is to segregate Objective-C "object" pointers from general C pointers (utilizing the recently added ObjCObjectPointerType). The fun starts in Sema::GetTypeForDeclarator(), where "SomeInterface *" is now represented by a single AST node (rather than a PointerType whose Pointee is an ObjCInterfaceType). Since a significant amount of code assumed ObjC object pointers where based on C pointers/structs, this patch is very tedious. It should also explain why it is hard to accomplish this in smaller, self-contained patches.
This patch does most of the "heavy lifting" related to moving from PointerType->ObjCObjectPointerType. It doesn't include all potential "cleanups". The good news is additional cleanups can be done later (some are noted in the code). This patch is so large that I didn't want to include any changes that are purely aesthetic.
By making the ObjC types truly built-in, they are much easier to work with (and require fewer "hacks"). For example, there is no need for ASTContext::isObjCIdStructType() or ASTContext::isObjCClassStructType()! We believe this change (and the follow-up cleanups) will pay dividends over time.
Given the amount of code change, I do expect some fallout from this change (though it does pass all of the clang tests). If you notice any problems, please let us know asap! Thanks.
llvm-svn: 75314
|
|
|
|
| |
llvm-svn: 75127
|
|
|
|
|
|
| |
if the return type on an Objective-C method is a CF type reference, not just an Objective-C object reference.
llvm-svn: 74841
|
|
|
|
| |
llvm-svn: 74816
|
|
|
|
|
|
| |
No functionality change.
llvm-svn: 74812
|
|
|
|
|
|
|
| |
Remove ASTContext parameter from DeclContext's methods. This change cascaded down to other Decl's methods and changes to call sites started "escalating".
Timings using pre-tokenized "cocoa.h" showed only a ~1% increase in time run between and after this commit.
llvm-svn: 74506
|
|
|
|
|
|
|
|
| |
subclasses.
Timings showed no significant difference before and after the commit.
llvm-svn: 74504
|
|
|
|
|
|
|
|
|
| |
The implementations of these methods can Use Decl::getASTContext() to get the ASTContext.
This commit touches a lot of files since call sites for these methods are everywhere.
I used pre-tokenized "carbon.h" and "cocoa.h" headers to do some timings, and there was no real time difference between before the commit and after it.
llvm-svn: 74501
|