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 testsuite proc check_effective_target_tls


I am committing this patch, as it was approved offline by Janis last
week.  The stub programs that test for TLS support were not being
compiled properly in all circumstances (I cannot remember the details
now, I'm afraid) because the proc was calling target_compile rather
than ${tool}_target_compile.

Tested with a full regression test run.

2006-09-19  Ben Elliston  <bje@au.ibm.com>

        * lib/target-supports.exp (check_effective_target_tls): Compile
        test stubs using ${tool}_target_compile, not just target_compile.
        (check_effective_target_tls_runtime): Likewise.

Index: lib/target-supports.exp
===================================================================
--- lib/target-supports.exp     (revision 117038)
+++ lib/target-supports.exp     (working copy)
@@ -390,6 +390,7 @@ proc check_effective_target_pcc_bitfield
 
 proc check_effective_target_tls {} {
     global et_tls_saved
+    global tool
 
     if [info exists et_tls_saved] {
        verbose "check_effective_target_tls: using cached result" 2
@@ -406,7 +407,7 @@ proc check_effective_target_tls {} {
 
        # Test for thread-local data supported by the platform.
        set comp_output \
-           [target_compile $src $asm assembly ""]
+           [${tool}_target_compile $src $asm assembly ""]
        file delete $src
        if { [string match "*not supported*" $comp_output] } {
            set et_tls_saved 0
@@ -423,6 +424,7 @@ proc check_effective_target_tls {} {
 
 proc check_effective_target_tls_runtime {} {
     global et_tls_runtime_saved
+    global tool
 
     if [info exists et_tls_runtime_saved] {
        verbose "check_effective_target_tls_runtime: using cached result" 2
@@ -439,7 +441,7 @@ proc check_effective_target_tls_runtime 
        close $f
 
        set comp_output \
-           [target_compile $src $exe executable ""]
+           [${tool}_target_compile $src $exe executable ""]
        file delete $src
 
        if [string match "" $comp_output] then {



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