Patchwork RFA: testsuite PATCH to add { target alias }

login
register
mail settings
Submitter Jason Merrill
Date Jan. 19, 2013, 3:38 p.m.
Message ID <50FABE0A.4010807@redhat.com>
Download mbox | patch
Permalink /patch/213875/
State New
Headers show

Comments

Jason Merrill - Jan. 19, 2013, 3:38 p.m.
When I was messing with TLS tests, I noticed that there's currently no 
effective target keyword for alias support.  This patch adds that.  OK 
for trunk?

Jason
Mike Stump - Jan. 20, 2013, 8:24 p.m.
On Jan 19, 2013, at 7:38 AM, Jason Merrill <jason@redhat.com> wrote:
> When I was messing with TLS tests, I noticed that there's currently no effective target keyword for alias support.  This patch adds that.  OK for trunk?

Ok.  [ looks trivial to me  :-)  ]

> +proc check_effective_target_alias { } {

Patch

commit 0737064c6a0d9f33c75d09d94db9bca1eb4053ca
Author: Jason Merrill <jason@redhat.com>
Date:   Sat Jan 19 00:09:28 2013 -0500

    	* lib/target-supports.exp (check_effective_target_alias): New.

diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp
index 0b11817..8b2fa29 100644
--- a/gcc/testsuite/lib/target-supports.exp
+++ b/gcc/testsuite/lib/target-supports.exp
@@ -354,6 +354,16 @@  proc check_alias_available { } {
     return $alias_available_saved
 }
 
+# Returns 1 if the target toolchain supports strong aliases, 0 otherwise.
+
+proc check_effective_target_alias { } {
+    if { [check_alias_available] < 2 } {
+	return 0
+    } else {
+	return 1
+    }
+}
+
 # Returns 1 if the target toolchain supports ifunc, 0 otherwise.
 
 proc check_ifunc_available { } {