about summary refs log tree commit diff
path: root/sysdeps/generic/libc-tls.c
Commit message (Collapse)AuthorAgeFilesLines
* * sysdeps/generic/dl-tls.c (_dl_allocate_tls_init): Fix inner loopRoland McGrath2002-08-121-4/+8
| | | | | | | | start count condition, use TOTAL instead of variable that was never set. Fix outer loop termination condition to TOTAL >= after update. * sysdeps/generic/libc-tls.c (__libc_setup_tls): Initialize dl_tls_static_align and dl_tls_static_nelem.
* Update.Ulrich Drepper2002-08-081-0/+1
| | | | * sysdeps/generic/libc-tls.c: Likewise.
* * sysdeps/generic/libc-tls.c (__libc_setup_tls): Make the phdr loopRoland McGrath2002-08-051-6/+4
| | | | | | | | | | actually iterate over the elements. Fix typo p_type -> p_vaddr. * include/pthread.h: Don't declare __pthread_initialize_minimal as weak here; we declare it weak or strong in the one place we use it. * sysdeps/generic/libc-start.c: ... which is here. Don't make the decl weak if [USE_TLS], since static programs need TLS setup even when single-threaded.
* * Makerules (cpp-srcs-left): When setting this to runRoland McGrath2002-08-051-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cppflags-iterator.mk, must append .c to $(tests) and $(xtests) words. Combine the two loops into one on the concatenated list, including those as well as $(test-srcs). * elf/dl-minimal.c (__libc_memalign): Guts of malloc moved here, since we align here with optimally minimal waste anyway. (malloc): Just call that. * sysdeps/generic/libc-tls.c (__libc_setup_tls): Set l_tls_offset to the right variable. * elf/dl-load.c (_dl_map_object_from_fd): Use p_vaddr, not p_offset, to compute memory location for l_tls_initimage. * elf/rtld.c (_dl_start): Likewise. * sysdeps/generic/libc-tls.c (__libc_setup_tls): Likewise. * libio/oldiopopen.c: Move #include's before #if SHLIB_COMPAT, because the .d file is generated in the non-shared case and so fails to catch them otherwise. * sysdeps/generic/dl-tls.c (_dl_allocate_tls_storage): New function, split out of _dl_allocate_tls. (_dl_allocate_tls_init): Likewise. (_dl_allocate_tls): Call those. * sysdeps/generic/ldsodefs.h: Declare them with attribute_hidden. * elf/rtld.c (dl_main): Call them separately instead of calling _dl_allocate_tls. Delay _dl_allocate_tls_init until after relocation is finished, so that the initializer data has been relocated before we copy it into the main thread's TLS block. * sysdeps/generic/dl-tls.c (_dl_allocate_tls): Fix off-by-one error in loop conditions, prevented the last used module from being initialized.
* Update.Ulrich Drepper2002-07-231-0/+182
2002-07-23 Ulrich Drepper <drepper@redhat.com> * sysdeps/generic/libc-tls.c: New file. * csu/Makefile (routines): Add libc-tls. (static-only-routines): Add libc-tls. * elf/dl-support.c (_dl_phdr): New variable. (_dl_phnum): New variable. (_dl_aux_init): Initialize _dl_phdr and _dl_phnum from aux vector. * sysdeps/generic/libc-start.c (__libc_start_main): Reorganize code for !SHARED. First look through auxiliary vector. If TLS always call __pthread_initialize_minimal. * sysdeps/generic/dl-tls.c (_dl_allocate_tls): Make sure size argument in mmap call is never zero.