This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Patch] Fix the testcases that use bind_pic_locally


Hello,

There are several tests that use "dg-add-options bind_pic_locally" in order to
add -fPIE or -fpie when -fPIC or -fpic are used respectively with the expecta-
tion that -fPIE/-fpie will override -fPIC/-fpic. But this doesn't happen since
since -fPIE/-fpie will be added before the -fPIC/-fpic (whether -fPIC/-fpic is
added as a multilib option or through cflags). This is essentially due to the
fact that cflags and multilib flags are added after the options are added 
through dg-options, dg-add-options, et al. in default_target_compile function.

Assuming dg-options or dg-add-options should always win, we can fix this by
modifying the order in which they are concatenated at default_target_compile in
target.exp. But this is not recommended since it depends on everyone who tests
upgrading their dejagnu (refer [1]). 

So this patch replaces:

/* { dg-add-options bind_pic_locally } */

with 

/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */

in all the applicable test files. 

NOTE: There are many files that uses bind_pic_locally but they do PASS whether
or not -fPIE/-fpie is passed. But I've replaced in all the files that uses
bind_pic_locally.

add_options_for_bind_pic_locally should IMO be removed or deprecated since it is
is misleading. I can post a separate patch for this if everyone agrees to it.

References:
[1] http://gcc.gnu.org/ml/gcc/2013-07/msg00281.html
[2] http://gcc.gnu.org/ml/gcc/2013-09/msg00207.html

This issue for obvious reasons, common to all targets. 

Tested for aarch64-none-elf. OK for trunk?

Cheers
VP

---

gcc/testsuite/ChangeLog:

2013-10-08  Vidya Praveen  <vidyapraveen@arm.com>

	* gcc.dg/inline-33.c: Remove bind_pic_locally and skip if -fPIC/-fpic
	is used.
	* gcc.dg/ipa/ipa-3.c: Likewise.
	* gcc.dg/ipa/ipa-5.c: Likewise.
	* gcc.dg/ipa/ipa-7.c: Likewise.
	* gcc.dg/ipa/ipcp-2.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-1.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-2.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-6.c: Likewise.
	* gcc.dg/ipa/ipa-1.c: Likewise.
	* gcc.dg/ipa/ipa-2.c: Likewise.
	* gcc.dg/ipa/ipa-4.c: Likewise.
	* gcc.dg/ipa/ipa-8.c: Likewise.
	* gcc.dg/ipa/ipacost-2.c: Likewise.
	* gcc.dg/ipa/ipcp-1.c: Likewise.
	* gcc.dg/ipa/ipcp-4.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-3.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-4.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-5.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-7.c: Likewise.
	* gcc.dg/ipa/ipcp-agg-8.c: Likewise.
	* gcc.dg/ipa/pr56988.c: Likewise.
	* g++.dg/ipa/iinline-1.C: Likewise.
	* g++.dg/ipa/iinline-2.C: Likewise.
	* g++.dg/ipa/iinline-3.C: Likewise.
	* g++.dg/ipa/inline-1.C: Likewise.
	* g++.dg/ipa/inline-2.C: Likewise.
	* g++.dg/ipa/inline-3.C: Likewise.
	* g++.dg/other/first-global.C: Likewise.
	* g++.dg/parse/attr-externally-visible-1.C: Likewise.
	* g++.dg/torture/pr40323.C: Likewise.
	* g++.dg/torture/pr55260-1.C: Likewise.
	* g++.dg/torture/pr55260-2.C: Likewise.
	* g++.dg/tree-ssa/inline-1.C: Likewise.
	* g++.dg/tree-ssa/inline-2.C: Likewise.
	* g++.dg/tree-ssa/inline-3.C: Likewise.
	* g++.dg/tree-ssa/nothrow-1.C: Likewise.
	* gcc.dg/tree-ssa/inline-3.c: Likewise.
	* gcc.dg/tree-ssa/inline-4.c: Likewise.
	* gcc.dg/tree-ssa/ipa-cp-1.c: Likewise.
	* gcc.dg/tree-ssa/local-pure-const.c: Likewise.
	* gfortran.dg/whole_file_5.f90: Likewise.
	* gfortran.dg/whole_file_6.f90: Likewise.
diff --git a/gcc/testsuite/g++.dg/ipa/iinline-1.C b/gcc/testsuite/g++.dg/ipa/iinline-1.C
index 9f99893..e4daa8c 100644
--- a/gcc/testsuite/g++.dg/ipa/iinline-1.C
+++ b/gcc/testsuite/g++.dg/ipa/iinline-1.C
@@ -2,7 +2,7 @@
    inlining..  */
 /* { dg-do compile } */
 /* { dg-options "-O3 -fdump-ipa-inline -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern void non_existent (const char *, int);
 
diff --git a/gcc/testsuite/g++.dg/ipa/iinline-2.C b/gcc/testsuite/g++.dg/ipa/iinline-2.C
index 670a5dd..64a4dce 100644
--- a/gcc/testsuite/g++.dg/ipa/iinline-2.C
+++ b/gcc/testsuite/g++.dg/ipa/iinline-2.C
@@ -2,7 +2,7 @@
    inlining..  */
 /* { dg-do compile } */
 /* { dg-options "-O3 -fdump-ipa-inline -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern void non_existent (const char *, int);
 
diff --git a/gcc/testsuite/g++.dg/ipa/iinline-3.C b/gcc/testsuite/g++.dg/ipa/iinline-3.C
index 3daee9a..0d59969 100644
--- a/gcc/testsuite/g++.dg/ipa/iinline-3.C
+++ b/gcc/testsuite/g++.dg/ipa/iinline-3.C
@@ -2,7 +2,7 @@
    parameters which have been modified.  */
 /* { dg-do run } */
 /* { dg-options "-O3 -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern "C" void abort (void);
 
diff --git a/gcc/testsuite/g++.dg/ipa/inline-1.C b/gcc/testsuite/g++.dg/ipa/inline-1.C
index dbbfb4e..018dd2c 100644
--- a/gcc/testsuite/g++.dg/ipa/inline-1.C
+++ b/gcc/testsuite/g++.dg/ipa/inline-1.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-ipa-inline --param max-early-inliner-iterations=1" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 namespace std {
   extern "C" void puts(const char *s);
diff --git a/gcc/testsuite/g++.dg/ipa/inline-2.C b/gcc/testsuite/g++.dg/ipa/inline-2.C
index fd284a1e2..50e6af7 100644
--- a/gcc/testsuite/g++.dg/ipa/inline-2.C
+++ b/gcc/testsuite/g++.dg/ipa/inline-2.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-ipa-inline --param max-early-inliner-iterations=1" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 namespace std {
   extern "C" void puts(const char *s);
diff --git a/gcc/testsuite/g++.dg/ipa/inline-3.C b/gcc/testsuite/g++.dg/ipa/inline-3.C
index 8d5f905..3a91ab7 100644
--- a/gcc/testsuite/g++.dg/ipa/inline-3.C
+++ b/gcc/testsuite/g++.dg/ipa/inline-3.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-ipa-inline --param max-early-inliner-iterations=1" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 #include <algorithm>
 
diff --git a/gcc/testsuite/g++.dg/other/first-global.C b/gcc/testsuite/g++.dg/other/first-global.C
index d58bc71..b349ec0 100644
--- a/gcc/testsuite/g++.dg/other/first-global.C
+++ b/gcc/testsuite/g++.dg/other/first-global.C
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 /* { dg-final { scan-assembler "_GLOBAL__(I|sub_I)(_|_65535_0_)foobar" } } */
 
 struct foo { foo (); };
diff --git a/gcc/testsuite/g++.dg/parse/attr-externally-visible-1.C b/gcc/testsuite/g++.dg/parse/attr-externally-visible-1.C
index 845d873..7ef18ef 100644
--- a/gcc/testsuite/g++.dg/parse/attr-externally-visible-1.C
+++ b/gcc/testsuite/g++.dg/parse/attr-externally-visible-1.C
@@ -1,6 +1,6 @@
 // { dg-do compile }
 // { dg-options "-O3 -fwhole-program" }
-// { dg-add-options bind_pic_locally }
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 // { dg-final { scan-assembler "foo1" } }
 // { dg-final { scan-assembler "foo2" } }
 // { dg-final { scan-assembler "foo3" } }
diff --git a/gcc/testsuite/g++.dg/torture/pr40323.C b/gcc/testsuite/g++.dg/torture/pr40323.C
index c7ffcb5..cdf28b1 100644
--- a/gcc/testsuite/g++.dg/torture/pr40323.C
+++ b/gcc/testsuite/g++.dg/torture/pr40323.C
@@ -1,7 +1,7 @@
 /* Testcase for PR 40323.  */
 /* { dg-do compile } */
 /* { dg-options "-fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern void do_something (const char *, int);
 
diff --git a/gcc/testsuite/g++.dg/torture/pr55260-1.C b/gcc/testsuite/g++.dg/torture/pr55260-1.C
index 552da8d..5fd5d74 100644
--- a/gcc/testsuite/g++.dg/torture/pr55260-1.C
+++ b/gcc/testsuite/g++.dg/torture/pr55260-1.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-std=gnu++0x -fno-inline" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
   struct B
   {
diff --git a/gcc/testsuite/g++.dg/torture/pr55260-2.C b/gcc/testsuite/g++.dg/torture/pr55260-2.C
index 43ed1e7..d012993 100644
--- a/gcc/testsuite/g++.dg/torture/pr55260-2.C
+++ b/gcc/testsuite/g++.dg/torture/pr55260-2.C
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct B
 {
diff --git a/gcc/testsuite/g++.dg/tree-ssa/inline-1.C b/gcc/testsuite/g++.dg/tree-ssa/inline-1.C
index d8682be..e0a4d1c 100644
--- a/gcc/testsuite/g++.dg/tree-ssa/inline-1.C
+++ b/gcc/testsuite/g++.dg/tree-ssa/inline-1.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-tree-einline --param max-early-inliner-iterations=3" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 namespace std {
   extern "C" void puts(const char *s);
diff --git a/gcc/testsuite/g++.dg/tree-ssa/inline-2.C b/gcc/testsuite/g++.dg/tree-ssa/inline-2.C
index 4c8a626..c3bb3d5 100644
--- a/gcc/testsuite/g++.dg/tree-ssa/inline-2.C
+++ b/gcc/testsuite/g++.dg/tree-ssa/inline-2.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-tree-einline --param max-early-inliner-iterations=3" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 namespace std {
   extern "C" void puts(const char *s);
diff --git a/gcc/testsuite/g++.dg/tree-ssa/inline-3.C b/gcc/testsuite/g++.dg/tree-ssa/inline-3.C
index 2804a63..1ec9853 100644
--- a/gcc/testsuite/g++.dg/tree-ssa/inline-3.C
+++ b/gcc/testsuite/g++.dg/tree-ssa/inline-3.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-tree-einline --param max-early-inliner-iterations=5" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 #include <algorithm>
 
diff --git a/gcc/testsuite/g++.dg/tree-ssa/nothrow-1.C b/gcc/testsuite/g++.dg/tree-ssa/nothrow-1.C
index 3346294..9678b0e 100644
--- a/gcc/testsuite/g++.dg/tree-ssa/nothrow-1.C
+++ b/gcc/testsuite/g++.dg/tree-ssa/nothrow-1.C
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O1 -fdump-tree-cfg" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 double a;
 void t()
diff --git a/gcc/testsuite/gcc.dg/inline-33.c b/gcc/testsuite/gcc.dg/inline-33.c
index d82ff71..2325bea 100644
--- a/gcc/testsuite/gcc.dg/inline-33.c
+++ b/gcc/testsuite/gcc.dg/inline-33.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fdump-tree-optimized"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 int i;
 
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-1.c b/gcc/testsuite/gcc.dg/ipa/ipa-1.c
index 3cc32da..2215ace 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-1.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-1.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 #include <stdio.h>
 int g (int b, int c)
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-2.c b/gcc/testsuite/gcc.dg/ipa/ipa-2.c
index 7f14d42..7549ead 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-2.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-2.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 #include <stdio.h>
 int g (int b, int c)
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-3.c b/gcc/testsuite/gcc.dg/ipa/ipa-3.c
index 36fd506..b117fd8 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-3.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-3.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 
 /* Double constants.  */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-4.c b/gcc/testsuite/gcc.dg/ipa/ipa-4.c
index 566b329..cbe78b5 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-4.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-4.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 #include <stdio.h>
 int g (int b, int c)
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-5.c b/gcc/testsuite/gcc.dg/ipa/ipa-5.c
index daa64fa..6db85e3 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-5.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-5.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 /* Float & short constants.  */
 
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-7.c b/gcc/testsuite/gcc.dg/ipa/ipa-7.c
index 271a34a..4d36314 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-7.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-7.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 #include <stdio.h>
 void send_addr (int *);
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-8.c b/gcc/testsuite/gcc.dg/ipa/ipa-8.c
index d138cf2..3995c90 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-8.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-8.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 #include <stdio.h>
 static int g (int b, int c)
diff --git a/gcc/testsuite/gcc.dg/ipa/ipacost-2.c b/gcc/testsuite/gcc.dg/ipa/ipacost-2.c
index ceb524e..d03fe69 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipacost-2.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipacost-2.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining -fdump-tree-optimized"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 int array[100];
 
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-1.c b/gcc/testsuite/gcc.dg/ipa/ipcp-1.c
index a2ffd42..522eed2 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-1.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-1.c
@@ -4,7 +4,7 @@
 
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern void use_stuff (int);
 
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-2.c b/gcc/testsuite/gcc.dg/ipa/ipcp-2.c
index 62f564f..b0a23a0 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-2.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-2.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern int get_stuff (int);
 extern void do_stuff (int);
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-4.c b/gcc/testsuite/gcc.dg/ipa/ipcp-4.c
index 462cade..5724c00 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-4.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-4.c
@@ -4,7 +4,7 @@
 
 /* { dg-do compile } */
 /* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern void use_stuff (int);
 extern void use_pointer (int *);
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-1.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-1.c
index b2e04f8..814da56 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-1.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-1.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-ipa-cp-details -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-2.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-2.c
index 7edfa40..349e260 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-2.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-2.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-ipa-cp-details -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-3.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-3.c
index 4c0a3e7..ea77ba7 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-3.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-3.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-ipa-cp-details -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-4.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-4.c
index 1c1da4d..2d333af 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-4.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-4.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-ipa-cp-details -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-5.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-5.c
index 9f6ee5b..9eaa37d 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-5.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-5.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-ipa-cp-details -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-6.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-6.c
index 050e13b..917398f 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-6.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-6.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-ipa-cp-details -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-7.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-7.c
index e85ca1a..d428474 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-7.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-7.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-ipa-cp-details -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-8.c b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-8.c
index 5014ffd..5e179cf 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipcp-agg-8.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-agg-8.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fno-ipa-sra -fdump-tree-optimized-slim"  } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/ipa/pr56988.c b/gcc/testsuite/gcc.dg/ipa/pr56988.c
index ab20159..24d9c42 100644
--- a/gcc/testsuite/gcc.dg/ipa/pr56988.c
+++ b/gcc/testsuite/gcc.dg/ipa/pr56988.c
@@ -1,6 +1,6 @@
 /* { dg-do run } */
 /* { dg-options "-O3" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 struct S
 {
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/inline-3.c b/gcc/testsuite/gcc.dg/tree-ssa/inline-3.c
index 35c3ebb..ec2f5df 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/inline-3.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/inline-3.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-tree-einline --param max-early-inliner-iterations=2" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern void inlined ();
 void inline_me_too (void);
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/inline-4.c b/gcc/testsuite/gcc.dg/tree-ssa/inline-4.c
index 1e700ef..8bc2fd3 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/inline-4.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/inline-4.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O2 -fdump-tree-einline" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 extern int rand(void);
 
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c b/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c
index ec628b7..a5afbc3 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O3 -fdump-tree-optimized -fno-inline" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 int
 very_long_function(int a)
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/local-pure-const.c b/gcc/testsuite/gcc.dg/tree-ssa/local-pure-const.c
index afb7ca4..e72f49e 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/local-pure-const.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/local-pure-const.c
@@ -1,6 +1,6 @@
 /* { dg-do compile } */
 /* { dg-options "-O1 -fdump-tree-local-pure-const1" } */
-/* { dg-add-options bind_pic_locally } */
+/* { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } } */
 
 t(int a, int b, int c)
 {
diff --git a/gcc/testsuite/gfortran.dg/whole_file_5.f90 b/gcc/testsuite/gfortran.dg/whole_file_5.f90
index 34240c9..69640b3 100644
--- a/gcc/testsuite/gfortran.dg/whole_file_5.f90
+++ b/gcc/testsuite/gfortran.dg/whole_file_5.f90
@@ -1,6 +1,6 @@
 ! { dg-do compile }
 ! { dg-options "-O3 -fwhole-file -fdump-tree-optimized" }
-! { dg-add-options bind_pic_locally }
+! { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } }
 !
 ! Check that inlining of functions declared BEFORE usage works.
 ! If yes, then the dump does not contain a call to F().
diff --git a/gcc/testsuite/gfortran.dg/whole_file_6.f90 b/gcc/testsuite/gfortran.dg/whole_file_6.f90
index 1d92bc3..46b261e 100644
--- a/gcc/testsuite/gfortran.dg/whole_file_6.f90
+++ b/gcc/testsuite/gfortran.dg/whole_file_6.f90
@@ -1,6 +1,6 @@
 ! { dg-do compile }
 ! { dg-options "-O3 -fwhole-file -fdump-tree-optimized" }
-! { dg-add-options bind_pic_locally }
+! { dg-skip-if "" { *-*-* } { "-fPIC" "-fpic" } { "" } }
 !
 ! Check that inlining of functions declared AFTER usage works.
 ! If yes, then the dump does not contain a call to F().

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]