1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-28 00:21:52 +03:00

2003-03-14 Roland McGrath <roland@redhat.com>

* descr.h (struct pthread): Move the union out of [!TLS_DTV_AT_TP], so
	we always define the padding space.
	[!TLS_DTV_AT_TP]: Give tcbhead_t field a name, `header', since GCC
	stopped supporting its own extensions fully.
	[TLS_MULTIPLE_THREADS_IN_TCB]: Put `multiple_threads' inside a wrapper
	struct also called `header', so `header.multiple_threads' is the field
	name to use on all machines.
	* allocatestack.c (allocate_stack): Use `header.' prefix.
	* sysdeps/pthread/createthread.c (create_thread): Likewise.
	* pthread_create.c (__pthread_create_2_1): Likewise.
	* sysdeps/i386/tls.h (INSTALL_NEW_DTV, THREAD_DTV): Likewise.
	(THREAD_SELF): Likewise.
	* sysdeps/x86_64/tls.h: Likewise.
	* sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
	(SINGLE_THREAD_P): Likewise.
	* sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
	(SINGLE_THREAD_P): Likewise.
	* sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
	(SINGLE_THREAD_P): Likewise.
This commit is contained in:
Roland McGrath
2003-03-14 22:34:02 +00:00
parent 0eb1828169
commit 55c11fbdb0
9 changed files with 35 additions and 25 deletions

View File

@ -321,14 +321,14 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp,
#ifdef TLS_MULTIPLE_THREADS_IN_TCB
/* This is at least the second thread. */
pd->multiple_threads = 1;
pd->header.multiple_threads = 1;
#else
__pthread_multiple_threads = *__libc_multiple_threads_ptr = 1;
#endif
#ifdef NEED_DL_SYSINFO
/* Copy the sysinfo value from the parent. */
pd->sysinfo = THREAD_GETMEM (THREAD_SELF, sysinfo);
pd->header.sysinfo = THREAD_GETMEM (THREAD_SELF, header.sysinfo);
#endif
/* Allocate the DTV for this thread. */
@ -446,14 +446,14 @@ allocate_stack (const struct pthread_attr *attr, struct pthread **pdp,
#ifdef TLS_MULTIPLE_THREADS_IN_TCB
/* This is at least the second thread. */
pd->multiple_threads = 1;
pd->header.multiple_threads = 1;
#else
__pthread_multiple_threads = *__libc_multiple_threads_ptr = 1;
#endif
#ifdef NEED_DL_SYSINFO
/* Copy the sysinfo value from the parent. */
pd->sysinfo = THREAD_GETMEM (THREAD_SELF, sysinfo);
pd->header.sysinfo = THREAD_GETMEM (THREAD_SELF, header.sysinfo);
#endif
/* Allocate the DTV for this thread. */