domi...@lps.ens.fr (Dominique Dhumieres) writes: > On x86_64-apple-darwin10 The following tests: > > g++.dg/gomp/tls-5.C > g++.dg/tls/thread_local-cse.C > g++.dg/tls/thread_local-order*.C > g++.dg/tls/thread_local*g.C > > fail with > > sorry, unimplemented: dynamic initialization of non-function-local > thread_local variables not supported on this target
May not be related, but I was seeing g++.dg/tls/thread_local-cse.C fail on mipsisa64-elf too. It had the right conditions, but the dg-do line needs to come first. g++.dg/tls/thread_local-wrap4.C was also failing because it requires -fPIC. I committed the following as (hopefully) obvious after testing on mipsisa64-elf. Richard gcc/testsuite/ * g++.dg/tls/thread_local-cse.C: Move dg-do line. * g++.dg/tls/thread_local-wrap4.C: Require fpic. Index: gcc/testsuite/g++.dg/tls/thread_local-cse.C =================================================================== --- gcc/testsuite/g++.dg/tls/thread_local-cse.C 2012-10-10 20:53:22.000000000 +0100 +++ gcc/testsuite/g++.dg/tls/thread_local-cse.C 2012-10-15 20:28:38.147650178 +0100 @@ -1,11 +1,11 @@ // Test for CSE of the wrapper function: we should only call it once // for the two references to ir. +// { dg-do run } // { dg-options "-std=c++11 -O -fno-inline -save-temps" } // { dg-require-effective-target tls_runtime } // { dg-require-alias } // { dg-final { scan-assembler-times "call *_ZTW2ir" 1 { xfail *-*-* } } } // { dg-final cleanup-saved-temps } -// { dg-do run } // XFAILed until the back end supports a way to mark a function as cseable // though not pure. Index: gcc/testsuite/g++.dg/tls/thread_local-wrap4.C =================================================================== --- gcc/testsuite/g++.dg/tls/thread_local-wrap4.C 2012-10-14 14:02:01.000000000 +0100 +++ gcc/testsuite/g++.dg/tls/thread_local-wrap4.C 2012-10-15 20:28:38.147650178 +0100 @@ -2,6 +2,7 @@ // copy per shared object. // { dg-require-effective-target tls } +// { dg-require-effective-target fpic } // { dg-options "-std=c++11 -fPIC" } // { dg-final { scan-assembler-not "_ZTW1i@PLT" { target i?86-*-* x86_64-*-* } } }