1 2004-09-07 Ulrich Drepper <drepper@redhat.com>
3 * sysdeps/pthread/pthread.h (pthread_once): Remove __THROW since
4 the initialization function might throw.
6 2004-08-30 Roland McGrath <roland@frob.com>
8 * Makefile (libpthread-abi-frozen): New variable.
10 2004-08-26 Roland McGrath <roland@redhat.com>
12 * configure.in: New file. If nptl add-on is also selected, barf if
13 explicit and elide ourselves if implicit.
14 * configure: Now generated.
16 2004-08-25 Richard Sandiford <rsandifo@redhat.com>
18 * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h (CENABLE, CDISABLE,
19 __local_multiple_threads): Fix definitions for IS_IN_librt.
20 * sysdeps/unix/sysv/linux/mips/mips64/sysdep-cancel.h: Likewise.
22 2004-08-22 Andreas Schwab <schwab@suse.de>
24 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO) [IS_IN_librt]:
25 Save gp around CENABLE/CDISABLE calls.
27 2004-08-15 Roland McGrath <roland@frob.com>
29 * pthread_atfork.c: Update copyright terms including special exception
30 for these trivial files, which are statically linked into executables
31 that use dynamic linking for the significant library code.
33 2004-08-09 Jakub Jelinek <jakub@redhat.com>
35 * libc-tsd.c: Move resolv.h include before the #if.
36 (__res_maybe_init): New function. Add libc_hidden_def.
38 2004-08-02 Ulrich Drepper <drepper@redhat.com>
40 * linuxthreads.texi (Cleanup Handlers): Fix typo.
41 Reported by Bjoern Engelmann <bjengelmann@gmx.de>.
43 2004-07-23 Jakub Jelinek <jakub@redhat.com>
46 * sysdeps/pthread/pthread.h (pthread_getcpuclockid): Use __clockid_t
49 2004-07-21 Roland McGrath <roland@redhat.com>
51 * Makefile ($(objpfx)multidir.mk): Use $(make-target-directory).
53 2004-07-02 Roland McGrath <roland@redhat.com>
55 * configure: Don't exit.
57 2004-07-20 Alexandre Oliva <aoliva@redhat.com>
59 * sysdeps/mips/pt-machine.h: Use standard names for ABI macros,
61 * sysdeps/mips/atomicity.h: Likewise.
63 2004-07-19 Alexandre Oliva <aoliva@redhat.com>
65 * sysdeps/unix/sysv/linux/mips/Makefile (CFLAGS-pt-initfini.s):
66 Remove redundant override that missed -g0.
68 2004-07-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
70 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
71 (__local_multiple_threads): Define for librt.
72 (SINGLE_THREAD_P): Likewise.
74 2004-07-07 Jakub Jelinek <jakub@redhat.com>
76 * sysdeps/pthread/getcpuclockid.c (pthread_getcpuclockid): Allow
77 using other thread's clock.
78 * ptclock_gettime.c (__pthread_clock_gettime): Likewise.
79 * ptclock_settime.c (__pthread_clock_settime): Likewise.
80 * internals.h (__pthread_clock_gettime, __pthread_clock_settime):
82 Reported by Bernd Schmidt <bernds@redhat.com>.
83 * Makefile (librt-tests): Add tst-clock1.
84 * tst-clock1.c: New test.
86 * sysdeps/x86_64/Versions: New file.
87 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: New file.
88 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: New file.
90 2004-04-16 Andreas Schwab <schwab@suse.de>
92 * sysdeps/ia64/tls.h (INIT_SYSINFO): Cast dl_sysinfo to void*.
94 2004-07-05 Jakub Jelinek <jakub@redhat.com>
96 * sysdeps/s390/pspinlock.c (__pthread_spin_lock,
97 __pthread_spin_trylock): Use constraint "m" instead of "0" for
99 * sysdeps/ia64/pt-machine.h (__compare_and_swap,
100 __compare_and_swap_with_release_semantic, testandset): Use
101 constraint "m" instead of "0" for futex.
103 2004-06-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
105 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (CENABLE): Fix
106 branch offset for a PLT entry.
107 (CDISABLE): Likewise.
109 2004-05-31 Andreas Jaeger <aj@suse.de>
111 * sysdeps/unix/sysv/linux/mips/Makefile (CFLAGS-pt-initfini.s):
112 Set to -fno-unit-at-a-time.
113 Patch by Dan Kegel <dank@kegel.com>.
115 2004-05-04 Jakub Jelinek <jakub@redhat.com>
117 * tst-stack1.c: Don't include mcheck.h.
118 (do_test): Make sure user defined stacks aren't reused,
119 don't free them at the end. [BZ #110]
121 2004-05-02 Jakub Jelinek <jakub@redhat.com>
123 * manager.c: Include not-cancel.h.
124 (__pthread_manager): Use read_not_cancel instead of __libc_read.
125 (pthread_start_thread, __pthread_manager_sighandler): Use
126 write_not_cancel instead of __libc_write.
127 (pthread_reap_children): Use waitpid_not_cancel instead of
129 * pthread.c: Include not-cancel.h.
130 (__pthread_initialize_minimal, __pthread_create_2_1,
131 pthread_onexit_process, __pthread_message): Use
132 write_not_cancel instead of __libc_write.
133 (__pthread_initialize_manager): Likewise. Use close_not_cancel
134 instead of __libc_close.
135 (__pthread_reset_main_thread): Use close_not_cancel instead of
137 * join.c: Include not-cancel.h.
138 (__pthread_do_exit, pthread_join, pthread_detach): Use
139 write_not_cancel instead of __libc_write.
140 * semaphore.c: Include not-cancel.h.
141 (__new_sem_post): Use write_not_cancel instead of __libc_write.
142 * specific.c: Include not-cancel.h.
143 (pthread_key_delete): Use write_not_cancel instead of __libc_write.
145 2004-05-01 Jakub Jelinek <jakub@redhat.com>
147 * Versions (libc): Add __on_exit and __libc_sigaction.
149 2004-04-28 Jakub Jelinek <jakub@redhat.com>
151 * semaphore.c (sem_timedwait): Return -1 and set errno instead of
152 returning error number [BZ #133]. Patch by <rmhaddad@yahoo.com>.
154 2004-04-22 SUGIOKA Toshinobu <sugioka@itonet.co.jp>
156 * sysdeps/unix/sysv/linux/sh/vfork.S: Fix wrong function pointer
157 reference in PIC case.
159 2004-04-20 Jakub Jelinek <jakub@redhat.com>
161 * oldsemaphore.c (SEM_VALUE_MAX): Remove.
163 2004-04-19 Kaz Kojima <kkojima@rr.iij4u.or.jp>
165 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (CENABLE): Define
166 for librt. Save the return value to a safe register.
167 (CDISABLE): Define for librt. Set the function argument correctly.
169 2004-04-18 Jakub Jelinek <jakub@redhat.com>
171 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
172 (PSEUDO_CANCEL): Define.
174 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (CENABLE,
175 CDISABLE): For librt, append @PLT.
177 2004-04-17 Jakub Jelinek <jakub@redhat.com>
179 * sysdeps/x86_64/tls.h [!__ASSEMBLER__]: Include tcb-offsets.h.
181 * sysdeps/pthread/timer_gettime.c (timer_gettime): For expired timer
182 return it_value { 0, 0 }.
183 * sysdeps/pthread/timer_create.c (timer_create): Handle SIGEV_NONE
185 * sysdeps/pthread/timer_routines.c (thread_expire_timer): Remove
186 assertion for SIGEV_NONE.
187 (thread_attr_compare): Compare all attributes, not just a partial
190 * sysdeps/unix/sysv/linux/mq_notify.c: Include stdlib.h.
192 2004-04-17 Ulrich Drepper <drepper@redhat.com>
194 * semaphore.h (SEM_VALUE_MAX): Just use a plain number.
196 2004-04-16 Ulrich Drepper <drepper@redhat.com>
198 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Fix last patch.
200 2004-04-13 Jakub Jelinek <jakub@redhat.com>
202 * sysdeps/unix/sysv/linux/mq_notify.c: Shut up GCC warning.
204 2004-04-12 Ulrich Drepper <drepper@redhat.com>
206 * sysdeps/unix/sysv/linux/mq_notify.c: New file.
208 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (CENABLE): Define
210 (CDISABLE): Likewise.
212 2004-04-08 Jakub Jelinek <jakub@redhat.com>
214 * sysdeps/unix/sysv/linux/bits/local_lim.h (MQ_PRIO_MAX): Define.
215 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h (MQ_PRIO_MAX): Define.
216 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h (MQ_PRIO_MAX): Define.
217 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h (MQ_PRIO_MAX): Define.
218 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_MESSAGE_PASSING):
220 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h
221 (_POSIX_MESSAGE_PASSING): Define.
223 2004-04-10 Andreas Jaeger <aj@suse.de>
225 * sysdeps/x86_64/pt-machine.h: Add used attribute to stack_pointer
226 to avoid warnings with GCC 3.5.
228 2004-04-09 Steven Munroe <sjmunroe@us.ibm.com>
230 * sysdeps/powerpc/tls.h (TLS_INIT_TP): Eliminate lvalue cast from
231 __thread_self assignment.
232 (THREAD_DTV): Replace __thread_register with __thread_self.
233 (INIT_THREAD_SELF): Eliminate lvalue cast from __thread_self
236 2004-04-08 Alexandre Oliva <aoliva@redhat.com>
238 * signals.c (pthread_sigmask): Don't ever block or mask
241 2004-03-11 Steven Munroe <sjmunroe@us.ibm.com>
243 * sysdeps/powerpc/tls.h: Remove __powerpc64__ conditional.
245 2004-03-23 Ulrich Drepper <drepper@redhat.com>
247 * sysdeps/ia64/pt-machine.h (BUSY_WAIT_NOP): Define.
248 * sysdeps/x86_64/pt-machine.h (BUSY_WAIT_NOP): Likewise.
250 2004-03-12 Ulrich Drepper <drepper@redhat.com>
252 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add HOST_NAME_MAX.
253 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
254 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
255 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
257 2004-03-08 Andreas Jaeger <aj@suse.de>
259 * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT_KERNEL_CHECK):
260 dl_osversion is readonly.
262 2004-03-07 Ulrich Drepper <drepper@redhat.com>
264 * sysdeps/i386/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
266 * sysdeps/ia64/tls.h (INIT_SYSINFO): Likewise.
268 2004-02-20 Steven Munroe <sjmunroe@us.ibm.com>
270 * sysdeps/unix/sysv/linux/powerpc/ptlongjmp.c [SHARED]: Code only
271 valid for SHARED case. Correct spelling of __vmx_longjmp.
273 * sysdeps/powerpc/pspinlock.c: Move from here.
274 * sysdeps/powerpc/powerpc32/pspinlock.c: To here.
275 * sysdeps/powerpc/powerpc64/pspinlock.c: New file.
276 * sysdeps/powerpc/powerpc64/pt-machine.h: Define __compare_and_swap32
277 and __compare_and_swap32_with_release_semantics.
279 2004-02-20 Jakub Jelinek <jakub@redhat.com>
281 * Makefile (generated): Remove tst-stack1.mtrace and tst-stack1-mem.
282 (tests): Remove $(objpfx)tst-stack1-mem.
283 (tst-stack1-ENV): Remove.
284 ($(objpfx)tst-stack1-mem): Remove.
286 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
287 (__syscall_error_handler2): Call CDISABLE.
288 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
289 (__syscall_error_handler2): Call CDISABLE.
291 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h (DL_ARGV_NOT_RELRO): Define.
293 2004-02-10 Steven Munroe <sjmunroe@us.ibm.com>
295 * Makefile (libpthread-routines): Add ptcleanup.
296 * ptlongjmp.c: Removed.
297 * ptcleanup.c: Copied __pthread_cleanup_upto to here. New file.
298 * sysdeps/pthread/ptlongjmp.c: Copied longjmp to here. New file.
299 * sysdeps/unix/sysv/linux/powerpc/Versions: New file.
300 Version longjmp, siglongjmp for GLIBC_2.3.4.
301 * sysdeps/unix/sysv/linux/powerpc/ptlongjmp.c: New File.
303 2004-01-22 Andreas Jaeger <aj@suse.de>
305 * spinlock.c (__pthread_lock): Fix contraint to avoid warning.
306 (__pthread_release): Likewise.
308 2004-01-16 Richard Henderson <rth@redhat.com>
310 * attr.c: Include ldsodefs.h.
311 (pthread_getattr_np): Don't declare __libc_stack_end.
313 2004-01-09 Steven Munroe <sjmunroe@us.ibm.com>
315 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
316 [!HAVE_TLS_SUPPORT]: Define SINGLE_THREAD_P using static
317 __lib*_multiple_threads.
318 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
319 [!HAVE_TLS_SUPPORT]: Likewise.
321 2004-01-13 Roland McGrath <roland@redhat.com>
323 * sysdeps/powerpc/tcb-offsets.sym: Put -- separator line before any
326 2004-01-10 Andreas Jaeger <aj@suse.de>
328 * sysdeps/unix/sysv/linux/x86_64/vfork.S: Add cfi directives.
330 2004-01-01 Andreas Jaeger <aj@suse.de>
332 * Makefile (generated): Add missing files.
334 2003-12-31 Ulrich Drepper <drepper@redhat.com>
336 * attr.c (pthread_getattr_np): Make sure stack info returned for
337 main thread does not overlap with any other VMA.
338 Patch by Jakub Jelinek.
340 2003-12-29 Jakub Jelinek <jakub@redhat.com>
342 * sysdeps/ia64/tls.h: Include dl-sysdep.h.
343 (INIT_SYSINFO): Define.
344 (TLS_INIT_TP): Use it.
346 2003-12-28 Carlos O'Donell <carlos@baldric.uwo.ca>
348 * attr.c (pthread_getattr_np): Add _STACK_GROWS_UP case.
350 2003-12-26 Jakub Jelinek <jakub@redhat.com>
352 * sysdeps/pthread/pthread.h (pthread_setcancelstate,
353 pthread_setcanceltype, pthread_cancel, pthread_testcancel): Remove
355 * semaphore.h (sem_wait, sem_timedwait): Likewise.
357 2003-12-17 Jakub Jelinek <jakub@redhat.com>
359 * manager.c (pthread_free): Call _dl_deallocate_tls even for
361 * pthread.c (__pthread_initialize_manager): Call _dl_deallocate_tls
363 (pthread_onexit_process): Update comment.
364 * Makefile (tests): Add tst-stack1. Depend on $(objpfx)tst-stack1-mem.
365 (generated): Add tst-stack1.mtrace and tst-stack1-mem.
366 (tst-stack1-ENV): Set.
367 ($(objpfx)tst-stack1-mem): New.
368 * tst-stack1.c: New test.
370 2003-12-16 Steven Munroe <sjmunroe@us.ibm.com>
372 * sysdeps/powerpc/tcb-offsets.sym [!__powerpc64__]: Remove
373 conditional so MULTIPLE_THREADS_OFFSET is generated for both.
374 * sysdeps/powerpc/tls.h [!__powerpc64__]: Remove conditional
375 so TLS_MULTIPLE_THREADS_IN_TCB is generated for both.
376 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h:
379 2003-12-04 Steven Munroe <sjmunroe@us.ibm.com>
381 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
382 (SINGLE_THREAD_P): Test using thread local p_multiple_threads field.
384 2003-12-10 David Mosberger <davidm@hpl.hp.com>
386 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Update copyright
387 message. Add include of <stddef.h>.
388 (INIT_NEW_WAY): New macro.
389 (INIT_OLD_WAY): Likewise.
390 (_init): Add unwind directives. Invoke
391 __pthread_initialize_minimal() via INIT_NEW_WAY or INIT_OLD_WAY,
393 (_init_EPILOG_BEGINS): Add unwind-directives. Drop unused .regstk
395 (_fini): Add unwind directives. Drop unnecessary .align 16
396 directive (bundles are always 16-byte aligned).
397 (_fini_EPILOG_BEGINS): Add unwind-directives.
399 2003-11-19 David Mosberger <davidm@hpl.hp.com>
401 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: New file.
403 2003-12-10 Andreas Jaeger <aj@suse.de>
404 Ruediger Oertel <ro@suse.de>
406 * sysdeps/alpha/elf/pt-initfini.c (__asm__): Remove extra .prologue.
408 2003-11-30 Andreas Jaeger <aj@suse.de>
410 * Makefile (CFLAGS-pt-initfini.s): Add $(fno_unit_at_a_time).
411 * sysdeps/unix/sysv/linux/x86_64/Makefile (CFLAGS-pt-initfini.s):
414 2003-11-04 Jakub Jelinek <jakub@redhat.com>
416 * signals.c (__pthread_sigaction): Set __sighandler[sig].old before
417 __libc_sigaction if it has been one of the special values before.
419 2003-10-06 Carlos O'Donell <carlos@baldric.uwo.ca>
421 * pthread.c (__pthread_self_stack): _STACK_GROWS_UP case added.
422 (__pthread_find_self): Likewise.
423 * manager.c (thread_segment): _STACK_GROWS_UP case added.
425 2003-10-10 Carlos O'Donell <carlos@baldric.uwo.ca>
427 * linuxthreads/sysdeps/unix/sysv/linux/hppa/malloc-machine.h: New file.
429 2003-10-10 Carlos O'Donell <carlos@baldric.uwo.ca>
431 * sysdeps/unix/sysv/linux/hppa/sysdep-cancel.h: New file.
433 2003-10-07 Jakub Jelinek <jakub@redhat.com>
435 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Backout 2003-10-02
437 (SAVE_OLDTYPE_0): Fix a typo.
439 2003-10-02 Ulrich Drepper <drepper@redhat.com>
441 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (DOCARGS_1): Use
444 2003-10-02 Jakub Jelinek <jakub@redhat.com>
446 * Makefile (tests): Add tst-cancel8.
447 * tst-cancel8.c: New test.
449 2003-10-02 Ulrich Drepper <drepper@redhat.com>
451 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Fix saving and
452 restoring of the old cancellation type.
454 2003-09-10 Chris Demetriou <cgd@broadcom.com>
456 * sysdeps/unix/sysv/linux/mips/mips64/sysdep-cancel.h: New file.
458 2003-09-30 Jakub Jelinek <jakub@redhat.com>
460 * sysdeps/pthread/malloc-machine.h [!__libc_maybe_call2] (mutex_init,
461 mutex_lock, mutex_trylock, mutex_unlock): Remove.
463 2003-09-27 Wolfram Gloger <wg@malloc.de>
465 * sysdeps/pthread/malloc-machine.h: New file.
467 2003-09-18 H.J. Lu <hongjiu.lu@intel.com>
469 * attr.c (__pthread_attr_init_2_1): Double __guardsize size
470 if NEED_SEPARATE_REGISTER_STACK is defined.
472 2003-09-22 Philip Blundell <philb@gnu.org>
474 * forward.c: Add _pthread_cleanup_push, _pthread_cleanup_pop.
475 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
477 * pthread.c (__pthread_elements): Initialise these new elements.
478 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_push): Use
480 (__libc_cleanup_pop): Likewise.
482 2003-09-22 Jakub Jelinek <jakub@redhat.com>
484 * attr.c: Include stdlib.h.
486 2003-09-18 Jakub Jelinek <jakub@redhat.com>
488 * sysdeps/pthread/pthread.h (pthread_getattr_np): Clarify usage.
490 * tst-attr1.c: New test.
491 * Makefile (tests): Add tst-attr1.
493 2003-09-17 Philip Blundell <philb@gnu.org>
495 * sysdeps/unix/sysv/linux/arm/vfork.S: Branch to fork if
496 libpthread is loaded. Elide backwards compatibility code when not
499 2003-09-17 Jakub Jelinek <jakub@redhat.com>
501 * descr.h (manager_thread): Rename to...
502 (__pthread_manager_threadp): ... this.
503 * pthread.c (manager_thread): Define to __pthread_manager_threadp.
504 (__pthread_manager_threadp): New variable.
505 * internals.h (__manager_thread): Define to
506 __pthread_manager_threadp if USE_TLS.
508 2003-09-15 Jakub Jelinek <jakub@redhat.com>
510 * sysdeps/i386/Makefile (CFLAGS-cancel.c, CFLAGS-manager.c,
511 CFLAGS-pthread.c, CFLAGS-sighandler.c): Add
512 -mpreferred-stack-boundary=4.
514 2003-09-16 Ulrich Drepper <drepper@redhat.com>
516 * attr.c (pthread_getattr_np): Correctly fill in the stack-related
517 values for the initial thread.
519 2003-09-17 Jakub Jelinek <jakub@redhat.com>
521 * pthread.c (manager_thread): Remove static, add attribute_hidden.
522 (thread_self_stack): Rename to...
523 (__pthread_self_stack): ... this. Remove static.
524 (pthread_handle_sigcancel): Use check_thread_self ().
525 (pthread_handle_sigrestart): Likewise.
526 * sighandler.c (__pthread_sighandler, __pthread_sighandler_rt):
528 * descr.h (manager_thread): Declare.
529 * internals.h (__pthread_self_stack): New prototype.
530 (__manager_thread): Define.
531 (check_thread_self): New function.
533 2003-09-15 Jakub Jelinek <jakub@redhat.com>
535 * Makefile (CFLAGS-mutex.c): Add $(uses-callbacks).
536 (CFLAGS-sighandler.c): Change $(exceptions) into $(uses-callbacks).
538 2003-09-12 Jakub Jelinek <jakub@redhat.com>
540 * sysdeps/unix/sysv/linux/s390/bits/typesizes.h: New.
541 (__SSIZE_T_TYPE): Define to __SWORD_TYPE for gcc 2.95.x and
542 __SLONGWORD_TYPE otherwise.
544 2003-09-11 Steven Munroe <sjmunroe@us.ibm.com>
546 * sysdeps/powerpc/powerpc64/pt-machine.h [MEMORY_BARRIER]: Use lwsync.
547 [READ_MEMORY_BARRIER]: Define.
548 [WRITE_MEMORY_BARRIER]: Define.
550 2003-09-10 Jakub Jelinek <jakub@redhat.com>
552 * sysdeps/pthread/pthread-functions.h (struct pthread_functions): Move
553 ptr___pthread_cond_timedwait to the end of the structure to avoid
554 breaking Wine unnecessarily.
556 2003-09-08 Jakub Jelinek <jakub@redhat.com>
558 * sysdeps/unix/sysv/linux/s390/bits/typesizes.h: Remove.
560 2003-09-02 Jakub Jelinek <jakub@redhat.com>
562 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: New file.
563 * sysdeps/unix/sysv/linux/alpha/Versions: New file.
564 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: New file.
565 * sysdeps/unix/sysv/linux/ia64/Versions: New file.
566 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: New file.
567 * sysdeps/unix/sysv/linux/sparc/Versions: New file.
568 * attr.c (__old_pthread_attr_setstacksize,
569 __old_pthread_attr_setstack): New functions.
570 (pthread_attr_setstacksize): If PTHREAD_STACK_MIN != 16384, export
571 as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.1.
572 (pthread_attr_setstack): If PTHREAD_STACK_MIN != 16384, export
573 as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.2.
574 * tststack.c: Include limits.h and sys/param.h.
575 (main): Set size to MAX (70 * 1024, PTHREAD_STACK_MIN).
577 * barrier.c (__pthread_barrierattr_getpshared): Always
578 return PTHREAD_PROCESS_PRIVATE.
579 (pthread_barrierattr_setpshared): Return EINVAL if pshared
580 is neither PTHREAD_PROCESS_PRIVATE nor PTHREAD_PROCESS_SHARED.
582 2003-09-02 Ulrich Drepper <drepper@redhat.com>
584 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
585 (DL_SYSINFO_IMPLEMENTATION): Add CFI and make sure the code ends
588 * barrier.c (pthread_barrierattr_setpshared): We don't handle
589 inter-process barriers.
591 2003-09-01 Jakub Jelinek <jakub@redhat.com>
593 * Makefile (tests): Add tst-tls1.
594 (module-names): Add tst-tls1mod{,a,b,c,d,e,f}.
595 ($(objpfx)tst-tls1mod{,a,b,c,d,e,f}.so-no-z-defs): Set to yes.
596 ($(objpfx)tst-tls1): New.
597 ($(objpfx)tst-tls2.out): Likewise.
598 (tests): Depend on $(objpfx)tst-tls2.out.
599 * tst-tls1.c: New test.
601 * tst-tls1mod.c: New.
602 * tst-tls1moda.c: New.
603 * tst-tls1modb.c: New.
604 * tst-tls1modc.c: New.
605 * tst-tls1modd.c: New.
606 * tst-tls1mode.c: New.
607 * tst-tls1modf.c: New.
608 * tst-tls2.sh: New test.
610 * internals.h (__pthread_cond_timedwait): New prototype.
611 * sysdeps/pthread/pthread-functions.h (struct pthread_functions): Add
612 ptr___pthread_cond_timedwait.
613 * pthread.c (__pthread_functions): Initialize them.
614 * forward.c (pthread_cond_timedwait@GLIBC_2.0,
615 pthread_cond_timedwait@@GLIBC_2.3.2): New forwards.
616 * Versions (libc): Export pthread_cond_timedwait@GLIBC_2.0,
617 pthread_cond_timedwait@@GLIBC_2.3.2.
619 2003-08-27 Ulrich Drepper <drepper@redhat.com>
621 * sysdeps/pthread/pthread.h: Don't mark pthread_exit,
622 pthread_join, pthread_cond_wait, and pthread_cond_timedwait with
623 __THROW to match NPTL.
625 2003-08-13 Ulrich Drepper <drepper@redhat.com>
627 * sysdeps/pthread/Makefile [subdir=rt] (CPPFLAGS): Add
628 -DBROKEN_THREAD_SIGNALS.
630 2003-08-11 Steven Munroe <sjmunroe@us.ibm.com>
632 * manager.c (pthread_start_thread) [!(USE_TLS && HAVE___THREAD)]:
633 Correct spelling of per thread resolver state.
635 2003-08-07 Jakub Jelinek <jakub@redhat.com>
637 * sysdeps/pthread/bits/libc-lock.h [_LIBC && SHARED]
638 (__rtld_lock_default_lock_recursive,
639 __rtld_lock_default_unlock_recursive): Define.
640 [_LIBC && SHARED] (__rtld_lock_lock_recursive,
641 __rtld_lock_unlock_recursive): Define using
642 GL(_dl_rtld_*lock_recursive).
643 * pthread.c (pthread_initialize): Initialize _dl_rtld_lock_recursive
644 and _dl_rtld_unlock_recursive. Lock GL(_dl_load_lock) the same
645 number of times as GL(_dl_load_lock) using non-mt implementation was
648 2003-07-31 Jakub Jelinek <jakub@redhat.com>
650 * sysdeps/pthread/bits/typesizes.h (__SSIZE_T_TYPE): Define.
651 * sysdeps/unix/sysv/linux/alpha/bits/typesizes.h (__SSIZE_T_TYPE):
653 * sysdeps/unix/sysv/linux/sparc/bits/typesizes.h (__SSIZE_T_TYPE):
655 * sysdeps/unix/sysv/linux/s390/bits/typesizes.h: New file.
657 * sysdeps/pthread/pthread.h (pthread_attr_setstackaddr,
658 pthread_attr_setstacksize): Change PTHREAD_STACK_SIZE to
659 PTHREAD_STACK_MIN in comments.
661 * sysdeps/alpha/pt-machine.h (PT_EI): Add
662 __attribute__((always_inline)).
663 * sysdeps/arm/pt-machine.h (PT_EI): Likewise.
664 * sysdeps/cris/pt-machine.h (PT_EI): Likewise.
665 * sysdeps/hppa/pt-machine.h (PT_EI): Likewise.
666 * sysdeps/i386/i686/pt-machine.h (PT_EI): Likewise.
667 * sysdeps/i386/pt-machine.h (PT_EI): Likewise.
668 * sysdeps/ia64/pt-machine.h (PT_EI): Likewise.
669 * sysdeps/m68k/pt-machine.h (PT_EI): Likewise.
670 * sysdeps/mips/pt-machine.h (PT_EI): Likewise.
671 * sysdeps/powerpc/powerpc32/pt-machine.h (PT_EI): Likewise.
672 * sysdeps/powerpc/powerpc64/pt-machine.h (PT_EI): Likewise.
673 * sysdeps/s390/s390-32/pt-machine.h (PT_EI): Likewise.
674 * sysdeps/s390/s390-64/pt-machine.h (PT_EI): Likewise.
675 * sysdeps/sh/pt-machine.h (PT_EI): Likewise.
676 * sysdeps/sparc/sparc32/pt-machine.h (PT_EI): Likewise.
677 * sysdeps/sparc/sparc64/pt-machine.h (PT_EI): Likewise.
678 * sysdeps/x86_64/pt-machine.h (PT_EI): Likewise.
679 * spinlock.h (__pthread_set_own_extricate_if): Likewise.
680 * sysdeps/ia64/tls.h (TLS_INIT_TP): Cast tcbp to __typeof
682 * Examples/ex13.c (main): Change res type to void * to avoid
684 * tst-cancel.c (cleanup, inner, tf1, tf2, tf3): Comment out.
686 2003-07-30 Jakub Jelinek <jakub@redhat.com>
688 * pthread.c (init_one_static_tls, __pthread_init_static_tls): New
690 (pthread_initialize): Initialize GL(dl_init_static_tls).
692 2003-06-19 Daniel Jacobowitz <drow@mvista.com>
694 * sysdeps/pthread/timer_create.c (timer_create): Call timer_delref
695 before __timer_dealloc.
696 * sysdeps/pthread/timer_routines.c (__timer_thread_find_matching):
697 Don't call list_unlink.
699 2003-07-29 Roland McGrath <roland@redhat.com>
701 * Makefile [$(build-shared) = yes] (tests): Depend on $(test-modules).
703 2003-07-25 Roland McGrath <roland@redhat.com>
705 * manager.c (pthread_start_thread): Fix typo in last change.
707 2003-07-14 Guido Guenther <agx@sigxcpu.org>
709 * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h: Add IS_IN_librt,
710 use L() for local labels.
712 2003-07-22 Jakub Jelinek <jakub@redhat.com>
714 * descr.h (struct _pthread_descr_struct): Provide p_res member
715 even if USE_TLS && HAVE___THREAD.
716 * sysdeps/pthread/res-state.c (__res_state): Return __resp
718 * manager.c: Include resolv.h.
719 (pthread_start_thread): Initialize __resp.
720 * libc-tls-loc.c (__res_state): Return __resp.
721 * Makefile (tests): Add tst-_res1.
722 (modules-names, extra-objs, test-extras, test-modules): Add support
724 ($(objpfx)tst-_res1mod2.so): Depend on $(objpfx)tst-_res1mod1.so.
725 ($(objpfx)tst-_res1): Depend on $(objpfx)tst-_res1mod2.so and
727 * tst-_res1.c: New test.
728 * tst-_res1mod1.c: New test.
729 * tst-_res1mod2.c: New test.
731 2003-07-20 Ulrich Drepper <drepper@redhat.com>
733 * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_push and
736 * tst-cancel-wrappers.sh: lseek and llseek are no cancellation points.
738 2003-07-14 Ulrich Drepper <drepper@redhat.com>
740 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Fix typo
741 in test for compilation in libc.
743 2003-07-04 Jakub Jelinek <jakub@redhat.com>
745 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO): Use
746 different symbol for the cancellation syscall wrapper and
747 non-cancellation syscall wrapper.
748 (PSEUDO_END): Define.
750 2003-07-05 Richard Henderson <rth@redhat.com>
752 * sysdeps/alpha/elf/pt-initfini.c: Avoid .ent/.end.
754 2003-06-20 Kaz Kojima <kkojima@rr.iij4u.or.jp>
756 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Support cancellation
759 2003-06-21 Andreas Schwab <schwab@suse.de>
761 * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h: Support cancellation
764 2003-06-20 Richard Henderson <rth@redhat.com>
766 * sysdeps/unix/sysv/linux/alpha/Makefile (libpthread-routines):
767 Remove ptw-osf_sigprocmask.
769 2003-06-18 Jakub Jelinek <jakub@redhat.com>
771 * internals.h (__librt_multiple_threads, __librt_enable_asynccancel,
772 __librt_disable_asynccancel): Declare.
773 (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET, LIBC_CANCEL_HANDLED): Define
775 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Support cancellation
777 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
778 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
779 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
780 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
781 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
782 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
783 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
784 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
785 * sysdeps/x86_64/tcb-offsets.sym: New file.
786 * sysdeps/x86_64/Makefile: New file.
787 * sysdeps/x86_64/tls.h (tcbhead_t): Add multiple_threads.
788 * Versions (libc): Export __librt_enable_asynccancel,
789 __librt_disable_asynccancel and __librt_multiple_threads as
791 * libc-cancellation.c (__librt_multiple_threads,
792 __librt_enable_asynccancel, __librt_disable_asynccancel): New aliases.
794 2003-06-12 Steven Munroe <sjmunroe@us.ibm.com>
796 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
797 (SINGLE_THREAD_P): Replace @ got notation with @toc.
799 2003-06-11 Ulrich Drepper <drepper@redhat.com>
801 * sysdeps/powerpc/pspinlock.c (__pthread_spin_init): Fix
802 initializer [PR libc/5052].
804 2003-06-09 Andreas Schwab <schwab@suse.de>
806 * Makefile: Move inclusion of ../Rules down after extra-objs is
809 2003-06-06 Ulrich Drepper <drepper@redhat.com>
811 * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h: New sequences for
812 5+ arg syscalls only needed for PIC.
813 Patch by Ralph Siemsen <ralphs@netwinder.org>.
815 2003-06-05 Richard Henderson <rth@redhat.com>
817 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (PSEUDO): Use
818 and require CFI assembler directives.
819 * sysdeps/unix/sysv/linux/alpha/vfork.S: Likewise.
821 2003-05-30 Andreas Jaeger <aj@suse.de>
823 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h
824 (SAVESTK_0): Add CFI directives.
825 (SAVESTK_3): Likewise.
826 (SAVESTK_5): Likewise.
827 (RESTSTK_0): Likewise.
828 (RESTSTK_3): Likewise.
829 (RESTSTK_5): Likewise.
831 2003-05-05 Ulrich Drepper <drepper@redhat.com>
833 * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Add \n to error
836 2003-05-04 Roland McGrath <roland@redhat.com>
838 * Makefile ($(objpfx)../libc.so): New target.
840 2003-04-26 Ulrich Drepper <drepper@redhat.com>
842 * pthread.c (__pthread_initialize_manager): Remove one last
843 p_multiple_threads call.
845 2003-04-22 Jakub Jelinek <jakub@redhat.com>
847 * pthread.c (__pthread_initialize_manager): Subtract
848 TLS_PRE_TCB_SIZE bytes from tcbp to get to descr.
849 * manager.c (pthread_handle_create): Subtract or add TLS_PRE_TCB_SIZE
850 instead of sizeof (pthread_descr).
851 (pthread_free): Add TLS_PRE_TCB_SIZE instead of sizeof (pthread_descr).
852 * sysdeps/powerpc/tls.h (TLS_INIT_TCB_SIZE, TLS_TCB_SIZE): Define to 0.
853 (TLS_INIT_TCB_ALIGN, TLS_TCB_ALIGN): Define to alignment of
855 (TLS_PRE_TCB_SIZE): Increase to cover tcbhead_t preceeded by pad
857 (INSTALL_DTV, GET_DTV, THREAD_DTV): tcbhead_t is immediately before
859 (TLS_INIT_TP, THREAD_SELF, INIT_THREAD_SELF): Don't add TLS_TCB_SIZE
861 (NO_TLS_OFFSET): Define.
863 2003-04-22 Roland McGrath <roland@redhat.com>
865 * Makeconfig (shared-thread-library): Reverse link order to work
868 2003-04-20 Ulrich Drepper <drepper@redhat.com>
870 * sysdeps/i386/useldt.h (DO_SET_THREAD_AREA): Make sure the
871 compiler knows we use the ldt_entry variable and that the syscall
874 * internals.h: Split pthread_functions definition into...
875 * sysdeps/pthread/pthread-functions.h: ...new file.
877 * sysdeps/i386/useldt.h: Include <sysdep.h>.
879 2003-04-13 Jakub Jelinek <jakub@redhat.com>
881 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Rename macros to
882 match changes in NPTL sysdep-cancel.h.
884 2003-04-11 Roland McGrath <roland@redhat.com>
886 * Makefile (multidir): Don't set the variable here with $(shell ...).
887 ($(objpfx)multidir.mk): New target, generated makefile; include that.
888 (generated): Append it.
890 2003-04-10 Jakub Jelinek <jakub@redhat.com>
892 * Makefile (multidir, crti-objs, crtn-objs): New variables.
893 (generated-dirs): Add pathname component of multidir.
894 (omit-deps, extra-objs): Include $(multidir)/crt? as well.
895 ($(objpfx)libpthread.so): Depend on $(multidir)/crt?.o as well.
896 ($(objpfx)$(multidir), $(objpfx)$(multidir)/crti.o,
897 $(objpfx)$(multidir)/crtn.o): New.
898 * sysdeps/unix/sysv/linux/sparc/Makefile: Removed.
899 * sysdeps/unix/sysv/linux/x86_64/Makefile (LDFLAGS-pthread.so,
900 before-compile, generated): Don't generate and use specs.
901 ($(objpfx)specs): Remove.
903 2003-04-11 Martin Schwidefsky <schwidefsky@de.ibm.com>
905 * sysdeps/s390/pspinlock.c (__pthread_spin_unlock): Fix asm contraints.
907 2003-04-03 Ulrich Drepper <drepper@redhat.com>
909 * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h (PSEUDO): Add
910 missing ; after ENTRY use [PR libc/4997].
912 2003-04-03 Jakub Jelinek <jakub@redhat.com>
914 * pthread.c (pthread_initialize): Unblock __pthread_sig_cancel
915 in case the parent blocked it.
917 2003-04-02 Jakub Jelinek <jakub@redhat.com>
919 * Makefile (libpthread-routines): Add pthread_atfork.
920 (libpthread-static-only-routines): Add pthread_atfork.
922 2003-04-01 Jakub Jelinek <jakub@redhat.com>
924 * pthread.c (__pthread_wait_for_restart_signal): Use
925 __pthread_sigsuspend instead of sigsuspend.
926 * internals.h (__pthread_sigsuspend): New prototype.
927 * Makefile (libpthread-routines): Add pt-sigsuspend.
928 (tests): Add tst-cancel7.
929 * sysdeps/unix/sysv/linux/pt-sigsuspend.c: New file.
930 * sysdeps/unix/sysv/linux/alpha/pt-sigsuspend.S: New file.
931 * sysdeps/unix/sysv/linux/ia64/pt-sigsuspend.c: New file.
932 * sysdeps/unix/sysv/linux/s390/s390-64/pt-sigsuspend.c: New file.
933 * sysdeps/unix/sysv/linux/sparc/sparc64/pt-sigsuspend.c: New file.
934 * sysdeps/unix/sysv/linux/x86_64/pt-sigsuspend.c: New file.
935 * tst-cancel7.c: New test.
937 2003-03-31 Alexandre Oliva <aoliva@redhat.com>
939 * alloca_cutoff.c: Include internals.h.
940 * sysdeps/pthread/errno-loc.c: Include linuxthreads/internals.h.
941 * sysdeps/pthread/herrno-loc.c: Likewise.
942 * sysdeps/pthread/res-state.c: Likewise.
944 2003-03-25 Ulrich Drepper <drepper@redhat.com>
946 * sysdeps/pthread/bits/typesizes.h: New file.
947 * sysdeps/unix/sysv/linux/alpha/bits/typesizes.h: New file.
948 * sysdeps/unix/sysv/linux/sparc/bits/typesizes.h: New file.
950 2003-03-24 Daniel Jacobowitz <drow@mvista.com>
952 * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h
953 (DOARGS_5, DOARGS_6, DOARGS_7): Rewritten.
955 2003-03-22 Jakub Jelinek <jakub@redhat.com>
957 * sysdeps/unix/sysv/linux/fork.c (__fork): Add libc_hidden_def.
959 2003-03-21 Daniel Jacobowitz <drow@mvista.com>
961 * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h
962 (SINGLE_THREAD_P_PIC): Use "reg" instead of "lr".
964 2003-03-21 Jakub Jelinek <jakub@redhat.com>
966 * sysdeps/i386/tls.h [__ASSUME_SET_THREAD_AREA_SYSCALL]
967 (TLS_SETUP_GS_SEGMENT): Fix a typo.
969 2003-03-19 Ulrich Drepper <drepper@redhat.com>
971 * sysdeps/pthread/Makefile: Fix cut&paste error.
973 2003-03-18 Roland McGrath <roland@redhat.com>
975 * Versions (libpthread: GLIBC_2.2): Remove
976 pthread_barrierattr_getpshared, never really existed.
977 (libpthread: GLIBC_2.0): Move __pthread_initialize to ...
978 (libpthread: GLIBC_PRIVATE): ... here.
980 2003-03-14 Jakub Jelinek <jakub@redhat.com>
982 * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: New file.
983 * sysdeps/unix/sysv/linux/sparc/Makefile ($(objpfx)specs): Use full
986 2003-03-14 Alexandre Oliva <aoliva@redhat.com>
988 * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Don't .set
990 * sysdeps/mips/pt-machine.h (__compare_and_swap): Likewise.
991 Handle 64-bit longs on n64.
993 2003-03-07 Jakub Jelinek <jakub@redhat.com>
995 * sysdeps/ia64/pspinlock.c (__pthread_spin_lock,
996 __pthread_spin_trylock): Rewritten.
998 2003-03-06 Ulrich Drepper <drepper@redhat.com>
1000 * tst-cancel4.c (tf_sleep): Lower sleep time a bit to not upset
1003 2003-03-02 Ulrich Drepper <drepper@redhat.com>
1005 * sysdeps/pthread/timer_create.c (timer_create): Return correct
1006 error for CPU clocks.
1008 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1009 _POSIX_MONOTONIC_CLOCK.
1010 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
1012 2003-03-01 Roland McGrath <roland@redhat.com>
1014 * sysdeps/powerpc/powerpc64/pt-machine.h
1015 (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM, THREAD_SETMEM_NC):
1017 * sysdeps/powerpc/tls.h: Don't define those here.
1019 * sysdeps/powerpc/tls.h [! USE_TLS && !__powerpc64__]: Define
1020 tcbhead_t with multiple_threads member.
1021 [USE_TLS] (tcbhead_t): Define minimal one-word version.
1022 [USE_TLS && !__powerpc64__] (TLS_MULTIPLE_THREADS_IN_TCB): Define.
1023 * sysdeps/powerpc/tcb-offsets.sym [USE_TLS]: Use tls.h macros to
1024 derive thread register offset of p_multiple_threads member.
1026 * descr.h (struct _pthread_descr_struct) [!USE_TLS || !TLS_DTV_AT_TP]:
1027 Conditionalize p_header member on this.
1028 [TLS_MULTIPLE_THREADS_IN_TCB]: Add p_multiple_threads alternatively.
1029 * sysdeps/ia64/tls.h [USE_TLS] (TLS_MULTIPLE_THREADS_IN_TCB): Define.
1030 * sysdeps/sh/tls.h: Likewise.
1031 * sysdeps/ia64/tcb-offsets.sym [USE_TLS]: Use p_multiple_threads.
1032 * sysdeps/sh/tcb-offsets.sym: Likewise.
1033 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
1034 (SINGLE_THREAD_P): Likewise.
1035 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1036 (SINGLE_THREAD_P): Likewise.
1037 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
1038 (SINGLE_THREAD_P): Likewise.
1039 * pthread.c (__pthread_initialize_manager): Likewise.
1040 * manager.c (pthread_handle_create): Likewise.
1042 * sysdeps/powerpc/tls.h [HAVE_TLS_SUPPORT]: Define USE_TLS and all
1045 2003-01-31 Steven Munroe <sjmunroe@us.ibm.com>
1047 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S [SHARED]:
1048 Conditionalize .toc section magic on this.
1050 2003-02-21 Roland McGrath <roland@redhat.com>
1052 * cancel.c (__pthread_perform_cleanup): Call __libc_thread_freeres
1053 instead of __rpc_thread_destroy.
1055 2003-02-21 Jakub Jelinek <jakub@redhat.com>
1057 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Call
1058 __fork instead of branching to it if BROKEN_SPARC_WDISP22.
1059 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h (PSEUDO):
1061 * sysdeps/unix/sysv/linux/sparc/Makefile (specs): Add ./ prefix
1062 to crti.o and crtn.o.
1063 * sysdeps/unix/sysv/linux/x86_64/Makefile (specs): Likewise.
1065 2003-02-21 Roland McGrath <roland@redhat.com>
1067 * Makefile (install-lib-ldscripts): New variable.
1069 2003-02-20 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
1071 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: Avoid short
1072 interprocedure branches.
1074 2003-02-19 Ulrich Drepper <drepper@redhat.com>
1076 * specific.c (pthread_key_delete_helper): Don't use GETMEM, we
1077 need the target thread's lock.
1079 2003-02-17 Ulrich Drepper <drepper@redhat.com>
1081 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define TTY_NAME_MAX
1084 2003-02-17 Kevin B. Hendricks <kevin.hendricks@sympatico.ca>
1085 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
1087 * sysdeps/powerpc/Makefile: Handle tcb-offsets.sym.
1088 * sysdeps/powerpc/tcb-offsets.sym: New file.
1089 * sysdeps/powerpc/tls.h: New file.
1090 * sysdeps/powerpc/powerpc32/pt-machine.h (FLOATING_STACKS): Define.
1091 (ARCH_STACK_MAX_SIZE): Define.
1092 (THREAD_SELF): Define.
1093 (INIT_THREAD_SELF): Define.
1094 (THREAD_GETMEM): Define.
1095 (THREAD_GETMEM_NC): Define.
1096 (THREAD_SETMEM): Define.
1097 (THREAD_SETMEM_NC): Define.
1098 (__thread_self): Declare.
1099 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Adjust
1100 for thread register.
1102 2003-02-14 Steven Munroe <sjmunroe@us.ibm.com>
1104 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S (__vfork):
1105 Check pthread_create existance, not __pthread_fork.
1107 2003-02-12 Ulrich Drepper <drepper@redhat.com>
1109 * sysdeps/pthread/Makefile: Define CFLAGS-confstr.c.
1111 2003-02-10 Jakub Jelinek <jakub@redhat.com>
1113 * sysdeps/unix/sysv/linux/alpha/vfork.S (__vfork): Check
1114 pthread_create existance, not __pthread_fork.
1115 * sysdeps/unix/sysv/linux/i386/vfork.S (__vfork): Likewise.
1116 * sysdeps/unix/sysv/linux/ia64/vfork.S (__vfork): Likewise.
1117 * sysdeps/unix/sysv/linux/m68k/vfork.S (__vfork): Likewise.
1118 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
1120 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Likewise.
1121 * sysdeps/unix/sysv/linux/x86_64/vfork.S (__vfork): Likewise.
1122 * sysdeps/unix/sysv/linux/sh/vfork.S (__vfork): Likewise.
1123 Add .weak pthread_create.
1124 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Fix a typo.
1125 Check pthread_create existance, not __pthread_fork.
1126 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
1127 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S (__vfork): Branch to
1128 __fork whenever libpthread.so is loaded.
1130 2003-02-09 Andreas Jaeger <aj@suse.de>
1132 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h:
1133 Rework: %r9 is destroyed by functions so don't use it as
1134 temporary, align stack correctly, fix parameter for CDISABLE.
1136 2003-02-07 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1138 * sysdeps/sh/Makefile: New file.
1139 * sysdeps/sh/tcb-offsets.sym: Likewise.
1140 * sysdeps/sh/tls.h: Don't include sysdep.h. Move include
1141 of linuxthreads/descr.h after the definition of THREAD_SELF.
1142 (tcbhead_t): Use IA64 type tcbhead_t for TLS case.
1143 (TLS_TCB_SIZE): Set size of tcbhead_t.
1144 (TLS_PRE_TCB_SIZE): Define.
1145 (INSTALL_NEW_DTV): Set dtv of tcbhead_t structure instead of
1146 a member of thread structure.
1147 (THREAD_DTV): Likewise.
1148 (TLS_INIT_TP_EXPENSIVE): Remove.
1149 (TLS_INIT_TP): Set gbr register only.
1151 (INIT_THREAD_SELF): Likewise.
1152 (NONTLS_INIT_TP): New.
1153 * sysdeps/unix/sysv/linux/sh/pt-initfini.c (__fpscr_values):
1155 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (PSEUDO): Add
1156 SYSCALL_INST_PAD macro after DO_CALL.
1157 (SINGLE_THREAD_P): Fix non-PIC and TLS case so to read the
1159 * sysdeps/unix/sysv/linux/sh/vfork.S (__vfork): Branch to __fork
1160 whenever libpthread.so is loaded.
1162 2003-02-08 Andreas Schwab <schwab@suse.de>
1164 * sysdeps/unix/sysv/linux/m68k/vfork.S: Branch to __fork whenever
1165 libpthread.so is loaded.
1167 2003-02-07 Ulrich Drepper <drepper@redhat.com>
1169 * sysdeps/unix/sysv/linux/i386/vfork.S: Make sure
1170 __ASSUME_VFORK_SYSCALL is not defined if the kernel headers have
1171 no __NR_vfork definition.
1173 2003-02-07 Jakub Jelinek <jakub@redhat.com>
1175 * tst-popen2.c: New test.
1176 * Makefile (tests): Add tst-popen2.
1177 * sysdeps/unix/sysv/linux/alpha/vfork.S (__vfork): Branch to __fork
1178 whenever libpthread.so is loaded.
1179 * sysdeps/unix/sysv/linux/i386/vfork.S (__vfork): Likewise.
1180 * sysdeps/unix/sysv/linux/ia64/vfork.S (__vfork): Likewise.
1181 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Likewise.
1182 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
1184 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Likewise.
1185 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
1186 * sysdeps/unix/sysv/linux/x86_64/vfork.S (__vfork): Likewise.
1188 2003-02-05 Ulrich Drepper <drepper@redhat.com>
1190 * sysdeps/pthread/bits/libc-lock.h (__libc_once): Set control
1191 variable for non-libpthread case to the same value the
1192 pthread_once function would use.
1194 2003-02-03 Jakub Jelinek <jakub@redhat.com>
1196 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): If
1197 BROKEN_SPARC_WDISP22, handle SHARED the same way as non-SHARED.
1199 2003-02-04 Andreas Jaeger <aj@suse.de>
1201 * sysdeps/unix/sysv/linux/hppa/pt-initfini.c: Do not use
1204 2003-01-30 Jakub Jelinek <jakub@redhat.com>
1206 * sysdeps/s390/tls.h (TLS_INIT_TP): Return NULL, not 0.
1208 2003-01-30 Jakub Jelinek <jakub@redhat.com>
1210 * sysdeps/alpha/tls.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1211 THREAD_SETMEM, THREAD_SETMEM_NC): Avoid warnings about unused self
1213 * sysdeps/ia64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1214 THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1215 * sysdeps/s390/s390-32/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1216 THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1217 * sysdeps/s390/s390-64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1218 THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1219 * sysdeps/sh/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1220 THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1221 * sysdeps/sparc/sparc32/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1222 THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1223 * sysdeps/sparc/sparc64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1224 THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1226 2003-01-27 Martin Schwidefsky <schwidefsky@de.ibm.com>
1228 * sysdeps/s390/s390-32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
1229 Define TLS versions.
1230 * sysdeps/s390/s390-64/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
1232 * sysdeps/s390/tls.h [HAVE_TLS_SUPPORT] (USE_TLS, TLS_INIT_TCB_SIZE,
1233 TLS_INIT_TCB_ALIGN, TLS_TCB_SIZE, TLS_TCB_ALIGN, TLS_TCB_AT_TP,
1234 INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV, TLS_INIT_TP, THREAD_DTV):
1236 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO): Use
1237 branch with 32 bit offset.
1238 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S: Likewise.
1240 2003-01-24 Jakub Jelinek <jakub@redhat.com>
1242 * sysdeps/sparc/sparc32/pt-machine.h (__thread_self): Change to %g7,
1243 as required by TLS ABI.
1244 * sysdeps/sparc/sparc64/pt-machine.h (__thread_self): Likewise.
1245 * sysdeps/sparc/tls.h [HAVE_TLS_SUPPORT] (USE_TLS, TLS_INIT_TCB_SIZE,
1246 TLS_INIT_TCB_ALIGN, TLS_TCB_SIZE, TLS_TCB_ALIGN, TLS_TCB_AT_TP,
1247 INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV, TLS_INIT_TP, THREAD_DTV):
1249 [HAVE_TLS_SUPPORT]: Include descr.h and sysdep.h.
1250 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Use %g7
1251 instead of %g6 for thread pointer.
1252 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: Likewise.
1253 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
1254 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: Likewise.
1256 2003-01-25 Guido Guenther <agx@sigxcpu.org>
1258 * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h: New file.
1259 * sysdeps/unix/sysv/linux/mips/Makefile: New file.
1261 2003-01-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
1263 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S: Avoid non pc relative
1264 reference to __fork.
1266 2003-01-17 Richard Henderson <rth@redhat.com>
1268 * sysdeps/alpha/tls.h (tcbhead_t): Clarify second member.
1269 (TLS_TCB_SIZE, TLS_TCB_ALIGN): Set for tcbhead_t.
1270 (TLS_PRE_TCB_SIZE): New.
1271 (TLS_INIT_TP, THREAD_SELF, INIT_THREAD_SELF): Update for
1272 new ia64-style thread pointer layout.
1273 (THREAD_GETMEM, THREAD_GETMEM_NC): New.
1274 (THREAD_SETMEM, THREAD_SETMEM_NC): New.
1275 * sysdeps/unix/sysv/linux/alpha/vfork.S: Don't tail-call to __fork
1278 2003-01-15 Jakub Jelinek <jakub@redhat.com>
1280 * sysdeps/ia64/tls.h (tcbhead_t): Use the TLS ABI required layout
1282 (NONTLS_INIT_TP): Revert last change.
1283 * sysdeps/ia64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Define to
1284 offsetof (tcbhead_t, multiple_threads) if USE_TLS not defined.
1286 2003-01-16 Jakub Jelinek <jakub@redhat.com>
1288 * pthread.c (_pthread_initialize_minimal): Use
1289 GL(dl_tls_dtv_slotinfo_list) != NULL to check whether TLS has
1290 been already initialized.
1292 2003-01-16 Jakub Jelinek <jakub@redhat.com>
1294 * sysdeps/i386/tls.h (INIT_SYSINFO): Initialize head->sysinfo even
1297 2003-01-15 Jakub Jelinek <jakub@redhat.com>
1299 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init,
1300 __libc_lock_init_recursive): Initialize fields directly.
1302 2003-01-15 Jakub Jelinek <jakub@redhat.com>
1304 * sysdeps/unix/sysv/linux/alpha/vfork.S (__vfork): Allow
1305 __fork to be far away from __vfork ifndef SHARED.
1306 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
1308 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Likewise.
1309 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
1310 Add a missing instruction.
1311 * sysdeps/unix/sysv/linux/arm/vfork.S (__vfork): Conditionally
1312 branch to __fork even if __NR_vfork is not defined.
1314 2003-01-14 Ulrich Drepper <drepper@redhat.com>
1316 * tst-cancel-wrappers.sh: Allow .__*_asynccancel functions names
1319 2003-01-14 Steven Munroe <sjmunroe@us.ibm.com>
1321 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: New file.
1323 2003-01-14 Jakub Jelinek <jakub@redhat.com>
1325 * sysdeps/unix/sysv/linux/ia64/vfork.S (JUMPTARGET): Remove.
1327 2003-01-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
1329 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c: Avoid
1330 unterminated string literals.
1331 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: Likewise.
1333 2003-01-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
1335 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
1336 (PSEUDO): Code reordering. Move CENABLE and CDISABLE literals from
1337 PSEUDO_END to PSEUDO.
1338 (PSEUDO_END): Remove.
1339 (SINGLE_THREAD_P): Save an instruction.
1340 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S (__vfork): Add missing
1341 parameter to SINGLE_THREAD_P call.
1342 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
1345 2003-01-10 Andreas Schwab <schwab@suse.de>
1347 * sysdeps/unix/sysv/linux/m68k/vfork.S: New file.
1349 2003-01-10 Martin Schwidefsky <schwidefsky@de.ibm.com>
1351 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO): Setup
1352 backchain in pseudo_cancel. Minor code improvements.
1353 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
1356 2003-01-10 Martin Schwidefsky <schwidefsky@de.ibm.com>
1358 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S: New file.
1359 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S: New file.
1361 2002-01-12 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
1363 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: New file.
1365 2002-01-09 Richard Henderson <rth@redhat.com>
1367 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Assume only
1368 ret follows pseudo, and thus avoid branch-to-branch in cancel
1369 case. Use SYSCALL_ERROR_LABEL.
1371 2003-01-11 Philip Blundell <philb@gnu.org>
1373 * sysdeps/unix/sysv/linux/arm/vfork.S: New file.
1374 * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h (PSEUDO_RET):
1375 Correctly unstack lr.
1376 (UNDOARGS_5): Fix ordering of pushes and pops.
1377 (SINGLE_THREAD_P_PIC): New.
1378 (SINGLE_THREAD_P_INT): New.
1379 (SINGLE_THREAD_P): Implement in terms of above. Restore lr if it
1381 (PSEUDO): Use SINGLE_THREAD_P_INT.
1383 2003-01-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1385 * sysdeps/unix/sysv/linux/sh/vfork.S: New file.
1387 2003-01-11 Jakub Jelinek <jakub@redhat.com>
1389 * sysdeps/ia64/tls.h (tcbhead_t): Change into dtv_t *, void *.
1390 [HAVE_TLS_SUPPORT] (USE_TLS, TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN,
1391 TLS_TCB_SIZE, TLS_PRE_TCB_SIZE, TLS_TCB_ALIGN, TLS_DTV_AT_TP,
1392 INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV, TLS_INIT_TP, THREAD_SELF,
1393 INIT_THREAD_SELF): Define.
1394 [HAVE_TLS_SUPPORT]: Include descr.h.
1395 (NONTLS_INIT_TP): Point __thread_self at the end of dummy
1396 struct _pthread_descr_struct.
1397 * sysdeps/ia64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1398 THREAD_SETMEM, THREAD_SETMEM_NC): Define using THREAD_SELF,
1400 * sysdeps/ia64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Adjust
1402 * pthread.c (__pthread_initialize_minimal): Use tcbp, not self
1404 (__pthread_initialize_manager): Rename tcb to mgr.
1405 Use tcbp for TCB pointer, if TLS_DTV_AT_TP set mgr to sizeof (struct
1406 _pthread_descr) below tcbp, otherwise to tcbp.
1407 * manager.c (pthread_handle_create): If TLS_DTV_AT_TP, set
1408 new_thread to be below _dl_allocate_tls (). Adjust new_thread back
1409 before freeing. Fix clone arguments if report_events and USE_TLS.
1410 (pthread_free): Adjust th back before freeing.
1412 2003-01-10 Steven Munroe <sjmunroe@us.ibm.com>
1414 * sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile: Moved to ...
1415 * sysdeps/unix/sysv/linux/powerpc/Makefile: ...here.
1416 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: New File.
1418 2003-01-09 Jakub Jelinek <jakub@redhat.com>
1420 * sysdeps/unix/sysv/linux/i386/vfork.S: New file.
1421 * sysdeps/unix/sysv/linux/ia64/vfork.S: New file.
1422 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1423 [__ASSEMBLER__] (SINGLE_THREAD_P): Remove trailing ;;.
1424 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: New file.
1425 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: New file.
1426 * sysdeps/unix/sysv/linux/x86_64/vfork.S: New file.
1427 * sysdeps/unix/sysv/linux/alpha/vfork.S: New file.
1428 * tst-popen.c: New test.
1429 * Makefile (tests): Add tst-popen.
1431 2003-01-06 Jakub Jelinek <jakub@redhat.com>
1433 * sysdeps/unix/sysv/linux/sigwait.c (do_sigwait): Add
1434 INTERNAL_SYSCALL_DECL, add err argument to INTERNAL_SYSCALL* macros.
1436 2003-01-06 Jakub Jelinek <jakub@redhat.com>
1438 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (PSEUDO): Use
1439 PSEUDO_PREPARE_ARGS. Fix branch condition after SINGLE_THREAD_P.
1441 2003-01-06 Philip Blundell <philb@gnu.org>
1443 * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h: New file.
1445 2003-01-06 Jakub Jelinek <jakub@redhat.com>
1447 * internals.h (LIBC_CANCEL_HANDLED): Define.
1448 * sysdeps/unix/sysv/linux/sigwait.c (LIBC_CANCEL_HANDLED): Add.
1449 * signals.c (LIBC_CANCEL_HANDLED): Add.
1450 * pt-system.c (LIBC_CANCEL_HANDLED): Add.
1451 * tst-cancel-wrappers.sh: Remove all exceptions.
1453 * sysdeps/unix/sysv/linux/alpha/Makefile: New file.
1455 2003-01-05 Andreas Schwab <schwab@suse.de>
1457 * sysdeps/m68k/Makefile: New file, use -fPIC for nonshared
1460 * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h (SINGLE_THREAD_P):
1462 (CENABLE): Likewise.
1463 (CDISABLE): Likewise.
1465 2003-01-05 Ulrich Drepper <drepper@redhat.com>
1467 * tst-cancel-wrappers.sh: Invoke gawk not awk since we use GNU awk
1468 features. Reported by Marijn Ros <marijn@mad.scientist.com>.
1470 * Makefile (libc.so-no-z-defs): Define to yes.
1472 2003-01-05 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1474 * sysdeps/sh/tls.h: Include dl-sysdep.h and stdint.h.
1475 (tcbhead_t): Add multiple_threads member.
1476 (TLS_INIT_TP_EXPENSIVE): Define.
1477 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: Don't use multi-line
1478 strings. Remove unused code.
1479 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: New file.
1481 2003-01-04 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
1483 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: New file.
1484 * sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile: New file.
1486 2003-01-04 Jakub Jelinek <jakub@redhat.com>
1488 * internals.h (LIBC_THREAD_GETMEM, LIBC_THREAD_SETMEM): Define
1489 even if NOT_IN_libc is defined.
1491 2003-01-05 Jakub Jelinek <jakub@redhat.com>
1493 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: New file.
1494 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: New file.
1495 * sysdeps/s390/Makefile: New file.
1496 * sysdeps/s390/tcb-offsets.sym: New file.
1497 * sysdeps/s390/tls.h: New file.
1499 2003-01-03 Richard Henderson <rth@redhat.com>
1501 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: New file.
1503 2003-01-03 Andreas Jaeger <aj@suse.de>
1505 * sysdeps/pthread/bits/libc-tsd.h: Declare weak_extern functions.
1507 2003-01-03 Jakub Jelinek <jakub@redhat.com>
1509 * Makefile ($(objpfx)libpthread.so): Depend on ld.so.
1511 2003-01-02 Ulrich Drepper <drepper@redhat.com>
1513 * tst-cancel-wrappers.sh: Exclude sigwait.c as well, it does not have
1516 2003-01-02 Jakub Jelinek <jakub@redhat.com>
1518 * internals.h (struct pthread_functions): Rename
1519 ptr_pthread_cond_* fields to ptr___pthread_cond_*.
1520 * pthread.c (pthread_functions): Adjust.
1521 * forward.c: Export both pthread_cond_*@@GLIBC_2.3.2 and
1522 pthread_cond_*@GLIBC_2.0 compatibility symbols.
1523 * Versions [libc] (GLIBC_2.3.2): Export pthread_cond_broadcast,
1524 pthread_cond_destroy, pthread_cond_init, pthread_cond_signal
1525 and pthread_cond_wait.
1527 * sysdeps/pthread/bits/pthreadtypes.h (__pthread_cond_align_t): New
1529 (pthread_cond_t): Add __align member, shorten __padding.
1530 * sysdeps/pthread/pthread.h (PHTREAD_COND_INITIALIZER): Initialize
1531 __padding and __align too.
1533 * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call2): Add
1535 * sysdeps/pthread/sigaction.c: New file.
1536 * sysdeps/unix/sysv/linux/raise.c: New file.
1537 * sysdeps/unix/sysv/linux/sigwait.c: New file.
1538 * sysdeps/unix/sysv/linux/fork.c (__pthread_fork): Protect
1539 weak_extern with #ifndef SHARED.
1540 * sysdeps/unix/sysv/linux/jmp-unwind.c (__pthread_cleanup_upto):
1542 * signals.c (__sigaction): Renamed to...
1543 (__pthread_sigaction): ... this.
1544 (__sigaction): New strong alias, #ifdef SHARED only.
1545 (sigaction): Protect with #ifdef SHARED.
1546 (sigwait): Renamed to...
1547 (__pthread_sigwait): ... this.
1548 (sigwait): New strong alias, #ifdef SHARED only.
1549 (raise): Renamed to...
1550 (__pthread_raise): ... this.
1551 (raise): New strong alias, #ifdef SHARED only.
1552 * internals.h (__pthread_sigaction, __pthread_sigwait,
1553 __pthread_raise): New prototypes.
1554 (struct pthread_functions): Add ptr_pthread_sigaction,
1555 ptr_pthread_sigwait, ptr_pthread_raise.
1556 * pthread.c (pthread_functions): Renamed to...
1557 (__pthread_functions): ... this. No longer static, no longer
1558 SHARED only. Initialize ptr_pthread_sigaction, ptr_pthread_sigwait
1559 and ptr_pthread_raise.
1560 [SHARED] (ptr_pthread_functions): Change to &__pthread_functions.
1561 * libc-cancellation.c (__pthread_thread_self): Remove weak_extern.
1562 * ptfork.c (__fork, __vfork): Protect with #ifdef SHARED.
1563 * ptlongjmp.c (siglongjmp, longjmp): Protect with #ifdef SHARED.
1565 * Makefile (tests, tests-static): Add tst-cancel-static.
1566 * tst-cancel-static.c: New test.
1568 2003-01-02 Jakub Jelinek <jakub@redhat.com>
1570 * Makefile (CFLAGS-pthread_atfork.c): Add -DNOT_IN_libc.
1572 2003-01-02 Ulrich Drepper <drepper@redhat.com>
1574 * sysdeps/pthread/bits/pthreadtypes.h (pthread_cond_t): Add padding.
1575 * condvar.c: Add symbol versioning. The compatibility versions
1576 are the same as the change in the interface does not effect this
1578 * Versions [libpthread]: Add definitions for new pthread_cond_*
1579 interfaces for version GLIBC_2.3.2.
1581 2002-12-31 Ulrich Drepper <drepper@redhat.com>
1583 * sysdeps/unix/sysv/linux/fork.h: Add libc_hidden_proto for
1585 * sysdeps/unix/sysv/linux/register-atfork.c: Add libc_hidden_def
1586 for __register_atfork.
1588 2002-12-31 Jakub Jelinek <jakub@redhat.com>
1590 * sysdeps/i386/i686/pt-machine.h: Use __ASSEMBLER__ instead of
1591 ASSEMBLER test macro.
1592 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Likewise.
1593 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
1594 * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h: Likewise.
1595 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
1596 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
1597 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
1599 * sysdeps/pthread/errno-loc.c (__errno_location): Add
1601 * sysdeps/pthread/herrno-loc.c (__h_errno_location): Likewise.
1602 * sysdeps/pthread/res-state.c (__res_state): Likewise.
1603 * sysdeps/unix/sysv/linux/allocrtsig.c (__libc_current_sigrtmin,
1604 __libc_current_sigrtmax): Likewise.
1605 * Versions [libc] (GLIBC_PRIVATE): Remove __libc_internal_tsd_get,
1606 __libc_internal_tsd_set, __libc_internal_tsd_address,
1607 __libc_alloca_cutoff.
1608 [libpthread] (GLIBC_PRIVATE): Remove __libc_internal_tsd_get,
1609 __libc_internal_tsd_set, __libc_internal_tsd_address.
1611 * sysdeps/pthread/list.h: Remove assert.h include.
1612 * sysdeps/unix/sysv/linux/fork.c: Include <fork.h>, not "fork.h".
1614 * sysdeps/pthread/list.h: New file.
1615 * sysdeps/unix/sysv/linux/jmp-unwind.c: New file.
1616 * sysdeps/unix/sysv/linux/fork.c: New file.
1617 * sysdeps/unix/sysv/linux/fork.h: New file.
1618 * sysdeps/unix/sysv/linux/ia64/fork.h: New file.
1619 * sysdeps/unix/sysv/linux/sparc/fork.h: New file.
1620 * sysdeps/unix/sysv/linux/register-atfork.c: New file.
1621 * sysdeps/unix/sysv/linux/unregister-atfork.c: New file.
1622 * sysdeps/unix/sysv/linux/Makefile: New file.
1623 * sysdeps/unix/sysv/linux/Versions: New file.
1624 * ptlongjmp.c (pthread_cleanup_upto): Rename to...
1625 (__pthread_cleanup_upto): ...this. Add targetframe argument,
1626 use it instead of currentframe. No longer static.
1627 (siglongjmp, longjmp): Remove pthread_cleanup_upto calls.
1628 * internals.h (__pthread_cleanup_upto, __pthread_fork): New prototypes.
1629 (struct pthread_functions): Add ptr_pthread_fork,
1630 ptr_pthread_cleanup_upto.
1631 * pthread.c (pthread_functions): Initialize ptr_pthread_fork and
1632 ptr_pthread_cleanup_upto.
1633 * ptfork.c: Include fork.h.
1634 (struct handler_list, struct handler_list_block): Remove.
1635 (pthread_atfork_lock, pthread_atfork_prepare, pthread_atfork_parent,
1636 pthread_atfork_child): Remove.
1637 (pthread_insert_list, __pthread_atfork, pthread_call_handlers): Remove.
1638 (__pthread_fork): New function.
1639 (__fork, __vfork): Call __libc_fork.
1640 * Makefile (libpthread-routines): Add old_pthread_atfork.
1641 (libpthread-nonshared): Add pthread_atfork.
1642 (others): Depend on $(objpfx)libpthread_nonshared.a.
1643 ($(objpfx)libpthread_nonshared.a): New rule.
1644 (install): Depend on $(inst_libdir)/libpthread.so.
1645 ($(inst_libdir)/libpthread.so, $(inst_libdir)/libpthread_nonshared.a):
1647 (tests): Depend on libpthread_nonshared.a too.
1648 * old_pthread_atfork.c: New file.
1649 * pthread_atfork.c: New file.
1650 * Makeconfig (shared-thread-library): Include libpthread_nonshared.a
1653 2002-12-30 Jakub Jelinek <jakub@redhat.com>
1655 * forward.c: Make all functions available by default again. It
1656 caused too much trouble.
1657 * internals.h (struct pthread_functions): Rename ptr_pthread_exit
1658 and ptr_pthread_attr_init_2_* to ptr___pthread_exit and
1659 ptr___pthread_attr_init_2_*.
1660 * pthread.c (pthread_functions): Adjust.
1662 2002-12-28 Jakub Jelinek <jakub@redhat.com>
1664 * libc_pthread_init.c (__libc_pthread_init): Remove
1665 MULTIPLE_THREADS_OFFSET check.
1666 * sysdeps/i386/tls.h: Include tcb-offsets.h in assembler.
1667 (SYSINFO_OFFSET): Remove.
1668 * sysdeps/i386/Makefile [csu] (gen-as-const-headers): Add
1670 * sysdeps/i386/tcb-offsets.sym: New file.
1671 * sysdeps/pthread/tcb-offsets.h: New file.
1672 * sysdeps/sparc/sparc32/tls.h: Removed.
1673 * sysdeps/sparc/sparc64/tls.h: Move...
1674 * sysdeps/sparc/tls.h: ...here. Include tcb-offsets.h in assembler.
1675 * sysdeps/sparc/Makefile: New file.
1676 * sysdeps/sparc/tcb-offsets.sym: New file.
1677 * sysdeps/ia64/tls.h: Include tcb-offsets.h in assembler.
1678 * sysdeps/ia64/Makefile: New file.
1679 * sysdeps/ia64/tcb-offsets.sym: New file.
1680 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
1681 (MULTIPLE_THREADS_OFFSET): Remove.
1682 Replace defined MULTIPLE_THREADS_OFFSET
1683 with defined FLOATING_STACKS && USE___THREAD.
1684 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1685 (MULTIPLE_THREADS_OFFSET): Remove.
1686 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
1687 (MULTIPLE_THREADS_OFFSET): Remove.
1688 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
1689 (MULTIPLE_THREADS_OFFSET): Remove.
1690 * pthread.c (__pthread_initialize_manager): Remove
1691 MULTIPLE_THREADS_OFFSET cbeck.
1693 * tst-cancel-wrappers.sh: Add line continuations.
1695 2002-12-27 Jakub Jelinek <jakub@redhat.com>
1697 * sysdeps/pthread/bits/libc-tsd.h: Include linuxthreads/descr.h
1698 and bits/libc-lock.h.
1699 (__libc_internal_tsd_get, __libc_internal_tsd_set,
1700 __libc_internal_tsd_address): Remove.
1701 (__pthread_internal_tsd_address, __pthread_internal_tsd_get,
1702 __pthread_internal_tsd_set): New weak_externs.
1703 (__libc_tsd_address, __libc_tsd_get, __libc_tsd_set): Define
1704 using __libc_maybe_call2.
1705 (__libc_tsd_key_t): Move to ...
1706 * descr.h (__libc_tsd_key_t): ...here.
1707 Remove bits/libc-tsd.h include.
1708 * sysdeps/pthread/errno-loc.c: New file.
1709 * sysdeps/pthread/herrno-loc.c: New file.
1710 * sysdeps/pthread/res-state.c: New file.
1711 * libc-cancellation.c (THREAD_GETMEM, THREAD_SETMEM): Remove.
1712 (__libc_enable_asynccancel, __libc_disable_asynccancel): Use
1713 thread_self unconditionally. Use LIBC_THREAD_[SG]ETMEM instead
1714 of THREAD_[SG]ETMEM.
1715 * specific.c (libc_internal_tsd_set): Renamed to...
1716 __pthread_internal_tsd_set. Remove static.
1717 (libc_internal_tsd_get): Renamed to...
1718 __pthread_internal_tsd_get. Remove static.
1719 (libc_internal_tsd_address): Renamed to...
1720 __pthread_internal_tsd_address. Remove static.
1721 (__libc_internal_tsd_set, __libc_internal_tsd_get,
1722 __libc_internal_tsd_address, __libc_alloca_cutoff): Remove.
1723 * internals.h [!NOT_IN_libc] (LIBC_THREAD_GETMEM, LIBC_THREAD_SETMEM):
1725 (__pthread_internal_tsd_set, __pthread_internal_tsd_get,
1726 __pthread_internal_tsd_address): New prototypes.
1727 (struct pthread_functions): Add
1728 ptr_pthread_internal_tsd_([sg]et|address) fields.
1729 [!NOT_IN_libc && !FLOATING_STACKS] (thread_self): Define.
1730 * pthread.c (pthread_functions) [!USE_TLS && !HAVE___THREAD]:
1731 Initialize ptr_pthread_internal_tsd_([sg]et|address) fields.
1732 * Versions (libpthread): Remove __libc_alloca_cutoff@GLIBC_PRIVATE.
1733 * alloca_cutoff.c: New file.
1734 * no-tsd.c: Removed.
1735 * Makefile (routines): Remove no-tsd. Add alloca_cutoff.
1736 * pt-system.c (system): Remove cancellation handling.
1737 * tst-cancel-wrappers.sh: Allow pt-system.o* to not use the
1738 cancellation routines.
1740 * sysdeps/i386/tls.h: Include dl-sysdep.h and stdint.h.
1741 (tcbhead_t): Add sysinfo field.
1742 (SYSINFO_OFFSET, INIT_SYSINFO): Define.
1743 (TLS_INIT_TP): Use INIT_SYSINFO.
1744 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: New file.
1745 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
1746 (MULTIPLE_THREADS_OFFSET): Adjust.
1747 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1748 (MULTIPLE_THREADS_OFFSET): Likewise.
1749 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
1750 (MULTIPLE_THREADS_OFFSET): Likewise.
1751 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
1752 (MULTIPLE_THREADS_OFFSET): Likewise.
1753 * descr.h: Include stdint.h.
1754 (struct _pthread_descr_struct): Add p_header.data.sysinfo field.
1756 2002-12-22 Jakub Jelinek <jakub@redhat.com>
1758 * libc_pthread_init.c: Include stdlib.h.
1759 * sysdeps/i386/tls.h (tcbhead_t): Add multiple_threads member.
1760 (TLS_INIT_TP_EXPENSIVE): Define.
1761 * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call,
1762 __libc_maybe_call2): In _LIBC check SHARED define.
1763 * sysdeps/ia64/tls.h: New file.
1764 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: New file.
1765 * sysdeps/unix/sysv/linux/ia64/Makefile: New file.
1766 * sysdeps/x86_64/tls.h (TLS_INIT_TP_EXPENSIVE): Define.
1767 * sysdeps/sparc/sparc32/tls.h: New file.
1768 * sysdeps/sparc/sparc64/tls.h: New file.
1769 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: New file.
1770 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: New file.
1771 * Makefile (tests): Add tst-cancel[1-6].
1772 (tests-reverse): Add tst-cancel5.
1773 Link libc.so before libpthread.so for tests-reverse.
1774 * tst-cancel1.c: New file.
1775 * tst-cancel2.c: New file.
1776 * tst-cancel3.c: New file.
1777 * tst-cancel4.c: New file.
1778 * tst-cancel5.c: New file.
1779 * tst-cancel6.c: New file.
1781 2002-12-27 Andreas Schwab <schwab@suse.de>
1783 * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h: New file.
1785 2002-12-22 Roland McGrath <roland@redhat.com>
1787 * Makefile (omit-deps): Add $(unix-syscalls:%=ptw-%).
1789 2002-12-21 Ulrich Drepper <drepper@redhat.com>
1791 * pthread.c (init_rtsigs): Remove incomplete __builtin_expect.
1792 Reported by Art Hass <ahaas@airmail.net>.
1794 2002-12-19 Jakub Jelinek <jakub@redhat.com>
1796 * forward.c (pthread_attr_init_2_0, pthread_attr_init_2_1):
1797 Use return 0 as 6th argument to FORWARD4.
1799 2002-12-18 Jakub Jelinek <jakub@redhat.com>
1801 * sysdeps/i386/useldt.h (FLOATING_STACKS, ARCH_STACK_MAX_SIZE): Only
1802 define if __ASSUME_LDT_WORKS > 0.
1803 * libc-cancellation.c (THREAD_GETMEM, THREAD_SETMEM): Redefine to
1804 struct member access if !FLOATING_STACKS.
1805 * sysdeps/pthread/flockfile.c (flockfile): Change into weak alias.
1807 2002-12-18 Jakub Jelinek <jakub@redhat.com>
1809 * internals.h (__pthread_thread_self): New prototype.
1810 (struct pthread_functions): Add ptr_pthread_thread_self field.
1811 * pthread.c (pthread_functions): Initialize ptr_pthread_thread_self.
1812 (__pthread_thread_self): New function.
1813 * libc-cancellation.c (__pthread_thread_self): Add weak_extern.
1814 (__libc_enable_asynccancel, __libc_disable_asynccancel): Don't
1815 use thread_self() directly if not FLOATING_STACKS.
1817 2002-12-18 Jakub Jelinek <jakub@redhat.com>
1819 * sysdeps/x86_64/pt-machine.h: Guard most of the header
1820 with #ifndef __ASSEMBLER__.
1821 * pthread.c (pthread_functions): Use SHLIB_COMPAT around
1822 pthread_attr_init_2_0 use.
1824 2002-12-17 Jakub Jelinek <jakub@redhat.com>
1826 * wrapsyscall.c: Removed.
1828 * Makefile (distribute): Add tst-cancel-wrappers.sh.
1829 (routines): Remove weaks. Add forward,
1830 libc_pthread_init, libc-cancellation.
1831 (shared-only-routines): Remove weaks. Add forward.
1832 (libpthread-routines): Remove wrapsyscall.
1833 Add ptw-write, ptw-read, ptw-close, ptw-fcntl, ptw-accept,
1834 ptw-connect, ptw-recv, ptw-recvfrom, ptw-recvmsg, ptw-send,
1835 ptw-sendmsg, ptw-sendto, ptw-fsync, ptw-lseek, ptw-lseek64,
1836 ptw-llseek, ptw-msync, ptw-nanosleep, ptw-open, ptw-open64,
1837 ptw-pause, ptw-pread, ptw-pread64, ptw-pwrite, ptw-pwrite64,
1838 ptw-tcdrain, ptw-wait, ptw-waitpid, pt-system, pt-allocrtsig.
1839 (libpthread-shared-only-routines): Add pt-allocrtsig.
1840 (tests): Depend on $(objpfx)tst-cancel-wrappers.out.
1841 ($(objpfx)tst-cancel-wrappers.out): New rule.
1842 * sysdeps/pthread/bits/libc-lock.h: Include linuxthreads/internals.h
1844 (__libc_maybe_call): In libpthread.* don't check for existance
1846 (__libc_maybe_call2): Define.
1847 (__libc_lock_init, __libc_lock_fini, __libc_lock_lock,
1848 __libc_lock_trylock, __libc_lock_unlock): Use it.
1849 * sysdeps/pthread/flockfile.c: New file.
1850 * sysdeps/pthread/ftrylockfile.c: New file.
1851 * sysdeps/pthread/funlockfile.c: New file.
1852 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: New file.
1853 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: New file.
1854 * sysdeps/unix/sysv/linux/allocrtsig.c: New file.
1855 * libc-cancellation.c: New file.
1856 * forward.c: New file.
1857 * libc_pthread_init.c: New file.
1858 * pt-system.c: New file.
1859 * pthread.c: Remove locale.h.
1860 (__pthread_manager_thread): Initialize multiple_threads.
1861 (__pthread_multiple_threads): Declare.
1862 (pthread_functions): New variable.
1863 (__pthread_initialize_minimal): Remove __uselocale call.
1864 Call __libc_pthread_init.
1865 (__pthread_initialize_manager): Initialize __pthread_multiple_threads,
1866 initial thread's multiple_threads and __libc_multiple_threads.
1867 Check MULTIPLE_THREADS_OFFSET value. Initialize manager thread's
1869 (pthread_setschedparam, pthread_getschedparam): Rename to __
1870 prefixed variants. Add strong_alias.
1871 (current_rtmin, current_rtmax, __libc_current_sigrtmin,
1872 __libc_current_sigrtmax, __libc_allocate_rtsig): Remove.
1873 (init_rtsigs): Use __libc_current_sigrtmin_private.
1874 (pthread_initialize): Only call init_rtsigs if
1875 !__ASSUME_REALTIME_SIGNALS.
1876 (__pthread_require_wrappers, __pthread_require_lockfile): Remove.
1877 * internals.h (__pthread_attr_destroy, __pthread_attr_setdetachstate,
1878 __pthread_attr_getdetachstate, __pthread_attr_setschedparam,
1879 __pthread_attr_getschedparam, __pthread_attr_setschedpolicy,
1880 __pthread_attr_getschedpolicy, __pthread_attr_setinheritsched,
1881 __pthread_attr_getinheritsched, __pthread_attr_setscope,
1882 __pthread_attr_getscope, __pthread_cond_init,
1883 __pthread_cond_destroy, __pthread_cond_wait,
1884 __pthread_cond_signal, __pthread_cond_broadcast,
1885 __pthread_condattr_init, __pthread_condattr_destroy,
1886 __pthread_equal, __pthread_getschedparam,
1887 __pthread_setschedparam, __pthread_setcancelstate,
1888 __pthread_setcanceltype, __pthread_enable_asynccancel,
1889 __libc_enable_asynccancel, __libc_pthread_init): New prototype.
1890 (__pthread_mutex_init, __pthread_mutex_destroy,
1891 __pthread_mutex_lock, __pthread_mutex_unlock,
1892 __pthread_mutex_trylock): Likewise.
1894 (struct pthread_functions): New type.
1895 (__libc_pthread_functions): New variable.
1896 (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): Define.
1897 * descr.h (struct _pthread_descr_struct): Add
1898 p_header.data.multiple_threads field.
1899 * manager.c (pthread_handle_create): Initialize multiple_threads.
1900 * cancel.c (__pthread_enable_asynccancel,
1901 __pthread_disable_asynccancel): New functions.
1902 (__pthread_provide_wrappers): Remove.
1903 (pthread_setcancelstate, pthread_setcanceltype): Rename to __
1904 prefixed variants. Add strong_alias.
1905 * condvar.c (pthread_cond_init, pthread_cond_destroy,
1906 pthread_cond_wait, pthread_cond_signal, pthread_cond_broadcast,
1907 pthread_condattr_init, pthread_condattr_destroy): Likewise.
1908 * join.c (pthread_exit): Likewise.
1909 * attr.c (pthread_attr_destroy, pthread_attr_setdetachstate,
1910 pthread_attr_getdetachstate, pthread_attr_setschedparam,
1911 pthread_attr_getschedparam, pthread_attr_setschedpolicy,
1912 pthread_attr_getschedpolicy, pthread_attr_setinheritsched,
1913 pthread_attr_getinheritsched, pthread_attr_setscope,
1914 pthread_attr_getscope): Likewise.
1915 * mutex.c (__pthread_mutex_init, __pthread_mutex_destroy,
1916 __pthread_mutex_lock, __pthread_mutex_unlock,
1917 __pthread_mutex_trylock): Add hidden_def.
1918 * Versions (libc): Add __libc_pthread_init,
1919 __libc_current_sigrtmin_private, __libc_current_sigrtmax_private,
1920 __libc_allocate_rtsig_private @@GLIBC_PRIVATE.
1921 * lockfile.c: Remove some USE_IN_LIBIO guards.
1922 (__pthread_provide_lockfile): Remove.
1923 * pt-allocrtsig.c: New file.
1924 * tst-cancel-wrappers.sh: New test.
1926 2002-12-15 Ulrich Drepper <drepper@redhat.com>
1928 * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect,
1929 readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev.
1930 * wrapsyscall.c: Remove creat, poll, pselect, readv, select,
1931 sigpause, sigsuspend, sigwaitinfo, waitid, and writev wrappers.
1933 2002-12-10 Ulrich Drepper <drepper@redhat.com>
1935 * wrapsyscall.c (CANCELABLE_SYSCALL): Don't define function as
1936 weak. There is no reason for that.
1937 (CANCELABLE_SYSCALL_VA): Likewise.
1939 2002-12-09 Ulrich Drepper <drepper@redhat.com>
1941 * wrapsyscall.c: Add wrappers for creat, poll, pselect, readv, select,
1942 sigpause, __xpg_sigpause, sigsuspend, sigwaitinfo, waitid, and writev.
1943 * Versions: Export creat, poll, pselect, readv, select, sigpause,
1944 __xpg_sigpause, sigsuspend, sigwaitinfo, waitid, and writev from
1945 libpthread in version GLIBC_2.3.2.
1947 2002-12-06 Ulrich Drepper <drepper@redhat.com>
1949 * sysdeps/pthread/bits/libc-lock.h: Define __rtld_lock_* macros.
1951 2002-12-05 Roland McGrath <roland@redhat.com>
1953 * pthread.c (__pthread_initialize_minimal)
1954 [USE_TLS && SHARED && !USE___THREAD]: Initialize TLS and set up the
1955 TCB if the dynamic linker didn't do it at startup.
1957 * sysdeps/i386/tls.h (TLS_INIT_TP): Make it return zero or an error
1959 (TLS_DO_SET_THREAD_AREA, TLS_DO_MODIFY_LDT, TLS_SETUP_GS_SEGMENT):
1961 * sysdeps/x86_64/tls.h (TLS_INIT_TP): Likewise.
1962 * sysdeps/alpha/tls.h (TLS_INIT_TP): Likewise (always zero).
1964 2002-12-03 Roland McGrath <roland@redhat.com>
1966 * pthread.c (pthread_initialize) [SHARED]: Copy dl_error_tsd value
1967 from dynamic linker internal cell to new libc cell.
1969 2002-11-28 Roland McGrath <roland@redhat.com>
1971 * tst-context.c: #define IS_IN_libpthread around #include <tls.h>
1972 before other headers, so FLOATING_STACKS is not defined wrongly.
1974 * sysdeps/i386/tls.h [!IS_IN_libpthread]: Enable TLS support
1975 even if [! FLOATING_STACKS].
1976 (TLS_DO_MODIFY_LDT_KERNEL_CHECK): New macro.
1977 If not under [__ASSUME_LDT_WORKS > 0], then do a runtime check of
1978 dl_osversion >= 2.3.99 and fatal if not.
1979 (TLS_DO_MODIFY_LDT): Use it.
1981 2002-11-28 Ulrich Drepper <drepper@redhat.com>
1983 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define macros which
1984 require it to 200112L. Remove _POSIX_POLL and _POSIX_SELECT.
1985 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
1987 2002-11-19 Ulrich Drepper <drepper@redhat.com>
1989 * Versions (libc: GLIBC_2.0): Remove names of functions which are
1990 not defined in libc.
1991 * Makefile (shared-only-routines): Add weaks.
1992 * weaks.c: Remove functions which are not exported from libc.so.
1994 2002-11-14 Roland McGrath <roland@redhat.com>
1996 * libc-tsd.c: New file.
1997 * Makefile (distribute): Add it.
1998 (libc-link.so): New variable.
1999 ($(objpfx)libpthread.so): Depend on that instead of libc.so file name.
2000 (libc-ok-for-link): New variable.
2001 [$(versioning) = yes]: Include $(common-objpfx)tls.make and define
2002 libc-ok-for-link to $(use-thread).
2003 [$(libc-ok-for-link) = no]
2004 (libc-link.so): Set to $(objpfx)libc.so, not $(common-objpfx)libc.so.
2005 ($(objpfx)libc_pic_lite.a,$(objpfx)libc_pic_lite.os, $(objpfx)libc.so):
2007 (generated): Append them.
2008 (extra-objs): Append libc-tsd.os.
2010 * libc-tls-loc.c: New file.
2011 * Makefile (libpthread-routines): Add it.
2013 2002-11-14 Andreas Schwab <schwab@suse.de>
2015 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Fix unterminated
2018 2002-11-13 Roland McGrath <roland@redhat.com>
2020 * Examples/ex6.c (main): Improve error reporting.
2022 2002-11-04 Ulrich Drepper <drepper@redhat.com>
2024 * sysdeps/i386/Makefile: Compile pthread.c and sighandler.c with
2025 -fno-omit-frame-pointer. Patch by Andreas Steinmetz <ast@domdv.de>.
2027 * sysdeps/i386/useldt.h [PIC] (USETLS_LOAD_EBX): Use correct input
2029 (DO_SET_THREAD_AREA): Mark asm output specifiers correctly.
2031 2002-10-22 Jakub Jelinek <jakub@redhat.com>
2033 * manager.c (pthread_start_thread): Call __uselocale even
2034 if [! SHARED]. Patch by Leon Kanter <leon@geon.donetsk.ua>.
2036 2002-10-17 Roland McGrath <roland@redhat.com>
2038 * Makefile (unload): Don't link in libpthread.so.
2039 ($(objpfx)unload.out): Do depend on it.
2040 * unload.c (main): Improve error reporting.
2042 2002-10-09 Roland McGrath <roland@redhat.com>
2044 * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call): New macro.
2045 Under [__PIC__], call the function via the pointer fetched for
2046 comparison rather than a call by name that uses the PLT.
2047 (__libc_lock_init, __libc_rwlock_init, __libc_lock_fini)
2048 (__libc_rwlock_fini, __libc_lock_lock, __libc_rwlock_rdlock)
2049 (__libc_rwlock_wrlock, __libc_lock_trylock, __libc_rwlock_tryrdlock)
2050 (__libc_rwlock_trywrlock, __libc_lock_unlock, __libc_rwlock_unlock)
2051 (__libc_key_create, __libc_getspecific, __libc_setspecific)
2052 (__libc_atfork): Use it.
2054 * pthread.c [SHARED] (__libc_dl_error_tsd): New function.
2055 (pthread_initialize) [SHARED]: Set _dl_error_catch_tsd to that.
2056 * Versions (libc: GLIBC_PRIVATE): Add __libc_dl_error_tsd.
2057 (ld: GLIBC_PRIVATE): Set removed.
2059 2002-10-11 Ulrich Drepper <drepper@redhat.com>
2061 * sysdeps/unix/sysv/linux/execve.c: New file.
2063 2002-10-09 Jakub Jelinek <jakub@redhat.com>
2065 * no-tsd.c: Include stdlib.h.
2067 2002-10-07 Jakub Jelinek <jakub@redhat.com>
2069 * sysdeps/unix/sysv/linux/allocalim.h: New file.
2070 * descr.h (struct _pthread_descr_struct): Add p_alloca_cutoff
2072 * manager.c (__pthread_allocate_stack): Add out_stacksize argument.
2073 Pass stack size to caller.
2074 (pthread_handle_create): Set p_alloca_cutoff.
2075 * pthread.c (__pthread_initial_thread): Use C99 designated
2076 initializers. Set p_alloca_cutoff.
2077 (__pthread_manager_thread): Likewise.
2078 (__pthread_initialize_minimal) [USE_TLS]: Set p_alloca_cutoff
2080 (__pthread_init_max_stacksize): Possibly decrease p_alloca_cutoff
2082 (__pthread_initialize_manager) [USE_TLS]: Set p_alloca_cutoff
2084 * specific.c (__libc_alloca_cutoff): New function.
2085 * no-tsd.c (__libc_alloca_cutoff): New function.
2086 * Versions: Export __libc_alloca_cutoff@@GLIBC_PRIVATE from libc
2089 2002-10-02 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2091 * sysdeps/sh/pt-machine.h: Make C code ifndef'ed with __ASSEMBLER__.
2092 * sysdeps/sh/tls.h: Likewise.
2093 * sysdeps/unix/sysv/linux/sh/smp.h: New file.
2095 2002-09-29 Jakub Jelinek <jakub@redhat.com>
2097 * sysdeps/pthread/tst-timer.c (main): Clear
2098 SIGEV2.sigev_notify_attributes.
2100 2002-09-29 Ulrich Drepper <drepper@redhat.com>
2102 * sysdeps/i386/useldt.h (DO_SET_THREAD_AREA): Don't use
2103 INLINE_SYSCALL for set_thread_area syscall.
2105 2002-09-28 Roland McGrath <roland@redhat.com>
2107 * pthread.c (__pthread_reset_main_thread) [FLOATING_STACKS]:
2108 Don't call setrlimit, since we did no prior bogon we need to undo.
2110 2002-09-27 Roland McGrath <roland@redhat.com>
2112 * sysdeps/x86_64/tls.h [__ASSEMBLER__]: Don't include <pt-machine.h>.
2114 2002-09-24 Roland McGrath <roland@redhat.com>
2116 * sysdeps/x86_64/tls.h: New file.
2118 2002-09-23 Roland McGrath <roland@redhat.com>
2120 * Examples/ex13.c (dump_mut): int -> size_t for counter.
2122 2002-09-18 Bruno Haible <bruno@clisp.org>
2124 * Examples/ex10.c (thread): Fail if pthread_mutex_timedlock() returns
2125 an unexpected error code.
2127 * internals.h (__pthread_message): Add const to first parameter type.
2128 * pthread.c (__pthread_message): Likewise.
2130 * sysdeps/unix/sysv/linux/configure: Moved to ../sysdeps/pthread.
2132 2002-09-17 Roland McGrath <roland@redhat.com>
2134 * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT, TLS_DO_SET_THREAD_AREA):
2135 Set the descriptor limit to the full 4GB, so %gs:OFFSET works for any
2136 offset (positive or negative) relative to the thread struct.
2137 * sysdeps/i386/useldt.h (DO_MODIFY_LDT, DO_SET_THREAD_AREA): Likewise.
2139 2002-09-12 Jakub Jelinek <jakub@redhat.com>
2141 * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: Move...
2142 * sysdeps/unix/sysv/linux/sparc/Makefile: ...here.
2143 Replace /usr/lib/crt[in].o with crt[in].o too.
2145 2002-09-11 Steven Munroe <sjmunroe@us.ibm.com>
2147 * sysdeps/powerpc/powerpc64/pt-machine.h: New file.
2149 2002-09-04 Bruno Haible <bruno@clisp.org>
2151 * pthread.c: Include <sys/time.h>.
2152 (is_smp_system): Move to sysdeps/unix/sysv/linux/smp.h.
2153 * sysdeps/unix/sysv/linux/smp.h: New file, extracted from pthread.c.
2154 * Makefile (distribute): Add smp.h to the list.
2156 2002-09-04 Bruno Haible <bruno@clisp.org>
2158 * sysdeps/alpha/pt-machine.h: Choose different include file location
2159 on non-Linux platforms.
2161 * wrapsyscall.c (PROMOTE_INTEGRAL_TYPE): New macro.
2162 (open, open64): Change va_arg argument type to the integral type to
2163 which mode_t promotes.
2165 * sysdeps/pthread/tst-timer.c (main): Don't assume anything about
2166 the structure of 'struct sigevent'.
2168 * errno.c (__errno_location, __h_errno_location, __res_state):
2169 Use prototype function definitions.
2171 2002-07-29 Steven Munroe <sjmunroe@us.ibm.com>
2173 * shlib-versions: Set libpthread version to 2.3 for powerpc64.
2174 * sysdeps/powerpc/pt-machine.h: moved to...
2175 * sysdeps/powerpc/powerpc32/pt-machine.h: ...here
2176 * sysdeps/powerpc/powerpc64/pt-machine.h: New file.
2178 2002-09-02 Roland McGrath <roland@redhat.com>
2180 * sysdeps/powerpc/Makefile (CFLAGS-pt-initfini.s): New variable.
2182 2002-09-01 Roland McGrath <roland@redhat.com>
2184 * sysdeps/pthread/bits/libc-tsd.h (enum __libc_tsd_key_t): Add new keys
2185 CTYPE_B, CTYPE_TOLOWER, CTYPE_TOUPPER.
2187 * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_address): New macro.
2188 (__libc_internal_tsd_address): Declare it.
2189 * Versions (libc, ld, libpthread: GLIBC_PRIVATE): Add
2190 __libc_internal_tsd_address.
2191 * specific.c (libc_internal_tsd_address): New function.
2192 (__libc_internal_tsd_address): New variable.
2193 * no-tsd.c (__libc_internal_tsd_address): New variable.
2195 2002-08-31 Ulrich Drepper <drepper@redhat.com>
2197 * Makefile: Don't use rule for crt%.o, spell it out as rules for
2200 2002-08-30 Roland McGrath <roland@redhat.com>
2202 * Makefile (extra-objs, omit-deps): Add crtn.
2203 ($(objpfx)libpthread.so): Depend on $(objpfx)crtn.o.
2204 ($(objpfx)libpthread.so: +postinit): Append $(objpfx)crtn.o.
2205 ($(objpfx)crtn.S): New target.
2206 ($(objpfx)crt%.o): Pattern rule replaces crti.o target.
2207 (generated): Add crtn.S.
2209 * sysdeps/unix/sysv/linux/x86_64/Makefile ($(objpfx)specs): Massage
2210 crtn.o pathname too.
2212 2002-08-30 Jakub Jelinek <jakub@redhat.com>
2214 * pthread.c (__pthread_initialize_minimal): Call __uselocale even
2217 2002-08-30 Roland McGrath <roland@redhat.com>
2219 * tst-static-locale.c: New file.
2220 * Makefile (tests, tests-static): Add it.
2222 2002-04-24 Steven Munroe <sjmunroe@us.ibm.com>
2224 * spinlock.c (__pthread_lock): Fix spurious wakeup
2225 handling. Don't clear lowest bit of list pointer as sign the thread
2226 is still on the wait list. Don't restart after spurious wakeup
2227 with spinning to get the lock.
2228 (__pthread_unlock): Take set lowest bit into account when handling
2229 pointer to list elements.
2230 Patch by Steve Munroe <sjmunroe@us.ibm.com>.
2232 2002-08-28 Roland McGrath <roland@redhat.com>
2234 * sysdeps/pthread/timer_routines.c (thread_func): Fix type in cast.
2236 2002-08-28 Jakub Jelinek <jakub@redhat.com>
2238 * sysdeps/unix/sysv/linux/hppa/aio_cancel.c: New file.
2239 * sysdeps/unix/sysv/linux/sparc/aio_cancel.c: New file.
2240 * sysdeps/unix/sysv/linux/alpha/aio_cancel.c: New file.
2242 2002-08-28 Ulrich Drepper <drepper@redhat.com>
2244 * sysdeps/pthread/timer_routines.c (thread_func): Change return
2245 type to void and add casts in use to avoid warnings with all gcc
2248 2002-08-08 Jakub Jelinek <jakub@redhat.com>
2250 * sysdeps/unix/sysv/linux/bits/local_lim.h (PTHREAD_THREADS_MAX):
2252 * manager.c (__pthread_handles): Remove.
2253 * pthandles.c: New file.
2254 * pthread.c (__pthread_initialize_minimal): Initialize
2255 __pthread_handles[0] and __pthread_handles[1].
2256 * Makefile (libpthread-routines): Add pthandles (must be last).
2258 2002-08-26 Brian Youmans <3diff@gnu.org>
2260 * Examples/ex10.c: Corrected version number in Lesser GPL copying
2261 permission notice from 2 to 2.1.
2262 * Examples/ex11.c: Likewise.
2263 * Examples/ex13.c: Likewise.
2264 * Examples/ex8.c: Likewise.
2265 * Examples/ex9.c: Likewise.
2266 * barrier.c: Likewise.
2267 * events.c: Likewise.
2268 * lockfile.c: Likewise.
2269 * no-tsd.c: Likewise.
2270 * pt-machine.c: Likewise.
2271 * ptclock_gettime.c: Likewise.
2272 * ptclock_settime.c: Likewise.
2273 * rwlock.c: Likewise.
2274 * sysdeps/alpha/pspinlock.c: Likewise.
2275 * sysdeps/alpha/pt-machine.h: Likewise.
2276 * sysdeps/arm/pspinlock.c: Likewise.
2277 * sysdeps/arm/pt-machine.h: Likewise.
2278 * sysdeps/cris/pspinlock.c: Likewise.
2279 * sysdeps/cris/pt-machine.h: Likewise.
2280 * sysdeps/hppa/pspinlock.c: Likewise.
2281 * sysdeps/hppa/pt-machine.h: Likewise.
2282 * sysdeps/i386/i686/pt-machine.h: Likewise.
2283 * sysdeps/i386/pspinlock.c: Likewise.
2284 * sysdeps/i386/pt-machine.h: Likewise.
2285 * sysdeps/i386/useldt.h: Likewise.
2286 * sysdeps/ia64/pspinlock.c: Likewise.
2287 * sysdeps/ia64/pt-machine.h: Likewise.
2288 * sysdeps/m68k/pspinlock.c: Likewise.
2289 * sysdeps/m68k/pt-machine.h: Likewise.
2290 * sysdeps/mips/pspinlock.c: Likewise.
2291 * sysdeps/mips/pt-machine.h: Likewise.
2292 * sysdeps/powerpc/pspinlock.c: Likewise.
2293 * sysdeps/powerpc/pt-machine.h: Likewise.
2294 * sysdeps/pthread/bits/initspin.h: Likewise.
2295 * sysdeps/pthread/bits/libc-lock.h: Likewise.
2296 * sysdeps/pthread/bits/libc-tsd.h: Likewise.
2297 * sysdeps/pthread/getcpuclockid.c: Likewise.
2298 * sysdeps/pthread/posix-timer.h: Likewise.
2299 * sysdeps/pthread/timer_create.c: Likewise.
2300 * sysdeps/pthread/timer_delete.c: Likewise.
2301 * sysdeps/pthread/timer_getoverr.c: Likewise.
2302 * sysdeps/pthread/timer_gettime.c: Likewise.
2303 * sysdeps/pthread/timer_routines.c: Likewise.
2304 * sysdeps/pthread/timer_settime.c: Likewise.
2305 * sysdeps/pthread/tst-timer.c: Likewise.
2306 * sysdeps/s390/pspinlock.c: Likewise.
2307 * sysdeps/s390/s390-32/pt-machine.h: Likewise.
2308 * sysdeps/s390/s390-64/pt-machine.h: Likewise.
2309 * sysdeps/sh/pspinlock.c: Likewise.
2310 * sysdeps/sh/pt-machine.h: Likewise.
2311 * sysdeps/sparc/sparc32/pspinlock.c: Likewise.
2312 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
2313 * sysdeps/sparc/sparc32/sparcv9/pspinlock.c: Likewise.
2314 * sysdeps/sparc/sparc64/pspinlock.c: Likewise.
2315 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
2316 * sysdeps/unix/sysv/linux/bits/local_lim.h: Likewise.
2317 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
2318 * sysdeps/unix/sysv/linux/bits/sigthread.h: Likewise.
2319 * sysdeps/unix/sysv/linux/hppa/bits/initspin.h: Likewise.
2320 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
2321 * tststack.c: Likewise.
2322 * unload.c: Likewise.
2323 * weaks.c: Likewise.
2324 * wrapsyscall.c: Likewise.
2326 * sysdeps/pthread/pt-initfini.c: Changed copying
2327 permission notice to Lesser GPL from Library GPL, including the
2328 references in the special exception.
2329 * sysdeps/unix/sysv/linux/hppa/pt-initfini.c: Likewise.
2330 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Likewise.
2331 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c:
2333 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c:
2335 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: Likewise.
2337 2002-08-26 Ulrich Drepper <drepper@redhat.com>
2339 * Examples/ex10.c (thread): tv_nsec == 1000000000 is already
2340 overflow [PR libc/4244].
2342 2002-08-25 Ulrich Drepper <drepper@redhat.com>
2344 * sysdeps/pthread/timer_routines.c (thread_func): Make the
2345 compiler happy by adding a return statement which will never be
2348 * tst-context.c (main): Cast to long before casting to pointer.
2350 * Examples/ex17.c (main): Use correct format string.
2352 * Examples/ex9.c (thread): Remove incorrect return statement.
2354 2002-08-23 Ulrich Drepper <drepper@redhat.com>
2356 * pthread.c (__linuxthreads_version): New global constant.
2358 2002-08-23 Andreas Jaeger <aj@suse.de>
2360 * sysdeps/x86_64/pt-machine.h: Use %fs instead of %gs
2361 as thread specific register.
2362 (testandset): Fix inline asm.
2363 (THREAD_GETMEM): Fix inline asm.
2365 2002-08-22 Roland McGrath <roland@redhat.com>
2367 * sysdeps/i386/useldt.h (INIT_THREAD_SELF): Remove [HAVE_TLS_SUPPORT]
2369 (INIT_THREAD_SELF): Pass second arg to DO_SET_THREAD_AREA.
2370 (DO_SET_THREAD_AREA): Take second arg, pass to DO_SET_THREAD_AREA_REUSE
2371 macro. That chooses whether to reuse %gs value or let kernel set it.
2372 [USE_TLS] (DO_SET_THREAD_AREA_REUSE): New macro, always 1.
2373 [!USE_TLS] (DO_SET_THREAD_AREA_REUSE): New macro, true if arg is
2376 2002-08-21 Ulrich Drepper <drepper@redhat.com>
2378 * sysdeps/i386/tls.h (TLS_SETUP_GS_SEGMENT): Add new parameter
2379 also to the third definition of this macro.
2381 2002-06-17 Andreas Jaeger <aj@suse.de>
2383 * sysdeps/unix/sysv/linux/x86_64/Makefile (CFLAGS-pt-initfini.s):
2386 2002-08-20 Ulrich Drepper <drepper@redhat.com>
2388 * sysdeps/i386/useldt.h: Go back to using 16-bit instructions when
2389 loading/reading segment registers. Some old hardware doesn't
2390 handle the 32-bit instructions as expected.
2391 * sysdeps/i386/tls.h: Likewise.
2393 * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Second parameter is
2394 renamed to secondcall and use is negated.
2395 (TLS_SETUP_GS_SEGMENT): Likewise.
2396 (TLS_INIT_TP): Likewise.
2397 * sysdeps/sh/tls.h (TLS_INIT_TP): Second parameter is renamed to
2400 * sysdeps/i386/tls.h: Use 32-bit operations when handling segment
2401 registers. No need to mask upper 16 bits in this case.
2402 * sysdeps/i386/useldt.h: Likewise.
2403 (DO_SET_THREAD_AREA): We have to load %gs again even if the value
2404 is the same since the GDT content changed.
2406 * sysdeps/i386/tls.h (TLS_INIT_TP): Add new parameter and pass it on
2407 to TLS_SETUP_GS_SEGMENT.
2408 (TLS_SETUP_GS_SEGMENT): Add new parameter and pass it on to
2409 TLS_DO_SET_THREAD_AREA.
2410 (TLS_DO_SET_THREAD_AREA): If new parameter is zero determine
2411 entry number from %gs value.
2412 * sysdeps/sh/tls.h (TLS_INIT_TP): Add new parameter and simply
2415 * manager.c (pthread_handle_create): Pass NULL to _dl_allocate_tls.
2416 Pass true to _dl_deallocate_tls.
2417 (pthread_free): Likewise.
2418 * pthread.c (__pthread_initialize_manager): Likewise.
2420 2002-08-19 Ulrich Drepper <drepper@redhat.com>
2422 * sysdeps/i386/useldt.h (DO_SET_THREAD_AREA): Use correct shift when
2423 computing index from %gs value.
2425 2002-08-16 Roland McGrath <roland@redhat.com>
2427 * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Calculate segment
2428 register value from entry number properly.
2430 * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT): Rewrite asm to use %ebx
2431 optimally conditional on [__PIC__].
2432 (TLS_DO_SET_THREAD_AREA): New macro, implement inline syscall
2433 without touching errno, and use latest modify_ldt-like interface.
2434 (TLS_SETUP_GS_SEGMENT): Use that instead of INLINE_SYSCALL.
2435 * sysdeps/i386/useldt.h (DO_MODIFY_LDT): Set %gs in this macro.
2436 (DO_SET_THREAD_AREA): New macro, uses current syscall interface with
2437 existing %gs value as the segment to set.
2438 (INIT_THREAD_SELF): Rewritten using those. Use set_thread_area only
2439 under [HAVE_TLS_SUPPORT] so we can rely on the initialization done
2440 by the first thread's early TLS setup.
2442 2002-08-15 Roland McGrath <roland@redhat.com>
2444 * sysdeps/i386/tls.h (TLS_INIT_TP): Use statement expression and
2445 return a value as callers now expect.
2447 2002-08-11 Roland McGrath <roland@redhat.com>
2449 * pthread.c (__pthread_initialize_manager): Initialize
2450 p_header.data.tcb field of manager thread's descriptor.
2451 (__pthread_initialize_minimal): Don't initialize p_header.data.self
2452 field, already done by TLS_INIT_TP.
2454 * manager.c (pthread_handle_create): Move p_header field initializers
2457 2002-08-08 Ulrich Drepper <drepper@redhat.com>
2459 * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Removed.
2461 2002-08-07 Ulrich Drepper <drepper@redhat.com>
2463 * pthread.c (__linuxthreads_initial_report_events): New variable.
2464 (__pthread_initialize_manager): Use it to initialize p_report_events
2466 [TLS]: Store pointer to descriptor of manager in __pthread_handles.
2468 2002-08-07 Roland McGrath <roland@redhat.com>
2470 * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT): Add an extra argument with
2471 an "m" constraint to the asm so the compiler knows LDT_ENTRY was used.
2473 2002-08-02 Roland McGrath <roland@redhat.com>
2475 * sysdeps/pthread/bits/libc-tsd.h (enum __libc_tsd_key_t):
2476 Add _LIBC_TSD_KEY_LOCALE.
2477 * manager.c (pthread_start_thread) [!(USE_TLS && HAVE___THREAD)]:
2478 Call __uselocale to initialize our per-thread locale pointer to
2480 * pthread.c (__pthread_initialize_minimal): Likewise.
2482 * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Add missing \s.
2484 2002-08-02 Ulrich Drepper <drepper@redhat.com>
2486 * pthread.c: Declare _errno, _h_errno, and _res unless we use TLS
2489 * cancel.c (__pthread_perform_cleanup) [USE_TLS && HAVE___THREAD]:
2490 Don't use p_libc_specific element in thread descriptor.
2492 2002-07-30 Roland McGrath <roland@redhat.com>
2494 * sysdeps/pthread/bits/libc-tsd.h: Include <tls.h>.
2495 [USE_TLS && HAVE___THREAD]: Just include the sysdeps/generic file,
2496 which does the right thing when __thread support is available.
2497 * descr.h (struct _pthread_descr_struct) [USE_TLS && HAVE___THREAD]:
2498 Omit `p_libc_specific', `p_errnop', `p_errno', `p_h_errnop',
2499 `p_h_errno', `p_resp', and `p_res' members.
2500 * pthread.c (__pthread_initialize_minimal) [USE_TLS && HAVE___THREAD]:
2501 Don't initialize `p_errnop' and `p_h_errnop' members.
2502 (__pthread_reset_main_thread): Likewise.
2503 (__pthread_initialize_manager): Likewise.
2504 * manager.c (__pthread_manager, pthread_handle_create): Likewise.
2505 * pthread.c (pthread_initialize) [USE_TLS && HAVE___THREAD]:
2506 Don't initialize `p_resp' member.
2507 (__pthread_reset_main_thread): Likewise.
2508 * manager.c (pthread_handle_create): Likewise.
2509 * specific.c (libc_internal_tsd_set, libc_internal_tsd_get):
2510 Conditionalize these on [!(USE_TLS && HAVE___THREAD)].
2511 * no-tsd.c: Conditionalize contents on [!(USE_TLS && HAVE___THREAD)].
2512 * errno.c [USE_TLS && HAVE___THREAD]
2513 (__h_errno_location, __res_state): Don't define these at all.
2515 * sysdeps/i386/tls.h (INSTALL_DTV): Add parens around arguments!
2516 (INSTALL_NEW_DTV, GET_DTV): Likewise.
2517 * sysdeps/sh/tls.h (INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV): Likewise.
2519 * weaks.c: Don't include <errno.h> here.
2521 2002-08-01 Roland McGrath <roland@redhat.com>
2523 * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT): New macro, broken out of
2525 (TLS_DO_SET_THREAD_AREA): New macro, uses thread_set_area syscall.
2526 (TLS_SETUP_GS_SEGMENT): New macro, try one or the other or both.
2527 (TLS_INIT_TP): Use that.
2529 2002-08-02 Jakub Jelinek <jakub@redhat.com>
2531 * sysdeps/i386/useldt.h (DO_MODIFY_LDT): Move from INIT_THREAD_SELF.
2532 (INIT_THREAD_SELF): Use sys_thread_area syscall instead if available.
2533 (FREE_THREAD): Avoid modify_ldt if using GDT.
2534 * sysdeps/i386/pspinlock.c (__have_no_set_thread_area): New variable.
2536 2002-07-25 Jakub Jelinek <jakub@redhat.com>
2538 * sysdeps/i386/tls.h: Use __ASSEMBLER__ test macro not ASSEMBLER.
2539 * sysdeps/i386/pt-machine.h: Likewise.
2540 * sysdeps/i386/useldt.h: Likewise.
2542 2002-07-22 Ulrich Drepper <drepper@redhat.com>
2544 * pthread.c (__pthread_initialize_minimal): If !SHARED and TLS
2545 call __libc_setup_tls first.
2546 * Makefile: Actually create tst-signal.out file when running the test.
2547 (tests): Add tststatic.
2548 * Examples/tststatic.c: New file.
2550 2002-07-19 Ulrich Drepper <drepper@redhat.com>
2552 * errno.c (__errno_location): Don't define unless !USE_TLS
2554 * sysdeps/i386/pt-machine.c: Protect C code with #ifndef ASSEMBLER.
2555 * sysdeps/i386/tls.h: Likewise.
2556 * sysdeps/i386/useldt.h: Likewise.
2557 * sysdeps/i386/i686/pt-machine.h: Likewise.
2559 2002-07-02 H.J. Lu <hjl@gnu.org>
2561 * sysdeps/mips/pspinlock.c: Don't include <sgidefs.h>. Always
2563 * sysdeps/mips/pt-machine.h: Likewise.
2565 2002-07-14 Ulrich Drepper <drepper@redhat.com>
2567 * manager.c (pthread_handle_create): Initialize self-reference in
2570 2002-07-01 Jakub Jelinek <jakub@redhat.com>
2572 * Examples/ex9.c (main): Remove unused th variable.
2574 2002-07-10 Ulrich Drepper <drepper@redhat.com>
2576 * wrapsyscall.c: Add __nanosleep alias.
2577 * Versions (GLIBC_2.2.6): Add __nanosleep.
2578 * bug-sleep.c: New file.
2579 * Makefile (tests): Add bug-sleep.
2581 2002-06-19 Steven Munroe <sjmunroe@vnet.ibm.com>
2583 * Examples/ex9.c (main): Use list of children and join them.
2584 (thread): Do not call exit.
2586 2002-06-20 Ulrich Drepper <drepper@redhat.com>
2588 * spinlock.c (wait_node_alloc): We cannot use compare-and-exchange.
2589 Unconditionally use the code using spinlock. Use __pthread_release
2591 (wait_node_free): Likewise.
2592 (__pthread_acquire, __pthread_release): Unconditionally define.
2594 2002-06-07 Jakub Jelinek <jakub@redhat.com>
2596 * sysdeps/ia64/pt-machine.h (MEMORY_BARRIER): Fix typo.
2598 2002-05-24 Ulrich Drepper <drepper@redhat.com>
2600 * sysdeps/ia64/pt-machine.h (MEMORY_BARRIER): Use __sync_synchronize.
2602 2002-05-21 Ulrich Drepper <drepper@redhat.com>
2604 * sysdeps/pthread/pthread.h (pthread_create): Rename first
2606 (pthread_cancel): Likewise.
2607 * internals.h (__pthread_create_2_1): Likewise.
2608 * sysdeps/unix/sysv/linux/bits/sigthread.h (pthread_kill): Likewise.
2610 2002-05-20 Ulrich Drepper <drepper@redhat.com>
2612 * sysdeps/alpha/pt-machine.c (THREAD_SELF): Remove clobber.
2613 Patch by Glen Nakamura <gen@flex.com>.
2615 2002-05-03 Ulrich Drepper <drepper@redhat.com>
2617 * signals.c: Move sighandler functions to...
2618 * sighandler.c: ...here. New file.
2619 * signals.c: Move signal handler related type definitions to...
2620 * internals.h: ...here. Add prototypes for signal handlers.
2621 * Makefile (libpthread-routines): Add sighandler.
2622 (CFLAGS-sighandler.c): Add $(exceptions).
2624 2002-04-30 Jakub Jelinek <jakub@redhat.com>
2626 * sysdeps/unix/sysv/linux/x86_64/Makefile: New file.
2628 2002-04-08 Ulrich Drepper <drepper@redhat.com>
2630 * sysdeps/pthread/timer_getoverr.c: Return real overrun.
2631 * sysdeps/pthread/posix-timer.h (struct timer_node): Add overrun_count.
2632 * sysdeps/pthread/timer_routines.c (thread_func): Schedule next timeout
2633 based on previous one and not on current time. Count overruns.
2634 Patch by Eric F. Sorton <eric@cctcorp.com>.
2636 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add DELAYTIMER_MAX.
2638 2002-04-08 kaz Kojima <kkojima@rr.iij4u.or.jp>
2640 * sysdeps/sh/pt-machine.h: Define _PT_MACHINE_H
2641 if it isn't defined yet.
2642 (FLOATING_STACKS, ARCH_STACK_MAX_SIZE): Defined.
2643 (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM, THREAD_SETMEM_NC):
2645 * sysdeps/sh/tls.h: New file.
2647 2002-04-08 Jakub Jelinek <jakub@redhat.com>
2649 * manager.c (__pthread_manager_event): Use self instead of arg
2650 for INIT_THREAD_SELF.
2651 * sysdeps/i386/useldt.h (INIT_THREAD_SELF): Use sizeof (struct
2652 _pthread_descr_struct) instead of sizeof (*descr).
2654 2002-04-05 Ulrich Drepper <drepper@redhat.com>
2656 * sysdeps/ia64/pt-machine.h: Protect against multiple inclusion.
2657 * sysdeps/alpha/pt-machine.h: Likewise.
2658 * sysdeps/arm/pt-machine.h: Likewise.
2659 * sysdeps/cris/pt-machine.h: Likewise.
2660 * sysdeps/hppa/pt-machine.h: Likewise.
2661 * sysdeps/m68k/pt-machine.h: Likewise.
2662 * sysdeps/mips/pt-machine.h: Likewise.
2663 * sysdeps/powerpc/pt-machine.h: Likewise.
2664 * sysdeps/s390/s390-32/pt-machine.h: Likewise.
2665 * sysdeps/s390/s390-64/pt-machine.h: Likewise.
2666 * sysdeps/sh/pt-machine.h: Likewise.
2667 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
2668 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
2669 * sysdeps/x86_64/pt-machine.h: Likewise.
2671 2002-04-05 Jakub Jelinek <jakub@redhat.com>
2673 * man/pthread_mutexattr_init.man (pthread_mutexattr_settype): Document
2674 instead of pthread_mutexattr_setkind_np.
2675 (pthread_mutexattr_gettype): Similarly.
2676 * man/pthread_mutexattr_setkind_np.man: New.
2677 * man/Makefile (SOURCES): Add pthread_mutexattr_setkind_np.man.
2679 2002-04-02 Ulrich Drepper <drepper@redhat.com>
2681 * sysdeps/ia64/pt-machine.h (MEMORY_BARRIER): Define.
2683 2002-03-22 Jakub Jelinek <jakub@redhat.com>
2685 * sysdeps/mips/pt-machine.h (MEMORY_BARRIER): Remove.
2687 2002-03-22 Ulrich Drepper <drepper@redhat.com>
2689 * internals.h (MEMORY_BARRIER): Define as asm with memory as clobber.
2691 2002-03-17 Andreas Jaeger <aj@suse.de>
2693 * sysdeps/i386/pt-machine.h: Add testandset and __compare_and_swap
2695 * sysdeps/alpha/pt-machine.h: Likewise.
2696 * sysdeps/arm/pt-machine.h: Likewise.
2697 * sysdeps/cris/pt-machine.h: Likewise.
2698 * sysdeps/hppa/pt-machine.h: Likewise.
2699 * sysdeps/i386/i686/pt-machine.h: Likewise.
2700 * sysdeps/ia64/pt-machine.h: Likewise.
2701 * sysdeps/m68k/pt-machine.h: Likewise.
2702 * sysdeps/mips/pt-machine.h: Likewise.
2703 * sysdeps/powerpc/pt-machine.h: Likewise.
2704 * sysdeps/s390/s390-32/pt-machine.h: Likewise.
2705 * sysdeps/s390/s390-64/pt-machine.h: Likewise.
2706 * sysdeps/sh/pt-machine.h: Likewise.
2707 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
2708 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
2709 * sysdeps/x86_64/pt-machine.h: Likewise.
2711 * internals.h: Move testandset and __compare_and_swap prototypes
2714 2002-03-03 Andreas Jaeger <aj@suse.de>
2716 * errno.c: Include resolv.h to avoid warning.
2718 2002-02-27 Ulrich Drepper <drepper@redhat.com>
2720 * pthread.c [USE_TLS] (thread_self_stack): Correct check for upper
2723 2002-02-23 Ulrich Drepper <drepper@redhat.com>
2725 * attr.c (pthread_getattr_np): Don't take thread descriptor size
2726 into account if USE_TLS.
2727 * manager.c (pthread_handle_create): Free TLS data structures if call
2728 failed. Pass correct stack to clone if USE_TLS.
2729 * sysdeps/i386/pt-machine.h: Handle multiple inclusion.
2730 * sysdeps/i386/i686/pt-machine.h: Likewise.
2731 * sysdeps/i386/tls.h: Unconditionally include <pt-machine.h>.
2733 * descr.h (struct _pthread_descr_struct): Update p_header for TLS.
2734 Add p_stackaddr element #if USE_TLS.
2735 * internals.c: Include <tls.h>.
2736 * manager.c: Integrate creating and handling of thread descriptor
2738 * pthread.c: Likewise.
2739 * sysdeps/i386/tls.h (tcbhead_t): Add self pointer.
2740 Include <linuxthreads/descr.h> only if TLS is really used.
2741 (GET_DTV): New macro.
2742 (TLS_INIT_TP): Initialize self pointer.
2744 2002-02-17 Andreas Schwab <schwab@suse.de>
2746 * signals.c (sigwait): Check for old sighandler being SIG_ERR,
2749 2002-02-12 Ulrich Drepper <drepper@redhat.com>
2751 * sysdeps/i386/tls.c (INSTALL_NEW_DTV): Define.
2752 (INSTALL_DTV): Adjust for being passed pointer to element with length.
2754 2002-02-08 Ulrich Drepper <drepper@redhat.com>
2756 * sysdeps/i386/tls.h (TLS_INIT_TP): Also initialize %gs.
2758 2002-02-08 Richard Henderson <rth@redhat.com>
2760 * sysdeps/alpha/elf/pt-initfini.c: Use \n\ for multiline string.
2762 2002-02-08 Ulrich Drepper <drepper@redhat.com>
2764 * sysdeps/i386/tls.h: TLS cannot be supported with FLOATING_STACKS
2767 2002-02-07 H.J. Lu <hjl@gnu.org>
2769 * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Silence the
2771 (__pthread_spin_lock): Remove ".set noreorder".
2772 * sysdeps/mips/pt-machine.h (__compare_and_swap): Liekwise.
2774 2002-02-05 H.J. Lu <hjl@gnu.org>
2776 * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Not use
2778 * sysdeps/mips/pt-machine.h (testandset): Likewise.
2779 (__compare_and_swap): Likewise.
2781 2002-02-07 Ulrich Drepper <drepper@redhat.com>
2783 * internals.h: Move declarations/definitions of
2784 __pthread_initial_thread_bos, __pthread_initial_thread,
2785 __pthread_manager_thread_bos, __pthread_manager_thread_tos,
2786 __pthread_manager_thread, __pthread_nonstandard_stacks, STACK_SIZE,
2787 CURRENT_STACK_FRAME, __pthread_find_self, and thread_self...
2789 * sysdeps/i386/tls.h: Add TLS definitions also for !FLOATING_STACKS.
2790 Define THREAD_GETMEM accordingly.
2792 2002-02-06 Ulrich Drepper <drepper@redhat.com>
2794 * sysdeps/i386/tls.h: Include <stddef.h> for size_t.
2796 * sysdeps/i386/tls.h: Define THREAD_DTV.
2798 2002-02-04 Ulrich Drepper <drepper@redhat.com>
2800 * internals.h: Move thread descriptor definition...
2801 * descr.h.: ...here. New file.
2802 * sysdeps/i386/tls.h: New file.
2804 2002-02-01 H.J. Lu <hjl@gnu.org>
2806 * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Use a
2807 different register in the delayed slot. Use branch likely.
2809 * sysdeps/mips/pt-machine.h (testandset): Call _test_and_set.
2810 (__compare_and_swap): Return 0 only when failed to compare. Use
2813 2002-02-01 Jakub Jelinek <jakub@redhat.com>
2815 * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set,
2816 __pthread_kill_other_threads_np): Move to GLIBC_PRIVATE.
2817 * sysdeps/i386/i586/Versions: Move all symbols to GLIBC_PRIVATE.
2818 * sysdeps/i386/i686/Versions: Move all symbols to GLIBC_PRIVATE.
2819 * sysdeps/sparc/sparc32/sparcv9/Versions: New file.
2820 * sysdeps/sparc/sparc64/Versions: New file.
2821 * sysdeps/ia64/Versions: Move all symbols to GLIBC_PRIVATE.
2823 2002-01-31 Ulrich Drepper <drepper@redhat.com>
2825 * pthread.c: _dl_cpuclock_offset is not any longer a global variable
2826 in SHARED code, use GL(dl_cpuclock_offset).
2828 2002-01-28 Andreas Jaeger <aj@suse.de>
2830 * sysdeps/mips/pspinlock.c (__pthread_spin_init): Clear *LOCK to
2831 0. Patch by Machida Hiroyuki <machida@sm.sony.co.jp>.
2833 2002-01-16 Martin Schwidefsky <schwidefsky@de.ibm.com>
2835 * sysdeps/s390/s390-32/pt-machine.h (MEMORY_BARRIER): Define.
2836 (CURRENT_STACK_FRAME): Remove duplicate definition.
2837 * sysdeps/s390/s390-64/pt-machine.h: Likewise.
2839 2002-01-14 Martin Schwidefsky <schwidefsky@de.ibm.com>
2841 * Makefile (CFLAGS-tst-cancel.c): Add -fno-inline-functions to prevent
2844 2002-01-12 Andreas Schwab <schwab@suse.de>
2846 * Makefile (test-srcs): Add tst-signal.
2847 (tests): Run tst-signal.
2848 (distribute): Add tst-signal.sh.
2849 * tst-signal.c, tst-signal.sh: New files.
2851 2002-01-14 Andreas Jaeger <aj@suse.de>
2853 * sysdeps/x86_64/pt-machine.h (INIT_THREAD_SELF): Avoid warning.
2855 2002-01-11 Andreas Schwab <schwab@suse.de>
2857 * signals.c (sighandler): Initialize all elements to SIG_ERR.
2858 (__sigaction): Don't use value from sighandler if it is SIG_ERR.
2860 2002-01-06 Richard Henderson <rth@redhat.com>
2862 * sysdeps/alpha/elf/pt-initfini.c: New file.
2864 2001-12-29 Andreas Jaeger <aj@suse.de>
2866 * Examples/ex9.c: Add noreturn attribute for thread.
2867 * Examples/ex10.c: Likewise.
2868 * Examples/ex13.c (thread_start): Likewise.
2869 * Examples/ex15.c (worker): Likewise.
2871 * Examples/ex18.c: Include unistd.h for prototype of sleep.
2873 2001-12-14 Ulrich Drepper <drepper@redhat.com>
2875 * man/pthread_atfork.man: Adjust description of mutex handling
2876 after fork for current implementation.
2877 * linuxthreads.texi: Likewise [PR libc/2519].
2879 2001-12-13 Andreas Schwab <schwab@suse.de>
2881 * specific.c (pthread_key_delete): Don't contact the thread
2882 manager if no threads have been created yet.
2884 2001-12-12 NIIBE Yutaka <gniibe@m17n.org>
2886 * sysdeps/sh/pt-machine.h (INIT_THREAD_SELF): Added __volatile__
2887 qualifier to be safe.
2889 2001-11-30 Andreas Schwab <schwab@suse.de>
2891 * pthread.c (pthread_handle_sigcancel) [THREAD_SELF]: Double check
2892 that self is the manager thread, and initialize the thread
2894 (thread_self_stack) [THREAD_SELF]: New function to find self via
2896 * manager.c (pthread_handle_create): Don't block cancel signal any
2899 2001-11-29 Andreas Jaeger <aj@suse.de>
2901 * sysdeps/x86_64/pt-machine.h: Use %gs as thread specific register.
2903 (INIT_THREAD_SELF): New.
2904 (THREAD_GETMEM): New.
2906 (THREAD_SETMEM): New.
2907 (THREAD_SETMEM_NC): New.
2908 (FLOATING_STACKS): Define.
2909 (ARCH_STACK_MAX_SIZE): Define.
2911 2001-11-28 Kaz Kylheku <kaz@ashi.footprints.net>
2913 Bugfix to pthread_key_delete. It was iterating over the thread
2914 manager's linked list of threads, behind the thread manager's
2915 back causing a race. The fix is to have the manager iterate over
2916 the threads instead, using a new request type for doing so.
2917 * internals.h (struct pthread_request): New manager request type
2918 REQ_FOR_EACH_THREAD.
2919 * manager.c (pthread_for_each_thread): New function.
2920 (__pthread_manager): Handle new REQ_FOR_EACH_THREAD request.
2921 * specific.c (struct pthread_key_delete_helper_args): New type.
2922 (pthread_key_delete_helper): New static function.
2923 (pthread_key_delete): Use the new thread manager
2924 REQ_FOR_EACH_THREAD function to iterate over the threads and set
2925 the delete key slot to a null value in each thread.
2926 * Examples/ex18.c: New test.
2927 * Makefile (tests): Add ex18.
2929 2001-11-22 Wolfram Gloger <wg@malloc.de>
2931 * pthread.c (pthread_onexit_process): Don't call free
2932 after threads have been asynchronously terminated.
2934 * manager.c (pthread_handle_exit): Surround cancellation
2935 of threads with __flockfilelist()/__funlockfilelist().
2937 2001-11-26 Andreas Schwab <schwab@suse.de>
2939 * manager.c (pthread_handle_create): Start the child thread with
2940 the cancel signal blocked, so that it does not handle it before
2941 the thread register is set up. Save errno from failed clone call.
2943 2001-11-15 Ulrich Drepper <drepper@redhat.com>
2945 * sysdeps/i386/i686/Implies: Removed.
2946 * sysdeps/i386/i686/Versions: New file.
2948 2001-10-31 Andreas Jaeger <aj@suse.de>
2950 * sysdeps/x86_64/Makefile: Remove, we do not need it anymore.
2952 2001-10-05 Kevin Buettner <kevinb@cygnus.com>
2954 * pthread.c (__linuxthread_pthread_sizeof_descr): Change name
2955 to __linuxthreads_pthread_sizeof_descr to match name used by
2956 symbol_list_arr[LINUXTHREADS_PTHREAD_SIZEOF_DESCR] in
2957 linuxthreads_db/td_symbol_list.c.
2959 2001-09-22 Andreas Jaeger <aj@suse.de>
2961 * linuxthreads/tst-context.c: Avoid compile warning.
2963 2001-09-20 Andreas Jaeger <aj@suse.de>
2965 * shlib-versions: Add x86-64.
2967 2001-09-19 Andreas Jaeger <aj@suse.de>
2969 * sysdeps/x86_64/Makefile: New file.
2970 * sysdeps/x86_64/pspinlock.c: New file.
2971 * sysdeps/x86_64/pt-machine.h: New file.
2973 2001-09-12 Jakub Jelinek <jakub@redhat.com>
2975 * sysdeps/pthread/timer_delete.c (timer_delete): Thread may be NULL
2977 * sysdeps/pthread/timer_settime.c (timer_settime): Likewise.
2979 2001-09-11 Ulrich Drepper <drepper@redhat.com>
2980 Wolfram Gloger <wg@malloc.de>
2982 * join.c: Protect all communications from and to manager with
2984 * manager.c: Likewise.
2985 * pthread.c: Likewise.
2986 * smeaphore.c: Likewise.
2988 2001-08-29 Ulrich Drepper <drepper@redhat.com>
2990 * spinlock.c (__pthread_lock): Top max_count value with
2991 MAX_ADAPTIVE_SPIN_COUNT.
2992 * internals.h (MAX_ADAPTIVE_SPIN_COUNT): Define if not already done.
2994 * sysdeps/i386/i686/pt-machine.h (BUSY_WAIT_NOP): New macro to
2997 2001-08-27 Jakub Jelinek <jakub@redhat.com>
2999 * sysdeps/pthread/bits/libc-lock.h (__libc_rwlock_t): Only define to
3000 non-opaque type if __USE_UNIX98.
3002 2001-08-26 Jakub Jelinek <jakub@redhat.com>
3004 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_t): Define
3005 non-opaque lock types also if _IO_MTSAFE_IO is defined.
3007 2001-08-23 Roland McGrath <roland@frob.com>
3009 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start): Take
3010 new first argument, skip the cleanup handler if it's zero.
3011 (_LIBC_LOCK_RECURSIVE_INITIALIZER): New macro.
3012 (__libc_lock_define_initialized_recursive): Use it.
3013 * sysdeps/pthread/bits/stdio-lock.h: File removed.
3014 The sysdeps/generic file from the main tree now suffices.
3016 2001-08-22 Roland McGrath <roland@frob.com>
3018 * sysdeps/pthread/bits/stdio-lock.h: Include <bits/libc-lock.h>
3019 instead of <pthread.h>.
3020 (_IO_lock_t): Define this typedef using __libc_lock_define_recursive.
3021 (_IO_lock_initializer): Add braces.
3022 (_IO_lock_lock): Use __libc_lock_lock_recursive.
3023 (_IO_lock_unlock): Use __libc_lock_unlock_recursive.
3025 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_recursive_t): New type.
3026 (__libc_lock_define_initialized_recursive): Use it.
3027 (__libc_lock_init_recursive): Likewise.
3028 (__libc_lock_fini_recursive): Likewise.
3029 (__libc_lock_lock_recursive): Likewise.
3030 (__libc_lock_trylock_recursive): Likewise.
3031 (__libc_lock_unlock_recursive): Likewise.
3032 (__libc_lock_define_recursive): New macro.
3034 2001-08-14 Jakub Jelinek <jakub@redhat.com>
3036 * lockfile.c (__pthread_provide_lockfile): New variable.
3037 * pthread.c (__pthread_require_lockfile): New variable.
3038 * cancel.c (__pthread_require_lockfile): New variable.
3040 2001-07-31 Ulrich Drepper <drepper@redhat.com>
3042 * tst-context.c (threadfct): Initialize context before calling
3045 * Examples/ex17.c: Make sure test thread is around long enough.
3047 2001-07-26 kaz Kojima <kkojima@rr.iij4u.or.jp>
3049 * sysdeps/sh/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF): Defined.
3051 2001-07-24 Ulrich Drepper <drepper@redhat.com>
3053 * tst-context.c (main): Print explanation before bailing out
3054 because context handling is not supported.
3056 2001-07-23 Ulrich Drepper <drepper@redhat.com>
3058 * Makefile (tests): Add tst-context.
3059 * tst-context.c: New file.
3061 * sysdeps/pthread/bits/stdio-lock.h: Define
3062 _IO_cleanup_region_start_noarg.
3064 2001-07-23 Jakub Jelinek <jakub@redhat.com>
3066 * sysdeps/alpha/pt-machine.h (FLOATING_STACKS): Define.
3067 (ARCH_STACK_MAX_SIZE): Define.
3068 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
3069 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
3071 2001-07-19 Jakub Jelinek <jakub@redhat.com>
3073 * sysdeps/i386/useldt.h: Fix typo in ARCH_STACK_MAX_SIZE comment.
3075 * sysdeps/ia64/pt-machine.h (FLOATING_STACKS): Define.
3076 (ARCH_STACK_MAX_SIZE): Define.
3077 * manager.c (pthread_allocate_stack): Handle FLOATING_STACKS with
3078 NEED_SEPARATE_REGISTER_STACK.
3080 2001-07-16 Andreas Schwab <schwab@suse.de>
3082 * Makefile (before-compile): Don't add $(objpfx)crti.o.
3083 (omit-deps): Add crti.
3084 ($(objpfx)libpthread.so): Depend on $(objpfx)crti.o, but make sure
3085 it is filtered out of the link command.
3087 2001-07-16 Ulrich Drepper <drepper@redhat.com>
3089 * pthread.c (pthread_initialize): For FLOATING_STACKS don't bother
3090 to find the right value for __pthread_initial_thread_bos, it's not
3091 used. If not FLOATING_STACKS first run
3092 __pthread_init_max_stacksize.
3094 2001-06-16 H.J. Lu <hjl@gnu.org>
3096 * internals.h: Include <stackinfo.h>.
3098 * attr.c: Don't include <stackinfo.h> here.
3099 * cancel.c: Likewise.
3100 * manager.c: Likewise.
3101 * pthread.c: Likewise.
3102 * ptlongjmp.c: Likewise.
3104 2001-03-23 Matthew Wilcox <willy@ldl.fc.hp.com>
3106 * attr.c: Make _STACK_GROWS_UP work.
3107 * internals.h: Likewise.
3108 * manager.c: Likewise.
3109 * pthread.c: Likewise.
3111 2001-06-15 H.J. Lu <hjl@gnu.org>
3113 * pthread.c (__pthread_reset_main_thread): Fix a typo.
3115 2001-02-02 John S. Marvin <jsm@udlkern.fc.hp.com>
3117 * semaphore.h: Use struct _pthread_fastlock as an element of
3118 sem_t instead of an identical struct.
3119 * rwlock.c: Remove casts.
3120 * semaphore.c: Likewise.
3122 2001-04-30 Alan Modra <amodra@one.net.au>
3124 * sysdeps/unix/sysv/linux/hppa/pt-initfini.c: New.
3126 2001-05-25 Bruce Mitchener <bruce@cubik.org>
3128 * linuxthreads.texi: Spelling corrections.
3130 2001-05-25 Ulrich Drepper <drepper@redhat.com>
3132 * oldsemaphore.c (__old_sem_wait): Clear p_nextwaiting before
3133 returning successfully.
3134 Patch by Gene Cooperman <gene@ccs.neu.edu>.
3136 2001-05-24 Ulrich Drepper <drepper@redhat.com>
3138 * spinlock.c (__pthread_lock) [HAS_COMPARE_AND_SWAP]: Before doing any
3139 serious work try once whether the lock is uncontested.
3140 Remove duplicate reading of __status before loop.
3141 Change suggested by Hans Boehm <hans_boehm@hp.com>.
3143 * spinlock.h (__pthread_trylock): Remove need for oldstatus variable.
3144 (__pthread_alt_trylock): Likewise.
3146 2001-05-01 Kaz Kylheku <kaz@ashi.footprints.net>
3148 Memory barrier overhaul following line by line inspection.
3149 * mutex.c (pthread_once): Missing memory barriers added.
3150 * pthread.c (__pthread_wait_for_restart_signal,
3151 __pthread_timedsuspend_new, __pthread_restart_new): Added
3152 memory barriers ``just in case'' and for documentary value.
3153 * spinlock.c (__pthread_release): New inline function for releasing
3154 spinlock, to complement __pthread_acquire. Includes memory
3155 barrier prior to assignment to spinlock, and __asm __volatile
3156 dance to prevent reordering or optimization of the spinlock access.
3157 * spinlock.c (__pthread_unlock, __pthread_alt_lock,
3158 __pthread_alt_timedlock, __pthread_alt_unlock,
3159 __pthread_compare_and_swap): Updated to use new __pthread_release
3160 instead of updating spinlock directly.
3161 * spinlock.c (__pthread_lock, __pthread_unlock, wait_node_alloc,
3162 wait_node_free, wait_node_dequeue, __pthread_alt_lock,
3163 __pthread_alt_timedlock, __pthread_alt_unlock, __pthread_acquire):
3164 Memory barrier overhaul. Lots of missing memory barriers added,
3165 a couple needless ones removed.
3166 * spinlock.c (__pthread_compare_and_swap): testandset optimization
3167 removed, just calls __pthread_acquire, which has the new read
3168 barrier in it before its testandset.
3170 2001-05-20 Roland McGrath <roland@frob.com>
3172 * Makeconfig: New file, variables used to be in main libc Makeconfig.
3174 2001-05-09 Geoff Keating <geoffk@redhat.com>
3176 * sysdeps/powerpc/pt-machine.h
3177 (HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS): Define.
3178 (__compare_and_swap): Remove memory barriers.
3179 (__compare_and_swap_with_release_semantics): New function.
3181 2001-04-24 Andreas Jaeger <aj@suse.de>
3183 * wrapsyscall.c: send* and recv* return ssize_t.
3185 * sysdeps/pthread/timer_getoverr.c (timer_getoverrun): Unlock the
3186 mutex instead of double locking it.
3187 Reported by Pierre Artaud <partaud@sodatec.com>.
3189 2001-04-23 Ulrich Drepper <drepper@redhat.com>
3191 * sysdeps/pthread/getcpuclockid.c: Make function generic, test
3192 using #ifdef whether the clock is available.
3193 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c: Removed.
3195 * sysdeps/ia64/Versions: New file.
3197 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c (_init): We don't
3198 have to call __gmon_start__ in the libpthread DSO.
3199 * sysdeps/pthread/pt-initfini.c (_init): Likewise.
3201 * Makefile (libpthread-routines): Add ptclock_gettime and
3203 * internals.h: Don't use cpuclock-init.h definitions, use
3204 hp-timing.h definitions.
3205 * pthread.c: Likewise.
3206 * manager.c: Likewise.
3207 * ptclock_gettime.c: New file.
3208 * ptclock_settime.c: New file.
3209 * internals.h: Fix parameter type for __pthread_clock_gettime and
3210 __pthread_clock_settime.
3212 * sysdeps/i386/i586/ptclock_gettime.c: Removed.
3213 * sysdeps/i386/i586/ptclock_settime.c: Removed.
3214 * sysdeps/i386/i586/Makefile: Removed.
3216 2001-04-22 Ulrich Drepper <drepper@redhat.com>
3218 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define _POSIX_ASYNCH_IO.
3219 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
3221 2001-04-21 Andreas Jaeger <aj@suse.de>
3223 * sysdeps/pthread/timer_routines.c (thread_func): Add noreturn
3224 attribute, remove statements that will never be executed.
3225 (thread_func): Remove mutex_unlock call since it's never executed.
3226 (thread_func): Fix comment as suggested by Jakub Jelinek.
3228 * manager.c (__pthread_manager): Add noreturn
3230 (pthread_start_thread): Likewise, remove return statement.
3231 (pthread_start_thread_event): Likewise.
3232 Add noreturn attribute for pthread_handle_exit.
3233 * weaks.c: Add noreturn attribute for pthread_exit.
3235 * internals.h: Add __pthread_clock_gettime and
3236 __pthread_clock_settime prototypes.
3238 2001-04-21 Ulrich Drepper <drepper@redhat.com>
3240 * internals.h: Include <cpuclock-init.h>.
3241 (struct _pthread_descr_struct): Add p_cpuclock_offset field if
3242 CPUCLOCK_VARDEF is defined.
3243 * pthread.c (__pthread_initialize_minimal): Initialize
3244 p_cpuclock_offset field for main thread if CPUCLOCK_INIT is defined.
3245 * manager.c (pthread_start_thread): Set p_cpuclock_offset field
3246 for new thread to current CPU clock value.
3248 * sysdeps/i386/useldt.h: Extend all the macros to handle 8-byte values.
3250 * sysdeps/i386/i586/Makefile: New file.
3251 * sysdeps/i386/i586/Versions: New file.
3252 * sysdeps/i386/i586/ptclock_gettime.c: New file.
3253 * sysdeps/i386/i586/ptclock_settime.c: New file.
3254 * sysdeps/i386/i686/Implies: New file.
3256 2001-04-18 Jakub Jelinek <jakub@redhat.com>
3258 * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: Put specs into
3259 $generated, not $postclean-generated.
3261 2001-04-18 Andreas Jaeger <aj@suse.de>
3263 * Makefile (otherlibs): Added.
3265 2001-04-18 Jakub Jelinek <jakub@redhat.com>
3267 * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: New file.
3269 2001-04-16 Ulrich Drepper <drepper@redhat.com>
3271 * signals.c (sigwait): NSIG is no signal number. Block all
3272 signals while in signal handler for signals in SET.
3273 Patch by Manfred Spraul <manfred@colorfullife.com>.
3275 2001-04-12 Ulrich Drepper <drepper@redhat.com>
3277 * tst-cancel.c: Disable most tests. Add new test where all
3278 cleanup handlers must run.
3279 * Makefile (tests): Add tst-cancel again.
3281 * cancel.c (__pthread_perform_cleanup): Correct condition for
3282 leaving cleanup loop early.
3284 * sysdeps/i386/Makefile: Make sure gcc uses a frame pointer for
3285 all the files which use CURRENT_STACK_FRAME.
3286 * sysdeps/i386/pt-machine.h (CURRENT_STACK_FRAME): Define using
3287 __builtin_frame_address.
3288 * sysdeps/i386/i686/pt-machine.h: Likewise.
3290 2001-04-11 Ulrich Drepper <drepper@redhat.com>
3292 * Makefile (tests): Comment out tst-cancel for now.
3294 * tst-cancel.c (main): Cleanup 4 is supposed to run. Create
3295 temporary file in object directory.
3296 * Makefile: Don't allow inlining when compiling tst-cancel.c.
3297 Pass $(objpfx) to tst-cancel.
3299 2001-04-11 David S. Miller <davem@redhat.com>
3301 * sysdeps/sparc/sparc32/pt-machine.h (stack_pointer): Advance
3302 up closer to user local variables so that new cleanup heuristics work.
3303 * sysdeps/sparc/sparc64/pt-machine.h (stack_pointer): Likewise.
3305 2001-04-11 Ulrich Drepper <drepper@redhat.com>
3307 * cancel.c (_pthread_cleanup_push): Catch invalid __prev buffer
3309 (_pthread_cleanup_push_defer): Likewise.
3311 * tst-cancel.c (main): Fix loop printing cleanup output.
3313 2001-04-10 kaz Kojima <kkojima@rr.iij4u.or.jp>
3315 * sysdeps/sh/pspinlock.c (__pthread_spin_lock): Fix a reverse
3317 (__pthread_spin_trylock): Likewise.
3318 * sysdeps/sh/pt-machine.h (testandset): Likewise.
3320 2001-04-10 Ulrich Drepper <drepper@redhat.com>
3322 * join.c (pthread_exit): Move code to new function __pthread_do_exit
3323 which takes an extra parameter with the current frame pointer.
3324 Call new function with CURRENT_STACK_FRAME.
3325 (__pthread_do_exit): New function. Call __pthread_perform_cleanup
3326 with the new parameter.
3327 (pthread_join): Call __pthread_do_exit instead of pthread_exit.
3328 * cancel.c (__pthread_perform_cleanup): Takes extra parameter. Use
3329 this parameter as the initial value the cleanup handler records are
3330 compared against. No active cleanup handler record must have an
3331 address lower than the previous one and the initial record must be
3332 above (below on PA) the frame address passed in.
3333 (pthread_setcancelstate): Call __pthread_do_exit instead of
3335 (pthread_setcanceltype): Likewise.
3336 (pthread_testcancel): Likewise.
3337 (_pthread_cleanup_pop_restore): Likewise.
3338 * condvar.c (pthread_cond_wait): Likewise.
3339 (pthread_cond_timedwait_relative): Likewise.
3340 * manager.c (pthread_start_thread): Likewise.
3341 * oldsemaphore.c (__old_sem_wait): Likewise.
3342 * pthread.c (pthread_handle_sigcancel): Likewise.
3343 * semaphore.c (__new_sem_wait): Likewise.
3344 (sem_timedwait): Likewise.
3345 * ptlongjmp.c (pthread_cleanup_upto): Also use current stack frame
3346 to limit the cleanup handlers which get run.
3347 * internals.h: Add prototype for __pthread_do_exit. Adjust prototype
3348 for __pthread_perform_cleanup.
3350 * Makefile (tests): Add tst-cancel.
3351 * tst-cancel.c: New file.
3353 2001-04-08 Hans-Peter Nilsson <hp@axis.com>
3355 * sysdeps/cris/pt-machine.h: New file.
3356 * sysdeps/cris/pspinlock.c: New file.
3358 2001-04-09 Hans-Peter Nilsson <hp@axis.com>
3360 * shlib-versions: Add case for Linux on CRIS.
3362 2001-03-26 Ulrich Drepper <drepper@redhat.com>
3364 * attr.c (pthread_getattr_np): Correct computation of stack size
3365 for machiens with register stack.
3367 * Examples/ex17.c (main): Correct detection of failed mmap call.
3369 2001-03-21 Jakub Jelinek <jakub@redhat.com>
3371 * pthread.c (__pthread_initialize_manager): Fix a typo.
3373 2001-03-21 Jakub Jelinek <jakub@redhat.com>
3375 * attr.c (__pthread_attr_setstack): Fix alignment check.
3376 (pthread_getattr_np): __stackaddr is top of stack, not bottom.
3377 * Makefile (tests): Add ex17 test.
3378 * Examples/ex17.c: New test.
3380 2001-03-20 Ulrich Drepper <drepper@redhat.com>
3382 * Makefile: Define -D_RPC_THREAD_SAFE_ for cancel.c.
3383 * cancel.c (__pthread_perform_cleanup): Call __rpc_thread_destroy.
3384 * sysdeps/pthread/bits/libc-tsd.h: Define _LIBC_TSD_KEY_VARS.
3386 2001-03-18 Ulrich Drepper <drepper@redhat.com>
3388 * Makefile: When generating DSO link with libc_nonshared.a.
3390 2001-02-26 Jakub Jelinek <jakub@redhat.com>
3392 * signals.c (pthread_sighandler): Use CALL_SIGHANDLER.
3394 2001-02-23 Jakub Jelinek <jakub@redhat.com>
3396 * internals.h (__pthread_init_max_stacksize): New prototype.
3397 * attr.c (__pthread_attr_setstacksize): Call
3398 __pthread_init_max_stacksize if not yet initialized.
3399 * pthread.c (__pthread_init_max_stacksize): New function.
3400 (__pthread_initialize_manager): Call it.
3401 Patch by <dtc@cmucl.cons.org>.
3403 2001-03-16 Ulrich Drepper <drepper@redhat.com>
3405 * attr.c (pthread_getattr_np): Fix __stacksize computation for IA-64.
3407 2001-03-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
3409 * shlib-versions: Add rule for Linux on 64 bit S/390.
3410 * sysdeps/s390/s390-64/pt-machine.h: New file.
3411 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: New file.
3413 2001-03-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
3415 * sysdeps/s390/pt-machine.h: Move to...
3416 * sysdeps/s390/s390-32/pt-machine.h: ...here.
3417 Add defines for FLOATING_STACK and ARCH_STACK_MAX_SIZE.
3419 2001-03-15 Ulrich Drepper <drepper@redhat.com>
3421 * Versions [libpthread] (GLIBC_2.2.3): Add pthread_getattr_np.
3422 * attr.c: Implement pthread_getattr_np.
3423 * sysdeps/pthread/pthread.h: Add prototype for pthread_getattr_np.
3424 * internals.h (struct _pthread_descr_struct): Add p_inheritsched.
3425 * manager.c (pthread_handle_create): Initialize p_inheritsched.
3427 2001-03-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
3429 * sysdeps/unix/sysv/linux/s390/pt-initfini.c: Use 0x07 padding for
3432 2001-02-20 Hans Boehm <hans_boehm@hp.com>
3434 * manager.c (manager_mask): Removed static vesion. Now always local
3435 to __pthread_manager().
3436 (manager_mask_all): Removed completely.
3437 (__pthread_manager): Remove manager_mask_all initialization.
3438 (pthread_handle_create): Remove code to set and reset signal mask
3439 around __clone2() calls.
3441 2001-02-17 Jakub Jelinek <jakub@redhat.com>
3443 * spinlock.c (__pthread_lock): Force lock->__status to be read from
3444 memory on every spin.
3446 2001-02-10 Andreas Jaeger <aj@suse.de>
3448 * Makefile (extra-objs): New.
3450 2001-02-09 Jakub Jelinek <jakub@redhat.com>
3452 * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Add
3453 __pthread_initialize_minimal prototype.
3455 2001-02-08 kaz Kojima <kkojima@rr.iij4u.or.jp>
3457 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: New file.
3459 2001-02-06 Martin Schwidefsky <schwidefsky@de.ibm.com>
3461 * sysdeps/unix/sysv/linux/s390/pt-initfini.c: New file.
3463 2001-02-06 Ulrich Drepper <drepper@redhat.com>
3465 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: First attempt to fix the
3466 broken code. Patch by Jes Sorensen.
3468 2001-02-06 Andreas Jaeger <aj@suse.de>
3470 * sysdeps/pthread/pthread.h: Move __pthread_initialize from here
3472 * internals.h: ...here.
3474 2001-02-05 Jes Sorensen <jes@linuxcare.com>
3476 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: New file.
3478 2001-02-02 Ulrich Drepper <drepper@redhat.com>
3480 * Versions: Remove __pthread_initialize_minimal.
3482 2001-02-01 Ulrich Drepper <drepper@redhat.com>
3484 * Makefile: Add rules to build crti.o and make it being used in
3485 building libpthread.so.
3486 * sysdeps/i386/Makefile: New file.
3487 * sysdeps/pthread/pt-initfini.c: New file.
3489 * pthread.c: Cleanups.
3491 2001-01-28 Andreas Jaeger <aj@suse.de>
3493 * oldsemaphore.c (__old_sem_init): Adjust for last change.
3494 * sysdeps/pthread/bits/libc-lock.h: Likewise.
3495 * spinlock.c: Likewise.
3497 2001-01-28 Ulrich Drepper <drepper@redhat.com>
3499 * sysdeps/pthread/bits/initspin.h: Make all names namespace clean.
3500 * sysdeps/unix/sysv/linux/hppa/bits/initspin.h: Likewise.
3501 * manager.c: Adjust for namespace cleanup in bits/initspin.h.
3502 * pthread.c: Likewise.
3503 * spinlock.h: Likewise.
3504 * sysdeps/pthread/pthread.h: Likewise.
3506 2001-01-26 Ulrich Drepper <drepper@redhat.com>
3508 * sysdeps/pthread/bits/pthreadtypes.h: Define pthread_attr_t also
3509 as struct __pthread_attr_s.
3511 * semaphore.h (sem_t): Cleanup namespace, rename status and
3514 2001-01-13 Jakub Jelinek <jakub@redhat.com>
3516 * pthread.c (pthread_onexit_process): Clear
3517 __pthread_manager_thread_bos after freeing it.
3518 * Makefile (tests): Add ex16.
3519 * Examples/ex16.c: New file.
3521 2001-01-11 Jakub Jelinek <jakub@redhat.com>
3523 * Makefile (CFLAGS-pthread.c): Pass -DHAVE_Z_NODELETE if ld supports
3525 * pthread.c (pthread_exit_process): Rename to...
3526 (pthread_onexit_process): ...this.
3527 (pthread_atexit_process, pthread_atexit_retcode): New.
3528 (pthread_initialize): Call __cxa_atexit instead of __cxa_on_exit
3529 and only if HAVE_Z_NODELETE is not defined.
3530 (__pthread_initialize_manager): Register pthread_atexit_retcode
3533 2001-01-11 Ulrich Drepper <drepper@redhat.com>
3535 * pthread.c (pthread_initialize): Use __cxs_on_exit not __cxa_atexit.
3537 2001-01-11 Jakub Jelinek <jakub@redhat.com>
3539 * Makefile (tests): Add ex15.
3540 * Examples/ex15.c: New test.
3542 2001-01-08 Ulrich Drepper <drepper@redhat.com>
3544 * pthread.c (pthread_exit_process): Free memory allocated for
3547 2000-12-31 Ulrich Drepper <drepper@redhat.com>
3549 * manager.c (pthread_alloca_stack): Remove MAP_FIXED from mmap calls.
3550 (pthread_free): Always unmap the stack. It's safe now that we don't
3551 use MAP_FIXED to allocate stacks.
3553 2000-12-31 Ulrich Drepper <drepper@redhat.com>
3555 * sysdeps/powerpc/pspinlock.c: Don't include pt-machine.h here.
3557 * manager.c (pthread_allocate_stack): Prepare for removal of MAP_FIXED.
3559 2000-11-15 Wolfram Gloger <wg@malloc.de>
3561 * manager.c (pthread_free): [!FLOATING_STACKS]: Only remap the
3562 stack to PROT_NONE, don't unmap it, avoiding collisions with malloc.
3564 2000-12-27 Andreas Jaeger <aj@suse.de>
3566 * Examples/ex13.c: Make local functions static.
3567 * ecmutex.c: Likewise.
3568 * joinrace.c: Likewise.
3569 * Examples/ex14.c: Likewise.
3571 * Examples/ex2.c: Make local functions static; reformat.
3572 * Examples/ex1.c: Likewise.
3573 * Examples/ex4.c: Likewise.
3574 * Examples/ex5.c: Likewise.
3575 * Examples/ex7.c: Likewise.
3577 * oldsemaphore.c: Add prototypes to shut up GCC.
3578 * pt-machine.c: Likewise.
3580 * weaks.c: Add prototype for pthread_exit.
3582 * internals.h: Add some prototypes, format prototypes and add
3584 Move __libc_waitpid prototype to include/sys/wait.h.
3586 * rwlock.c: Include <bits/libc-lock.h> for prototypes.
3587 * mutex.c: Likewise.
3588 * specific.c: Likewise.
3589 * ptfork.c: Likewise.
3591 * lockfile.c: Include internals.h to get prototypes.
3592 * events.c: Likewise.
3593 * sysdeps/alpha/pspinlock.c: Likewise.
3594 * sysdeps/arm/pspinlock.c: Likewise.
3595 * sysdeps/hppa/pspinlock.c: Likewise.
3596 * sysdeps/i386/pspinlock.c: Likewise.
3597 * sysdeps/ia64/pspinlock.c: Likewise.
3598 * sysdeps/m68k/pspinlock.c: Likewise.
3599 * sysdeps/mips/pspinlock.c: Likewise.
3600 * sysdeps/powerpc/pspinlock.c: Likewise.
3601 * sysdeps/s390/pspinlock.c: Likewise.
3602 * sysdeps/sh/pspinlock.c: Likewise.
3603 * sysdeps/sparc/sparc32/pspinlock.c: Likewise.
3604 * sysdeps/sparc/sparc32/sparcv9/pspinlock.c: Likewise.
3605 * sysdeps/sparc/sparc64/pspinlock.c: Likewise.
3607 2000-12-27 Ulrich Drepper <drepper@redhat.com>
3609 * attr.c (__pthread_attr_setstack): Fix setting of __stackaddr element.
3610 (__pthread_attr_getstack): Return correct address.
3611 Add warnings for using pthread_attr_getstackaddr and
3612 pthread_attr_setstackaddr.
3614 2000-12-26 Ulrich Drepper <drepper@redhat.com>
3616 * Examples/ex6.c (test_thread): Make static.
3617 * Examples/ex12.c (test_thread): Make static and add noreturn
3620 2000-12-18 Jes Sorensen <jes@linuxcare.com>
3622 * linuxthreads/sysdeps/ia64/pt-machine.h: __compare_and_swap
3623 and compare_and_swap_with_release_semantics returns int not long.
3625 2000-12-17 Andreas Jaeger <aj@suse.de>
3627 * sysdeps/s390/pt-machine.h (testandset): Use long int as return
3629 * sysdeps/arm/pt-machine.h (testandset): Likewise.
3630 * sysdeps/hppa/pt-machine.h (testandset): Likewise.
3631 * sysdeps/m68k/pt-machine.h (testandset): Likewise.
3632 * sysdeps/sh/pt-machine.h (testandset): Likewise.
3633 * sysdeps/sparc/sparc32/pt-machine.h (testandset): Likewise.
3634 * sysdeps/sparc/sparc64/pt-machine.h (testandset): Likewise.
3636 2000-12-17 Ulrich Drepper <drepper@redhat.com>
3638 * sysdeps/i386/pt-machine.h (testandset): Adjust for prototype change.
3639 * sysdeps/i386/i686/pt-machine.h (testandset): Likewise.
3641 2000-12-17 Andreas Jaeger <aj@suse.de>
3643 * internals.h: Add prototypes for testandset and
3644 __compare_and_swap to shut up gcc warnings.
3646 2000-12-06 Wolfram Gloger <wg@malloc.de>
3648 * join.c (pthread_detach): Allow case where the thread has already
3651 2000-12-05 Andreas Jaeger <aj@suse.de>
3653 * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Don't set mips2.
3654 * sysdeps/mips/pt-machine.h (testandset): Likewise.
3655 (__compare_and_swap): Likewise.
3656 Patches by Maciej W. Rozycki <macro@ds2.pg.gda.pl>.
3658 2000-11-20 Jakub Jelinek <jakub@redhat.com>
3660 * Examples/ex3.c (main): Cast int to long before casting to void *.
3661 (search): Cast void * to long, not int.
3662 * Examples/ex8.c (main, thread): Similarly.
3663 * Examples/ex11.c (main): Similarly.
3664 * Examples/ex14.c (worker, do_test): Similarly.
3665 * ecmutex.c (worker, do_test): Similarly.
3666 (nlocks): Cast to int.
3668 2000-11-08 Bruce Mitchener <bruce@cubik.org>
3670 * linuxthreads.texi: Add documentation for pthreads attributes
3671 guardsize, stackaddr, stacksize, and stack. Fix typo in previous
3672 patch. Document pthread_[sg]etconcurrency(). Mark
3673 pthread_mutexattr_[sg]ettype() as POSIX rather than GNU.
3675 2000-11-07 Ulrich Drepper <drepper@redhat.com>
3677 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_MESSAGE_PASSING):
3679 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
3680 Reported by Christopher Yeoh <cyeoh@linuxcare.com.au>.
3682 2000-11-06 Ulrich Drepper <drepper@redhat.com>
3684 * cancel.c (pthread_cancel): Always set p_canceled, even if we are
3685 not doing it right now.
3686 Reported by Kaz Kylheku <kaz@ashi.footprints.net>.
3688 2000-10-30 Ulrich Drepper <drepper@redhat.com>
3690 * Examples/ex4.c (main): Don't use exit() to avoid warning with
3693 2000-10-29 Ulrich Drepper <drepper@redhat.com>
3695 * attr.c (__pthread_attr_setguardsize): Don't round guardsize
3696 here. Reported by Bruce Mitchener <bruce@cubik.org>.
3698 * linuxthreads.texi: Changes terminology to 'type' from 'kind' when
3699 discussing mutexes. (As per the Unix98 name for the API.)
3700 Changes documentation for pthread_mutexattr_setkind_np() and
3701 pthread_mutexattr_getkind_np() over to the Unix98 APIs for the
3702 same: pthread_mutexattr_settype() and pthread_mutexattr_gettype().
3703 Changes references to PTHREAD_MUTEXATTR_FAST_NP to
3704 PTHREAD_MUTEXATTR_ADAPTIVE_NP.
3705 Begins to introduce discussion of the ``timed'' mutex type. This
3706 discussion is currently incomplete.
3707 Patch by Bruce Mitchener <bruce@cubik.org>.
3709 2000-10-26 Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
3710 Yutaka Niibe <gniibe@chroot.org>
3712 * sysdeps/sh/pt-machine.h (testandset): Since the operand of TAS.B
3713 has restrictions, use register.
3715 2000-10-23 Andreas Schwab <schwab@suse.de>
3717 * Examples/ex14.c (TIMEOUT): Override default timeout.
3719 2000-10-16 Ulrich Drepper <drepper@redhat.com>
3721 * specific.c: Protect tsd array modification in thread data
3722 structures by getting the thread lock in pthread_key_delete and
3723 __pthread_destroy_specifics.
3724 Patch by Wolfram Gloger <Wolfram.Gloger@dent.med.uni-muenchen.de>.
3726 2000-10-12 Alan Modra <alan@linuxcare.com.au>
3728 * sysdeps/pthread/bits/initspin.h: New file.
3729 * spinlock.h: Move LOCK_INITIALIZER definition to <bits/initspin.h>.
3730 (__pthread_init_lock): Initialize lock with LT_SPINLOCK_INIT.
3731 (__pthread_alt_init_lock): Likewise.
3732 (__pthread_alt_trylock): Release lock with LT_SPINLOCK_INIT.
3734 2000-10-12 David Huggins-Daines <dhd@linuxcare.com>
3736 * oldsemaphore.c (__old_sem_init): Release lock with
3737 LT_SPINLOCK_INIT, not zero.
3738 * spinlock.c (__pthread_unlock): Likewise.
3739 (__pthread_alt_lock): Likewise.
3740 (__pthread_alt_timedlock): Likewise.
3741 (__pthread_alt_unlock): Likewise.
3742 * sysdeps/pthread/bits/libc-lock.h: Initialize locks with
3743 LT_SPINLOCK_INIT if it is non-zero. Likewise for init-once flags.
3744 * sysdeps/pthread/pthread.h: Include bits/initspin.h. Use
3745 LT_SPINLOCK_INIT do initialize spinlocks not 0.
3747 2000-10-12 David Huggins-Daines <dhd@linuxcare.com>
3749 * shlib-versions: Add version definitions for hppa-linux.
3751 2000-10-12 Alan Modra <alan@linuxcare.com.au>
3753 * sysdeps/hppa/pspinlock.c: New file.
3754 * sysdeps/hppa/pt-machine.h: New file.
3755 * sysdeps/unix/sysv/linux/hppa/bits/initspin.h: New file.
3757 2000-10-05 Jakub Jelinek <jakub@redhat.com>
3759 * mutex.c (__pthread_mutex_destroy): Correct test of
3760 busy mutex for mutexes using alternate fastlocks.
3761 Patch by dtc@cmucl.cons.org.
3763 2000-09-28 Martin Schwidefsksy <schwidefsky@de.ibm.com>
3765 * sysdeps/s390/pt-machine.h: Make %a0 the thread register.
3767 2000-09-28 Ulrich Drepper <drepper@redhat.com>
3769 * mutex.c (__pthread_mutex_unlock): For PTHREAD_MUTEX_RECURSIVE_NP
3770 test for owner first.
3771 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
3773 * cancel.c (pthread_cancel): Don't do anything if cancelation is
3776 2000-09-26 Ulrich Drepper <drepper@redhat.com>
3778 * spinlock.h (__pthread_set_own_extricate_if): Optimize a bit.
3779 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
3781 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remove
3782 _POSIX_MONOTONIC_CLOCK.
3784 * spinlock.h (__pthread_set_own_extricate_if): Add back locking
3787 2000-09-20 Andreas Jaeger <aj@suse.de>
3789 * pthread.c [!__ASSUME_REALTIME_SIGNALS]: Make inclusion of
3790 "testrtsig.h" conditional.
3792 2000-09-11 Ulrich Drepper <drepper@redhat.com>
3794 * sysdeps/pthread/pthread.h: Declare pthread_attr_getstack and
3795 pthread_attr_setstack.
3796 * Versions [libpthread] (GLIBC_2.2): Export pthread_attr_getstack and
3797 pthread_attr_setstack.
3798 * attr.c (pthread_attr_getstack, pthread_attr_setstack): New functions.
3800 2000-09-05 Ulrich Drepper <drepper@redhat.com>
3802 * Examples/ex14.c: New file.
3803 * Makefile (tests): Add ex14.
3805 * mutex.c (__pthread_mutex_unlock): Correct test for already unlocked
3806 mutex. Patch by dtc@cmucl.cons.org.
3808 * ecmutex.c: New file.
3809 * Makefile (tests): Add ecmutex.
3811 2000-09-04 H.J. Lu <hjl@gnu.org>
3813 * attr.c (__pthread_attr_setguardsize): Use page_roundup
3814 instead of roundup to round up to the page size.
3816 2000-09-03 Mark Kettenis <kettenis@gnu.org>
3818 * manager.c (pthread_exited): Correctly report event as TD_REAP
3819 instead of TD_DEATH. Fix comments.
3821 2000-09-03 Ulrich Drepper <drepper@redhat.com>
3823 * spinlock.h (testandset): Add cast to avoid warning.
3824 Patch by Franz Sirl <Franz.Sirl-kernel@lauterbach.com>.
3826 2000-09-02 Andreas Jaeger <aj@suse.de>
3828 * sysdeps/pthread/timer_routines.c: Include stdlib.h for abort
3831 2000-09-01 Ulrich Drepper <drepper@redhat.com>
3833 * sysdeps/pthread/bits/stdio-lock.h (_IO_cleanup_region_start):
3834 Fix typo in last patch (_mode -> _flags).
3836 * sysdeps/pthread/bits/stdio-lock.h (_IO_cleanup_region_start):
3837 Provide definition which respects _IO_USER_LOCK flag.
3839 2000-08-30 Ulrich Drepper <drepper@redhat.com>
3841 * manager.c (pthread_allocate_stack): Clear descriptor only if not
3844 2000-08-25 Ulrich Drepper <drepper@redhat.com>
3846 * Makefile: Add rules to build and run unload.
3847 * unload.c: New file.
3849 * pthread.c (pthread_exit_process): Move thread_self use inside `if'.
3851 * sysdeps/pthread/pthread.h
3852 (PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP): Defined.
3853 (PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP: Defined.
3855 2000-08-24 Andreas Jaeger <aj@suse.de>
3857 * Examples/ex13.c: Include <string.h> for strerror prototype and
3858 <stdlib.h> for abort prototype.
3859 (pthr_cond_signal_mutex): Rewrite to silence GCC.
3860 (thread_start): Remove unused variable err.
3861 (main): Silence GCC warnings.
3863 2000-08-22 Andreas Jaeger <aj@suse.de>
3865 * Examples/ex13.c: New test by Kurt Garloff <garloff@suse.de>.
3867 * Makefile (tests): Add ex13.
3869 2000-08-20 Ulrich Drepper <drepper@redhat.com>
3871 * semaphore.h: Add restrict where required by AGd4.
3872 * sysdeps/pthread/pthread.h: Likewise.
3873 * sysdeps/pthread/unix/sysv/linux/bits/sigthread.h: Likewise.
3875 2000-08-15 Ulrich Drepper <drepper@redhat.com>
3877 * Makefile (tests): Add ex12. Add rule to build it.
3878 * Examples/ex12.c: New file.
3880 2000-08-13 Ulrich Drepper <drepper@redhat.com>
3882 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define _POSIX_SEMAPHORES
3883 even though the implementation is not quite complete (but it reports
3884 it). Define _POSIX_MESSAGE_PASSING to -1.
3885 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
3887 2000-08-12 Andreas Jaeger <aj@suse.de>
3889 * sysdeps/mips/pt-machine.h (testandset): Add .set mips2 for
3891 (__compare_and_swap): Likewise.
3892 * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Likewise.
3894 2000-08-10 Ulrich Drepper <drepper@redhat.com>
3896 * pthread.c (__pthread_initial_thread): Initialize p_errnop and
3897 p_h_errnop correctly and not to NULL.
3899 2000-08-05 Ulrich Drepper <drepper@redhat.com>
3901 * Banner: Bump version number to 0.9.
3903 2000-08-04 Ulrich Drepper <drepper@redhat.com>
3905 * Makefile (tests): Add tststack. Add rule to build the program.
3906 * tststack.c: New file.
3908 * internals.h: Declare __pthread_max_stacksize.
3909 * pthread.c (__pthread_max_stacksize): New variable.
3910 (__pthread_initialize_manager): Determine __pthread_initialize_manager
3912 * manager.c (thread_segment): Return always NULL if FLOATING_STACKS.
3913 (pthread_allocate_stack): Allow kernel to choose stack address if
3914 FLOATING_STACKS. This also handles variable-sized stacks.
3915 Always allocate stack and guardpage together. Use mprotect to
3916 change guardpage access.
3917 * sysdeps/i386/useldt.h: Define FLOATING_STACKS and
3918 ARCH_STACK_MAX_SIZE.
3920 * attr.c (__pthread_attr_setstacksize): Also test value against
3923 * manager.c (__pthread_nonstandard_stacks): Define only if
3924 THREAD_SELF is not defined.
3925 (pthread_allocate_stack): Always initialize gardaddr to a correct
3927 (pthread_handle_create): Unmap thread with one call.
3928 (pthread_free): Remove test for initial thread before removing stack.
3929 Unmap stack with one call.
3931 * pthread.c (__pthread_initial_thread): Initialize p_userstack to
3932 1 to avoid removing the stack.
3934 2000-07-27 Jes Sorensen <jes@linuxcare.com>
3936 * sysdeps/ia64/pspinlock.c (__pthread_spin_lock): Add
3937 load of spin lock to prime the cache before the atomic compare and
3938 exchange operation (cmpxchg4). This avoids the spinning on the
3939 cmpxchg4 instruction and reduces movement of the cache line back
3940 and forth between the processors (explanation by Asis K. Mallick
3941 from Intel). This basically makes the implementation operate the
3942 same as the Linux kernel implementation.
3944 * shlib-versions: Use GLIBC_2_2 for Linux/ia64.
3945 * sysdeps/ia64/pspinlock.c: New file.
3947 2000-08-03 Ulrich Drepper <drepper@redhat.com>
3949 * pthread.c: Move definition of __pthread_set_own_extricate_if...
3950 * spinlock.h: ...here. Remove locking.
3951 * internals.h: Remove __pthread_set_own_extricate_if prototype.
3953 * rwlock.c: Use THREAD_GETMEM And THREAD_SETMEM.
3954 (rwlock_rd_extricate_func): Don't determine self, let
3955 __pthread_lock do it.
3956 (rwlock_wr_extricate_func): Likewise.
3957 (rwlock_have_already): Optimize *pself handling a bit.
3959 * mutex.c: Use __builtin_expect.
3960 * pthread.c: Likewise.
3962 2000-08-02 Andreas Jaeger <aj@suse.de>
3964 * sysdeps/s390/pspinlock.c: New file.
3965 * sysdeps/s390/pt-machine.h: New file.
3966 Patches by Martin Schwidefsky <schwidefsky@de.ibm.com>.
3968 2000-07-12 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
3970 * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Implement for
3972 * sysdeps/mips/pt-machine.h (testandset): Likewise.
3974 2000-07-26 Andreas Jaeger <aj@suse.de>
3976 * pthread.c: Initialize p_sem_avail.
3978 2000-07-25 Ulrich Drepper <drepper@redhat.com>
3980 * internals.h (struct __pthread_descr_struct): Add p_sem_avail.
3981 * semaphore.c: Handle spurious wakeups.
3983 * sysdeps/pthread/pthread.h: Add back PTHREAD_MUTX_FAST_NP as an alias
3984 for PTHREAD_MUTEX_ADAPTIVE_NP for source code compatibility.
3986 * pthread.c (__pthread_set_own_extricate): Use THREAD_GETMEM.
3987 (__pthread_wait_for_restart): Likewise.
3989 * condvar.c (pthread_cond_wait): Also check whether thread is
3990 cancelable before aborting loop.
3991 (pthread_cond_timedwait): Likewise.
3993 * signals.c (pthread_sighandler): Remove special code to restrore
3995 (pthread_sighandler_t): Likewise.
3997 2000-07-25 Mark Kettenis <kettenis@gnu.org>
3999 * internals.h (__RES_PTHREAD_INTERNAL): Remove define.
4000 * pthread.c: Include <resolv.h>.
4001 (_res): Undefine. Add extern declaration.
4003 2000-07-24 Ulrich Drepper <drepper@redhat.com>
4005 * pthread.c (__pthread_initial_thread): Update initializer.
4006 (__pthread_manager_thread): Likewise.
4007 (pthread_initialize): Move setrlimit call to...
4008 (__pthread_initialize_manager): ...here.
4009 (__pthread_reset_main_thread): Reset also soft limit on stack size.
4011 * condvar.c: Handle spurious wakeups. [PR libc/1749].
4012 * internals.h (struct _pthread_descr_struct): Add p_condvar_avail.
4014 2000-07-21 Ulrich Drepper <drepper@redhat.com>
4016 * spinlock.h: If IMPLEMENT_TAS_WITH_CAS is defined use
4017 __compare_and_swap to define testandset.
4018 * sysdeps/powerpc/pt-machine.h: Add volatile to asms.
4019 Define IMPLEMENT_TAS_WITH_CAS.
4021 2000-07-20 Ulrich Drepper <drepper@redhat.com>
4023 * Makefile: Pass -z nodelete to linker for libpthread.so
4024 generation if it understand this option.
4026 2000-07-18 Mark Kettenis <kettenis@gnu.org>
4028 * manager.c (pthread_handle_create): Remove initialization of
4029 new_thread->p_res._sock.
4031 2000-07-19 Kaz Kylheku <kaz@ashi.footprints.net>
4033 Bugfixes to the variant of the code for machines with no compare
4036 * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Wait
4037 node was not being properly enqueued, due to failing to update
4038 the lock->__status field.
4040 * spinlock.c (__pthread_alt_timedlock): The oldstatus variable was
4041 being set inappropriately, causing the suspend function to be called
4042 with a null self pointer and crash.
4044 2000-07-18 Ulrich Drepper <drepper@redhat.com>
4046 * spinlock.h (__pthread_alt_trylock): Fix code used if no
4047 compare&swap is available.
4049 * spinlock.h (__pthread_trylock): Use __compare_and_swap, not
4052 * pthread.c (pthread_initialize): Don't use sysconf to determine
4053 whether the machine has more than one processor.
4055 * spinlock.c (__pthread_alt_timedlock): Add back one of the
4056 removed thread_self calls.
4058 2000-07-18 Kaz Kylheku <kaz@ashi.footprints.net>
4060 * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Changed
4061 __compare_and_swap to compare_and_swap in code which assumes
4062 compare swap is available.
4064 2000-07-18 Kaz Kylheku <kaz@ashi.footprints.net>
4066 * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Fixed
4067 bug whereby thr field of waitnode structure would not be correctly
4068 set unless a null self pointer is passed to the functions.
4069 Eliminated redundant calls to thread_self().
4071 2000-07-18 Jakub Jelinek <jakub@redhat.com>
4073 * pthread.c (__pthread_initialize_manager): Lock
4074 __pthread_manager_thread.p_lock before calling clone.
4076 2000-05-05 H.J. Lu <hjl@gnu.org>
4078 * sysdeps/ia64/pt-machine.h (__compare_and_swap): Change it to
4079 have acquire semantics.
4080 (__compare_and_swap_with_release_semantics): New inline
4082 (HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS): New macro.
4084 2000-01-28 Hans Boehm <hboehm@exch.hpl.hp.com>
4086 * manager.c: Fix the problem with signals at startup.
4087 Change the way that thread stacks are allocated on IA64.
4088 Clean up some of the guard page allocation stuff.
4090 1999-12-19 H.J. Lu <hjl@gnu.org>
4092 * internals.h (page_roundup): New.
4093 * attr.c (__pthread_attr_setguardsize); Use page_roundup
4095 * manager.c (pthread_allocate_stack): Make sure guardaddr is
4096 page aligned with page_roundup if NEED_SEPARATE_REGISTER_STACK
4099 1999-12-17 Hans Boehm <hboehm@exch.hpl.hp.com>
4101 * manager.c (pthread_allocate_stack): Unmap the stack top
4102 if failed to map the stack bottom.
4104 (pthread_free): Fix the guard page.
4106 * pthread.c (pthread_initialize): Set rlimit correctly for
4107 NEED_SEPARATE_REGISTER_STACK.
4109 1999-12-16 H.J. Lu <hjl@gnu.org>
4111 * pthread.c (__pthread_initialize_manager): Pass
4112 __pthread_manager_thread_bos instead of
4113 __pthread_manager_thread_tos to __clone2.
4115 1999-12-16 H.J. Lu <hjl@gnu.org>
4117 * manager.c (pthread_allocate_stack): Correct the calculation
4118 of "new_thread_bottom". Remove MAP_GROWSDOWN from mmap for
4121 1999-12-13 H.J. Lu <hjl@gnu.org>
4123 * sysdeps/ia64/pt-machine.h (__compare_and_swap): Added a stop
4124 bit after setting ar.ccv.
4126 1999-12-12 H.J. Lu <hjl@gnu.org>
4128 * manager.c (pthread_allocate_stack): Make the starting
4129 address of the stack bottom page aligned. FIXME: it may
4130 need changes in other places.
4131 (pthread_handle_create): Likewise.
4133 1999-12-11 Hans Boehm <hboehm@exch.hpl.hp.com>
4135 * manager.c (pthread_allocate_stack): Handle
4136 NEED_SEPARATE_REGISTER_STACK.
4137 (pthread_handle_create): Likewise.
4138 * pthread.c (__pthread_initialize_manager): Likewise.
4140 * sysdeps/ia64/pt-machine.h: Use r13 for thread pointer.
4142 1999-12-02 H.J. Lu <hjl@gnu.org>
4144 * sysdeps/ia64/pt-machine.h: New.
4146 2000-07-13 Ulrich Drepper <drepper@redhat.com>
4148 * wrapsyscall.c: Mark non-__ protected names as weak.
4151 2000-07-12 Bruno Haible <haible@clisp.cons.org>
4153 * Examples/ex8.c: Include <sys/wait.h>, not <wait.h>.
4155 2000-07-12 Ulrich Drepper <drepper@redhat.com>
4157 * spinlock.c: Fix code for TEST_FOR_COMPARE_AND_SWAP being defined.
4158 Add tests also to new alternative spinlock implementation.
4159 * spinlock.h: Likewise.
4160 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4162 2000-07-06 Ulrich Drepper <drepper@redhat.com>
4164 * Version: Export __sigaction.
4165 * signals.c: Define __sigaction alias. Use __libc_sigaction instead
4167 * pthread.c: Use __libc_sigaction instead of __sigaction.
4169 * condvar.c: Implement pthread_condattr_getpshared and
4170 pthread_condattr_setpshared.
4171 * mutex.c: Implement pthread_mutexattr_getpshared and
4172 pthread_mutexattr_setpshared.
4173 * Versions: Export new functions.
4174 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
4176 * rwlock.c (pthread_rwlockattr_init): Use PTHREAD_PROCESS_PRIVATE.
4177 (pthread_rwlockattr_setpshared): Fail if PTHREAD_PROCESS_PRIVATE
4180 2000-07-04 Greg McGary <greg@mcgary.org>
4182 * sysdeps/pthread/bits/libc-lock.h: Remove BP_SYM from
4183 pragmas. Include bp-sym.h only if _LIBC.
4185 2000-07-04 Ulrich Drepper <drepper@redhat.com>
4187 * spinlock.c (__pthread_unlock): Properly place write barrier.
4188 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4190 2000-07-03 Ulrich Drepper <drepper@redhat.com>
4192 * spinlock.c: Replace fast spinlocks by adaptive spinlocks which are
4193 faster on SMP systems. No more emulation of compare&swap for adaptive
4195 * spinlock.h: Likewise.
4196 * sysdeps/pthread/pthread.h: Shuffle PTHREAD_MUTEX_* values around.
4197 Replace fast with adaptive mutex.
4198 * mutex.c: Rewrite for replacement of fast by adaptive mutex.
4199 * condvar.c: Likewise.
4200 * pthread.c: Define and initialize __pthread_smp_kernel variable.
4201 * internals.h: Declare __pthread_smp_kernel.
4202 * sysdeps/pthread/bits/pthreadtypes.h: Update comment of
4203 _pthread_fastlock structure.
4204 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4206 * pthread.c: Remove initialization to zero from global variables.
4208 2000-06-29 Jakub Jelinek <jakub@redhat.com>
4210 * shlib-versions: Make sparc64 GLIBC_2.2+ only.
4212 2000-06-28 Greg McGary <greg@mcgary.org>
4214 * weaks.c: Wrap BP_SYM () around weak extern declarations of
4215 pthread functions that have pointers in their return+arg signatures.
4217 2000-06-27 Greg McGary <greg@mcgary.org>
4219 * sysdeps/pthread/bits/libc-lock.h: Wrap BP_SYM () around weak
4220 extern declarations of pthread functions that have pointers in
4221 their return+arg signatures.
4223 2000-06-26 Ulrich Drepper <drepper@redhat.com>
4225 * Makefile (tests): Add ex11. Add rules to build it.
4226 * Examples/ex11.c: New file.
4227 * rwlock.c: Fix complete braindamaged previous try to implement
4230 * spinlock.c: Pretty print.
4232 2000-06-25 Ulrich Drepper <drepper@redhat.com>
4234 * Makefile (tests): Add ex10. Add rules to build it.
4235 * Versions [GLIBC_2.2] (libpthread): Add pthread_mutex_timedlock,
4236 pthread_rwlock_timedrdlock, and pthread_rwlock_timedwrlock.
4237 * condvar.c (pthread_cond_wait): Allow mutex of kind
4238 PTHREAD_MUTEX_TIMED_NP.
4239 (pthread_cond_timedwait_relative): Likewise.
4240 * mutex.c (__pthread_mutex_init): Default is PTHREAD_MUTEX_TIMED_NP.
4241 (__pthread_mutex_trylock): Use __pthread_alt_trylock for
4242 PTHREAD_MUTEX_ERRORCHECK_NP. Handle PTHREAD_MUTEX_TIMED_NP.
4243 (__pthread_mutex_lock): Use __pthread_alt_lock for
4244 PTHREAD_MUTEX_ERRORCHECK_NP. Handle PTHREAD_MUTEX_TIMED_NP.
4245 (__pthread_mutex_timedlock): New function.
4246 (__pthread_mutex_unlock): Use __pthread_alt_unlock for
4247 PTHREAD_MUTEX_ERRORCHECK_NP. Handle PTHREAD_MUTEX_TIMED_NP.
4248 (__pthread_mutexattr_init): Use PTHREAD_MUTEX_TIMED_NP.
4249 (__pthread_mutexattr_settype): Allow PTHREAD_MUTEX_TIMED_NP.
4250 * spinlock.c: Implement alternate fastlocks.
4251 * spinlock.h: Add prototypes.
4252 * Examples/ex10.c: New file.
4253 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
4254 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4256 * rwlock.c (__pthread_rwlock_rdlock): Optimize loop a bit.
4257 (__pthread_rwlock_timedrdlock): New function.
4258 (__pthread_rwlock_timedwrlock): New function.
4259 Use laternate fastlock function everywhere.
4261 2000-06-21 Andreas Jaeger <aj@suse.de>
4263 * sysdeps/pthread/timer_routines.c: Include <string.h> for memset
4266 * join.c: Include <stdlib.h> for exit prototype.
4268 2000-06-20 Ulrich Drepper <drepper@redhat.com>
4270 * sysdeps/i386/useldt.h: Include <stdlib.h>.
4272 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define _POSIX_BARRIERS.
4273 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4275 * Makefile (libpthread-routines): Add barrier.
4276 (tests): Add ex9. Add rule to build ex9.
4277 * Versions: Export barrier functions.
4278 * barrier.c: New file.
4279 * Examples/ex9.c: New file.
4280 * sysdeps/pthread/pthread.h: Add barrier data types and declarations.
4281 * sysdeps/pthread/bits/pthreadtypes.h: Likewise.
4282 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4284 2000-06-19 H.J. Lu <hjl@gnu.org>
4286 * spinlock.h (HAS_COMPARE_AND_SWAP): Defined if
4287 HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS is defined.
4288 (compare_and_swap_with_release_semantics): New. Default to
4289 compare_and_swap if HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS
4292 * spinlock.c (__pthread_unlock): Call
4293 compare_and_swap_with_release_semantics () instead of
4294 compare_and_swap ().
4296 2000-06-19 Ulrich Drepper <drepper@redhat.com>
4298 * sysdeps/pthread/timer_create.c: Use _set_errno instead of assigning
4300 * sysdeps/pthread/timer_delete.c: Likewise.
4301 * sysdeps/pthread/timer_getoverr.c: Likewise.
4302 * sysdeps/pthread/timer_gettime.c: Likewise.
4303 * sysdeps/pthread/timer_settime.c: Likewise.
4305 2000-06-13 Kaz Kylheku <kaz@ashi.footprints.net>
4307 Timer nodes are now reference counted, and can be marked
4308 as deleted. This allows for the safe release of the global mutex
4309 in the middle without losing the timer being operated on.
4311 * sysdeps/pthread/posix-timer.h (struct timer_node): The inuse
4312 member is now an enum with three values, so that an intermediate
4313 state can be represented (deleted but not free for reuse yet).
4314 New refcount member added.
4315 * sysdeps/pthread/timer_routines.c: Likewise.
4317 * sysdeps/pthread/posix-timer.h (timer_addref, timer_delref,
4318 timer_valid): New inline functions added.
4320 * sysdeps/pthread/timer_gettime.c (timer_gettime): Function
4321 restructured, recursive deadlock bug fixed.
4323 * sysdeps/pthread/timer_gettime.c (timer_gettime): Uses new
4324 timer_addref to ensure that timer won't be deleted while mutex is not
4325 held. Also uses timer_invalid to perform validation of timer handle.
4326 * sysdeps/pthread/timer_settime.c (timer_settime): Likewise.
4327 * sysdeps/pthread/timer_getoverr.c (timer_getoverrun): Likewise.
4329 2000-06-14 Ulrich Drepper <drepper@redhat.com>
4331 * shlib-versions: Add entry for SH.
4332 Patch by Kaz Kojima <kkojima@rr.iij4u.or.jp>.
4334 2000-06-13 Kaz Kylheku <kaz@ashi.footprints.net>
4336 A few optimizations. Got rid of unnecessary wakeups of timer threads,
4337 tightened up some critical regions and micro-optimized some list
4340 * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
4341 Returns int value now to indicate whether timer was queued at head.
4342 * sysdeps/pthread/posix-timer.h: Likewise.
4343 * sysdeps/pthread/timer_settime.c (timer_settime): Takes advantage of
4344 new return value from __timer_thread_queue_timer to avoid waking
4345 up timer thread unnecessarily.
4347 * sysdeps/pthread/posix-timer.h (timer_id2ptr): No longer checks
4348 inuse flag, because this requires mutex to be held. Callers updated
4349 to do the check when they have the mutex.
4350 * sysdeps/pthread/timer_getoverr.c: Add check for inuse here.
4352 * sysdeps/pthread/timer_settime.c (timer_settime): Tighter critical
4353 regions: avoids making system calls while holding timer mutex, and
4354 a few computations were moved outside of the mutex as well.
4355 * sysdeps/pthread/timer_gettime.c (timer_gettime): Likewise.
4357 * sysdeps/pthread/posix-timer.h (list_unlink_ip): Function name changed
4358 to list_unlink_ip, meaning idempotent. Pointer manipulation
4359 changed to get better better code out of gcc.
4360 * sysdeps/pthread/timer_routines.c (list_unlink): Non-idempotent
4361 version of list_unlink added here.
4362 * sysdeps/pthread/timer_delete.c: Use appropriate list unlink
4363 function in all places: idempotent one for timers, non-idempotent
4364 one for thread nodes.
4365 * sysdeps/pthread/timer_settime: Likewise.
4366 * sysdeps/pthread/timer_routines.c: Likewise.
4368 2000-06-13 Ulrich Drepper <drepper@redhat.com>
4370 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_TIMERS): Define.
4371 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4373 * sysdeps/pthread/Makefile: Remove tests definition.
4375 2000-06-12 Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
4376 Yutaka Niibe <gniibe@chroot.org>
4378 * sysdeps/sh/pspinlock.c: New file.
4379 * sysdeps/sh/pt-machine.h: New file.
4381 2000-06-12 Ulrich Drepper <drepper@redhat.com>
4383 * Makefile (tests): Add joinrace.
4385 * Examples/ex6.c: Test return value of pthread_join.
4387 2000-06-11 Geoff Keating <geoffk@cygnus.com>
4389 * sysdeps/powerpc/pspinlock.c (__pthread_spin_lock): Implement.
4390 (__pthread_spin_trylock): Implement.
4391 (__pthread_spin_unlock): Implement.
4392 (__pthread_spin_init): Implement.
4393 (__pthread_spin_destroy): Implement.
4395 2000-06-10 Ulrich Drepper <drepper@redhat.com>
4397 * sysdeps/pthread/timer_routines.c (list_append): Little fix to
4398 really append the entry.
4400 2000-06-10 Andreas Jaeger <aj@suse.de>
4402 * lockfile.c (__fresetlockfiles): Remove unused variable fp.
4404 2000-06-10 Kaz Kylheku <kaz@ashi.footprints.net>
4406 * sysdeps/pthread/timer_create.c: Thread matching now done on
4407 clock type as well as thread attributes.
4408 There are individual global signal-delivering threads for
4409 different clock types.
4410 * sysdeps/pthread/posix-timer.h: Likewise.
4411 * sysdeps/pthread/timer_routines.c: Likewise.
4413 * sysdeps/pthread/timer_routines.c: Thread allocation and
4414 deallocation function now remembers to put thread on active
4415 list and remove from active list.
4416 Thus now the feature of binding multiple timers
4417 to a single thread actually works.
4419 2000-06-10 Ulrich Drepper <drepper@redhat.com>
4421 * pthread.c (__pthread_create_2_1): Optimize a bit.
4423 * internals.h (invalid_handle): Also test for p_terminated != 0.
4424 (nonexisting_handle): New function. Same as old invalid_handle.
4425 * join.c (pthread_join): Use nonexisting_handle instead of
4426 invalid_handle to test for acceptable thread handle.
4427 * manager.c (pthread_handle_free): Likewise.
4428 * joinrace.c: New file.
4429 Reported by Permaine Cheung <pcheung@cygnus.com>.
4431 2000-06-08 Ulrich Drepper <drepper@redhat.com>
4433 * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
4434 Correct handling of matching variable.
4436 * sysdeps/pthread/tst-timer.c (main): Rewrite initializers to
4439 * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
4440 Be prepared for empty timer list.
4442 * sysdeps/pthread/timer_create.c (timer_create): Correct names of
4443 CPUTIME clock ID. Add support for thread clocks.
4445 * sysdeps/pthread/posix-timer.h (timer_ptr2id): Operands in
4446 subtraction were switched.
4448 * sysdeps/pthread/timer_routines.c (init_module): Use
4449 THREAD_MAXNODES threads.
4451 * sysdeps/pthread/posix-timer.h (struct timer_node): Add creator_pid.
4452 * sysdeps/pthread/timer_create.c: Fill in creator_pid.
4453 * sysdeps/pthread/timer_routines.c (thread_expire_timer): Send signal
4454 with sigqueueinfo is this system call is available.
4456 * sysdeps/pthread/timer_create.c (timer_create): Allow
4457 CLOCK_CPUTIME if _POSIX_CPUTIME is defined.
4459 * sysdeps/pthread/Makefile: New file. Add rules to build timer
4461 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add TIMER_MAX.
4463 2000-06-04 Kaz Kylheku <kaz@ashi.footprints.net>
4465 * sysdeps/pthread/posix-timer.h: New file.
4466 * sysdeps/pthread/timer_create.c: New file.
4467 * sysdeps/pthread/timer_delete.c: New file.
4468 * sysdeps/pthread/timer_getoverr.c: New file.
4469 * sysdeps/pthread/timer_gettime.c: New file.
4470 * sysdeps/pthread/timer_routines.c: New file.
4471 * sysdeps/pthread/timer_settime.c: New file.
4472 * sysdeps/pthread/tst-timer.c: New file.
4474 2000-06-08 Ulrich Drepper <drepper@redhat.com>
4476 * sysdeps/unix/sysv/linux/bits/local_lim.h: Remove OPEN_MAX and
4477 LINK_MAX definitions if necessary.
4479 2000-06-04 Kaz Kylheku <kaz@ashi.footprints.net>
4481 Added missing fork time handling of global libio lock.
4483 * lockfile.c (__fresetlockfiles): Now also resets the list lock,
4484 not just the individual stream locks. Rewritten to use new
4485 iterator interface provided by libio rather than accessing
4488 * lockfile.c (__flockfilelist, _funlockfilelist): New functions
4489 which lock and unlock the stream list using the new interface
4491 * internals.h: Likewise.
4493 * ptfork.c (__fork): Now calls __flockfilelist before fork,
4494 and __funlockfilelist in the parent after the fork.
4495 Child still calls __fresetlockfiles as before.
4497 * linuxthreads.texi: Now explains what happens to streams at
4498 fork time. Also whole new section on forking and thread added.
4499 Definition of pthread_atfork moved out of Miscellaneous Functions
4500 to this new section.
4502 2000-06-04 Jakub Jelinek <jakub@redhat.com>
4504 * sysdeps/sparc/sparc32/sparcv9/pspinlock.c (__pthread_spin_lock):
4505 Add missing register.
4506 * sysdeps/sparc/sparc64/pspinlock.c (__pthread_spin_lock): Likewise.
4508 2000-06-02 Jakub Jelinek <jakub@redhat.com>
4510 * sysdeps/sparc/sparc32/pspinlock.c: Implement spinlocks.
4511 * sysdeps/sparc/sparc32/sparcv9/pspinlock.c: New.
4512 * sysdeps/sparc/sparc64/pspinlock.c: Implement spinlocks.
4514 2000-05-31 Andreas Jaeger <aj@suse.de>
4516 * sysdeps/mips/pspinlock.c: Implement spinlocks.
4518 2000-05-28 Ulrich Drepper <drepper@redhat.com>
4520 * spinlock.c (__pthread_lock): Remove ASSERT.
4522 * Makefile (tests): Add ex8.
4523 * Examples/ex8.c: New file.
4525 2000-05-12 Kaz Kylheku <kaz@ashi.footprints.net>
4527 Bugfix: The pthread_atfork mechanism now takes care of its
4528 own internal mutex at fork time.
4530 * ptfork.c (__fork): Revised so that the mutex is held across
4531 the fork operation and while the handlers are called, and so that
4532 the child resets the mutex.
4534 * linuxthreads.texi: Updated pthread_atfork documentation to make
4535 it clear that fork and pthread_atfork can't be reentered from
4536 atfork handlers, that pthread_atfork and fork are mutually atomic,
4537 and that the handlers are inherited by the child process.
4539 2000-05-24 Ulrich Drepper <drepper@redhat.com>
4541 * Makefile (libpthread-routines): Add pspinlock.
4542 * cancel.c: Rename __pthread_spin_unlock back to __pthread_unlock.
4543 Use struct _pthread_fastlock instead of pthread_spinlock_t.
4544 * condvar.c: Likewise.
4545 * internals.h: Likewise.
4547 * manager.c: Likewise.
4548 * mutex.c: Likewise.
4549 * pthread.c: Likewise.
4550 * rwlock.c: Likewise.
4551 * semaphore.c: Likewise.
4552 * signals.c: Likewise.
4553 * spinlock.h: Likewise.
4554 * spinlock.c: Likewise. Remove pthread_spin_lock functions.
4555 * sysdeps/alpha/pspinlock.c: New file.
4556 * sysdeps/arm/pspinlock.c: New file.
4557 * sysdeps/i386/pspinlock.c: New file.
4558 * sysdeps/m68k/pspinlock.c: New file.
4559 * sysdeps/mips/pspinlock.c: New file.
4560 * sysdeps/powerpc/pspinlock.c: New file.
4561 * sysdeps/sparc/sparc32/pspinlock.c: New file.
4562 * sysdeps/sparc/sparc64/pspinlock.c: New file.
4563 * sysdeps/pthread/bits/pthreadtypes.h: Remove pthread_spinlock_t
4564 back to _pthread_fastlock. Define new pthread_spinlock_t.
4566 2000-05-24 Andreas Jaeger <aj@suse.de>
4568 * sysdeps/i386/i686/pt-machine.h: Only use LDT on newer kernels.
4570 2000-05-21 Jakub Jelinek <jakub@redhat.com>
4572 * manager.c (pthread_handle_create): Initialize p_res._sock to -1.
4574 2000-05-13 Jakub Jelinek <jakub@redhat.com>
4576 * internals.h (__RES_PTHREAD_INTERNAL): Define.
4578 2000-05-06 Kaz Kylheku <kaz@ashi.footprints.net>
4580 * mutex.c (pthread_once): IN_PROGRESS state of pthread_once_t
4581 object state is represented with additional bits which distinguish
4582 whether that state was set up in the current process, or
4583 in an ancestor process. If that state was set in an ancestor,
4584 it means that a fork happened while thread was executing the init
4585 function. In that case, the state is reset to NEVER.
4586 * mutex.c (__pthread_once_fork_prepare): New function.
4587 (__pthread_once_fork_child): Likewise
4588 (__pthread_once_fork_parent): Likewise
4589 (__pthread_reset_pthread_once): Removed.
4590 * ptfork.c (__fork): Call new handlers in mutex.c.
4591 * internals.h: Declarations of new mutex.c functions added.
4592 Declaration of removed function deleted.
4593 * linuxthreads.texi: Updated documentation about pthread_once
4594 to clarify what happens under cancellation and forking.
4596 2000-05-06 Kaz Kylheku <kaz@ashi.footprints.net>
4598 * internals.h: New thread manager request type, REQ_KICK.
4599 * join.c (pthread_exit): main thread now calls exit() instead
4600 of _exit() in order to proper process cleanup.
4601 * manager.c (__pthread_manager): Do not terminate manager
4602 after unblocking main thread; wait for main thread's
4603 REQ_PROCESS_EXIT request instead.
4604 Also, added REQ_KICK case to handle new request; this just does
4606 * manager.c (pthread_exited): Do not terminate manager after
4607 unblocking main thread.
4608 * manager.c (__pthread_manager_sighandler): If the main thread
4609 is waiting for all other threads to die, send a REQ_KICK into
4610 the thread manager request pipe to get it to clean out the threads
4611 and unblock the main thread as soon as possible. This fixes
4612 the 2000 millisecond hang on shutdown bug.
4613 * Examples/ex7.c: New file, tests shutdown behavior when all threads
4614 including the main one call pthread_exit(), or implicitly do so.
4615 * Makefile (tests): Add ex7.
4617 2000-05-05 Andreas Jaeger <aj@suse.de>
4619 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
4620 (pthread_getcpuclockid): Correct test for ourselves.
4622 2000-05-05 Ulrich Drepper <drepper@redhat.com>
4624 * internals.h (struct _pthread_descr_struct): Reorganization.
4625 Allocate room for 16 pointers at head of the structure for future
4626 thread-local data handling. Move p_self member in this area.
4627 * manager.c (pthread_handle_create): Adjust use of p_self.
4628 * sysdeps/i386/useldt.h (THREAD_SELF): Likewise.
4629 * pthread.c (__pthread_initial_thread): Adjust initialization.
4630 (__pthread_manager_thread): Likewise.
4632 2000-04-29 Bruno Haible <haible@clisp.cons.org>
4634 * join.c (pthread_exit): Use THREAD_GETMEM_NC instead of THREAD_GETMEM
4635 for eventmask larger than 1 word.
4637 2000-04-27 Ulrich Drepper <drepper@redhat.com>
4639 * Versions [libpthread] (GLIBC_2.2): Add __pthread_initialize_minimal.
4640 * pthread.c (__pthread_initialize_minimal): New function. Perform
4641 minimal initialization.
4642 (pthread_initialize): Remove this code here.
4643 * sysdeps/i386/i686/pt-machine.h: Include "../useldt.h" again. We
4644 are working around the problem in glibc.
4646 2000-04-25 Ulrich Drepper <drepper@redhat.com>
4648 * sysdeps/i386/i686/pt-machine.h: Do not use "../useldt.h" for
4649 now. First gcc must be fixed (more concrete: libgcc).
4651 2000-04-24 Ulrich Drepper <drepper@redhat.com>
4653 * pthread.c: Remove special treatement for interrupt handlers on x86.
4654 * manager.c (pthread_free): Use FREE_THREAD not FREE_THREAD_SELF.
4655 * sysdeps/i386/useldt.h: Use "q" constraint instead of "r" where
4657 * sysdeps/i386/i686/pt-machine.h: Include "../useldt.h".
4659 2000-04-24 Mark Kettenis <kettenis@gnu.org>
4661 * join.c (pthread_exit): Set p_terminated after reporting the
4662 termination event instead of before.
4664 2000-04-20 Jakub Jelinek <jakub@redhat.com>
4666 * sysdeps/pthread/bits/libc-lock.h: Only declare __pthread_rwlock_*
4669 2000-04-18 Andreas Jaeger <aj@suse.de>
4671 * Versions: Use ld instead of ld.so.
4673 2000-04-18 Jakub Jelinek <jakub@redhat.com>
4675 * sysdeps/unix/sysv/linux/sparc/bits/sigcontext.h (struct sigcontext):
4676 Remove the typedef keyword.
4678 2000-04-18 Jakub Jelinek <jakub@redhat.com>
4680 * sysdeps/sparc/sparc64/pt-machine.h (MEMORY_BARRIER): Use membar,
4682 (READ_MEMORY_BARRIER): Define.
4683 * spinlock.c (__pthread_spin_unlock): Use READ_MEMORY_BARRIER, not
4685 * internals.h (READ_MEMORY_BARRIER): Define if not defined in sysdep
4688 2000-04-17 Ulrich Drepper <drepper@redhat.com>
4690 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
4691 (pthread_getcpuclockid): Don't compare thread_id with thread_self,
4692 use thread_handle().
4694 2000-04-16 Ulrich Drepper <drepper@redhat.com>
4696 * condvar.c (pthread_cond_timedwait_relative): Don't test for owner
4697 if fast mutex is used. Don't initialize `already_canceled' twice.
4698 Correctly test for return value of timedsuspend.
4700 * pthread.c: Correct long-time braino. We never set SA_SIGINFO and
4701 therefore don't need the _rt versions of the signal handlers.
4703 2000-04-15 Ulrich Drepper <drepper@redhat.com>
4705 * pthread.c (pthread_yield): New function.
4706 * sysdeps/pthread/pthread.h (pthread_yield): Add prototype.
4707 * Versions [libpthread] (GLIBC_2.2): Add pthread_yield.
4708 * internals.h: Declare __pthread_yield.
4710 * pthread.c (pthread_initialize): Avoid a bit more code if
4711 realtime signals are known to exist.
4713 * pthread.c: Is __ASSUME_REALTIME_SIGNALS then avoid generating code
4714 to dynamically detect RT signals and avoid generating compatibility
4715 functions with old kernel.
4716 * restart.h (restart) [__ASSUME_REALTIME_SIGNALS]: Use
4717 __pthread_restart_new directly.
4718 (suspend) [__ASSUME_REALTIME_SIGNALS]: Use
4719 __pthread_wait_for_restart_signal directly.
4720 (timedsuspend) [__ASSUME_REALTIME_SIGNALS]: Use
4721 __pthread_timedsuspend_new directly.
4723 2000-04-15 Ulrich Drepper <drepper@redhat.com>
4725 * condvar.c: Remove all the special code to handle cond_timedwait.
4726 Use timedsuspend instead.
4727 * internals.h: Declare __pthread_timedsuspend_old,
4728 __pthread_timedsuspend_new, and __pthread_timedsuspend.
4729 Remove declaration of __pthread_init_condvar.
4730 * pthread.c: Define __pthread_timedsuspend variable.
4731 (__pthread_timedsuspend_old): New function. Timed suspension
4732 implementation for old Linux kernels.
4733 (__pthread_timedsuspend_new): New function. Timed suspension
4734 implementation for new Linux kernels.
4735 * restart.h (timedsuspend): New function. Call appropriate
4736 suspension function through __pthread_timedsuspend.
4737 * semaphore.c (sem_timedwait): Use timedsuspend, don't duplicate
4739 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4741 * internals.h (WRITE_MEMORY_BARRIER): Define as MEMORY_BARRIER if
4743 * spinlock.c: Use WRITE_MEMORY_BARRIER instead of MEMORY_BARRIER
4745 * sysdeps/alpha/pt-machine.h: Define WRITE_MEMORY_BARRIER.
4746 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
4748 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _POSIX_SPAWN.
4749 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4751 2000-04-14 Andreas Jaeger <aj@suse.de>
4753 * weaks.c: Fix typo.
4755 * shlib-versions (mips.*-.*-linux.*): Support only GLIBC 2.0 and
4756 2.2 for linuxthreads.
4758 2000-04-13 Ulrich Drepper <drepper@redhat.com>
4760 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
4761 (pthread_getcpuclockid): Fix typo.
4763 2000-04-12 Ulrich Drepper <drepper@redhat.com>
4765 * Makefile (libpthread-routines): Add getcpuclockid.
4766 * Versions [libpthread] (GLIBC_2.2): Add pthread_getcpuclockid.
4767 * sysdeps/pthread/getcpuclockid.c: New file.
4768 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c: New file.
4769 * sysdeps/pthread/pthread.h: Add prototype for pthread_getcpuclockid.
4771 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_SPIN_LOCKS):
4773 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4775 * sysdeps/pthread/pthread.h: Add prototypes for pthread_spin_init,
4776 pthread_spin_destroy, pthread_spin_lock, pthread_spin_trylock,
4777 and pthread_spin_unlock.
4778 * sysdeps/pthread/bits/pthreadtypes.h: Change struct _pthread_fastlock
4779 into pthread_spinlock_t. Change all uses.
4780 * spinlock.c: Implement pthread_spin_lock.
4781 Rename __pthread_unlock to __pthread_spin_unlock and define weak
4782 alias for real name.
4783 Define pthread_spin_trylock, pthread_spin_init, and
4784 pthread_spin_destroy.
4785 Change all uses of _pthread_fastlock to pthread_spinlock_t.
4786 * spinlock.h: Rename __pthread_unlock to __pthread_spin_unlock.
4787 Change all uses of _pthread_fastlock to pthread_spinlock_t.
4788 * Versions [libpthread] (GLIBC_2.2): Add pthread_spin_init,
4789 pthread_spin_destroy, pthread_spin_lock, pthread_spin_trylock,
4790 and pthread_spin_unlock.
4791 * cancel.c: Use __pthread_spin_unlock instead of __pthread_unlock.
4792 Change all uses of _pthread_fastlock to pthread_spinlock_t.
4793 * condvar.c: Likewise.
4794 * internals.h: Likewise.
4796 * manager.c: Likewise.
4797 * mutex.c: Likewise.
4798 * pthread.c: Likewise.
4799 * rwlock.c: Likewise.
4800 * semaphore.c: Likewise.
4801 * signals.c: Likewise.
4803 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add various new POSIX
4805 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: New file.
4807 2000-04-11 Ulrich Drepper <drepper@redhat.com>
4809 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add
4810 _POSIX_SHARED_MEMORY_OBJECTS.
4812 2000-04-11 Andreas Jaeger <aj@suse.de>
4814 * sysdeps/mips/pt-machine.h (MEMORY_BARRIER): Define.
4815 (__compare_and_swap): Mark as modifying memory.
4817 2000-04-11 Geoff Keating <geoffk@cygnus.com>
4819 * sysdeps/powerpc/pt-machine.h (MEMORY_BARRIER): Don't be
4821 (__compare_and_swap): Replace other 'sync' with MEMORY_BARRIER.
4822 Don't have the 'asm' __volatile__.
4824 2000-04-11 Ulrich Drepper <drepper@redhat.com>
4826 * internals.h: Define MEMORY_BARRIER as empty if not defined already.
4827 * spinlock.c (__pthread_lock): Add memory barriers.
4828 (__pthread_unlock): Likewise.
4829 * sysdeps/alpha/pt-machine.h (MEMORY_BARRIER): Define using mb
4831 (RELEASE): Not needed anymore.
4832 (__compare_and_swap): Mark asm as modifying memory.
4833 * sysdeps/powerpc/pt-machine.h (sync): Remove. Replace with definition
4835 (__compare_and_swap): Use MEMORY_BARRIER instead of sync.
4836 * sysdeps/sparc/sparc32/pt-machine.h (RELEASE): Not needed anymore.
4837 (MEMORY_BARRIER): Define using stbar.
4838 * sysdeps/sparc/sparc64/pt-machine.h (MEMORY_BARRIER): Define using
4840 (__compare_and_swap): Use MEMORY_BARRIER to ensure ordering.
4841 Patch by Xavier Leroy <Xavier.Leroy@inria.fr> based on comments by
4842 Mike Burrows <m3b@pa.dec.com>.
4844 2000-04-09 Ulrich Drepper <drepper@redhat.com>
4846 * signals.c (sigaction): Fix return value for the case SIG is one
4847 of the signals the implementation uses.
4848 Patch by Xavier.Leroy@inria.fr.
4850 2000-04-01 Andreas Jaeger <aj@suse.de>
4852 * attr.c: Use shlib-compat macros.
4853 * oldsemaphore.c: Likewise.
4854 * pthread.c: Likewise.
4855 * weaks.c: Likewise.
4857 2000-03-26 Ulrich Drepper <drepper@redhat.com>
4859 * semaphore.c (sem_timedwait): New function.
4860 Patch by Carl Mailloux <carlm@oricom.ca>.
4861 * semaphore.h: Declare sem_timedwait.
4862 * Versions [libpthread] (GLIBC_2.2): Add sem_timedwait.
4864 2000-03-26 Roland McGrath <roland@baalperazim.frob.com>
4866 * sysdeps/pthread/Makefile: File removed.
4868 2000-03-23 Ulrich Drepper <drepper@redhat.com>
4870 * mutex.c (__pthread_reset_pthread_once): Reset once_masterlock.
4871 * internals.h (__pthread_reset_pthread_once): Add prototype.
4872 * ptfork.c (__fork): Call __pthread_reset_pthread_once.
4874 * manager.c (pthread_handle_create): Store ID of new thread before
4877 2000-03-21 Ulrich Drepper <drepper@redhat.com>
4879 * attr.c: Use new macros from shlib-compat.h to define versions.
4880 * oldsemaphore.c: Likewise.
4881 * semaphore.c: Likewise.
4882 * weaks.c: Likewise.
4884 * pthread.c: Update for new SHLIB_COMPAT definition.
4886 * manager.c (__pthread_manager): Unmask debug signal.
4888 * pthread.c (pthread_initialize): Test for address of __dso_handle
4889 being NULL, not value. Use __on_exit, not on_exit.
4890 Patch by Andreas Jaeger <aj@suse.de>.
4892 * pthread.c: Use new macros from shlib-compat.h to define versions.
4894 2000-03-19 Ulrich Drepper <drepper@redhat.com>
4896 * pthread.c (pthread_initialize): Instead of on_exit use
4897 __cxa_atexit if __dso_label is available to allow unloading the
4898 libpthread shared library.
4900 2000-03-16 Ulrich Drepper <drepper@redhat.com>
4902 * condvar.c: Make tests for ownership of mutex less strict.
4904 2000-03-14 Ulrich Drepper <drepper@redhat.com>
4906 * condvar.c (pthread_cond_wait): Check whether mutex is owned by
4907 current thread and return error if not.
4908 (pthread_cond_timedwait_relative_old): Likewise.
4909 (pthread_cond_timedwait_relative_new): Likewise.
4911 * mutex.c (__pthread_once): Handle cancelled init function correctly.
4912 (pthread_once_cancelhandler): New function.
4913 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4915 2000-03-14 Andreas Jaeger <aj@suse.de>
4917 * pthread.c (pthread_handle_sigcancel_rt): GS has been renamed to
4919 (pthread_handle_sigrestart_rt): Likewise.
4920 * signals.c (pthread_sighandler_rt): Likewise.
4922 2000-03-02 Andreas Jaeger <aj@suse.de>
4924 * sysdeps/pthread/bits/libc-lock.h: Fix typo.
4925 Reported by Sean Chen <sean.chen@turbolinux.com>.
4927 2000-02-28 Andreas Jaeger <aj@suse.de>
4929 * rwlock.c: Fix typo.
4931 2000-02-27 Ulrich Drepper <drepper@redhat.com>
4933 * rwlock.c: Define __* variants of the functions and make old names
4935 * Versions [GLIBC_2.2]: Export the __pthread_rwlock_* functions.
4936 * sysdeps/pthread/bits/libc-lock.h: Define __libc_rwlock_* macros.
4938 2000-02-25 Andreas Jaeger <aj@suse.de>
4940 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
4941 pwrite64, lseek64, open64, and __open64 with version 2.2.
4943 2000-02-22 Ulrich Drepper <drepper@redhat.com>
4945 * semaphore.h (SEM_FAILED): Use 0 not NULL.
4947 2000-02-14 Ulrich Drepper <drepper@redhat.com>
4949 * condvar.c (pthread_cond_timedwait_relative_old): Tight loop with
4950 nanosleep does not work either. Get absolute time inside the
4952 (pthread_cond_timedwait_relative_new): Likewise.
4953 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4955 2000-02-13 Andreas Jaeger <aj@suse.de>
4957 * condvar.c (pthread_cond_timedwait_relative_new): Fix last patch.
4958 (pthread_cond_timedwait_relative_old): Likewise.
4960 2000-02-13 Ulrich Drepper <drepper@redhat.com>
4962 * condvar.c (pthread_cond_timedwait_relative_old): Undo last patch
4963 but keep the code around. A bug in the kernel prevent us from
4965 (pthread_cond_timedwait_relative_new): Likewise.
4966 (PR libc/1597 and libc/1598).
4968 2000-02-01 Kaz Kylheku <kaz@ashi.footprints.net>
4970 * condvar.c (pthread_cond_timedwait_relative_old): Do tight
4971 loop around nanosleep calls instead of around most of the function
4972 (pthread_cond_timedwait_relative_new): Likewise.
4973 body. Got rid of backwards goto and one local.
4975 2000-01-31 Ulrich Drepper <drepper@redhat.com>
4977 * condvar.c (pthread_cond_timedwait_relative_old): Recompute time
4978 before every nanosleep call to account for time spent in the rest
4980 (pthread_cond_timedwait_relative_new): Likewise.
4981 Patch by khendricks@ivey.uwo.ca (PR libc/1564).
4983 2000-01-29 Ulrich Drepper <drepper@redhat.com>
4985 * condvar.c (pthread_cond_timedwait_relative_old): Get remaining time
4986 from nanosleep call so that in case we restart we only wait for the
4988 (pthread_cond_timedwait_relative_new): Likewise.
4989 Patch by khendricks@ivey.uwo.ca (PR libc/1561).
4991 2000-01-18 Ulrich Drepper <drepper@cygnus.com>
4993 * manager.c (pthread_allocate_stack): Compute guard page address
4994 correctly. Patch by HJ Lu.
4996 * sysdeps/pthread/pthread.h: Define
4997 PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP.
4999 2000-01-16 Ulrich Drepper <drepper@cygnus.com>
5001 * rwlock.c (pthread_rwlock_unlock): Correct one more problem with
5002 preference handling.
5003 (pthread_rwlockattr_setkind_np): Allow
5004 PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP.
5005 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
5007 2000-01-12 Ulrich Drepper <drepper@cygnus.com>
5009 * internals.h (pthread_readlock_info): New structure.
5010 (_pthread_descr_struct): Add p_readlock_list, p_readlock_free, and
5011 p_untracked_readlock_count.
5012 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
5013 Add initializers for new fields.
5014 * manager.c (pthread_free): Free read/write lock lists.
5015 * queue.h (queue_is_empty): New function.
5016 * rwlock.c: Implement requirements about when readers should get
5018 * sysdeps/pthread/pthread.h
5019 (PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP): New definition.
5020 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_rwlock_t):
5021 Define this name as well.
5022 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
5024 2000-01-05 Ulrich Drepper <drepper@cygnus.com>
5026 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
5027 Adjust initializers for struct _pthread_descr_struct change.
5028 * internals.h (struct _pthread_descr_struct): Move new elements to
5031 2000-01-03 Kaz Kylheku <kaz@ashi.footprints.net>
5033 Redesigned how cancellation unblocks a thread from internal
5034 cancellation points (sem_wait, pthread_join,
5035 pthread_cond_{wait,timedwait}).
5036 Cancellation won't eat a signal in any of these functions
5037 (*required* by POSIX and Single Unix Spec!).
5038 * condvar.c: Spontaneous wakeup on pthread_cond_timedwait won't eat a
5039 simultaneous condition variable signal (not required by POSIX
5040 or Single Unix Spec, but nice).
5041 * spinlock.c: __pthread_lock queues back any received restarts
5042 that don't belong to it instead of assuming ownership of lock
5043 upon any restart; fastlock can no longer be acquired by two threads
5045 * restart.h: Restarts queue even on kernels that don't have
5046 queued real time signals (2.0, early 2.1), thanks to atomic counter,
5047 avoiding a rare race condition in pthread_cond_timedwait.
5049 1999-12-31 Andreas Jaeger <aj@suse.de>
5051 * internals.h: Remove duplicate prototype declarations.
5053 * weaks.c: Remove __THROW from prototypes since the file is not
5054 compiled by a C++ compiler.
5055 * internals.h: Likewise.
5057 1999-12-30 Andreas Jaeger <aj@suse.de>
5059 * sysdeps/pthread/pthread.h: Move internal functions to...
5060 * sysdeps/pthread/bits/libc-lock.h: ...here.
5062 1999-12-29 Andreas Jaeger <aj@suse.de>
5064 * sysdeps/pthread/pthread.h: Fix typos, reformat comments.
5066 1999-12-28 Ulrich Drepper <drepper@cygnus.com>
5068 * sysdeps/alpha/pt-machine.h: Move stack_pointer definition to the
5071 * manager.c (__pthread_start): Add one more cast to prevent
5072 warning on 64bit machines.
5074 1999-12-21 Ulrich Drepper <drepper@cygnus.com>
5076 * manager.c (pthread_handle_create): Set p_pid of new thread
5077 before calling the callback function to report a new thread.
5079 1999-12-20 Andreas Jaeger <aj@suse.de>
5081 * pthread.c (pthread_initialize): Move getrlimit call after
5084 1999-12-18 Ulrich Drepper <drepper@cygnus.com>
5086 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
5087 pwrite64, lseek64, open64, and __open64.
5088 * wrapsyscall.c: Define pread, __pread64, pread64, pwrite, __pwrite64,
5089 pwrite64, lseek64, open64, and __open64.
5091 * manager.c (pthread_allocate_stack): Correct computation of
5092 new_thread_bottom. Correct handling of stack size and when the
5093 rlimit method to guard for stack growth is used.
5094 * pthread.c (pthread_initialize): Stack limit must be STACK_SIZE
5095 minus one pagesize (not two).
5097 1999-12-03 Andreas Jaeger <aj@suse.de>
5099 * Versions: Add __res_state with version GLIBC_2.2.
5101 * errno.c (__res_state): New function to return thread specific
5104 * pthread.c (pthread_initialize): Initialize p_resp.
5105 (__pthread_reset_main_thread): Also set p_resp.
5107 * manager.c (pthread_handle_create): Initialize p_resp.
5109 * internals.h: Add thread specific resolver state.
5110 Based on patches by Adam D. Bradley <artdodge@cs.bu.edu>.
5112 1999-12-01 Ulrich Drepper <drepper@cygnus.com>
5114 * sysdeps/i386/pt-machine.h: Move stack_pointer definition to the
5116 * sysdeps/i386/i686/pt-machine.h: Likewise.
5117 Patches by Alan Modra <alan@SPRI.Levels.UniSA.Edu.Au>.
5119 1999-11-23 Ulrich Drepper <drepper@cygnus.com>
5121 * manager.c (pthread_start_thread_event): Initialize p_pid already
5124 1999-11-22 Ulrich Drepper <drepper@cygnus.com>
5126 * internals.h: Add prototype for __pthread_manager_event.
5127 * manager.c (__pthread_manager_event): New function.
5128 (pthread_start_thread_event): Correct computation of self.
5129 Use INIT_THREAD_SELF.
5130 * pthread.c (__pthread_manager_thread): Initialize p_lock.
5131 (__pthread_initialize_manager): Respect event flags also for creation
5132 of the manager thread.
5134 1999-11-08 Ulrich Drepper <drepper@cygnus.com>
5136 * pthread.c (__pthread_initialize_manager): Initialize
5137 __pthread_manager_thread.p_tid.
5139 1999-11-02 Ulrich Drepper <drepper@cygnus.com>
5141 * internals.h: Declare __pthread_last_event.
5142 * manager.c: Define __pthread_last_event.
5143 (pthread_handle_create): Set __pthread_last_event.
5144 (pthread_exited): Likewise.
5145 * join.c (pthread_exit): Likewise.
5147 * Makefile (libpthread-routines): Add events.
5148 * events.c: New file.
5149 * internals.h: Protect against multiple inclusion.
5150 Include thread_dbP.h header.
5151 (struct _pthread_descr_struct): Add new fields p_report_events and
5153 Declare event reporting functions.
5154 * join.c (pthread_exit): Signal event if this is wanted.
5155 * manager.c (__pthread_threads_events): New variable.
5156 (pthread_handle_create): Take new parameters with event information.
5157 Signal TD_CREATE event if wanted.
5158 (__pthread_manager): Adjust pthread_handle_create call.
5159 (pthread_start_thread_event): New function. Block until manager is
5160 finished and then call pthread_start_thread.
5161 (pthread_exited): Signal TD_REAP event if wanted.
5163 1999-10-26 Ulrich Drepper <drepper@cygnus.com>
5165 * restart.h (suspend_with_cancellation): Rewrite as a macro.
5167 * condvar.c (pthread_cond_timedwait_relative): Don't mark as inline.
5169 1999-10-25 Andreas Jaeger <aj@suse.de>
5171 * internals.h: Remove K&R compatibility.
5172 * no-tsd.c: Likewise.
5173 * semaphore.h: Likewise.
5174 * signals.c: Likewise.
5175 * sysdeps/pthread/bits/libc-tsd.h: Likewise.
5176 * sysdeps/unix/sysv/linux/bits/sigthread.h: Likewise.
5177 * weaks.c: Likewise.
5179 1999-10-21 Xavier Leroy <Xavier.Leroy@inria.fr>
5181 * pthread.c: For i386, wrap pthread_handle_sigrestart and
5182 pthread_handle_sigcancel with functions that restore %gs from the
5183 signal context. For each signal handling function, two wrappers
5184 are required, one for a non-RT signal and one for a RT signal.
5185 * signal.c: For i386, add code to restore %gs from the signal
5186 context in pthread_sighandler and pthread_sighandler_rt.
5188 1999-10-17 Ulrich Drepper <drepper@cygnus.com>
5190 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add cast.
5192 1999-10-14 Ulrich Drepper <drepper@cygnus.com>
5194 * pthread.c (__pthread_initial_thread): Pass argument to
5195 PTHREAD_START_ARGS_INITIALIZER.
5196 (__pthread_manager_thread): Likewise.
5198 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add parameter to
5199 initialize function.
5201 * manager.c (pthread_handle_create): Remove p_startfct initialization.
5203 * internals.h (_pthread_descr_struct): We don't need p_startfct field.
5205 1999-10-12 Ulrich Drepper <drepper@cygnus.com>
5207 * internals.h: Correct return types for __libc_read and __libc_write.
5209 1999-10-09 Andreas Jaeger <aj@suse.de>
5211 * internals.h: Add __new_sem_post to get prototype in
5212 manager.c; include semaphore.h for needed types.
5214 1999-10-08 Ulrich Drepper <drepper@cygnus.com>
5216 * manager.c (__pthread_manager) [REQ_POST]: Use __new_sem_post
5217 directly instead of calling sem_post which should not be necessary
5218 but is faster and might help in some case to work around problems.
5219 Patch by khendricks@ivey.uwo.ca [libc/1382].
5221 1999-10-08 Andreas Schwab <schwab@suse.de>
5223 * sysdeps/pthread/Subdirs: New file.
5226 1999-10-07 Ulrich Drepper <drepper@cygnus.com>
5228 * Implies: New file.
5229 * internals.h (struct _pthread_descr_struct): Add p_startfct.
5230 * manager.c (pthread_handle_create): Initialize p_startfct.
5231 * pthread.c: Define __linuxthread_pthread_sizeof_descr variable.
5233 1999-09-25 Ulrich Drepper <drepper@cygnus.com>
5235 * manager.c (__linuxthreads_pthread_threads_max): New variable.
5236 * specific.c (__linuxthreads_pthread_keys_max): New variable.
5237 (__linuxthreads_pthread_key_2ndlevel_size): New variable.
5239 * condvar.c (pthread_cond_timedwait_relative): Never return with
5240 EINTR. Patch by Andreas Schwab.
5242 1999-09-19 Ulrich Drepper <drepper@cygnus.com>
5244 * signals.c (sigaction): Correct last patch. Don't select
5245 pthread_sighandler_rt based on the signal number but instead of
5246 the SA_SIGINFO flag.
5248 1999-09-23 Ulrich Drepper <drepper@cygnus.com>
5250 * specific.c: Move definitions of struct pthread_key_struct and
5251 destr_function to ...
5252 * internals.h: ...here.
5254 1999-09-18 Ulrich Drepper <drepper@cygnus.com>
5256 * pthread.c (pthread_handle_sigrestart_rt): New function. Use
5257 this instead of pthread_handle_sigrestart if the signal is an RT
5260 * signals.c: Handle passing through of sighandler arguments also
5261 for real-time signals.
5263 1999-09-03 Andreas Schwab <schwab@suse.de>
5265 * ptfork.c (__fork): Renamed from fork and use __libc_fork. Add
5267 (__vfork): New function, alias vfork.
5268 * Versions: Export __fork, vfork, and __vfork in libpthread.
5270 1999-08-23 Andreas Schwab <schwab@suse.de>
5272 * signals.c (pthread_sighandler): Add SIGCONTEXT_EXTRA_ARGS to
5273 call to signal handler.
5275 1999-08-20 Ulrich Drepper <drepper@cygnus.com>
5277 * pthread.c (__pthread_reset_main_thread): Undo last change.
5278 (__pthread_kill_other_threads_np): Reset signal handlers for the
5279 signals we used in the thread implementation here.
5281 1999-08-19 Ulrich Drepper <drepper@cygnus.com>
5283 * pthread.c (__pthread_reset_main_thread): Reset signal handlers
5284 for the signals we used in the thread implementation [PR libc/1234].
5286 * Versions: Export __pthread_kill_other_threads_np from libpthread
5289 * signals.c: Pass sigcontext through wrapper to the user function.
5291 1999-08-01 Ulrich Drepper <drepper@cygnus.com>
5293 * Versions [ld.so] (GLIBC_2.0): Export __libc_internal_tsd_get and
5294 __libc_internal_tsd_set.
5296 1999-07-29 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5298 * manager.c: Remove inclusion of <linux/tasks.h> since it's not
5301 1999-07-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5303 * internals.h: Align _pthread_descr_struct to 32 bytes.
5304 Reported by Tim Hockin <thockin@cobaltnet.com>, close PR
5307 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
5309 * oldsemaphore.c (sem_compare_and_swap): Fix use of compare and
5312 1999-07-09 Cristian Gafton <gafton@redhat.com>
5314 * Makefile (libpthread-routines): Add oldsemaphore routine.
5315 * Versions: Add sem_destroy, sem_getvalue, sem_init, sem_post,
5316 sem_trywait, and sem_wait to GLIBC_2.1.
5317 * oldsemaphore.c: New file.
5318 * semaphore.c: Add default_symbol_versions for the changed functions.
5319 (__new_sem_init): Rename from sem_init.
5320 (__new_sem_post): Rename from sem_post.
5321 (__new_sem_wait): Rename from sem_wait.
5322 (__new_sem_trywait): Rename from sem_trywait.
5323 (__new_sem_getvalue): Rename from sem_getvalue.
5324 (__new_sem_destroy): Rename from sem_destroy.
5326 1999-06-23 Robey Pointer <robey@netscape.com>
5328 * internals.h: Added p_nextlock entry to separate queueing for a
5329 lock from queueing for a CV (sometimes a thread queues on a lock
5330 to serialize removing itself from a CV queue).
5331 * pthread.c: Added p_nextlock to initializers.
5332 * spinlock.c: Changed to use p_nextlock instead of p_nextwaiting.
5334 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
5336 * manager.c (pthread_handle_create): Free mmap region after stack
5337 if clone failed. Patch by Kaz Kylheku <kaz@ashi.FootPrints.net>.
5339 1999-05-23 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5341 * man/pthread_cond_init.man: Correct example.
5342 Reported by Tomas Berndtsson <tomas@nocrew.org>.
5344 * linuxthreads.texi (Condition Variables): Likewise.
5346 1999-05-18 Jakub Jelinek <jj@ultra.linux.cz>
5348 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): Use
5349 casx not cas, also successful casx returns the old value in rd
5350 and not the new value.
5352 1999-05-16 Xavier Leroy <Xavier.Leroy@inria.fr>
5354 * manager.c: If pthread_create() is given a NULL attribute
5355 and the thread manager runs with a realtime policy, set the
5356 scheduling policy of the newly created thread back to SCHED_OTHER.
5357 * manager.c: If the PTHREAD_INHERIT_SCHED attribute is given,
5358 initialize the schedpolicy field of new_thread->p_start_args
5359 to that of the calling thread.
5361 1999-04-29 Ulrich Drepper <drepper@cygnus.com>
5363 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): cas
5364 instruction does not allow memory element to use offset.
5366 1999-04-28 Ulrich Drepper <drepper@cygnus.com>
5368 * manager.c (pthread_allocate_stack): Optimize initialization of new
5371 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_define_initialized):
5372 Don't use initializer since it is all zeroes.
5373 (__libc_once_define): Likewise.
5375 1999-04-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5377 * sysdeps/arm/Implies: Removed since cmpxchg/no-cmpxchg
5378 doesn't exist anymore.
5379 * sysdeps/i386/Implies: Likewise.
5380 * sysdeps/m68k/Implies: Likewise.
5381 * sysdeps/mips/Implies: Likewise.
5382 * sysdeps/powerpc/Implies: Likewise.
5383 * sysdeps/sparc/sparc32/Implies: Likewise.
5384 * sysdeps/sparc/sparc64/Implies: Likewise.
5386 1999-04-15 Ulrich Drepper <drepper@cygnus.com>
5388 * sysdeps/alpha/bits/semaphore.h: Removed.
5389 * sysdeps/powerpc/bits/semaphore.h: Removed.
5390 * sysdeps/pthread/cmpxchg/bits/semaphore.h: Removed.
5391 * sysdeps/pthread/no-cmpxchg/bits/semaphore.h: Removed.
5392 * Makefile (headers): Remove bits/semaphore.h.
5394 * semaphore.h: Define _pthread_descr if necessary.
5395 Don't include limits.h. Define SEM_VALUE_MAX directly.
5397 (sem_t): Protect element names with leading __.
5398 Add declarations for sem_close, sem_open, and sem_unlink.
5399 * semaphore.c: Adjust all functions for new element names.
5400 Define sem_close, sem_open, and sem_unlink.
5401 * Versions (libthread): Add sem_close, sem_open, and sem_unlink for
5403 * sysdeps/pthread/bits/pthreadtypes.h: Define _pthread_descr only if
5406 1999-03-16 H.J. Lu <hjl@gnu.org>
5408 * specific.c (pthread_key_delete): Check th->p_terminated to see
5409 if the thread is running.
5411 * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set):
5412 Added to GLIBC_2.0 for libc.so.
5414 1999-02-12 H.J. Lu <hjl@gnu.org>
5416 * Versions (__libc_current_sigrtmin, __libc_current_sigrtmax,
5417 __libc_allocate_rtsig): Added to GLIBC_2.1.
5419 * internals.h (DEFAULT_SIG_RESTART): Removed.
5420 (DEFAULT_SIG_CANCEL): Removed.
5422 * pthread.c (init_rtsigs, __libc_current_sigrtmin,
5423 __libc_current_sigrtmax, __libc_allocate_rtsig): New functions.
5424 (__pthread_sig_restart, __pthread_sig_cancel,
5425 __pthread_sig_debug): Initialized.
5426 (pthread_initialize): Call init_rtsigs () to initialize
5429 1999-02-03 H.J. Lu <hjl@gnu.org>
5431 * manager.c (__pthread_manager): Do block __pthread_sig_debug.
5432 Don't restart the thread which sent REQ_DEBUG.
5433 (pthread_start_thread): Check if __pthread_sig_debug > 0
5436 * pthread.c (__pthread_initialize_manager): Suspend ourself
5437 after sending __pthread_sig_debug to gdb instead of
5438 __pthread_sig_cancel.
5440 1999-01-24 H.J. Lu <hjl@gnu.org>
5442 * manager.c (__pthread_manager): Delete __pthread_sig_debug
5443 from mask if __pthread_sig_debug > 0.
5444 (pthread_handle_create): Increment __pthread_handles_num.
5446 * manager.c (pthread_handle_create): Don't pass CLONE_PTRACE to clone.
5447 * pthread.c (__pthread_initialize_manager): Likewise.
5449 * pthread.c (pthread_initialize): Use __libc_allocate_rtsig (1)
5450 instead of __libc_allocate_rtsig (2).
5451 (__pthread_initialize_manager): Send __pthread_sig_debug to gdb
5452 instead of __pthread_sig_cancel.
5453 (pthread_handle_sigdebug): Fix comments.
5455 1999-01-21 Ulrich Drepper <drepper@cygnus.com>
5457 * manager.c (pthread_allocate_stack): Set
5458 __pthread_nonstandard_stacks if user-specified stack is used.
5460 1999-01-16 Ulrich Drepper <drepper@cygnus.com>
5462 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _LFS_ASYNCHRONOUS_IO,
5463 _LFS_LARGEFILE, _LFS64_LARGEFILE, and _LFS64_STDIO from Unix98.
5465 1999-01-07 Xavier Leroy <Xavier.Leroy@inria.fr>
5467 * pthread.c: Use a third signal __pthread_sig_debug distinct
5468 from __pthread_sig_cancel to notify gdb when a thread is
5470 * manager.c: Likewise.
5471 * internals.h: Likewise.
5472 * signals.c: The implementation of sigwait(s) assumed that
5473 all signals in s have signal handlers already attached.
5474 This is not required by the standard, so make it work
5475 also if some of the signals have no handlers.
5477 1999-01-05 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
5479 * linuxthreads.texi: Remove pointers from first @node. Move old
5480 @node spec inside comment.
5482 1998-12-31 Ulrich Drepper <drepper@cygnus.com>
5484 * sysdeps/pthread/bits/stdio-lock.h: Define _IO_lock_lock and
5487 1998-12-29 Ulrich Drepper <drepper@cygnus.com>
5489 * semaphore.c (sem_trywait): Don't forget to unlock the semaphore
5490 lock. Patch by Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>.
5492 1998-12-21 Ulrich Drepper <drepper@cygnus.com>
5494 * manager.c: Threads now send __pthread_sig_cancel on termination.
5495 Change clone call and signal masks.
5496 * thread.c (pthread_handle_sigrestart): Remove special code for
5498 (pthread_handle_sigcancel): In manager thread call
5499 __pthread_manager_sighandler.
5500 * sysdeps/i386/pt-machine.h (__compare_and_swap): Add memory clobber.
5501 * sysdeps/i386/i686/pt-machine.h: Likewise.
5502 Patches by Xavier Leroy.
5504 1998-12-14 Ulrich Drepper <drepper@cygnus.com>
5506 * spinlock.c (__pthread_unlock): Don't crash if called for an
5507 untaken mutex. Reported by Ruslan V. Brushkoff <rus@Snif.Te.Net.UA>.
5509 * Examples/ex6.c: Unbuffer stdout and reduce sleep time to reduce
5512 1998-12-13 Ulrich Drepper <drepper@cygnus.com>
5514 * Examples/ex3.c: Wait until all threads are started before
5515 searching for the number to avoid race condition on very fast
5518 1998-12-08 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5520 * sysdeps/pthread/pthread.h: Remove __pthread_setcanceltype
5521 declaration since it's not needed.
5523 * sysdeps/pthread/pthread.h: Move internal functions to ...
5524 * internals.h: ...here.
5526 1998-12-02 H.J. Lu <hjl@gnu.org>
5528 * pthread.c (__pthread_sig_restart): Initiliaze to 0 if
5529 SIGRTMIN is defined.
5530 (__pthread_sig_cancel): Likewise.
5532 1998-12-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5534 * wrapsyscall.c: Include <sys/mman.h> for msync,
5535 <stdlib.h> for system and <termios.h> for tcdrain prototype.
5536 Correct msync declaration.
5538 1998-11-29 Roland McGrath <roland@baalperazim.frob.com>
5540 * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_define, __libc_tsd_get,
5541 __libc_tsd_set): New macros for new interface.
5542 * no-tsd.c: New file, provide uninitialized defns of
5543 __libc_internal_tsd_get and __libc_internal_tsd_set.
5544 * Makefile (routines): Add no-tsd.
5546 1998-10-12 Roland McGrath <roland@baalperazim.frob.com>
5548 * internals.h: Include <bits/libc-tsd.h>, not <bits/libc-lock.h>.
5549 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
5550 __libc_internal_tsd_set): Move decls to ...
5551 * sysdeps/pthread/bits/libc-tsd.h: New file for __libc_internal_tsd_*
5554 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
5555 __libc_internal_tsd_set): Make these pointers to functions, not
5556 functions; remove #pragma weak decls for them.
5557 * specific.c (__libc_internal_tsd_get, __libc_internal_tsd_set):
5558 Define static functions and initialized pointers to them.
5560 1998-11-18 Ulrich Drepper <drepper@cygnus.com>
5562 * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES.
5563 (CFLAGS-specific.c): Likewise.
5564 (CFLAGS-pthread.c): Likewise.
5565 (CFLAGS-ptfork.c): Likewise.
5566 (CFLAGS-cancel.c): Likewise.
5567 * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions
5568 as weak references if __NO_WEAK_PTHREAD_ALIASES is defined.
5570 * mutex.c (pthread_mutex_init): Define as strong symbol.
5571 (pthread_mutex_destroy): Likewise.
5572 (pthread_mutex_trylock): Likewise.
5573 (pthread_mutex_lock): Likewise.
5574 (pthread_mutex_unlock): Likewise.
5575 (pthread_mutexattr_init): Likewise.
5576 (pthread_mutexattr_destroy): Likewise.
5577 (pthread_once): Likewise.
5578 * ptfork.c (pthread_atfork): Likewise.
5579 * specific.c (pthread_key_create): Likewise.
5580 (pthread_setspecific): Likewise.
5581 (pthread_getspecific): Likewise.
5583 1998-11-15 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
5585 * linuxthreads.texi: Fix punctuation after xref.
5587 1998-11-10 H.J. Lu <hjl@gnu.org>
5589 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine NR_OPEN
5590 if it is defined in <linux/limits.h>.
5592 1998-10-29 14:28 Ulrich Drepper <drepper@cygnus.com>
5594 * spinlock.h (__pthread_trylock): Define inline.
5595 (__pthread_lock): Add extra parameter to declaration. Declare
5596 using internal_function.
5597 (__pthread_unlock): Declare using internal_function.
5598 * spinlock.c (__pthread_lock): Add new parameter. Use it instead
5599 of local variable self. Avoid recomputing self. Define using
5601 (__pthread_trylock): Remove.
5602 (__pthread_unlock): Define using internal_function.
5603 * cancel.c: Adjust for __pthread_lock interface change. Use already
5604 computed self value is possible.
5605 * condvar.c: Likewise.
5607 * manager.c: Likewise.
5608 * mutex.c: Likewise.
5609 * pthread.c: Likewise.
5610 * rwlock.c: Likewise.
5611 * semaphore.c: Likewise.
5612 * signals.c: Likewise.
5614 1998-10-27 13:46 Ulrich Drepper <drepper@cygnus.com>
5616 * sysdeps/pthread/pthread.h (struct _pthread_cleanup_buffer): Prepend
5617 __ to field names of the struct.
5618 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_fastlock):
5620 (pthread_attr_t): Likewise.
5621 (pthread_cond_t): Likewise.
5622 (pthread_condattr_t): Likewise.
5623 (pthread_mutex_t): Likewise.
5624 (pthread_mutexattr_t): Likewise.
5625 (pthread_rwlock_t): Likewise.
5626 (pthread_rwlockattr_t): Likewise.
5627 * attr.c: Adjust for pthread.h and pthreadtypes.h change.
5628 * cancel.c: Likewise.
5629 * condvar.c: Likewise.
5630 * manager.c: Likewise.
5631 * mutex.c: Likewise.
5632 * pthread.c: Likewise.
5633 * ptlongjmp.c: Likewise.
5634 * rwlock.c: Likewise.
5635 * spinlock.c: Likewise.
5637 1998-10-09 Ulrich Drepper <drepper@cygnus.com>
5639 * sysdeps/i386/pt-machine.h (get_eflags, set_eflags): Mark these
5642 * sysdeps/i386/i686/pt-machine.h: Remove unused inline
5645 * Makefile (libpthread-routines): Add pt-machine.
5646 * pt-machine.c: New file.
5647 * sysdeps/alpha/pt-machine.h: Define PT_EI as extern inline is not
5648 yet defined. Use PT_EI in extern inline definitions.
5649 * sysdeps/arm/pt-machine.h: Likewise.
5650 * sysdeps/i386/pt-machine.h: Likewise.
5651 * sysdeps/i386/i686/pt-machine.h: Likewise.
5652 * sysdeps/m68k/pt-machine.h: Likewise.
5653 * sysdeps/mips/pt-machine.h: Likewise.
5654 * sysdeps/powerpc/pt-machine.h: Likewise.
5655 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
5656 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
5658 1998-10-02 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5660 * semaphore.h: Include <sys/types.h> so that _pthread_descr
5663 1998-09-15 David S. Miller <davem@pierdol.cobaltmicro.com>
5665 * sysdeps/sparc/sparc32/pt-machine.h (INIT_THREAD_SELF): Add nr
5667 * sysdeps/sparc/sparc64/pt-machine.h (INIT_THREAD_SELF): Likewise.
5669 1998-09-12 14:24 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
5671 * sysdeps/unix/sysv/linux/bits/sigthread.h: Add multiple inclusion
5674 1998-09-02 11:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5676 * signals.c (sigaction): Check that sig is less than NSIG to avoid
5677 array index overflow.
5679 1998-09-06 10:56 Ulrich Drepper <drepper@cygnus.com>
5681 * sysdeps/pthread/semaphore.h: New file.
5683 1998-09-06 09:08 Ulrich Drepper <drepper@cygnus.com>
5685 * sysdeps/pthread/bits/libc-lock.h (enum __libc_tsd_key_t): Add
5686 _LIBC_TSD_KEY_DL_ERROR.
5688 1998-08-31 Ulrich Drepper <drepper@cygnus.com>
5690 * sysdeps/i386/i686/pt-machine.h (testandset): Add memory clobber.
5691 * sysdeps/i386/pt-machine.h: Likewise.
5692 Suggested by Roland McGrath.
5694 1998-08-28 13:58 Ulrich Drepper <drepper@cygnus.com>
5696 * internals.h: Also define THREAD_GETMEM_NC and THREAD_SETMEM_NC to
5697 access thread data with non-constant offsets.
5698 * specific.c: Use THREAD_GETMEM_NC and THREAD_SETMEM_NC where
5701 * sysdeps/i386/useldt.h: Fix typo. Add THREAD_GETMEM_NC and
5702 THREAD_SETMEM_NC definitions.
5704 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM_NC and
5706 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
5708 1998-08-26 15:46 Ulrich Drepper <drepper@cygnus.com>
5710 * internals.h: Define THREAD_GETMEM and THREAD_SETMEM to default if
5711 not already defined.
5712 (struct _pthread_descr_struct): Add p_self and p_nr field.
5713 * manager.c (__pthread_handles): Define second element to point
5715 (__pthread_handles_num): Initialize to 2.
5716 (__pthread_manager): Use INIT_THREAD_SELF with two arguments.
5717 (pthread_start_thread): Likewise.
5718 (pthread_handle_create): Start search for free slot at entry 2.
5719 Initialize new fields p_self and p_nr.
5720 Call __clone with CLONE_PTRACE if available.
5721 (pthread_free): Call FREE_THREAD_SELF if available.
5722 * pthread.c (__pthread_initial_thread): Initialize new fields.
5723 (__pthread_manager_thread): Likewise.
5724 (__pthread_initialize_manager): Call __clone with CLONE_PTRACE.
5726 * cancel.c: Use THREAD_GETMEM and THREAD_SETMEM to access the
5727 elements of the thread descriptor.
5728 * condvar.c: Likewise.
5729 * errno.c: Likewise.
5731 * manager.c: Likewise.
5732 * pthread.c: Likewise.
5733 * ptlongjmp.c: Likewise.
5734 * semaphore.c: Likewise.
5735 * signals.c: Likewise.
5736 * specific.c: Likewise.
5737 * spinlock.c: Likewise.
5739 * sysdeps/alpha/pt-machine.h (INIT_THREAD_SELF): Add extra parameter.
5741 * sysdeps/i386/useldt.h: New file.
5742 * sysdeps/i386/i686/pt-machine.h: Show how to use this file.
5744 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM and
5745 THREAD_SETMEM using __thread_self.
5746 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
5748 1998-08-24 Geoff Keating <geoffk@ozemail.com.au>
5750 * spinlock.c (__pthread_lock): Reset p_nextwaiting to NULL if it
5751 turned out that we didn't need to queue after all.
5753 1998-08-22 Geoff Keating <geoffk@ozemail.com.au>
5755 * sysdeps/powerpc/pt-machine.h: Remove testandset, it's not used
5756 and wastes space; correct types.
5758 1998-08-08 11:18 H.J. Lu <hjl@gnu.org>
5760 * signals.c (sigaction): Handle NULL argument.
5762 1998-08-04 Ulrich Drepper <drepper@cygnus.com>
5764 * sysdeps/unix/sysv/linux/bits/sigthread.h: Use __sigset_t instead
5767 1998-08-02 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5769 * Makefile (linuxthreads-version): Extract correct number from
5772 1998-07-29 Xavier Leroy <Xavier.Leroy@inria.fr>
5774 * Banner: Bump version number to 0.8
5775 * FAQ.html: Many updates, in particular w.r.t. debugging.
5776 * manager.c: Support for non-default stacksize for
5777 LinuxThreads-allocated stacks;
5778 don't use guard pages for stacks with default size, rely on
5779 rlimit(RLIMIT_STACK) instead (it's cheaper).
5781 * cancel.c: Use __pthread_sig_cancel and __pthread_sig_restart
5782 everywhere instead of PTHREAD_SIG_CANCEL and PTHREAD_SIG_RESTART.
5783 * condvar.c: Likewise.
5784 * internals.h: Likewise.
5785 * restart.h: Likewise.
5786 * signals.c: Likewise.
5787 * pthread.c: Likewise; set rlimit(RLIMIT_STACK) as we need it.
5789 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5791 * weaks.c: Define pthread_mutexattr_[sg]ettype instead of
5792 __pthread_mutexattr_[sg]ettype. Add more weak aliases.
5793 * Versions: Put __pthread_mutexattr_settype under version
5794 GLIBC_2.0. Don't export __pthread_mutexattr_setkind_np and
5795 __pthread_mutexattr_gettype.
5797 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5799 * sysdeps/pthread/bits/libc-lock.h: Make
5800 __pthread_mutexattr_settype weak. Don't make
5801 __pthread_mutexattr_setkind_np weak.
5803 1998-07-16 10:52 Ulrich Drepper <drepper@cygnus.com>
5805 * manager.c (pthread_handle_create): Check whether sched_setscheduler
5806 call can succeed here.
5808 * mutex.c: Define __pthread_mutexattr_settype and make
5809 __pthread_mutexattr_setkind_np an alias.
5810 Likewise for __pthread_mutexattr_gettype.
5812 1998-07-15 11:00 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
5814 * attr.c (pthread_attr_setschedpolicy): Don't check whether caller
5817 1998-07-14 19:38 Ulrich Drepper <drepper@cygnus.com>
5819 * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_end.
5821 1998-07-11 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5823 * Examples/ex6.c: Include <unistd.h> for usleep.
5825 1998-06-13 11:04 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5827 * Examples/ex4.c (main): Use exit, not pthread_exit.
5829 1998-07-09 13:39 Ulrich Drepper <drepper@cygnus.com>
5831 * Versions: Add __pthread_mutexattr_gettype and
5832 __pthread_mutexattr_settype.
5833 * lockfile.c: Use __pthread_mutexattr_settype instead of
5834 __pthread_mutexattr_setkind_np.
5835 * mutex.c: Define __pthread_mutexattr_gettype and
5836 __pthread_mutexattr_settype.
5838 * sysdeps/pthread/pthread.h: Declare __pthread_mutexattr_gettype and
5839 __pthread_mutexattr_settype.
5840 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init_recursive):
5841 Use __pthread_mutexattr_settype.
5843 1998-07-08 22:26 Ulrich Drepper <drepper@cygnus.com>
5845 * Versions: Add pthread_mutexattr_gettype, pthread_mutexattr_settype.
5846 * mutex.c: Define weak alias pthread_mutexattr_gettype and
5847 pthread_mutexattr_settype.
5848 * sysdeps/pthread/pthread.h: Declare these functions.
5849 Move pthread_sigmask and pthread_kill declaration in separate header.
5850 * sysdeps/unix/sysv/linux/bits/sigthread.h: New file.
5852 1998-07-07 15:20 Ulrich Drepper <drepper@cygnus.com>
5854 * Makefile: Add rules to compile and run tests.
5855 * Examples/ex1.c: Little changes to fix warnings.
5856 * Examples/ex2.c: Likewise.
5857 * Examples/ex3.c: Likewise.
5858 * Examples/ex4.c: Likewise.
5859 * Examples/ex5.c: Likewise.
5860 * Examples/ex6.c: New file.
5862 1998-07-05 11:54 Ulrich Drepper <drepper@cygnus.com>
5864 * Versions: Add pthread_attr_init to GLIBC_2.1 version in libc.
5866 1998-07-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5868 * attr.c: Include <string.h>.
5870 1998-06-30 11:47 Ulrich Drepper <drepper@cygnus.com>
5872 * attr.c: Include errno.h. Use memcpy to copy sched_param.
5873 * internals.h: Include limits.h.
5874 * manager.c: Use memcpy to copy sched_param.
5875 * ptfork.c: Include errno.h.
5876 * pthread.c: Likewise.
5877 * semaphore.c: Likewise.
5878 * specific.c: Likewise.
5879 * spinlock.h: Likewise.
5880 * sysdeps/pthread/pthread.h: Include only allowed headers. Move
5881 type definition to ...
5882 * sysdeps/pthread/bits/pthreadtypes.h: ...here. New file.
5884 1998-06-29 12:34 Ulrich Drepper <drepper@cygnus.com>
5886 * sysdeps/pthread/pthread.h: Use __PMT not __P for function pointers.
5888 * sysdeps/pthread/pthread.h: Define various PTHREAD_* symbols also
5889 as macros as demanded in POSIX.1, Annex C.
5891 1998-06-29 12:29 Ulrich Drepper <drepper@cygnus.com>
5893 * internals.h (struct pthread_request): For free use pthread_t
5894 instead of pthread_descr.
5895 * join.c (pthread_join): Pass thread_id, not th to manager.
5896 (pthread_detach): Likewise.
5897 * manager.c (__pthread_manager): Except thread ID in FREE_REQ case.
5898 (pthread_exited): Remove detached queue code.
5899 (pthread_handle_free): Expect thread ID parameter and use it to
5900 validate the thread decsriptor. Don't use detached queue.
5901 Patches by Xavier Leroy.
5903 1998-06-27 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5905 * libpthread.map: Export accept, longjmp, sigaction, siglongjmp,
5906 _IO_flockfile, _IO_ftrylockfile, _IO_funlockfile,
5907 __pthread_atfork, __pthread_key_create, __pthread_once.
5908 * internals.h: Doc fix.
5909 * pthread.c (__pthread_initialize): Define again.
5911 1998-06-26 Ulrich Drepper <drepper@cygnus.com>
5913 * manager.c (pthread_exited): If thread is not detached put it on
5915 (pthread_handle_free): If thread is not on list with living threads
5916 search on list with detached threads.
5918 * sysdeps/pthread/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Correct
5919 for new definition of pthread_rwlock_t.
5921 * spinlock.c: Correct test whether to compile
5922 __pthread_compare_and_swap or not.
5924 1998-06-25 19:27 Ulrich Drepper <drepper@cygnus.com>
5926 * attr.c: Finish user stack support. Change locking code to be safe
5927 in situations with different priorities.
5928 * cancel.c: Likewise.
5929 * condvar.c: Likewise.
5930 * internals.h: Likewise.
5932 * manager.c: Likewise.
5933 * mutex.c: Likewise.
5934 * pthread.c: Likewise.
5935 * ptlongjmp.c: Likewise.
5936 * queue.h: Likewise.
5937 * rwlock.c: Likewise.
5938 * semaphore.c: Likewise.
5939 * semaphore.h: Likewise.
5940 * signals.c: Likewise.
5941 * spinlock.c: Likewise.
5942 * spinlock.h: Likewise.
5943 * sysdeps/pthread/pthread.h: Likewise.
5944 Patches by Xavier Leroy.
5946 * sysdeps/i386/i686/pt-machine.h: New file.
5948 1998-06-25 Ulrich Drepper <drepper@cygnus.com>
5950 * sysdeps/pthread/pthread.h: Make [sg]et_stacksize and
5951 [sg]et_stackaddr prototypes always available.
5953 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
5954 _POSIX_THREAD_ATTR_STACKSIZE and _POSIX_THREAD_ATTR_STACKADDR.
5956 1998-06-24 Ulrich Drepper <drepper@cygnus.com>
5958 * manager.c (pthread_free): Undo patch from 980430.
5959 Reported by David Wragg <dpw@doc.ic.ac.uk>.
5961 1998-06-09 15:07 Ulrich Drepper <drepper@cygnus.com>
5963 * manager.c: Define __pthread_manager_adjust_prio and use it to
5964 increase priority when needed.
5965 * internals.h: Add prototype for __pthread_manager_adjust_prio.
5966 * mutex.c: Optimize mutexes to wake up only one thread.
5967 * pthread.c: Move PID of manager for global variable in structure
5969 Patches by Xavier Leroy.
5971 1998-06-07 13:47 Ulrich Drepper <drepper@cygnus.com>
5973 * sysdeps/pthread/bits/libc-lock.h: Optimize cleanup handlers a bit.
5975 1998-06-03 Andreas Jaeger <aj@arthur.rhein-neckar.de>
5977 * attr.c: Correct typo.
5979 1998-05-01 Ulrich Drepper <drepper@cygnus.com>
5981 * manager.c (pthread_free): Unmap guard before the stack.
5982 Patch by Matthias Urlichs.
5984 1998-04-30 Ulrich Drepper <drepper@cygnus.com>
5986 * manager.c (pthread_free): Detect already free child.
5987 Patch by Xavier Leroy, reported by Matthias Urlichs.
5989 1998-04-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
5991 * Makefile (linuxthreads-version): Renamed back from
5994 1998-04-21 Ulrich Drepper <drepper@cygnus.com>
5996 * ptlongjmp.c: Add prototypes for __libc_siglongjmp and
5999 1998-04-20 14:55 Ulrich Drepper <drepper@cygnus.com>
6001 * Makefile (libpthread-routines): Add ptlongjmp and spinlock.
6002 * internals.h: Add definitions for new spinlock implementation.
6003 * ptlongjmp.c: New file.
6004 * spinlock.c: New file.
6005 * spinlock.h (acquire): Don't reschedule using __sched_yield, use
6006 new function __pthread_acquire to prevent deadlocks with thread
6007 with different priorities.
6008 Patches by Xavier Leroy <Xavier.Leroy@inria.fr>.
6010 1998-03-16 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
6012 * manager.c (__pthread_manager): Reduce first argument to select
6013 to include just the needed file descriptor.
6015 1998-03-17 00:06 Ulrich Drepper <drepper@cygnus.com>
6017 * manager.c: Fix last patch which caused core dumps.
6019 * pthread.c: Correctly handle missing SIGRTMIN.
6021 1998-03-15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
6023 * libpthread.map: Add __libc_internal_tsd_get and
6024 __libc_internal_tsd_set. Add missing cancelable functions. Export
6025 libc internal versions of the cancelable functions.
6027 1998-03-13 16:51 Ulrich Drepper <drepper@cygnus.com>
6029 * weaks.c: Define pthread_attr_init as GLIBC_2.0 and GLIBC_2.1.
6031 1998-03-13 00:46 Ulrich Drepper <drepper@cygnus.com>
6033 * attr.c: Implement pthread_attr_[gs]etguardsize,
6034 pthread_attr_[gs]setstackaddr, pthread_attr_[gs]etstacksize.
6035 Change pthread_attr_init to have two interfaces.
6036 * internals.h (struct _pthread_descr_struct): Add new fields for
6038 * libpthread.map: Add names in GLIBC_2.1 section.
6039 * manager.c (pthread_handle_create): Implement guardsize and
6041 (pthread_free): Likewise.
6042 * pthread.c (pthread_create): Add new interface for changed
6044 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
6045 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add definition of
6048 1998-03-11 00:42 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
6050 * manager.c: Enable resetting of the thread scheduling policy
6051 to SCHED_OTHER when the parent thread has a different one.
6053 1998-02-01 13:51 Ulrich Drepper <drepper@cygnus.com>
6055 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
6056 _POSIX_ASYNCHRONOUS_IO.
6058 * sysdeps/pthread/pthread.h: Define bits for Unix98 variants of
6060 * mutex.c: Implement new mutex types.
6062 * internals.h: Include <signal.h>.
6064 * libpthread.map: Add __erno_location and __h_errno_location.
6066 * errno.c: Return pointer to variable actually in use. This might
6067 not be the one in the thread structure.
6068 * internals.h (struct _pthread_descr_struct): Add new fields p_errnop
6070 * manager.c (__pthread_manager): Set p_errnop and p_h_errnop member
6071 of manager thread structure.
6072 (pthread_handle_create): Set p_errnop and p_h_errnop members for new
6074 * pthread.c: Adapt initializer for thread structures.
6075 (__pthread_initial_thread): Set p_errnop and p_h_errnop member.
6076 (__pthread_reset_main_thread): Reset p_errnop and p_h_errnop of
6077 current thread to global variables.
6079 1998-01-31 17:27 Ulrich Drepper <drepper@cygnus.com>
6081 * rwlock.c: New file.
6082 * Makefile (libpthread-routines): Add rwlock.
6083 * sysdeps/pthread/pthread.h: Define data structures and declare
6085 * libpthread.map: Add new functions.
6087 1997-12-18 13:50 Philip Blundell <pb@nexus.co.uk>
6089 * sysdeps/arm/pt-machine.h: New file; add ARM support.
6090 * sysdeps/arm/Implies: likewise.
6091 * README: Document it.
6093 1997-12-13 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
6095 * signals.c: Remove unneeded initializer for sigwaited, saving a
6098 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
6100 * semaphore.c (sem_init): Set sem_spinlock only if available.
6102 1997-12-04 01:48 Ulrich Drepper <drepper@cygnus.com>
6104 * mutex.c: Implement PTHREAD_MUTEX_CHECKERROR.
6105 * sysdeps/pthread/pthread.h: Define PTHREAD_MUTEX_CHECKERROR.
6107 * Makefile: Update from LinuxThreads 0.7.
6108 * internals.h. Likewise.
6109 * manager.c: Likewise.
6110 * mutex.c: Likewise.
6111 * pthread.c: Likewise.
6112 * signals.c: Likewise.
6113 * specific.c: Likewise.
6114 * Examples/ex3.c: Likewise.
6116 1997-11-20 18:13 Ulrich Drepper <drepper@cygnus.com>
6118 * pthread.c (__pthread_reset_main_thread): Close pipe only if still
6121 1997-10-29 05:38 Ulrich Drepper <drepper@cygnus.com>
6123 * wrapsyscall.c: Add socket functions which are also cancelation
6126 1997-10-19 21:40 Wolfram Gloger <wg@wolfram.dent.med.uni-muenchen.de>
6128 * specific.c (__libc_internal_tsd_set, __libc_internal_tsd_get):
6129 New functions for fast thread specific data within libc.
6131 * internals.h: Add new array p_libc_specific to struct
6132 _pthread_descr_struct.
6134 * sysdeps/pthread/bits/libc-lock.h: Declare new functions.
6136 1997-10-13 05:39 Ulrich Drepper <drepper@cygnus.com>
6138 * semaphore.h: Add __BEGIN_DECLS/__END_DECLS.
6139 Reported by Ralf Corsepius <corsepiu@faw.uni-ulm.de>.
6141 1997-08-29 03:05 Ulrich Drepper <drepper@cygnus.com>
6143 * internals.h (struct _pthread_descr_struct): Add definitions for
6144 two-level specific key handling.
6145 * manager.c (pthread_handle_create): Initialize specific memory array.
6146 * specific.c: Implement two-level key handling.
6147 * weaks.c: Don't provide dummy key handling.
6148 * sysdeps/pthread/bits/libc-lock.h: Typedef __libc_lock_t (no #define).
6149 Add definition of __libc_key_t.
6150 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define PTHREAD_KEYS_MAX
6152 Add definition of _POSIX_THREAD_DESTRUCTOR_ITERATIONS and
6153 PTHREAD_DESTRUCTOR_ITERATIONS.
6155 * manager.c (pthread_handle_create): Compare mmap result with
6158 * ptfork.c: Rename to __pthread_atfork and make old name a weak alias.
6159 * sysdeps/pthread/bits/pthread.h: Add prototype for __pthread_atfork.
6161 1997-08-22 19:04 Richard Henderson <rth@cygnus.com>
6163 sysdeps/sparc -> sysdeps/sparc/sparc32
6164 sysdeps/sparc64 -> sysdeps/sparc/sparc64
6166 * internals.h: Change definition of THREAD_SELF to be an expression,
6167 not a statement that did a return.
6168 * sysdeps/alpha/pt-machine.h (THREAD_SELF): Update accordingly.
6169 * sysdeps/sparc/sparc32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
6170 Follow Solaris and use a "system reserved" register (%g6) to hold
6171 the thread descriptor.
6172 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
6174 1997-08-03 00:09 Ulrich Drepper <drepper@cygnus.com>
6176 * mutex.c: Correct pthread_once. Patch by Xavier Leroy.
6177 * sysdeps/pthread/pthread.h: Add prototype for __pthread_once.
6178 * sysdeps/pthread/bits/pthread.h: Add macros for __libc_once.
6180 * semaphore.c: Include spinlock.h only when needed.
6182 * specific.c (__pthread_setsepcific, __pthread_getspecific): Reject
6183 keys for entries not in use.
6185 * weaks.c: Implement key handling functions for real.
6187 1997-06-29 01:04 Richard Henderson <richard@gnu.ai.mit.edu>
6189 Initial sparc64-linux support:
6190 * sysdeps/sparc64/Implies: New file.
6191 * sysdeps/sparc64/pt-machine.h: Likewise.
6193 1997-06-29 00:48 Ulrich Drepper <drepper@cygnus.com>
6195 * semaphore.c: Include spinlock.h at correct place.
6198 1997-06-13 10:06 Richard Henderson <rth@tamu.edu>
6200 The Great Bit File Move:
6201 * sysdeps/alpha/semaphorebits.h: -> .../bits/semaphore.h.
6202 * sysdeps/powerpc/semaphorebits.h: Likewise.
6203 * sysdeps/pthread/cmpxchg/semaphorebits.h: Likewise.
6204 * sysdeps/pthread/no-cmpxchg/semaphorebits.h: Likewise.
6205 * sysdeps/pthread/libc-lock.h: -> bits/
6206 * sysdeps/pthread/stdio-lock.h: Likewise.
6207 * sysdeps/unix/sysv/linux/local_lim.h: Likewise.
6208 * sysdeps/unix/sysv/linux/posix_opt.h: Likewise.
6209 * semaphore.h: Likewise.
6210 * sysdeps/pthread/pthread.h: Likewise.
6212 * lockfile.c: <foo.h> -> <bits/foo.h>.
6213 * semaphore.h: Likewise.
6215 * Makefile: (headers): foo.h -> bits/foo.h.
6216 * sysdeps/pthread/Makefile: Likewise.
6218 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
6220 * semaphore.c (sem_init): Set sem_spinlock only if available.
6222 * sysdeps/m68k/pt-machine.h (testandset, __compare_and_swap): Fix
6225 1997-04-09 03:00 Ulrich Drepper <drepper@cygnus.com>
6227 Update from LinuxThreads 0.6.
6229 * attr.c (pthread_attr_getdetachstate): Use __sched_get_priority_max
6230 and __sched_get_priority_min instead of names without `__'.
6232 * manager.c: Rewrite large parts to implement opaque pthread_t.
6234 * cancel.c: Adapt for opaque pthread_t type.
6235 * condvar.c: Likewise.
6236 * errno.c: Likewise.
6238 * mutex.c: Likewise.
6239 * pthread.c: Likewise.
6240 * signals.c: Likewise.
6241 * specific.c: Likewise.
6242 * restart.h: Likewise.
6243 * queue.h: Likewise.
6244 * Examples/ex3.c: Likewise.
6245 * Examples/ex4.c: Likewise.
6246 * sysdeps/pthread/pthread.h: Likewise.
6248 * pthread.c: Accumulate time for all threads in thread manager.
6250 * semaphore.c: Implement fallback implementation for architectures
6251 sometimes missing compare-exchange operations.
6253 * cancel.c (pthread_cancel): Validate handle argument.
6254 * join.c (pthread_join): Likewise.
6255 (pthread_detach): Likewise.
6256 * signals.c (pthread_kill): Likewise.
6258 * spinlock.h (acquire): Use __sched_yield not sched_yield.
6260 * queue.h (enqueue): Enqueue thread according to priority.
6262 * internals.c (struct pthread_start_args): New struct for passing
6263 args to cloning function.
6264 (struct _pthread): Rename to _pthread_descr_struct and adapt for
6267 * Examples/Makefile (clean): Pass -f option to rm.
6269 * sysdeps/i386/pt-machine.h: Add check for compare-exchange instruction
6270 and define TEST_FOR_COMPARE_AND_SWAP.
6271 * sysdeps/i386/i486/pt-machine.h: Removed.
6273 * sysdeps/unix/sysv/linux/local_lim.h (PTHREAD_THREADS_MAX): Increase
6276 1997-04-04 16:38 Ulrich Drepper <drepper@cygnus.com>
6278 * restart.h (suspend): Clear p_signal before suspending.
6279 (suspend_with_cancellation): Likewise.
6280 Patch by Xavier Leroy <Xavier.Leroy@inria.fr>.
6282 * weaks.c: Make __pthread_key_create return 1.
6283 * sysdeps/pthread/libc-lock.h: Define __libc_key_create,
6284 __libc_getspecific, __libc_setspecific, and __libc_key_t.
6285 * sysdeps/pthread/stdio-lock.h: Don't care for implementation not
6288 1997-03-19 15:13 Miguel de Icaza <miguel@nuclecu.unam.mx>
6290 * sysdeps/sparc/pt-machine (RELEASE): Fix.
6292 1997-03-01 07:55 Geoff Keating <geoffk@ozemail.com.au>
6294 * sysdeps/powerpc/Implies: Added.
6295 * sysdeps/powerpc/pt-machine.h: Added.
6296 * sysdeps/powerpc/semaphorebits.h: Added.
6298 1997-01-22 01:22 Ulrich Drepper <drepper@cygnus.com>
6300 * pthread.c (__pthread_initial_thread): Correct
6302 (__pthread_manager_thread): Likewise.
6303 Reported by Andreas Jaeger.
6305 1997-01-18 22:15 Richard Henderson <rth@tamu.edu>
6307 Since sigset_t no longer fits in a register, we can't pass in the
6308 thread's initial mask so easily. Take this opportunity to simplify
6309 the clone implementation by only accepting a single void* argument.
6311 * manager.c (__pthread_manager): Put thread vitals in the thread
6312 struct instead of as arguments through clone.
6313 (pthread_start_thread): Look for them there.
6314 * internals.h (struct _pthread): Add p_initial_fn,
6315 p_initial_fn_arg, p_initial_mask. Fix __pthread_manager proto.
6316 * pthread.c (pthread_initialize_manager): Revise clone invocation.