- Dec 16, 2008
-
-
Ted Kremenek authored
- one queue (FIFO) to queue up nodes at block entrances - another queue (LIFO) to queue up other nodes - The idea is to explore basic blocks to completion, but to do a BFS exploration of blocks. llvm-svn: 61106
-
Ted Kremenek authored
- Added four new ProgramPoint types that subclass PostStmt for use in GRExprEngine::EvalLocation: - PostOutOfBoundsCheckFailed - PostUndefLocationCheckFailed - PostNullCheckFailed - PostLocationChecksSucceed These were created because of a horribly subtle caching bug in EvalLocation where a node representing an "bug condition" in EvalLocation (e.g. a null dereference) could be re-used as the "non-bug condition" because the Store did not contain any information to differentiate between the two. The extra program points just disables any accidental caching between EvalLocation and its callers. GRExprEngine: - EvalLocation now returns a NodeTy* instead of GRState*. This should be used as the "vetted" predecessor for EvalLoad/EvalStore. llvm-svn: 61105
-
Douglas Gregor authored
is completely defined (C++ [class.mem]p2). Reverse the order in which we process the definitions of member functions specified inline. This way, we'll get diagnostics in the order in which the member functions were declared in the class. llvm-svn: 61103
-
Eli Friedman authored
change the semantics. Please correct this if the precedence was actually supposed to be something different. llvm-svn: 61099
-
Eli Friedman authored
Someone should double-check that I didn't somehow break ObjC serialization; I think the change there actually changes the semantics. llvm-svn: 61098
-
Nate Begeman authored
llvm-svn: 61097
-
Fariborz Jahanian authored
llvm-svn: 61090
-
rdar://problem/6445502Steve Naroff authored
Fix <rdar://problem/6445502> clang ObjC rewriter: _Block_release has wrong parameter type in preamble llvm-svn: 61088
-
Douglas Gregor authored
N::X only skips those entities specified in C++ [basic.lookup.qual]p1. Note that both EDG and GCC currently get this wrong. EDG has confirmed that the bug will be fixed in a future version. llvm-svn: 61079
-
Zhongxing Xu authored
llvm-svn: 61069
-
Fariborz Jahanian authored
be duplicates and a test case. llvm-svn: 61068
-
Douglas Gregor authored
Make name lookup when we're inside a declarator's scope, such as ClassName::func, work with the new unqualified name lookup code. Test it with default arguments in out-of-line member definitions llvm-svn: 61060
-
Douglas Gregor authored
functions. They work except that name lookup within the default arguments needs to be deferred until the class definition is complete (see FIXME in the test). llvm-svn: 61059
-
Douglas Gregor authored
specifiers. Specifically: * Determine when an out-of-line function definition does not match any declaration within the class or namespace (including coping with overloaded functions). * Complain about typedefs and parameters that have scope specifiers. * Complain about out-of-line declarations that aren't also definitions. * Complain about non-static data members being declared out-of-line. * Allow cv-qualifiers on out-of-line member function definitions. llvm-svn: 61058
-
- Dec 15, 2008
-
-
Eli Friedman authored
programs. llvm-svn: 61056
-
Eli Friedman authored
llvm-svn: 61055
-
Fariborz Jahanian authored
is done. Layout is calculated lazily at code gen type. This patch changes the name. llvm-svn: 61054
-
Douglas Gregor authored
just like all other members, and remove the special variables in CXXRecordDecl to store them. This eliminates a lot of special-case code for constructors and destructors, including ActOnConstructor/ActOnDeclarator and special lookup rules in LookupDecl. The result is far more uniform and manageable. Diagnose the redeclaration of member functions. llvm-svn: 61048
-
Fariborz Jahanian authored
llvm-svn: 61044
-
Fariborz Jahanian authored
ivars. llvm-svn: 61043
-
Ted Kremenek authored
Preprocessor: Allocate MacroInfo objects using a BumpPtrAllocator instead using new/delete. This speeds up -Eonly on Cocoa.h using the regular lexer by 1.8% and the PTHLexer by 3%. llvm-svn: 61042
-
Ted Kremenek authored
llvm-svn: 61039
-
Fariborz Jahanian authored
llvm-svn: 61038
-
Douglas Gregor authored
half-solution; the real solution is coming when constructors and destructors are treated like all other functions by ActOnDeclarator. llvm-svn: 61037
-
Douglas Gregor authored
together in the same way that we link RecordDecl/CXXRecordDecl nodes. Unify ActOnTag and ActOnTagStruct. Fixes PR clang/2753. llvm-svn: 61034
-
- Dec 14, 2008
-
-
Nuno Lopes authored
llvm-svn: 61015
-
Nuno Lopes authored
llvm-svn: 61008
-
Nuno Lopes authored
llvm-svn: 61007
-
Zhongxing Xu authored
llvm-svn: 61003
-
Ted Kremenek authored
llvm-svn: 61002
-
- Dec 13, 2008
-
-
Anders Carlsson authored
Store the size of the EH stack inside each BreakContinue struct so we know when a break/continue won't cross a try block. llvm-svn: 60998
-
Fariborz Jahanian authored
matching the storage layout for this ivar llvm-svn: 60996
-
Ted Kremenek authored
- Overhauled the notion of "types" for TypedRegions. We now distinguish between the "lvalue" of a region (via getLValueRegion()) and the "rvalue" of a region (va getRValueRegion()). Since a region represents a chunk of memory it has both, but we were conflating these concepts in some cases, leading to some insidious bugs. - Removed AnonPointeeType, partially because it is unused and because it doesn't have a clear notion of lvalue vs rvalue type. We can add it back once there is a need for it and we can resolve its role with these concepts. StoreManager: - Overhauled StoreManager::CastRegion. It expects an *lvalue* type for a region. This is actually what motivated the overhaul to the MemRegion type mechanism. It also no longer returns an SVal; we can just return a MemRegion*. - BasicStoreManager::CastRegion now overlays an "AnonTypedRegion" for pointer-pointer casts. This matches with the MemRegion changes. - Similar changes to RegionStore, except I've added a bunch of FIXMEs where it wasn't 100% clear where we should use TypedRegion::getRValueRegion() or TypedRegion::getLValueRegion(). AuditCFNumberCreate check: - Now blasts through AnonTypedRegions that may layer the original memory region, thus checking if the actually memory block is of the appropriate type. This change was needed to work with the changes to StoreManager::CastRegion. GRExprEngine::VisitCast: - Conform to the new interface of StoreManager::CastRegion. Tests: - None of the analysis tests fail now for using the "basic store". - Disabled the tests 'array-struct.c' and 'rdar-6442306-1.m' pending further testing and bug fixing. llvm-svn: 60995
-
Fariborz Jahanian authored
llvm-svn: 60993
-
Chris Lattner authored
use identifierinfo instead. Patch by Chris Goller! llvm-svn: 60992
-
Ted Kremenek authored
llvm-svn: 60991
-
rdar://problem/6442306Ted Kremenek authored
GRExprEngine (VisitCast): - When using StoreManager::CastRegion, always use the state and value it returns to generate the next node. Failure to do so means that region values returned that don't require the state to be modified will get ignored. MemRegion: - Tighten the interface for ElementRegion. Now ElementRegion can only be created with a super region that is a 'TypedRegion' instead of any MemRegion. Code in BasicStoreManager/RegionStoreManager already assumed this, but it would result in a dynamic assertion check (and crash) rather than just having the compiler forbid the construction of such regions. - Added ElementRegion::getArrayRegion() to return the 'typed version' of an ElementRegion's super region. - Removed bogus assertion in ElementRegion::getType() that assumed that the super region was an AnonTypedRegion. All that matters is that it is a TypedRegion, which is now true all the time by design. BasicStore: - Modified getLValueElement() to check if the 'array' region is a TypedRegion before creating an ElementRegion. This conforms to the updated interface for ElementRegion. RegionStore: - In ArrayToPointer() gracefully handle things we don't reason about, and only create an ElementRegion if the array region is indeed a TypedRegion. llvm-svn: 60990
-
Chris Lattner authored
llvm-svn: 60989
-
Sebastian Redl authored
llvm-svn: 60983
-
Sebastian Redl authored
llvm-svn: 60982
-