[llvm-branch-commits] [cfe-tag] r87076 - in /cfe/tags/checker/checker-228: lib/Analysis/GRExprEngineExperimentalChecks.cpp lib/Analysis/GRExprEngineInternalChecks.cpp test/Analysis/array-struct.c test/Analysis/misc-ps-region-store.m test/Analysis/misc-ps.m test/Analysis/no-outofbounds.c test/Analysis/outofbound.c test/Analysis/ptr-arith.c test/Analysis/rdar-6442306-1.m test/Analysis/rdar-6541136-region.c

Ted Kremenek kremenek at apple.com
Thu Nov 12 19:43:38 PST 2009


Author: kremenek
Date: Thu Nov 12 21:43:38 2009
New Revision: 87076

URL: http://llvm.org/viewvc/llvm-project?rev=87076&view=rev
Log:
Make the following checkers experimental for this tag:

PointerSubChecker
PointerArithChecker
FixedAddressChecker
PointerRangeChecker
CastToStructChecker
ArrayBoundChecker


Modified:
    cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineExperimentalChecks.cpp
    cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineInternalChecks.cpp
    cfe/tags/checker/checker-228/test/Analysis/array-struct.c
    cfe/tags/checker/checker-228/test/Analysis/misc-ps-region-store.m
    cfe/tags/checker/checker-228/test/Analysis/misc-ps.m
    cfe/tags/checker/checker-228/test/Analysis/no-outofbounds.c
    cfe/tags/checker/checker-228/test/Analysis/outofbound.c
    cfe/tags/checker/checker-228/test/Analysis/ptr-arith.c
    cfe/tags/checker/checker-228/test/Analysis/rdar-6442306-1.m
    cfe/tags/checker/checker-228/test/Analysis/rdar-6541136-region.c

Modified: cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineExperimentalChecks.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineExperimentalChecks.cpp?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineExperimentalChecks.cpp (original)
+++ cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineExperimentalChecks.cpp Thu Nov 12 21:43:38 2009
@@ -12,6 +12,7 @@
 //
 //===----------------------------------------------------------------------===//
 
+#include "GRExprEngineInternalChecks.h"
 #include "GRExprEngineExperimentalChecks.h"
 #include "clang/Analysis/LocalCheckers.h"
 
@@ -19,5 +20,14 @@
 
 void clang::RegisterExperimentalChecks(GRExprEngine &Eng) {
   RegisterPthreadLockChecker(Eng);  
+  
+  RegisterPointerSubChecker(Eng);
+  RegisterPointerArithChecker(Eng);
+  RegisterFixedAddressChecker(Eng);
+  // Note that this must be registered after ReturnStackAddressChecker.
+  RegisterReturnPointerRangeChecker(Eng);
+  
+  RegisterCastToStructChecker(Eng);
+  RegisterArrayBoundChecker(Eng);
 }
 

Modified: cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineInternalChecks.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineInternalChecks.cpp?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineInternalChecks.cpp (original)
+++ cfe/tags/checker/checker-228/lib/Analysis/GRExprEngineInternalChecks.cpp Thu Nov 12 21:43:38 2009
@@ -395,13 +395,6 @@
   RegisterDivZeroChecker(*this);
   RegisterReturnStackAddressChecker(*this);
   RegisterReturnUndefChecker(*this);
-  RegisterPointerSubChecker(*this);
-  RegisterPointerArithChecker(*this);
-  RegisterFixedAddressChecker(*this);
-  // Note that this must be registered after ReturnStackAddressChecker.
-  RegisterReturnPointerRangeChecker(*this);
 
-  RegisterCastToStructChecker(*this);
-  RegisterArrayBoundChecker(*this);
   RegisterUndefinedArraySubscriptChecker(*this);
 }

Modified: cfe/tags/checker/checker-228/test/Analysis/array-struct.c
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/array-struct.c?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/array-struct.c (original)
+++ cfe/tags/checker/checker-228/test/Analysis/array-struct.c Thu Nov 12 21:43:38 2009
@@ -1,7 +1,7 @@
-// RUN: clang-cc -analyze -checker-cfref -analyzer-store=basic -analyzer-constraints=basic -verify %s
-// RUN: clang-cc -analyze -checker-cfref -analyzer-store=basic -analyzer-constraints=range -verify %s
-// RUN: clang-cc -analyze -checker-cfref -analyzer-store=region -analyzer-constraints=basic -verify %s
-// RUN: clang-cc -analyze -checker-cfref -analyzer-store=region -analyzer-constraints=range -verify %s
+// RUN: clang-cc -analyze -analyzer-experimental-checks -checker-cfref -analyzer-store=basic -analyzer-constraints=basic -verify %s
+// RUN: clang-cc -analyze -analyzer-experimental-checks -checker-cfref -analyzer-store=basic -analyzer-constraints=range -verify %s
+// RUN: clang-cc -analyze -analyzer-experimental-checks -checker-cfref -analyzer-store=region -analyzer-constraints=basic -verify %s
+// RUN: clang-cc -analyze -analyzer-experimental-checks -checker-cfref -analyzer-store=region -analyzer-constraints=range -verify %s
 
 struct s {
   int data;

Modified: cfe/tags/checker/checker-228/test/Analysis/misc-ps-region-store.m
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/misc-ps-region-store.m?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/misc-ps-region-store.m (original)
+++ cfe/tags/checker/checker-228/test/Analysis/misc-ps-region-store.m Thu Nov 12 21:43:38 2009
@@ -1,5 +1,5 @@
-// RUN: clang-cc -triple i386-apple-darwin9 -analyze -checker-cfref --analyzer-store=region --verify -fblocks %s
-// RUN: clang-cc -triple x86_64-apple-darwin9 -analyze -checker-cfref --analyzer-store=region --verify -fblocks %s
+// RUN: clang-cc -analyzer-experimental-checks -triple i386-apple-darwin9 -analyze -checker-cfref --analyzer-store=region --verify -fblocks %s
+// RUN: clang-cc -analyzer-experimental-checks -triple x86_64-apple-darwin9 -analyze -checker-cfref --analyzer-store=region --verify -fblocks %s
 
 typedef struct objc_selector *SEL;
 typedef signed char BOOL;

Modified: cfe/tags/checker/checker-228/test/Analysis/misc-ps.m
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/misc-ps.m?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/misc-ps.m (original)
+++ cfe/tags/checker/checker-228/test/Analysis/misc-ps.m Thu Nov 12 21:43:38 2009
@@ -1,8 +1,8 @@
 // NOTE: Use '-fobjc-gc' to test the analysis being run twice, and multiple reports are not issued.
-// RUN: clang-cc -analyze -checker-cfref --analyzer-store=basic -fobjc-gc -analyzer-constraints=basic --verify -fblocks %s
-// RUN: clang-cc -analyze -checker-cfref --analyzer-store=basic -analyzer-constraints=range --verify -fblocks %s
-// RUN: clang-cc -analyze -checker-cfref --analyzer-store=region -analyzer-constraints=basic --verify -fblocks %s
-// RUN: clang-cc -analyze -checker-cfref --analyzer-store=region -analyzer-constraints=range --verify -fblocks %s
+// RUN: clang-cc -analyzer-experimental-checks -analyze -checker-cfref --analyzer-store=basic -fobjc-gc -analyzer-constraints=basic --verify -fblocks %s
+// RUN: clang-cc -analyzer-experimental-checks -analyze -checker-cfref --analyzer-store=basic -analyzer-constraints=range --verify -fblocks %s
+// RUN: clang-cc -analyzer-experimental-checks -analyze -checker-cfref --analyzer-store=region -analyzer-constraints=basic --verify -fblocks %s
+// RUN: clang-cc -analyzer-experimental-checks -analyze -checker-cfref --analyzer-store=region -analyzer-constraints=range --verify -fblocks %s
 
 typedef struct objc_ivar *Ivar;
 typedef struct objc_selector *SEL;

Modified: cfe/tags/checker/checker-228/test/Analysis/no-outofbounds.c
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/no-outofbounds.c?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/no-outofbounds.c (original)
+++ cfe/tags/checker/checker-228/test/Analysis/no-outofbounds.c Thu Nov 12 21:43:38 2009
@@ -1,5 +1,5 @@
-// RUN: clang-cc -checker-cfref -analyze -analyzer-store=basic -verify %s
-// RUN: clang-cc -checker-cfref -analyze -analyzer-store=region -verify %s
+// RUN: clang-cc -analyzer-experimental-checks -checker-cfref -analyze -analyzer-store=basic -verify %s
+// RUN: clang-cc -analyzer-experimental-checks -checker-cfref -analyze -analyzer-store=region -verify %s
 // XFAIL: *
 
 //===----------------------------------------------------------------------===//

Modified: cfe/tags/checker/checker-228/test/Analysis/outofbound.c
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/outofbound.c?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/outofbound.c (original)
+++ cfe/tags/checker/checker-228/test/Analysis/outofbound.c Thu Nov 12 21:43:38 2009
@@ -1,4 +1,4 @@
-// RUN: clang-cc -analyze -checker-cfref -analyzer-store=region -verify %s
+// RUN: clang-cc -analyzer-experimental-checks -analyze -checker-cfref -analyzer-store=region -verify %s
 
 char f1() {
   char* s = "abcd";

Modified: cfe/tags/checker/checker-228/test/Analysis/ptr-arith.c
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/ptr-arith.c?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/ptr-arith.c (original)
+++ cfe/tags/checker/checker-228/test/Analysis/ptr-arith.c Thu Nov 12 21:43:38 2009
@@ -1,5 +1,5 @@
-// RUN: clang-cc -analyze -checker-cfref -analyzer-store=region -verify -triple x86_64-apple-darwin9 %s
-// RUN: clang-cc -analyze -checker-cfref -analyzer-store=region -verify -triple i686-apple-darwin9 %s
+// RUN: clang-cc -analyzer-experimental-checks -analyze -checker-cfref -analyzer-store=region -verify -triple x86_64-apple-darwin9 %s
+// RUN: clang-cc -analyzer-experimental-checks -analyze -checker-cfref -analyzer-store=region -verify -triple i686-apple-darwin9 %s
 
 void f1() {
   int a[10];

Modified: cfe/tags/checker/checker-228/test/Analysis/rdar-6442306-1.m
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/rdar-6442306-1.m?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/rdar-6442306-1.m (original)
+++ cfe/tags/checker/checker-228/test/Analysis/rdar-6442306-1.m Thu Nov 12 21:43:38 2009
@@ -1,5 +1,5 @@
-// RUN: clang-cc -analyze -checker-cfref %s --analyzer-store=basic -verify
-// RUN: clang-cc -analyze -checker-cfref %s --analyzer-store=region -verify
+// RUN: clang-cc -analyze -analyzer-experimental-checks -checker-cfref %s --analyzer-store=basic -verify
+// RUN: clang-cc -analyze -analyzer-experimental-checks -checker-cfref %s --analyzer-store=region -verify
 
 typedef int bar_return_t;
 typedef struct {

Modified: cfe/tags/checker/checker-228/test/Analysis/rdar-6541136-region.c
URL: http://llvm.org/viewvc/llvm-project/cfe/tags/checker/checker-228/test/Analysis/rdar-6541136-region.c?rev=87076&r1=87075&r2=87076&view=diff

==============================================================================
--- cfe/tags/checker/checker-228/test/Analysis/rdar-6541136-region.c (original)
+++ cfe/tags/checker/checker-228/test/Analysis/rdar-6541136-region.c Thu Nov 12 21:43:38 2009
@@ -1,4 +1,4 @@
-// RUN: clang-cc -verify -analyze -checker-cfref -analyzer-store=region %s
+// RUN: clang-cc -analyzer-experimental-checks -verify -analyze -checker-cfref -analyzer-store=region %s
 
 struct tea_cheese { unsigned magic; };
 typedef struct tea_cheese kernel_tea_cheese_t;





More information about the llvm-branch-commits mailing list