summaryrefslogtreecommitdiffstats
path: root/clang/Driver
Commit message (Collapse)AuthorAgeFilesLines
...
* Moved main control flow functions to bottom of file.Steve Naroff2008-10-041-165/+133
| | | | | | | | | Reworked control flow to: - rewrite the block expr body "in place". - used Chris's new rewriter hook "getRewritenText" to "lift" the text for later use. - finally, we do the block expr text replacement. llvm-svn: 57052
* Remove an old/vacuous if clause.Steve Naroff2008-10-031-6/+0
| | | | llvm-svn: 57036
* More fun & games with the block rewriter.Steve Naroff2008-10-031-21/+90
| | | | llvm-svn: 57028
* Rewrite global block expressions.Steve Naroff2008-10-031-6/+15
| | | | llvm-svn: 57004
* - Add a convenience constructor to Type.Steve Naroff2008-10-031-14/+47
| | | | | | - Many rewriter modifications. llvm-svn: 57003
* Rework SynthesizeBlockImpl() to include a constructor.Steve Naroff2008-10-031-12/+49
| | | | llvm-svn: 57001
* Pass postfix attributes to ActOnFields.Daniel Dunbar2008-10-031-1/+2
| | | | llvm-svn: 56992
* Get the right location to insert the synthesized block literals/functions.Steve Naroff2008-10-031-1/+1
| | | | llvm-svn: 56987
* Name changes and some cleanup of preamble.Steve Naroff2008-10-021-27/+35
| | | | llvm-svn: 56984
* Changed Sema::CheckForConstantInitializer to allow global block literals.Steve Naroff2008-10-021-15/+15
| | | | | | This commit also includes some name changes in the blocks rewriter (no functionality change). llvm-svn: 56955
* (llvm up) If the target triple is unspecified, automatically set theDaniel Dunbar2008-10-021-1/+13
| | | | | | OS version part to that of the host on darwin. llvm-svn: 56943
* Drop code to validate OS part of target triple on darwin, too fragile.Daniel Dunbar2008-10-021-11/+0
| | | | llvm-svn: 56941
* Fix help for --suppress-system-warningsDaniel Dunbar2008-09-301-1/+1
| | | | llvm-svn: 56878
* Handle minor version numbers in __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__Chris Lattner2008-09-301-11/+6
| | | | | | like "10.3.9" llvm-svn: 56873
* Finish handling of -mmacosx-version-min. If you now do something like:Chris Lattner2008-09-301-26/+73
| | | | | | | | clang -mmacosx-version-min=10.4.9 ... you'll end up with a target triple like "i686-apple-darwin8.9". llvm-svn: 56871
* start handling 'mmacosx-version-min', this is not complete yet.Chris Lattner2008-09-301-10/+40
| | | | llvm-svn: 56828
* clean up a bunch of fixme's I added, by moving Chris Lattner2008-09-261-6/+6
| | | | | | DirectoryLookup::DirType into SourceManager.h llvm-svn: 56692
* fit in 80 cols.Chris Lattner2008-09-261-1/+1
| | | | llvm-svn: 56687
* Make clang preprocessed output a bit more like gcc output.Daniel Dunbar2008-09-261-1/+1
| | | | llvm-svn: 56636
* Fix a couple harmless warnings when compiling optimized with gcc (reported ↵Steve Naroff2008-09-241-2/+2
| | | | | | by mrs@apple.com). llvm-svn: 56591
* Fix some const-ness to keep the VisualStudio C++ compiler happy.Steve Naroff2008-09-241-4/+4
| | | | llvm-svn: 56560
* RewriteBlocks::RewriteBlockPointerDecl(): Handle TypedefDecl's and VarDecl's ↵Steve Naroff2008-09-231-35/+32
| | | | | | uniformly. llvm-svn: 56500
* Teach block rewriter to replace '^' with '*' in VarDecls.Steve Naroff2008-09-231-12/+64
| | | | | | | | Since we don't have DeclGroup's and location information for types, there is some fancy footwork to do this fairly reliably. O.K...it's a kludge. One day, we can use this as motivation to do this more gracefully:-) llvm-svn: 56499
* Change implementation of NSError** coding-style check to be invoked at the ↵Ted Kremenek2008-09-182-9/+0
| | | | | | end of the retain/release analysis. llvm-svn: 56312
* Add driver support for invoking block rewriter.Steve Naroff2008-09-183-11/+27
| | | | | | Also tweaked the create function to take an explicit output file. llvm-svn: 56305
* Implemented one of the checks requested in PR 2600:Ted Kremenek2008-09-182-0/+9
| | | | | | | | "Method accepting NSError** argument should have non-void return value to indicate that an error occurred." Test case written, but the header needs to be delta-debugged reduced. Will commit shortly. llvm-svn: 56297
* Remove BlockStmtExpr. Steve Naroff2008-09-171-6/+6
| | | | | | | | Block literals are now represented by the concrete BlockExpr class. This is cleanup (removes a FIXME). No functionality change. llvm-svn: 56288
* Add support for rewriting blocks...Steve Naroff2008-09-172-0/+910
| | | | llvm-svn: 56266
* Patch by Csaba Hruska!Ted Kremenek2008-09-135-30/+51
| | | | | | | "Here is a patch what replaces std::ostream with llvm::raw_ostream. This patch covers the AST library, but ignores Analysis lib." llvm-svn: 56185
* Add --suppress-system-warnings (on by default, use =0 to disable)Daniel Dunbar2008-09-121-0/+8
| | | | | | | | | - For investigating warnings in system headers / builtins. - Currently also enables the behavior that allows silent redefinition of types in system headers. Conceptually these are separate but I didn't feel it was worth two options (or changing LangOptions). llvm-svn: 56163
* Fix <rdar://problem/6210791> clang ObjC rewriter: @try / @catch block with ↵Steve Naroff2008-09-111-2/+15
| | | | | | | | no @finally does not call objc_exception_try_exit. Need a couple tweaks to RewriteObjCTryStmt(). Need to deal with implicit finally clauses (to make sure objc_exception_try_exit is called). Also fixed a related bug where we need to generate an implicit @catch else clause (to again make sure objc_exception_try_exit is called). llvm-svn: 56104
* LangOptions.C99 should be false in C++.Argyrios Kyrtzidis2008-09-111-0/+5
| | | | llvm-svn: 56092
* Add support for expected-note to Clang's -verify optionDouglas Gregor2008-09-111-5/+26
| | | | llvm-svn: 56089
* Fix <rdar://problem/6197841> try, finally with no catch stops the exception ↵Steve Naroff2008-09-091-0/+5
| | | | | | from being propagated llvm-svn: 56004
* rename libclangSEMA to libclangSemaNico Weber2008-09-071-1/+1
| | | | llvm-svn: 55887
* Change struct forward declarations and definitions to use unique ↵Ted Kremenek2008-09-051-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RecordDecls, as opposed to creating a single RecordDecl and reusing it. This change effects both RecordDecls and CXXRecordDecls, but does not effect EnumDecls (yet). The motivation of this patch is as follows: - Capture more source information, necessary for refactoring/rewriting clients. - Pave the way to resolve ownership issues with RecordDecls with the forthcoming addition of DeclGroups. Current caveats: - Until DeclGroups are in place, we will leak RecordDecls not explicitly referenced by the AST. For example: typedef struct { ... } x; The RecordDecl for the struct will be leaked because the TypedefDecl doesn't refer to it. This will be solved with DeclGroups. - This patch also (temporarily) breaks CodeGen. More below. High-level changes: - As before, TagType still refers to a TagDecl, but it doesn't own it. When a struct/union/class is first referenced, a RecordType and RecordDecl are created for it, and the RecordType refers to that RecordDecl. Later, if a new RecordDecl is created, the pointer to a RecordDecl in RecordType is updated to point to the RecordDecl that defines the struct/union/class. - TagDecl and RecordDecl now how a method 'getDefinition()' to return the TagDecl*/RecordDecl* that refers to the TagDecl* that defines a particular enum/struct/class/union. This is useful from going from a RecordDecl* that defines a forward declaration to the RecordDecl* that provides the actual definition. Note that this also works for EnumDecls, except that in this case there is no distinction between forward declarations and definitions (yet). - Clients should no longer assume that 'isDefinition()' returns true from a RecordDecl if the corresponding struct/union/class has been defined. isDefinition() only returns true if a particular RecordDecl is the defining Decl. Use 'getDefinition()' instead to determine if a struct has been defined. - The main changes to Sema happen in ActOnTag. To make the changes more incremental, I split off the processing of enums and structs et al into two code paths. Enums use the original code path (which is in ActOnTag) and structs use the ActOnTagStruct. Eventually the two code paths will be merged, but the idea was to preserve the original logic both for comparison and not to change the logic for both enums and structs all at once. - There is NO CHAINING of RecordDecls for the same RecordType. All RecordDecls that correspond to the same type simply have a pointer to that type. If we need to figure out what are all the RecordDecls for a given type we can build a backmap. - The diff in CXXRecordDecl.[cpp,h] is actually very small; it just mimics the changes to RecordDecl. For some reason 'svn' marks the entire file as changed. Why is CodeGen broken: - Codegen assumes that there is an equivalence between RecordDecl* and RecordType*. This was true before because we only created one RecordDecl* for a given RecordType*, but it is no longer true. I believe this shouldn't be too hard to change, but the patch was big enough as it is. I have tested this patch on both the clang test suite, and by running the static analyzer over Postgresql and a large Apple-internal project (mix of Objective-C and C). llvm-svn: 55839
* Workaround gcc bug causing crash on our preprocessed outputs.Daniel Dunbar2008-09-051-44/+45
| | | | | | | | | | | | - gcc is not happy if we start a preprocessed file with #line 1 "XXX" 1 - Workaround by making sure file starts with a simple #line change. Also, factored WriteLineInfo out. Also, fixed bug where FileType was not being correctly updated. llvm-svn: 55825
* Remove "NextDecl" from RecordDecl. This change touches many files that ↵Ted Kremenek2008-09-051-6/+6
| | | | | | | | where RecordDecl or CXXRecordDecl was constructed, always with an argument of 'NULL' for the previous declaration. The motivation behind this change is that chaining the RecordDecls is simply unnecessary. Once we create multiple RecordDecls for the same struct/union/class, clients that care about all the declarations of the same struct can build a back map by seeing which Decls refer to the same RecordType. llvm-svn: 55821
* Output "ANALYZE:" diagnostics to STDOUT instead of STDERR.Ted Kremenek2008-09-041-2/+2
| | | | llvm-svn: 55750
* Following gcc's behavior, only enable trigraphs if '-trigraphs' or '-ansi' isTed Kremenek2008-09-031-4/+19
| | | | | | specified, or -std is set to a conforming mode. llvm-svn: 55738
* Add newline to end of file.Daniel Dunbar2008-08-291-1/+1
| | | | llvm-svn: 55525
* Always print out the function we're analyzing.Ted Kremenek2008-08-281-2/+4
| | | | llvm-svn: 55488
* Ubigraph visualization: represent cached nodes with a different style.Ted Kremenek2008-08-281-3/+14
| | | | llvm-svn: 55463
* Automatically execute ubiviz.Ted Kremenek2008-08-281-3/+28
| | | | | | Cleanup ubigraph files when don't drawing the graphs. llvm-svn: 55459
* Ubigraph-rendered ExplodedGraphs now have arrows and are oriented downward.Ted Kremenek2008-08-271-1/+2
| | | | llvm-svn: 55446
* Added Ubigraph visualization for the static analyzer (this is pretty alpha ↵Ted Kremenek2008-08-273-15/+117
| | | | | | quality). llvm-svn: 55442
* Rename ObjCPropertyImplDecl::PropertyImplKind (consistency)Daniel Dunbar2008-08-261-2/+1
| | | | | | | | | - Change enum name to Kind. - Change enum constants to English strings. Also, fix getPropertyImplementation (which probably should be renamed) llvm-svn: 55354
* Moved HTMLDiagnostics to lib/Driver.Zhongxing Xu2008-08-245-478/+3
| | | | llvm-svn: 55274
* adjust to changes in various APIs from LLVM. We can't printChris Lattner2008-08-231-1/+1
| | | | | | | | an APInt directly to an ostream now, so add some hacks. It would be better to switch all of the bugreport (and friends) stuff over to raw_ostream. llvm-svn: 55264
* Add TargetInfo::useNeXTRuntimeAsDefaultDaniel Dunbar2008-08-231-4/+4
| | | | | | | | - Used to autoselect runtime when neither -fnext-runtime nor -fgnu-runtime is specified. - Default impl is false, all darwin targets set it to true. llvm-svn: 55231
OpenPOWER on IntegriCloud