This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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]

Re: [PATCH] Fix .tls_common handling in ld -r


On Fri, Jun 16, 2006 at 05:20:32PM +0200, Jakub Jelinek wrote:
> On Thu, Jun 15, 2006 at 08:00:23AM -0700, H. J. Lu wrote:
> > > > Can you add a testcase?
> > > 
> > > We don't have yet any checks in the testsuite whether the compiler
> > > supports __thread.  But, perhaps just compiling/ld -r'ing/linking
> > > __asm (".tls_common foo,4,4");
> > > int main (void) { return 0; }
> > > would be enough.  But then again, we need some test to see whether
> > > the target supports TLS at all.  The current TLS tests are all in
> > > ld-<cpu>/ ATM, but this test isn't arch specific.
> > 
> > You can put the test in ld-elf and limit it to those targets with
> > TLS support. There are many cases in ld-elf.
> 
> Ok, here is a testcase for the patch I sent yesterday.
> Verified it passes on x86_64-linux with the patch in and fails without it
> (also if I comment out these 2 lines:
> #       fail "tls_common"
>     } else {
>        unresolved "tls_common"
>     }
> #    return
> }
> it fails without the patch on the readelf test).
> Ok?
> 
> 2006-06-16  Jakub Jelinek  <jakub@redhat.com>
> 
> 	* ld-elf/tls_common.exp: New test.
> 	* ld-elf/tls_common.s: New file.
> 

Is that possible to add tls_common.d instead of tls_common.exp?


H.J.


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