diff options
author | Ulrich Drepper <drepper@redhat.com> | 2002-12-11 09:32:45 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2002-12-11 09:32:45 +0000 |
commit | 85631c8ecf0d8f777ce30a072a82335add0b194b (patch) | |
tree | 31d934fbc655627f9339e47d2b1b3303eabd6072 /nptl/init.c | |
parent | 70a8ca6d899d41054ee2d5688bef416bdfc9d48c (diff) | |
download | glibc-85631c8ecf0d8f777ce30a072a82335add0b194b.zip glibc-85631c8ecf0d8f777ce30a072a82335add0b194b.tar.gz glibc-85631c8ecf0d8f777ce30a072a82335add0b194b.tar.bz2 |
Update.
2002-12-11 Ulrich Drepper <drepper@redhat.com>
* init.c (__pthread_initialize_minimal): Fix initialization in
static lib by preventing gcc from being too clever.
Diffstat (limited to 'nptl/init.c')
-rw-r--r-- | nptl/init.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/nptl/init.c b/nptl/init.c index e3f5111..678c0a5 100644 --- a/nptl/init.c +++ b/nptl/init.c @@ -104,6 +104,12 @@ __pthread_initialize_minimal (void) /* Unlike in the dynamically linked case the dynamic linker has not taken care of initializing the TLS data structures. */ __libc_setup_tls (TLS_TCB_SIZE, TLS_TCB_ALIGN); + + /* We must prevent gcc from being clever and move any of the + following code ahead of the __libc_setup_tls call. This function + will initialize the thread register which is subsequently + used. */ + __asm __volatile (""); #endif /* Minimal initialization of the thread descriptor. */ |