This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [RFC] killing remaining USE___THREAD use
- From: Andreas Schwab <schwab at suse dot de>
- To: Roland McGrath <roland at hack dot frob dot com>
- Cc: Mike Frysinger <vapier at gentoo dot org>, libc-alpha at sourceware dot org
- Date: Tue, 25 Mar 2014 12:23:04 +0100
- Subject: Re: [RFC] killing remaining USE___THREAD use
- Authentication-results: sourceware.org; auth=none
- References: <4096104 dot BXBWkszvSk at vapier> <20140324224059 dot 737BC74484 at topped-with-meat dot com> <mvmtxamn1i3 dot fsf at hawking dot suse dot de>
If you go that route you have to apply this patch, though I have no idea
why this code may be needed.
diff --git a/elf/rtld.c b/elf/rtld.c
index 16e7f7a..ba92a2a 100644
--- a/elf/rtld.c
+++ b/elf/rtld.c
@@ -467,15 +467,16 @@ _dl_start (void *arg)
/* Initialize the TLS block. */
#if TLS_TCB_AT_TP
- initdtv[2].pointer = tlsblock;
+ initdtv[2].pointer.val = tlsblock;
#elif TLS_DTV_AT_TP
bootstrap_map.l_tls_offset = roundup (TLS_INIT_TCB_SIZE,
bootstrap_map.l_tls_align);
- initdtv[2].pointer = (char *) tlsblock + bootstrap_map.l_tls_offset;
+ initdtv[2].pointer.val = (char *) tlsblock + bootstrap_map.l_tls_offset;
#else
# error "Either TLS_TCB_AT_TP or TLS_DTV_AT_TP must be defined"
#endif
- p = __mempcpy (initdtv[2].pointer, bootstrap_map.l_tls_initimage,
+ initdtv[2].pointer.is_static = true;
+ p = __mempcpy (initdtv[2].pointer.val, bootstrap_map.l_tls_initimage,
bootstrap_map.l_tls_initimage_size);
#ifdef HAVE_BUILTIN_MEMSET
__builtin_memset (p, '\0', (bootstrap_map.l_tls_blocksize
Andreas.
--
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."