summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* Provide the option to run the CF-retain checker in GC enabled mode.Ted Kremenek2008-04-291-4/+6
| | | | | | The transfer functions for the checker don't do anything special yet in GC mode. llvm-svn: 50394
* Add -fobjc-gc and -fobjc-gc-only options to the driver.Ted Kremenek2008-04-291-1/+3
| | | | | | Add corresponding enum in LangOptions. llvm-svn: 50387
* Bug fix in CFG::getBlockEdgeImpl(): Use a BumpPtrAllocator to allocateTed Kremenek2008-04-281-13/+71
| | | | | | | | | std::pair<CFGBlock*, CFGBlock*> that have an 8-byte alignment for use with ProgramPoint. This fixes a bug reported by Argiris where using std::set<> on Windows would result in a 4-byte alignment, not an 8-byte alignment. Fixes: <rdar://problem/5892265> llvm-svn: 50364
* Call ExitScope before ActOnFinishNamespaceDef.Argyrios Kyrtzidis2008-04-271-2/+3
| | | | | | This is the same for functions and it's preferable to have the namespace as DeclContext during ActOnPopScope. llvm-svn: 50322
* Parsing of namespaces:Argyrios Kyrtzidis2008-04-277-46/+193
| | | | | | | | | -NamespaceDecl for the AST -Checks for name clashes between namespaces and tag/normal declarations. This commit doesn't implement proper name lookup for namespaces. llvm-svn: 50321
* Use PushOnScopeChains to introduce a decl into scope.Argyrios Kyrtzidis2008-04-271-4/+2
| | | | llvm-svn: 50320
* Make assertions for all addresses passed to ProgramPoint that they have at ↵Argyrios Kyrtzidis2008-04-261-4/+3
| | | | | | least an 8-byte alignment. llvm-svn: 50310
* Fix bug in BugReporter where we didn't handle emitting diagnostics forTed Kremenek2008-04-251-10/+28
| | | | | | | | | | empty CFGBlocks that only contained a terminator. Added improved diagnostics for break and continue statements and default branches in switch statements. This fixes <rdar://problem/5889244>. llvm-svn: 50286
* remove the 'unused static' diagnostic from codegen. This should be Chris Lattner2008-04-251-8/+0
| | | | | | | reimplemented in Sema someday. This is tracked in PR2236. Until then disabling it removes some bogus diagnostics (see 2236). llvm-svn: 50263
* initial support for recognizing __transparent_union__ attributesNuno Lopes2008-04-253-0/+30
| | | | | | comments on the ML will follow llvm-svn: 50262
* Handle dereferences of function pointers (which return a handle to the ↵Ted Kremenek2008-04-251-0/+3
| | | | | | function). llvm-svn: 50246
* Don't abort on GetRVal when the LVal is a StringLiteralVal.Ted Kremenek2008-04-251-0/+4
| | | | llvm-svn: 50245
* Don't emit empty strings for path diagnostics when taking the default branch ↵Ted Kremenek2008-04-251-0/+7
| | | | | | of a switch statement that has no label. llvm-svn: 50242
* Do a better job at computing dead symbols.Ted Kremenek2008-04-254-24/+24
| | | | | | | | | Implemented support for better localized leaks in the CF reference count checker. Now leaks should be flagged close to where they occur. This should implement the desired functionality in <rdar://problem/5879592>, although the diagnostics still need to be improved. llvm-svn: 50241
* Add preliminary support for flagging leaks around when they happen (doesn't ↵Ted Kremenek2008-04-241-2/+70
| | | | | | work yet). llvm-svn: 50237
* More boilerplate for handling specialized-transfer function logic for dead ↵Ted Kremenek2008-04-241-29/+32
| | | | | | symbols. llvm-svn: 50233
* Patch to diagnose inconsistancies between properties declared in current andFariborz Jahanian2008-04-242-0/+71
| | | | | | its super class. This patch is incomplete. llvm-svn: 50228
* Added initial boilerplate in GRExprEngine to allow checker-specific transferTed Kremenek2008-04-242-11/+48
| | | | | | function logic to act when symbols become dead. llvm-svn: 50221
* CF reference count checker: handle variadic functions that allocate CF objects.Ted Kremenek2008-04-241-56/+54
| | | | | | | | | This fixes <rdar://problem/5886141>. Part of this change resulted in creating sparser summaries. I also added some more comments and did some minor code cleanups. llvm-svn: 50214
* Have ValidateOutputConstraint return false instead of firing an assertionTed Kremenek2008-04-241-2/+2
| | | | | | | when processing a constraint we don't understand. This allows the frontend to gracefully fail. llvm-svn: 50213
* For case statements involving enums, BugReporter now generates PathDiagnosticsTed Kremenek2008-04-231-32/+38
| | | | | | | | that say that we are jumping to "case a" instead of "case 0". This is a feature implementation for <rdar://problem/5880430>. llvm-svn: 50197
* Fix minor regression in bug report generation.Ted Kremenek2008-04-231-2/+3
| | | | llvm-svn: 50195
* When building PathDiagnostics for bug reports, generate a trimmed ↵Ted Kremenek2008-04-231-18/+50
| | | | | | ExplodedGraph with a single path that BugReport objects can safely walk and introspect. llvm-svn: 50194
* Fixed: <rdar://problem/5881148>Ted Kremenek2008-04-234-84/+58
| | | | | | | | | | Problem: In the recently refactored VisitDeref (which processes dereferences), we were incorrectly skipping the node just generated for the subexpression of the dereference. This was a horrible regression. llvm-svn: 50176
* TranslationUnit now owns IdentifierTable, TargetInfo, and Selectors objectsTed Kremenek2008-04-231-2/+19
| | | | | | | | | | | | | | | | when it is constructed via deserialization. This is done by recording a flag indicating that this is the case, and it deletes these objects by getting the references stored in the ASTContext object. This fixes some memory leaks that occurs when we deserialize translation units from bitcode files. The rationale between having TranslationUnit sometimes own these objects and sometimes not is that a TranslationUnit object can be constructed from state generated by the parser (Preprocessor; semantic analyzer, etc.), and thus in these cases won't own the IdentifierTable or Selectors, etc. During deserialization, there is no Preprocessor, so somebody needs to own these objects in order for them to be properly reclaimed. llvm-svn: 50149
* Remove false path where the default branch in a switch statement wouldTed Kremenek2008-04-231-2/+5
| | | | | | always be taken even if it was not feasible. llvm-svn: 50132
* fix a rewriter crash on zero length files.Chris Lattner2008-04-231-0/+1
| | | | llvm-svn: 50126
* Added panic function "assfail".Ted Kremenek2008-04-231-0/+4
| | | | llvm-svn: 50119
* Patch to build AST for property implementation declarations andFariborz Jahanian2008-04-232-16/+27
| | | | | | to print declaration from its AST. llvm-svn: 50117
* For default branches in switch statements with no default label, print outTed Kremenek2008-04-221-3/+1
| | | | | | the line we are going to. llvm-svn: 50113
* Rewrote VisitDeclStmt to properly handle initializers that can do anything.Ted Kremenek2008-04-221-54/+84
| | | | llvm-svn: 50112
* Added lval type (and tracking) for StringLiterals.Ted Kremenek2008-04-225-0/+20
| | | | llvm-svn: 50109
* Added "nonlval::LValAsInteger" to represent abstract LVals casted to ↵Ted Kremenek2008-04-224-17/+107
| | | | | | integers, allowing us to track lvals when they are casted back to pointers. llvm-svn: 50108
* "This patch renames Chris Lattner2008-04-224-18/+18
| | | | | | | | | | | DeclContext *CtxDecl -> DeclContext *DeclCtx DeclContext *CD -> DeclContext *DC It makes the code more consistent." Patch by Zhongxing Xu! llvm-svn: 50105
* PathDiagnosticClients now retain ownership of passed PathDiagnostics, requiringTed Kremenek2008-04-222-16/+15
| | | | | | | | | | them to not be stack-allocated. HTMLDiagnostics now batches PathDiagnostics before emitting HTML in its dtor. This is a workaround for a problem when we trampled the Preprocessor state when highlighting macros (sometimes resulting in an assertion failure). llvm-svn: 50102
* Use back() instead of end()-1Argyrios Kyrtzidis2008-04-221-2/+2
| | | | llvm-svn: 50098
* Added panic function "dtrace_assfail".Ted Kremenek2008-04-221-0/+5
| | | | llvm-svn: 50091
* Hardcode "Assert" as a no-return function (panic).Ted Kremenek2008-04-221-0/+4
| | | | llvm-svn: 50089
* Add some basic ARM asm constraintsNate Begeman2008-04-221-1/+10
| | | | llvm-svn: 50085
* Added null-dereference check for ArraySubscriptExpr.Ted Kremenek2008-04-221-1/+35
| | | | llvm-svn: 50083
* Allow property in base class to be implemented in a Fariborz Jahanian2008-04-211-0/+4
| | | | | | derived class. llvm-svn: 50074
* Added support for detected bad dereferences involving MemberExprs, e.g. x->f ↵Ted Kremenek2008-04-211-77/+123
| | | | | | where "x" is NULL. llvm-svn: 50071
* More semantics checks of properties. Property implementation can implicitly useFariborz Jahanian2008-04-211-5/+4
| | | | | | | ivar of same name. Better diagnostics to bring home this point. llvm-svn: 50065
* Support for @dynamic AST build.Fariborz Jahanian2008-04-212-8/+24
| | | | | | | More property semantics checking. First test case for ObjC2's property implementation. llvm-svn: 50057
* Fix pasto, thanks to Anders for pointing this out.Chris Lattner2008-04-211-1/+1
| | | | llvm-svn: 50055
* Continuation of work on ObjC2's properties.Fariborz Jahanian2008-04-212-36/+70
| | | | | | | | Added iterators, methods to find property and categories. Use them in doing semantic analysis on property implementation declarations. Fixed typos. llvm-svn: 50050
* add arm supportChris Lattner2008-04-211-0/+132
| | | | llvm-svn: 50049
* Clean up handling of function redeclarationsDouglas Gregor2008-04-213-10/+104
| | | | llvm-svn: 50021
* Fix improper dereference of end() iterator. Patch by Argiris Kirtzidis!Ted Kremenek2008-04-201-2/+5
| | | | llvm-svn: 50012
* Fix PR2236Nate Begeman2008-04-202-8/+19
| | | | | | | Add test Implement feedback from Chris re: PR1998 llvm-svn: 50001
OpenPOWER on IntegriCloud