Use -fblocks and -fobjc-nonfragile-abi when that is what is being tested, instead of forcing the triple.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89072 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Analysis/unused-ivars.m b/test/Analysis/unused-ivars.m
index 9e9360d..754799b 100644
--- a/test/Analysis/unused-ivars.m
+++ b/test/Analysis/unused-ivars.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -analyze -warn-objc-unused-ivars %s -verify
+// RUN: clang-cc -fblocks -analyze -warn-objc-unused-ivars %s -verify
 
 //===--- BEGIN: Delta-debugging reduced headers. --------------------------===//
 
diff --git a/test/CodeGenObjC/bitfield-ivar-offsets.m b/test/CodeGenObjC/bitfield-ivar-offsets.m
index e720232..64e14ee 100644
--- a/test/CodeGenObjC/bitfield-ivar-offsets.m
+++ b/test/CodeGenObjC/bitfield-ivar-offsets.m
@@ -1,5 +1,5 @@
 // RUNX: llvm-gcc -m64  -emit-llvm -S -o %t %s &&
-// RUN: clang-cc -triple x86_64-apple-darwin10 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 // RUN: grep -F '@"OBJC_IVAR_$_I0._b0" = global i64 0, section "__DATA, __objc_const", align 8' %t
 // RUN: grep -F '@"OBJC_IVAR_$_I0._b1" = global i64 0, section "__DATA, __objc_const", align 8' %t
 // RUN: grep -F '@"OBJC_IVAR_$_I0._b2" = global i64 1, section "__DATA, __objc_const", align 8' %t
diff --git a/test/CodeGenObjC/class-obj-hidden-visibility.m b/test/CodeGenObjC/class-obj-hidden-visibility.m
index fc4ac12..0135bbc 100644
--- a/test/CodeGenObjC/class-obj-hidden-visibility.m
+++ b/test/CodeGenObjC/class-obj-hidden-visibility.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -fvisibility=hidden -triple x86_64-apple-darwin10  -S -o - %s | grep -e "private_extern _OBJC_" | count 2 
+// RUN: clang-cc -fvisibility=hidden -fobjc-nonfragile-abi -S -o - %s | grep -e "private_extern _OBJC_" | count 2 
 
 @interface INTF @end
 
diff --git a/test/CodeGenObjC/forward-class-impl-metadata.m b/test/CodeGenObjC/forward-class-impl-metadata.m
index b8ce10a..5dfddde 100644
--- a/test/CodeGenObjC/forward-class-impl-metadata.m
+++ b/test/CodeGenObjC/forward-class-impl-metadata.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 
 @interface BASE  {
 @private
diff --git a/test/CodeGenObjC/hidden-synthesized-ivar.m b/test/CodeGenObjC/hidden-synthesized-ivar.m
index 50a87cb..c8d9990 100644
--- a/test/CodeGenObjC/hidden-synthesized-ivar.m
+++ b/test/CodeGenObjC/hidden-synthesized-ivar.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -fvisibility=hidden -triple x86_64-apple-darwin10  -S -o - %s | grep -e "private_extern _OBJC_IVAR_"
+// RUN: clang-cc -fobjc-nonfragile-abi -fvisibility=hidden -S -o - %s | grep -e "private_extern _OBJC_IVAR_"
 @interface I
 {
 	int P;
diff --git a/test/CodeGenObjC/interface-layout-64.m b/test/CodeGenObjC/interface-layout-64.m
index c18bbd6..60b06c0 100644
--- a/test/CodeGenObjC/interface-layout-64.m
+++ b/test/CodeGenObjC/interface-layout-64.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin9 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 // RUNX: llvm-gcc -m64 -emit-llvm -S -o %t %s &&
 
 // RUN: grep '@"OBJC_IVAR_$_I3._iv2" = global i64 8, section "__DATA, __objc_const", align 8' %t
diff --git a/test/CodeGenObjC/ivar-layout-64.m b/test/CodeGenObjC/ivar-layout-64.m
index 38d29eb..f9ac6cd 100644
--- a/test/CodeGenObjC/ivar-layout-64.m
+++ b/test/CodeGenObjC/ivar-layout-64.m
@@ -1,5 +1,5 @@
 // RUNX: llvm-gcc -m64 -fobjc-gc -emit-llvm -S -o %t %s &&
-// RUN: clang-cc -triple x86_64-apple-darwin9 -fobjc-gc -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -fobjc-gc -emit-llvm -o %t %s
 // RUN: grep '@"\\01L_OBJC_CLASS_NAME_.*" = internal global .* c"A\\00"' %t
 // RUN: grep '@"\\01L_OBJC_CLASS_NAME_.*" = internal global .* c"\\11q\\10\\00"' %t
 // RUN: grep '@"\\01L_OBJC_CLASS_NAME_.*" = internal global .* c"!q\\00"' %t
diff --git a/test/CodeGenObjC/metadata-symbols-64.m b/test/CodeGenObjC/metadata-symbols-64.m
index 7dac6f5..d007671 100644
--- a/test/CodeGenObjC/metadata-symbols-64.m
+++ b/test/CodeGenObjC/metadata-symbols-64.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin9 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 // RUNX: llvm-gcc -m64 -emit-llvm -S -o %t %s &&
 
 // RUN: grep '@"OBJC_CLASS_$_A" = global' %t
diff --git a/test/CodeGenObjC/metadata_symbols.m b/test/CodeGenObjC/metadata_symbols.m
index 222c013..c608cd4 100644
--- a/test/CodeGenObjC/metadata_symbols.m
+++ b/test/CodeGenObjC/metadata_symbols.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin9 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 
 // RUN: grep '@"OBJC_METACLASS_$_A" = global .*section "__DATA, __objc_data", align 8' %t
 // RUN: grep '@"OBJC_CLASS_$_A" = global .*section "__DATA, __objc_data", align 8' %t
@@ -10,7 +10,7 @@
 // RUN: grep -F 'define internal void @"\01-[A im0]"' %t
 // RUN: grep -F 'define internal void @"\01-[A(Cat) im1]"' %t
 
-// RUN: clang-cc -fvisibility=hidden -triple x86_64-apple-darwin9 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -fvisibility=hidden -emit-llvm -o %t %s
 
 // RUN: grep '@"OBJC_METACLASS_$_A" = hidden global .*section "__DATA, __objc_data", align 8' %t
 // RUN: grep '@"OBJC_CLASS_$_A" = hidden global .*section "__DATA, __objc_data", align 8' %t
diff --git a/test/CodeGenObjC/non-lazy-classes.m b/test/CodeGenObjC/non-lazy-classes.m
index 1064186..367705f 100644
--- a/test/CodeGenObjC/non-lazy-classes.m
+++ b/test/CodeGenObjC/non-lazy-classes.m
@@ -1,5 +1,5 @@
 // RUNX: llvm-gcc -m64 -emit-llvm -S -o %t %s &&
-// RUN: clang-cc -triple x86_64-apple-darwin10 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 // RUN: grep '@".01L_OBJC_LABEL_NONLAZY_CLASS_$" = internal global \[1 x .*\] .*@"OBJC_CLASS_$_A".*, section "__DATA, __objc_nlclslist, regular, no_dead_strip", align 8' %t
 // RUN: grep '@".01L_OBJC_LABEL_NONLAZY_CATEGORY_$" = internal global \[1 x .*\] .*@".01l_OBJC_$_CATEGORY_A_$_Cat".*, section "__DATA, __objc_nlcatlist, regular, no_dead_strip", align 8' %t
 
diff --git a/test/CodeGenObjC/objc2-ivar-assign.m b/test/CodeGenObjC/objc2-ivar-assign.m
index 31b042d..8e9a872 100644
--- a/test/CodeGenObjC/objc2-ivar-assign.m
+++ b/test/CodeGenObjC/objc2-ivar-assign.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -fobjc-gc -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -fobjc-gc -emit-llvm -o %t %s
 // RUN: grep objc_assign_ivar %t | count 6
 
 @interface I @end
diff --git a/test/CodeGenObjC/objc2-write-barrier-3.m b/test/CodeGenObjC/objc2-write-barrier-3.m
index 9b15742..63fa3a9 100644
--- a/test/CodeGenObjC/objc2-write-barrier-3.m
+++ b/test/CodeGenObjC/objc2-write-barrier-3.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -fobjc-gc -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -fblocks -fobjc-gc -emit-llvm -o %t %s
 // RUN: grep objc_assign_ivar %t | count 3
 // RUN: grep objc_assign_strongCast %t | count 6
 
diff --git a/test/CodeGenObjC/protocol-definition-hidden-visibility.m b/test/CodeGenObjC/protocol-definition-hidden-visibility.m
index 31a864b..f63bb03 100644
--- a/test/CodeGenObjC/protocol-definition-hidden-visibility.m
+++ b/test/CodeGenObjC/protocol-definition-hidden-visibility.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10  -S -o - %s | grep -e "private_extern l_OBJC_PROTOCOL_" | count 2
+// RUN: clang-cc -fobjc-nonfragile-abi  -S -o - %s | grep -e "private_extern l_OBJC_PROTOCOL_" | count 2
 
 @interface FOO @end
 
diff --git a/test/CodeGenObjC/protocol-in-extended-class.m b/test/CodeGenObjC/protocol-in-extended-class.m
index d0ff741..cad59b0 100644
--- a/test/CodeGenObjC/protocol-in-extended-class.m
+++ b/test/CodeGenObjC/protocol-in-extended-class.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -S %s -o %t-64.s
+// RUN: clang-cc -triple x86_64-apple-darwin10 -fobjc-nonfragile-abi -S %s -o %t-64.s
 // RUN: FileCheck -check-prefix LP64 --input-file=%t-64.s %s
 // RUN: clang-cc -triple i386-apple-darwin -S %s -o %t-32.s
 // RUN: FileCheck -check-prefix LP32 --input-file=%t-32.s %s
diff --git a/test/CodeGenObjC/protocol-property-synth.m b/test/CodeGenObjC/protocol-property-synth.m
index e91f355..ab230af 100644
--- a/test/CodeGenObjC/protocol-property-synth.m
+++ b/test/CodeGenObjC/protocol-property-synth.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 
 @interface BaseClass {
     id _delegate;
diff --git a/test/CodeGenObjC/synthesize_ivar-cont-class.m b/test/CodeGenObjC/synthesize_ivar-cont-class.m
index 2691ccf..dd444c3 100644
--- a/test/CodeGenObjC/synthesize_ivar-cont-class.m
+++ b/test/CodeGenObjC/synthesize_ivar-cont-class.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 // RUN: grep '@"OBJC_IVAR_$_XCOrganizerDeviceNodeInfo.viewController"' %t
 
 @interface XCOrganizerNodeInfo
diff --git a/test/CodeGenObjC/synthesize_ivar.m b/test/CodeGenObjC/synthesize_ivar.m
index e1746f1..9ed08d9 100644
--- a/test/CodeGenObjC/synthesize_ivar.m
+++ b/test/CodeGenObjC/synthesize_ivar.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -emit-llvm -o %t %s
+// RUN: clang-cc -fobjc-nonfragile-abi -emit-llvm -o %t %s
 
 @interface I
 @property int IP;
diff --git a/test/Index/c-index-api-test.m b/test/Index/c-index-api-test.m
index 20071ba..ac9ed92 100644
--- a/test/Index/c-index-api-test.m
+++ b/test/Index/c-index-api-test.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin10 -emit-pch -x objective-c %s -o %t.ast
+// RUN: clang-cc -fobjc-nonfragile-abi -fblocks -emit-pch -x objective-c %s -o %t.ast
 // RUN: c-index-test %t.ast all | FileCheck %s
 
 // CHECK: <invalid loc>:0:0: TypedefDecl=__int128_t:0:0 [Context=c-index-api-test.m]
diff --git a/test/SemaObjC/deref-interface.m b/test/SemaObjC/deref-interface.m
index 1c85918..57750a5 100644
--- a/test/SemaObjC/deref-interface.m
+++ b/test/SemaObjC/deref-interface.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin9 -verify -fsyntax-only %s
+// RUN: clang-cc -fobjc-nonfragile-abi -verify -fsyntax-only %s
 
 @interface NSView 
   - (id)initWithView:(id)realView;
diff --git a/test/SemaObjC/ivar-sem-check-2.m b/test/SemaObjC/ivar-sem-check-2.m
index ba6b389..a5a830d 100644
--- a/test/SemaObjC/ivar-sem-check-2.m
+++ b/test/SemaObjC/ivar-sem-check-2.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc  -fsyntax-only -triple x86_64-apple-darwin10 -verify %s
+// RUN: clang-cc  -fsyntax-only -fobjc-nonfragile-abi -verify %s
 
 @interface Super  {
   id value2; // expected-note {{previously declared 'value2' here}}
diff --git a/test/SemaObjC/property-nonfragile-abi.m b/test/SemaObjC/property-nonfragile-abi.m
index e2de77d..8352091 100644
--- a/test/SemaObjC/property-nonfragile-abi.m
+++ b/test/SemaObjC/property-nonfragile-abi.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -fsyntax-only -triple x86_64-apple-darwin9 -verify %s 
+// RUN: clang-cc -fsyntax-only -fobjc-nonfragile-abi -verify %s
 
 typedef signed char BOOL;
 
diff --git a/test/SemaObjC/sizeof-interface.m b/test/SemaObjC/sizeof-interface.m
index 140a980..aeb1b3f 100644
--- a/test/SemaObjC/sizeof-interface.m
+++ b/test/SemaObjC/sizeof-interface.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -triple x86_64-apple-darwin9 -verify -fsyntax-only %s
+// RUN: clang-cc -fobjc-nonfragile-abi -verify -fsyntax-only %s
 
 @class I0;
 
diff --git a/test/SemaObjC/synthesized-ivar.m b/test/SemaObjC/synthesized-ivar.m
index de44857..305629b 100644
--- a/test/SemaObjC/synthesized-ivar.m
+++ b/test/SemaObjC/synthesized-ivar.m
@@ -1,4 +1,4 @@
-// RUN: clang-cc -fsyntax-only -triple x86_64-apple-darwin9 -verify %s
+// RUN: clang-cc -fsyntax-only -fobjc-nonfragile-abi -verify %s
 @interface I
 {
 }