]> granicus.if.org Git - clang/commitdiff
[analyzer] Replace "-analyzer-ipa" with "-analyzer-config ipa".
authorAnna Zaks <ganna@apple.com>
Thu, 24 Jan 2013 23:15:30 +0000 (23:15 +0000)
committerAnna Zaks <ganna@apple.com>
Thu, 24 Jan 2013 23:15:30 +0000 (23:15 +0000)
The idea is to eventually place all analyzer options under
"analyzer-config". In addition, this lays the ground for introduction of
a high-level analyzer mode option, which will influence the
default setting for IPAMode.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@173385 91177308-0d34-0410-b5e6-96231b3b80d8

36 files changed:
include/clang/StaticAnalyzer/Core/Analyses.def
include/clang/StaticAnalyzer/Core/AnalyzerOptions.h
include/clang/StaticAnalyzer/Core/PathSensitive/AnalysisManager.h
lib/Frontend/CompilerInvocation.cpp
lib/StaticAnalyzer/Core/AnalyzerOptions.cpp
lib/StaticAnalyzer/Core/ExprEngineCallAndReturn.cpp
test/Analysis/analyzer-config.c
test/Analysis/analyzer-config.cpp
test/Analysis/base-init.cpp
test/Analysis/blocks-no-inline.c
test/Analysis/ctor-inlining.mm
test/Analysis/derived-to-base.cpp
test/Analysis/dtor.cpp
test/Analysis/dynamic-cast.cpp
test/Analysis/initializer.cpp
test/Analysis/inline.cpp
test/Analysis/inlining/DynDispatchBifurcate.m
test/Analysis/inlining/InlineObjCClassMethod.m
test/Analysis/inlining/ObjCDynTypePopagation.m
test/Analysis/inlining/ObjCImproperDynamictallyDetectableCast.m
test/Analysis/inlining/RetainCountExamples.m
test/Analysis/inlining/assume-super-init-does-not-return-nil.m
test/Analysis/inlining/dyn-dispatch-bifurcate.cpp
test/Analysis/inlining/retain-count-self-init.m
test/Analysis/inlining/stl.cpp
test/Analysis/inlining/test_objc_inlining_option.m
test/Analysis/method-call-path-notes.cpp
test/Analysis/method-call.cpp
test/Analysis/misc-ps-region-store.cpp
test/Analysis/operator-calls.cpp
test/Analysis/pointer-to-member.cpp
test/Analysis/refcnt_naming.m
test/Analysis/reinterpret-cast.cpp
test/Analysis/self-init.m
test/Analysis/temporaries.cpp
test/Analysis/unix-fns.c

index 2efd8cb08c1fd61cdb11ba2fa38d906d895b85c3..dc7945016b1a739992f334a3a350f8a7bed11652 100644 (file)
@@ -41,16 +41,6 @@ ANALYSIS_PURGE(PurgeStmt,  "statement", "Purge symbols, bindings, and constraint
 ANALYSIS_PURGE(PurgeBlock, "block", "Purge symbols, bindings, and constraints before every basic block")
 ANALYSIS_PURGE(PurgeNone,  "none", "Do not purge symbols, bindings, or constraints")
 
-#ifndef ANALYSIS_IPA
-#define ANALYSIS_IPA(NAME, CMDFLAG, DESC)
-#endif
-
-ANALYSIS_IPA(None, "none", "Perform only intra-procedural analysis")
-ANALYSIS_IPA(BasicInlining, "basic-inlining", "Inline C functions and blocks when their definitions are available")
-ANALYSIS_IPA(Inlining, "inlining", "Inline callees when their definitions are available")
-ANALYSIS_IPA(DynamicDispatch, "dynamic", "Experimental: Enable inlining of dynamically dispatched methods")
-ANALYSIS_IPA(DynamicDispatchBifurcate, "dynamic-bifurcate", "Experimental: Enable inlining of dynamically dispatched methods, bifurcate paths when exact type info is unavailable")
-
 #ifndef ANALYSIS_INLINING_MODE
 #define ANALYSIS_INLINING_MODE(NAME, CMDFLAG, DESC)
 #endif
index 25b2f7138632829922ea1a5959d43820510918f5..aba4388ffd61f1c7e97acf040cfa407c6d9111d3 100644 (file)
@@ -64,13 +64,6 @@ enum AnalysisPurgeMode {
 NumPurgeModes
 };
 
-/// AnalysisIPAMode - Set of inter-procedural modes.
-enum AnalysisIPAMode {
-#define ANALYSIS_IPA(NAME, CMDFLAG, DESC) NAME,
-#include "clang/StaticAnalyzer/Core/Analyses.def"
-NumIPAModes
-};
-
 /// AnalysisInlineFunctionSelection - Set of inlining function selection heuristics.
 enum AnalysisInliningMode {
 #define ANALYSIS_INLINING_MODE(NAME, CMDFLAG, DESC) NAME,
@@ -102,6 +95,27 @@ enum CXXInlineableMemberKind {
   CIMK_Destructors
 };
 
+/// \brief Describes the different modes of inter-procedural analysis.
+enum IPAKind {
+  IPAK_NotSet = 0,
+
+  /// Perform only intra-procedural analysis.
+  IPAK_None = 1,
+
+  /// Inline C functions and blocks when their definitions are available.
+  IPAK_BasicInlining = 2,
+
+  /// Inline callees when their definitions are available.
+  // TODO: How is this different from BasicInlining?
+  IPAK_Inlining = 3,
+
+  /// Enable inlining of dynamically dispatched methods.
+  IPAK_DynamicDispatch = 4,
+
+  /// Enable inlining of dynamically dispatched methods, bifurcate paths when
+  /// exact type info is unavailable.
+  IPAK_DynamicDispatchBifurcate = 5
+};
 
 class AnalyzerOptions : public RefCountedBase<AnalyzerOptions> {
 public:
@@ -117,9 +131,6 @@ public:
   AnalysisDiagClients AnalysisDiagOpt;
   AnalysisPurgeMode AnalysisPurgeOpt;
   
-  // \brief The interprocedural analysis mode.
-  AnalysisIPAMode IPAMode;
-  
   std::string AnalyzeSpecificFunction;
   
   /// \brief The maximum number of exploded nodes the analyzer will generate.
@@ -165,6 +176,9 @@ public:
   AnalysisInliningMode InliningMode;
 
 private:
+  /// Controls the mode of inter-procedural analysis.
+  IPAKind IPAMode;
+
   /// Controls which C++ member functions will be considered for inlining.
   CXXInlineableMemberKind CXXMemberInliningMode;
   
@@ -210,9 +224,8 @@ private:
   int getOptionAsInteger(StringRef Name, int DefaultVal);
 
 public:
-  AnalysisIPAMode getIPAMode() const {
-    return IPAMode;
-  }
+  /// \brief Returns the inter-procedural analysis mode.
+  IPAKind getIPAMode();
 
   /// Returns the option controlling which C++ member functions will be
   /// considered for inlining.
@@ -289,28 +302,28 @@ public:
   unsigned getMaxTimesInlineLarge();
 
 public:
-  AnalyzerOptions() : CXXMemberInliningMode() {
-    AnalysisStoreOpt = RegionStoreModel;
-    AnalysisConstraintsOpt = RangeConstraintsModel;
-    AnalysisDiagOpt = PD_HTML;
-    AnalysisPurgeOpt = PurgeStmt;
-    IPAMode = DynamicDispatchBifurcate;
-    ShowCheckerHelp = 0;
-    AnalyzeAll = 0;
-    AnalyzerDisplayProgress = 0;
-    AnalyzeNestedBlocks = 0;
-    eagerlyAssumeBinOpBifurcation = 0;
-    TrimGraph = 0;
-    visualizeExplodedGraphWithGraphViz = 0;
-    visualizeExplodedGraphWithUbiGraph = 0;
-    UnoptimizedCFG = 0;
-    PrintStats = 0;
-    NoRetryExhausted = 0;
+  AnalyzerOptions() :
+    AnalysisStoreOpt(RegionStoreModel),
+    AnalysisConstraintsOpt(RangeConstraintsModel),
+    AnalysisDiagOpt(PD_HTML),
+    AnalysisPurgeOpt(PurgeStmt),
+    ShowCheckerHelp(0),
+    AnalyzeAll(0),
+    AnalyzerDisplayProgress(0),
+    AnalyzeNestedBlocks(0),
+    eagerlyAssumeBinOpBifurcation(0),
+    TrimGraph(0),
+    visualizeExplodedGraphWithGraphViz(0),
+    visualizeExplodedGraphWithUbiGraph(0),
+    UnoptimizedCFG(0),
+    PrintStats(0),
+    NoRetryExhausted(0),
     // Cap the stack depth at 4 calls (5 stack frames, base + 4 calls).
-    InlineMaxStackDepth = 5;
-    InlineMaxFunctionSize = 50;
-    InliningMode = NoRedundancy;
-  }
+    InlineMaxStackDepth(5),
+    InlineMaxFunctionSize(50),
+    InliningMode(NoRedundancy),
+    CXXMemberInliningMode() {}
+
 };
   
 typedef IntrusiveRefCntPtr<AnalyzerOptions> AnalyzerOptionsRef;
index 9038ae5276a70bb579ab3f85439a88666403038a..458c8966e79ec8ddb3e8011cf96dffdf91bcaddb 100644 (file)
@@ -100,7 +100,7 @@ public:
   }
 
   bool shouldInlineCall() const {
-    return options.IPAMode != None;
+    return options.getIPAMode() != IPAK_None;
   }
 
   CFG *getCFG(Decl const *D) {
index 011e3e1538af333bd622129b9bec5c8cbb182c15..9c94dfe87e7e1612aff54f9fa8b61571b8174895 100644 (file)
@@ -188,22 +188,6 @@ static bool ParseAnalyzerArgs(AnalyzerOptions &Opts, ArgList &Args,
     }
   }
 
-  if (Arg *A = Args.getLastArg(OPT_analyzer_ipa)) {
-    StringRef Name = A->getValue();
-    AnalysisIPAMode Value = llvm::StringSwitch<AnalysisIPAMode>(Name)
-#define ANALYSIS_IPA(NAME, CMDFLAG, DESC) \
-      .Case(CMDFLAG, NAME)
-#include "clang/StaticAnalyzer/Core/Analyses.def"
-      .Default(NumIPAModes);
-    if (Value == NumIPAModes) {
-      Diags.Report(diag::err_drv_invalid_value)
-        << A->getAsString(Args) << Name;
-      Success = false;
-    } else {
-      Opts.IPAMode = Value;
-    }
-  }
-
   if (Arg *A = Args.getLastArg(OPT_analyzer_inlining_mode)) {
     StringRef Name = A->getValue();
     AnalysisInliningMode Value = llvm::StringSwitch<AnalysisInliningMode>(Name)
index a336f04c8f74fbc31dc8207393028e8f299f3c42..107b739c1706773cbf1b1113d6e9dea7343513cb 100644 (file)
 using namespace clang;
 using namespace llvm;
 
+IPAKind AnalyzerOptions::getIPAMode() {
+  if (IPAMode == IPAK_NotSet) {
+
+    // Lookup the ipa configuration option, use the default from User Mode.
+    StringRef ModeStr(Config.GetOrCreateValue("ipa", 
+                                              "dynamic-bifurcate").getValue());
+    IPAKind IPAConfig = llvm::StringSwitch<IPAKind>(ModeStr)
+            .Case("none", IPAK_None)
+            .Case("basic-inlining", IPAK_BasicInlining)
+            .Case("inlining", IPAK_Inlining)
+            .Case("dynamic", IPAK_DynamicDispatch)
+            .Case("dynamic-bifurcate", IPAK_DynamicDispatchBifurcate)
+            .Default(IPAK_NotSet);
+    assert(IPAConfig != IPAK_NotSet && "IPA Mode is not set or invalid.");
+
+    // Set the member variable.
+    IPAMode = IPAConfig;
+  }
+  
+  return IPAMode;
+}
+
 bool
 AnalyzerOptions::mayInlineCXXMemberFunction(CXXInlineableMemberKind K) {
-  if (getIPAMode() < Inlining)
+  if (getIPAMode() < IPAK_Inlining)
     return false;
 
   if (!CXXMemberInliningMode) {
index 6e7701475ecc039472f7d04a74791998ab588d86..bdbc5d367957f78d553cfadc9cde93443fffab59 100644 (file)
@@ -559,8 +559,8 @@ bool ExprEngine::inlineCall(const CallEvent &Call, const Decl *D,
     if (!Opts.mayInlineObjCMethod())
       return false;
     AnalyzerOptions &Options = getAnalysisManager().options;
-    if (!(Options.getIPAMode() == DynamicDispatch ||
-          Options.getIPAMode() == DynamicDispatchBifurcate))
+    if (!(Options.getIPAMode() == IPAK_DynamicDispatch ||
+          Options.getIPAMode() == IPAK_DynamicDispatchBifurcate))
       return false;
     break;
   }
@@ -741,13 +741,13 @@ void ExprEngine::defaultEvalCall(NodeBuilder &Bldr, ExplodedNode *Pred,
         AnalyzerOptions &Options = getAnalysisManager().options;
 
         // Explore with and without inlining the call.
-        if (Options.getIPAMode() == DynamicDispatchBifurcate) {
+        if (Options.getIPAMode() == IPAK_DynamicDispatchBifurcate) {
           BifurcateCall(RD.getDispatchRegion(), *Call, D, Bldr, Pred);
           return;
         }
 
         // Don't inline if we're not in any dynamic dispatch mode.
-        if (Options.getIPAMode() != DynamicDispatch) {
+        if (Options.getIPAMode() != IPAK_DynamicDispatch) {
           conservativeEvalCall(*Call, Bldr, Pred, State);
           return;
         }
index d156a6ec3b5305ddfd101ad8ec78f232b4c584bb..bf9289bde5198813e2333677782d2de98feedd4f 100644 (file)
@@ -8,7 +8,8 @@ void foo() { bar(); }
 // CHECK-NEXT: cfg-temporary-dtors = false
 // CHECK-NEXT: faux-bodies = true
 // CHECK-NEXT: graph-trim-interval = 1000
+// CHECK-NEXT: ipa = dynamic-bifurcate
 // CHECK-NEXT: ipa-always-inline-size = 3
 // CHECK-NEXT: max-times-inline-large = 32
 // CHECK-NEXT: [stats]
-// CHECK-NEXT: num-entries = 5
+// CHECK-NEXT: num-entries = 6
index b3a8b34d49528f87565699c4087487f614edab1a..46b583d7797f2b04ecb07a4253231ac1463166ad 100644 (file)
@@ -17,7 +17,8 @@ public:
 // CHECK-NEXT: cfg-temporary-dtors = false
 // CHECK-NEXT: faux-bodies = true
 // CHECK-NEXT: graph-trim-interval = 1000
+// CHECK-NEXT: ipa = dynamic-bifurcate
 // CHECK-NEXT: ipa-always-inline-size = 3
 // CHECK-NEXT: max-times-inline-large = 32
 // CHECK-NEXT: [stats]
-// CHECK-NEXT: num-entries = 8
+// CHECK-NEXT: num-entries = 9
index 34e01aa5d7fcc129812c2a336226413c6dd1220c..3c870e1ccf88a657500a87500d0e8898564f6ca9 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=inlining -analyzer-config c++-inlining=constructors -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config c++-inlining=constructors -verify %s
 
 void clang_analyzer_eval(bool);
 
index 1ec14e820b0e0ca790a0da668e60359116dabe41..88f96acce1d626ef9164feccc78ad646ca8b2cce 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=none -fblocks -verify %s
+// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config ipa=none -fblocks -verify %s
 
 void clang_analyzer_eval(int);
 
index ac963e5d9b0992e2118a06f3d2bd3b857159c1f8..be5d81a58ed1f72111777fd2976806884c28ba8c 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -fobjc-arc -analyzer-ipa=inlining -analyzer-config c++-inlining=constructors -Wno-null-dereference -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -fobjc-arc -analyzer-config c++-inlining=constructors -Wno-null-dereference -verify %s
 
 void clang_analyzer_eval(bool);
 void clang_analyzer_checkInlined(bool);
index 30e7a3127ba2e3f87897a5ac77cebac55fc27f9d..57689d19e3b942a9858ec83029b97d37cc0ead88 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=inlining -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -verify %s
 
 void clang_analyzer_eval(bool);
 
index 40407ea5b63a496157a904782c4d9e6acca82341..a30823766e7919d6a466a01d4e08af88489c2805 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-ipa=inlining  -analyzer-config c++-inlining=destructors -Wno-null-dereference -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-config c++-inlining=destructors -Wno-null-dereference -verify %s
 
 void clang_analyzer_eval(bool);
 void clang_analyzer_checkInlined(bool);
index b1133ac2bee54bfb7c2d031e6e840923ce4a0f20..6bb571de47760da4b0be4a2b3b9534bfbfa2054d 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple i386-apple-darwin10 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=none -verify %s
+// RUN: %clang_cc1 -triple i386-apple-darwin10 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config ipa=none -verify %s
 
 void clang_analyzer_eval(bool);
 
index 92d581b82a31de3118b744c9d4f62262eab31ce8..d4f336977e31eb07159a8948c5993089bda9615e 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-ipa=inlining -analyzer-config c++-inlining=constructors -std=c++11 -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-config c++-inlining=constructors -std=c++11 -verify %s
 
 void clang_analyzer_eval(bool);
 
index ddcf5d01c34ceb19d324bdc1c2d9accc70da542e..873b046eb1ae135c8a952f4661897bd8ab0d2c5b 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-ipa=inlining -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-config ipa=inlining -verify %s
 
 void clang_analyzer_eval(bool);
 void clang_analyzer_checkInlined(bool);
@@ -192,7 +192,7 @@ namespace Invalidation {
     virtual void touchV2(int &x) const;
 
     int test() const {
-      // We were accidentally not invalidating under -analyzer-ipa=inlining
+      // We were accidentally not invalidating under inlining
       // at one point for virtual methods with visible definitions.
       int a, b, c, d;
       touch(a);
index 1fffb6503680b16e87190e7d99d3d1a0cd604f16..ab1dfc5ec14b6aa3bde2111b00ced92c07e35ea0 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx -analyzer-ipa=dynamic-bifurcate -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx -analyzer-config ipa=dynamic-bifurcate -verify %s
 
 #include "InlineObjCInstanceMethod.h"
 
index 814d437a52d031000e260221517315d64ef6dc06..90ce3c051babcd3aeabc043d71c4fca9b1a7d5d4 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-ipa=dynamic-bifurcate -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-config ipa=dynamic-bifurcate -verify %s
 
 // Test inlining of ObjC class methods.
 
index 4faaa2cb3033132fcf9fbb6d85c3c83515340c88..fc38a85d8590cb99a0c5a0814770846914ec19ad 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=dynamic-bifurcate -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config ipa=dynamic-bifurcate -verify %s
 
 #include "InlineObjCInstanceMethod.h"
 
index 739e10f2a5f93d194c8692d563a9539ad5b08213..06b271ad4b36b35686b1570cf7a2585d932f1d1f 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=dynamic-bifurcate -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config ipa=dynamic-bifurcate -verify %s
 
 typedef signed char BOOL;
 @protocol NSObject  - (BOOL)isEqual:(id)object; @end
index 276ab5209517ed52a1952d90505f4a33a5477d6b..41479af0a0968971bad28d80ebf61a2baa87f4ea 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount -analyzer-ipa=dynamic-bifurcate -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount -analyzer-config ipa=dynamic-bifurcate -verify %s
 
 typedef signed char BOOL;
 typedef struct objc_class *Class;
index cda1e87918e6df60d1f56110be3e3688653ffb1e..fba3e2d1b54b69402a3e766012ea9a5f3ecf0cdb 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-ipa=dynamic-bifurcate -analyzer-checker=core,osx -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx -verify %s
 
 typedef signed char BOOL;
 
index 37713481a48daad905d51d962c57016cd654ab58..890e5640cefbf04fb04c70e024f1cb4c1753bce3 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=dynamic-bifurcate -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config ipa=dynamic-bifurcate -verify %s
 
 void clang_analyzer_eval(bool);
 
index ee8dbe391c426165ecf11ddbf2a9de2377718ea1..97379dbc7a88ca898225c432075c652cb9c9ea3e 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount,osx.cocoa.SelfInit -analyzer-ipa=dynamic-bifurcate -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount,osx.cocoa.SelfInit -analyzer-config ipa=dynamic-bifurcate -verify %s
 
 typedef signed char BOOL;
 typedef struct objc_class *Class;
index cec782151c959d8f825c49d42158b06c2aa71e08..b09a5126bc639364c218bd5f3cd86c2fcb5e7ca1 100644 (file)
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-ipa=dynamic -analyzer-config c++-stdlib-inlining=false -verify %s
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-ipa=dynamic -analyzer-config c++-stdlib-inlining=true -DINLINE=1 -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-config c++-stdlib-inlining=false -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,debug.ExprInspection -analyzer-config c++-stdlib-inlining=true -DINLINE=1 -verify %s
 
 #include "../Inputs/system-header-simulator-cxx.h"
 
index 34502c4aa81d4a564aac528e79deb0f8f8c4ab4f..61408c1f3d42244ac058e0f0a72821f1e4987331 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-ipa=dynamic-bifurcate -analyzer-config objc-inlining=false -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-config ipa=dynamic-bifurcate -analyzer-config objc-inlining=false -verify %s
 // expected-no-diagnostics
 
 typedef signed char BOOL;
index b6068647a2f10422b98c8c8577245ff5e5298118..d6308a7bfa909df584c51c055ca8675a41d41384 100644 (file)
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-ipa=inlining -analyzer-output=text -verify %s
-// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-ipa=inlining -analyzer-output=plist-multi-file %s -o %t.plist
+// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=text -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=plist-multi-file %s -o %t.plist
 // RUN: FileCheck --input-file=%t.plist %s
 
 // Test warning about null or uninitialized pointer values used as instance member
index 1a2fedda33bc321b9c4d10fac31cb14a1a39b092..95db452aec6ab4c755ead760bbb5f8ba77e99aff 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=inlining -analyzer-config c++-inlining=constructors -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config c++-inlining=constructors -verify %s
 
 void clang_analyzer_eval(bool);
 
index de70d3b754dff80db304c304f8f1480697a224b2..6fbe441b2744d981c6e1f89023c62a93e177bc2b 100644 (file)
@@ -1,5 +1,5 @@
-// RUN: %clang_cc1 -triple i386-apple-darwin9 -analyze -analyzer-checker=core,alpha.core -analyzer-store=region -verify -fblocks -analyzer-ipa=inlining -analyzer-opt-analyze-nested-blocks %s -fexceptions -fcxx-exceptions
-// RUN: %clang_cc1 -triple x86_64-apple-darwin9 -analyze -analyzer-checker=core,alpha.core -analyzer-store=region -verify -fblocks -analyzer-ipa=inlining -analyzer-opt-analyze-nested-blocks %s -fexceptions -fcxx-exceptions
+// RUN: %clang_cc1 -triple i386-apple-darwin9 -analyze -analyzer-checker=core,alpha.core -analyzer-store=region -verify -fblocks -analyzer-opt-analyze-nested-blocks %s -fexceptions -fcxx-exceptions
+// RUN: %clang_cc1 -triple x86_64-apple-darwin9 -analyze -analyzer-checker=core,alpha.core -analyzer-store=region -verify -fblocks -analyzer-opt-analyze-nested-blocks %s -fexceptions -fcxx-exceptions
 
 // Test basic handling of references.
 char &test1_aux();
index 066f6a3bc67a34f2e4287a8a317134790e7799dd..4f686e55fdfa7fe4e02f917d51c46b96d5f37d8c 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,alpha.core,debug.ExprInspection -analyzer-ipa=inlining -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,alpha.core,debug.ExprInspection -verify %s
 void clang_analyzer_eval(bool);
 
 struct X0 { };
index cef5dc58669070e2c3557f789021375b4cd2d312..84dfe30646ddd9246db8091224effa51f8d7edb0 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=inlining -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -verify %s
 
 void clang_analyzer_eval(bool);
 
index 7a83fc198db47af8dae1a3cf642661f7d6ba2b5b..cff5970b315a9627a6f6a2da272ce8ef6fa3c8e1 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount,alpha.core -analyzer-ipa=none -analyzer-store=region -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx.cocoa.RetainCount,alpha.core -analyzer-config ipa=none -analyzer-store=region -verify %s
 
 typedef const struct __CFString * CFStringRef;
 typedef const struct __CFAllocator * CFAllocatorRef;
index 73f2e2de7381e8703fac2ce088e1d92158dda328..e82f7b686948e9cdc084013a547ccd97b7309292 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=inlining -verify %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -verify %s
 
 void clang_analyzer_eval(bool);
 
index d8e8888287d8652ca9d2fe78b017f058919fa80e..5a4354f49ad21613216883b0e0365d764e447111 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=osx.cocoa.SelfInit -fobjc-default-synthesize-properties -analyzer-ipa=dynamic -fno-builtin %s -verify
+// RUN: %clang_cc1 -analyze -analyzer-checker=osx.cocoa.SelfInit -fobjc-default-synthesize-properties -analyzer-config ipa=dynamic -fno-builtin %s -verify
 // RUN: %clang_cc1 -analyze -analyzer-checker=osx.cocoa.SelfInit -fobjc-default-synthesize-properties -fno-builtin %s -verify
 
 @class NSZone, NSCoder;
index df1ab5a30bea180bbd653e69e484973aec53d0cd..547be02791a345a4af11f6609198c1f72d4b0482 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-ipa=inlining -verify -w %s
+// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -verify -w %s
 
 struct Trivial {
   Trivial(int x) : value(x) {}
index b19476feb5bf4aedce339b37115fd97d2ae32aa8..9db5fa8256cadabeb5fd1e3c6573a703ce36d801 100644 (file)
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -analyze -analyzer-checker=core,unix.API,osx.API %s -analyzer-store=region -analyzer-output=plist -analyzer-ipa=inlining -analyzer-eagerly-assume -analyzer-config faux-bodies=true -fblocks -verify -o %t.plist
+// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -analyze -analyzer-checker=core,unix.API,osx.API %s -analyzer-store=region -analyzer-output=plist -analyzer-eagerly-assume -analyzer-config faux-bodies=true -fblocks -verify -o %t.plist
 // RUN: FileCheck --input-file=%t.plist %s
 
 struct _opaque_pthread_once_t {