Commit Graph

9 Commits

Author SHA1 Message Date
Ted Kremenek d461d7ad7e Added Ubigraph visualization for the static analyzer (this is pretty alpha quality).
llvm-svn: 55442
2008-08-27 22:31:43 +00:00
Ted Kremenek fd7efdf20d Provide an "Analysis Scope" for Analyses so checks can either be run on code declarations (bodies) or Objective-C @implementation blocks.
llvm-svn: 53584
2008-07-15 00:46:02 +00:00
Ted Kremenek 3063b73773 Break off declaration of Analysis enum into Analyses.def. The driver options in
clang.cpp now #include these definitions to create the command line options, and
AnalysisConsumer #includes this file to generate the switch statement to create
actions.

Renamed -check-objc-methodsigs to -warn-objc-methodsigs.

The "missing -dealloc" check is now optional: -warn-objc-missing-dealloc

llvm-svn: 53575
2008-07-14 23:41:13 +00:00
Ted Kremenek 3bfb314c25 Add new check: -check-objc-methodsigs. This check scans methods in
ObjCImplementationDecls and sees if a ancestor class defines a method with the
same selector but with a different type signature. Right now it just compares
return types, and mainly looks at differences in primitive values. The checking
will be expanded in the future.

llvm-svn: 53482
2008-07-11 22:40:47 +00:00
Ted Kremenek f992cfb4ab Moved logic for -dump-cfg and -view-cfg into AnalysisConsumer.
Renamed -dump-cfg to -cfg-dump, and -view-cfg to -cfg-view.  This naming better matches the same options for asts (e.g. -ast-dump).

llvm-svn: 53041
2008-07-02 18:23:21 +00:00
Ted Kremenek bdbe6130f4 Move -dump-live-variables logic to AnalysisConsumer.
llvm-svn: 53039
2008-07-02 18:11:29 +00:00
Ted Kremenek becec2cbbc Move logic for "-checker-simple" to the new AnalysisConsumer interface.
llvm-svn: 53028
2008-07-02 16:35:50 +00:00
Ted Kremenek 8e631a0267 Migrated driver logic for running the CF retain/release checker over to the new AnalysisConsumer interface.
llvm-svn: 53002
2008-07-02 00:44:58 +00:00
Ted Kremenek f0413bfcda Added AnalysisConsumer, a meta-level ASTConsumer class to drive various
analyses. This potentially is the primordial origins of a Clang-equivalent
"PassManager".

The new AnalysisConsumer interface allows multiple analyses to be run from a
single invocation of Clang.

Migrated the logic of "-warn-dead-stores" and "-warn-uninit-values" to use the
new AnalysisConsumer interface. The new interface results in a significant code
reduction to incorporate an analysis into the Driver.

Updated a test case to (correctly) acknowledge that it contains a dead store
(this check wasn't being performed because it was previously masked by
-warn-uninit-values).

llvm-svn: 52996
2008-07-02 00:03:09 +00:00