Update.
[glibc.git] / linuxthreads / ChangeLog
blobbf842818d7b761d2ad2898181b8f47d0f0ad55c2
1 2005-03-21  GOTO Masanori  <gotom@debian.or.jp>
3         * linuxthreads/sysdeps/m68k/Makefile: Remove to delete
4         unneeded o-iterator thing.
6 2005-02-21  H.J. Lu  <hongjiu.lu@intel.com>
8         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Add local _init
9         and _fini labels.
11 2005-03-05  Ulrich Drepper  <drepper@redhat.com>
13         * sysdeps/i386/Makefile (CFLAGS-pt-initfini.s): Unconditionally
14         use -mtune.
16 2005-03-05  Roland McGrath  <roland@redhat.com>
18         * sysdeps/i386/Makefile (CFLAGS-pt-initfini.s): Use $(cc-mtune).
20 2005-03-05  Jakub Jelinek  <jakub@redhat.com>
22         * sysdeps/powerpc/tcb-offsets.sym (thread_offsetof): Rework for GCC 4.
24 2005-02-09  Daniel Jacobowitz  <dan@codesourcery.com>
26         [BZ #740]
27         * descr.h (__pthread_find_self, thread_self): Mark as pure
28         instead of const.
30 2005-02-07  Jakub Jelinek  <jakub@redhat.com>
32         [BZ #739]
33         * specific.c (pthread_key_delete): If pthread_create has not been
34         called yet, clear p_specific for the current thread.
35         * Makefile (tests): Add tst-tsd1.
36         * tst-tsd1.c: New test.
38 2005-01-08  Andreas Jaeger  <aj@suse.de>
40         * pthread.c (init_one_static_tls): Adjust initialization of DTV
41         entry for static tls deallocation fix.
43         * sysdeps/alpha/tls.h (dtv_t): Change pointer type to be struct which
44         also contains information whether the memory pointed to is static
45         TLS or not, include <stdbool.h>.
46         * sysdeps/i386/tls.h: Likewise.
47         * sysdeps/ia64/tls.h: Likewise.
48         * sysdeps/powerpc/tls.h: Likewise.
49         * sysdeps/s390/tls.h: Likewise.
50         * sysdeps/sh/tls.h: Likewise.
51         * sysdeps/sparc/tls.h: Likewise.
52         * sysdeps/x86_64/tls.h: Likewise.
54 2004-12-21  Jakub Jelinek  <jakub@redhat.com>
56         * Makefile (tests): Add tst-align.
57         * tst-align.c: New test.
58         * sysdeps/i386/Makefile (CFLAGS-tst-align.c): Add
59         -mpreferred-stack-boundary=4.
61 2004-12-12  Ulrich Drepper  <drepper@redhat.com>
63         * internals.h: Include <stdbool.h> to match includes used in nptl.
65 2004-12-01  Jakub Jelinek  <jakub@redhat.coM.
67         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_CPUTIME,
68         _POSIX_THREAD_CPUTIME): Define to 0.
69         * sysdeps/pthread/timer_create.c (timer_create): Remove unused code
70         handling CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID.
71         * sysdeps/pthread/timer_routines.c (__timer_signal_thread_pclk,
72         __timer_signal_thread_tclk): Remove.
73         (init_module): Remove their initialization.
74         (thread_cleanup): Remove their cleanup assertions.
75         * sysdeps/pthread/posix-timer.h (__timer_signal_thread_pclk,
76         __timer_signal_thread_tclk): Remove.
77         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Removed.
78         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Removed.
79         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Removed.
80         * tst-clock1.c (do_test): Check for availability of CPU clock.
82 2004-11-18  Daniel Jacobowitz  <dan@codesourcery.com>
84         * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h: Update RETINSTR use.
85         * sysdeps/unix/sysv/linux/arm/vfork.S: Likewise.
87 2004-12-02  Roland McGrath  <roland@redhat.com>
89         * Makefile (libpthread-nonshared): Variable removed.
90         ($(objpfx)libpthread_nonshared.a): Target removed.
91         ($(inst_libdir)/libpthread_nonshared.a): Likewise.
92         These are now handled by generic magic from
93         libpthread-static-only-routines being set.
95 2004-11-27  Ulrich Drepper  <drepper@redhat.com>
97         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_PRIORITIZED_IO,
98         _POSIX2_CHAR_TERM, _POSIX_THREAD_PRIO_INHERIT,
99         _POSIX_THREAD_PRIO_PROTECT): Define.
100         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
101         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
102         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
104 2004-11-26  Jakub Jelinek  <jakub@redhat.com>
106         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_ADVISORY_INFO,
107         _POSIX_SPORADIC_SERVER, _POSIX_THREAD_SPORADIC_SERVER, _POSIX_TRACE,
108         _POSIX_TRACE_EVENT_FILTER, _POSIX_TRACE_INHERIT, _POSIX_TRACE_LOG,
109         _POSIX_TYPED_MEMORY_OBJECTS): Define.
110         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
111         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
112         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
114 2004-11-05  Maciej W. Rozycki  <macro@mips.com>
116         * sysdeps/mips/pspinlock.c: Include <sgidefs.h>.  Use _ABIO32,
117         _ABIN32 and _ABI64 for ABI selection throughout.
118         * sysdeps/mips/pt-machine.h: Use _ABIO32, _ABIN32 and _ABI64 for
119         ABI selection throughout.
121 2004-10-18  Roland McGrath  <roland@redhat.com>
123         [BZ #406]
124         * Makefile (linuxthreads-CPPFLAGS): New variable;
125         adds -DIS_IN_linuxthreads=1.
126         * sysdeps/i386/tls.h: Protect "useldt.h" with
127         [!IS_IN_linuxthreads && !DO_MODIFY_LDT].
128         * sysdeps/i386/i686/pt-machine.h: Revert last change.
130 2004-10-14  Jakub Jelinek  <jakub@redhat.com>
132         * sysdeps/pthread/errno-loc.c: Don't undef #errno
133         if RTLD_PRIVATE_ERRNO.
135 2004-10-05  Dwayne Grant McConnell  <dgm69@us.ibm.com>
137         * pthread.c: Mask restart signal during cancel signal handler.
139 2004-10-05  Jakub Jelinek  <jakub@redhat.com>
141         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h (_POSIX_CPUTIME,
142         _POSIX_THREAD_CPUTIME): Define to 0.
144 2004-10-04  Ulrich Drepper  <drepper@redhat.com>
146         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Set _POSIX_CPUTIME
147         and _POSIX_THREAD_CPUTIME to zero.
148         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
150         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
151         _POSIX_THREAD_PROCESS_SHARED and _POSIX_CLOCK_SELECTION as -1.
152         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
153         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
154         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
156 2004-09-25  Roland McGrath  <roland@redhat.com>
158         [BZ #406]
159         * sysdeps/i386/i686/pt-machine.h: Don't #include "../useldt.h" if
160         [_TLS_H], since sysdeps/i386/tls.h includes it after including us.
162 2004-09-24  Roland McGrath  <roland@redhat.com>
164         [BZ #406]
165         * sysdeps/i386/tls.h: Move #include "useldt.h" outside
166         of [__ASSUME_LDT_WORKS > 0] test.
167         Reported by Carlos Velasco <carlos.velasco@newipnet.com>.
169 2004-09-21  Roland McGrath  <roland@redhat.com>
171         * Versions: Add comment about linuxthreads' frozen ABI.
173 2004-09-20  Ulrich Drepper  <drepper@redhat.com>
175         * Versions: Remove exports for pthread_set*id_np functions.
176         * sysdeps/pthread/pthread.h: Remove pthread_set*id_np prototypes
177         for now.
178         * Makefile: Don't build pthread_set*id code for now.
180 2004-09-19  Ulrich Drepper  <drepper@redhat.com>
182         * sysdeps/pthread/pthread.h: Declare pthread_setgid_np,
183         pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
184         pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
185         and pthread_setresuid_np.
186         * pthread_setgid_np.c: New file.
187         * pthread_setuid_np.c: New file.
188         * pthread_setegid_np.c: New file.
189         * pthread_seteuid_np.c: New file.
190         * pthread_setregid_np.c: New file.
191         * pthread_setreuid_np.c: New file.
192         * pthread_setresgid_np.c: New file.
193         * pthread_setresuid_np.c: New file.
194         * Versions [libpthread, GLIBC_2.3.4]: Add pthread_setgid_np,
195         pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
196         pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
197         and pthread_setresuid_np.
198         * Makefile (libpthread-routines): Add pthread_setuid, pthread_seteuid,
199         pthread_setreuid, pthread_setresuid, pthread_setgid, pthread_setegid,
200         pthread_setregid, and pthread_setresgid.
202 2004-09-12  Ulrich Drepper  <drepper@redhat.com>
204         * sysdeps/pthread/pthread.h: Make rwlock prototypes available also
205         for __USE_XOPEN2K.
206         * sysdeps/pthread/bits/pthreadtypes.h: Define rwlock types also
207         for __USE_XOPEN2K.  [BZ #320]
209 2004-09-04  Jakub Jelinek  <jakub@redhat.com>
211         * tst-cancel4.c (tf_waitid): Use WEXITED flag bit if available.
213 2004-09-07  Ulrich Drepper  <drepper@redhat.com>
215         * sysdeps/pthread/pthread.h (pthread_once): Remove __THROW since
216         the initialization function might throw.
218 2004-08-30  Roland McGrath  <roland@frob.com>
220         * Makefile (libpthread-abi-frozen): New variable.
222 2004-08-26  Roland McGrath  <roland@redhat.com>
224         * configure.in: New file.  If nptl add-on is also selected, barf if
225         explicit and elide ourselves if implicit.
226         * configure: Now generated.
228 2004-08-25  Richard Sandiford  <rsandifo@redhat.com>
230         * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h (CENABLE, CDISABLE,
231         __local_multiple_threads): Fix definitions for IS_IN_librt.
232         * sysdeps/unix/sysv/linux/mips/mips64/sysdep-cancel.h: Likewise.
234 2004-08-22  Andreas Schwab  <schwab@suse.de>
236         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO) [IS_IN_librt]:
237         Save gp around CENABLE/CDISABLE calls.
239 2004-08-15  Roland McGrath  <roland@frob.com>
241         * pthread_atfork.c: Update copyright terms including special exception
242         for these trivial files, which are statically linked into executables
243         that use dynamic linking for the significant library code.
245 2004-08-09  Jakub Jelinek  <jakub@redhat.com>
247         * libc-tsd.c: Move resolv.h include before the #if.
248         (__res_maybe_init): New function.  Add libc_hidden_def.
250 2004-08-02  Ulrich Drepper  <drepper@redhat.com>
252         * linuxthreads.texi (Cleanup Handlers): Fix typo.
253         Reported by Bjoern Engelmann <bjengelmann@gmx.de>.
255 2004-07-23  Jakub Jelinek  <jakub@redhat.com>
257         [BZ #284]
258         * sysdeps/pthread/pthread.h (pthread_getcpuclockid): Use __clockid_t
259         instead of clockid_t.
261 2004-07-21  Roland McGrath  <roland@redhat.com>
263         * Makefile ($(objpfx)multidir.mk): Use $(make-target-directory).
265 2004-07-02  Roland McGrath  <roland@redhat.com>
267         * configure: Don't exit.
269 2004-07-20  Alexandre Oliva  <aoliva@redhat.com>
271         * sysdeps/mips/pt-machine.h: Use standard names for ABI macros,
272         include sgidefs.h.
273         * sysdeps/mips/atomicity.h: Likewise.
275 2004-07-19  Alexandre Oliva  <aoliva@redhat.com>
277         * sysdeps/unix/sysv/linux/mips/Makefile (CFLAGS-pt-initfini.s):
278         Remove redundant override that missed -g0.
280 2004-07-14  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
282         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
283         (__local_multiple_threads): Define for librt.
284         (SINGLE_THREAD_P): Likewise.
286 2004-07-07  Jakub Jelinek  <jakub@redhat.com>
288         * sysdeps/pthread/getcpuclockid.c (pthread_getcpuclockid): Allow
289         using other thread's clock.
290         * ptclock_gettime.c (__pthread_clock_gettime): Likewise.
291         * ptclock_settime.c (__pthread_clock_settime): Likewise.
292         * internals.h (__pthread_clock_gettime, __pthread_clock_settime):
293         Remove prototypes.
294         Reported by Bernd Schmidt <bernds@redhat.com>.
295         * Makefile (librt-tests): Add tst-clock1.
296         * tst-clock1.c: New test.
298         * sysdeps/x86_64/Versions: New file.
299         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: New file.
300         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: New file.
302 2004-04-16  Andreas Schwab  <schwab@suse.de>
304         * sysdeps/ia64/tls.h (INIT_SYSINFO): Cast dl_sysinfo to void*.
306 2004-07-05  Jakub Jelinek  <jakub@redhat.com>
308         * sysdeps/s390/pspinlock.c (__pthread_spin_lock,
309         __pthread_spin_trylock): Use constraint "m" instead of "0" for
310         futex.
311         * sysdeps/ia64/pt-machine.h (__compare_and_swap,
312         __compare_and_swap_with_release_semantic, testandset): Use
313         constraint "m" instead of "0" for futex.
315 2004-06-29  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
317         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (CENABLE): Fix
318         branch offset for a PLT entry.
319         (CDISABLE): Likewise.
321 2004-05-31  Andreas Jaeger  <aj@suse.de>
323         * sysdeps/unix/sysv/linux/mips/Makefile (CFLAGS-pt-initfini.s):
324         Set to -fno-unit-at-a-time.
325         Patch by Dan Kegel <dank@kegel.com>.
327 2004-05-04  Jakub Jelinek  <jakub@redhat.com>
329         * tst-stack1.c: Don't include mcheck.h.
330         (do_test): Make sure user defined stacks aren't reused,
331         don't free them at the end.  [BZ #110]
333 2004-05-02  Jakub Jelinek  <jakub@redhat.com>
335         * manager.c: Include not-cancel.h.
336         (__pthread_manager): Use read_not_cancel instead of __libc_read.
337         (pthread_start_thread, __pthread_manager_sighandler): Use
338         write_not_cancel instead of __libc_write.
339         (pthread_reap_children): Use waitpid_not_cancel instead of
340         __libc_waitpid.
341         * pthread.c: Include not-cancel.h.
342         (__pthread_initialize_minimal, __pthread_create_2_1,
343         pthread_onexit_process, __pthread_message): Use
344         write_not_cancel instead of __libc_write.
345         (__pthread_initialize_manager): Likewise.  Use close_not_cancel
346         instead of __libc_close.
347         (__pthread_reset_main_thread): Use close_not_cancel instead of
348         __libc_close.
349         * join.c: Include not-cancel.h.
350         (__pthread_do_exit, pthread_join, pthread_detach): Use
351         write_not_cancel instead of __libc_write.
352         * semaphore.c: Include not-cancel.h.
353         (__new_sem_post): Use write_not_cancel instead of __libc_write.
354         * specific.c: Include not-cancel.h.
355         (pthread_key_delete): Use write_not_cancel instead of __libc_write.
357 2004-05-01  Jakub Jelinek  <jakub@redhat.com>
359         * Versions (libc): Add __on_exit and __libc_sigaction.
361 2004-04-28  Jakub Jelinek  <jakub@redhat.com>
363         * semaphore.c (sem_timedwait): Return -1 and set errno instead of
364         returning error number [BZ #133].  Patch by <rmhaddad@yahoo.com>.
366 2004-04-22  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
368         * sysdeps/unix/sysv/linux/sh/vfork.S: Fix wrong function pointer
369         reference in PIC case.
371 2004-04-20  Jakub Jelinek  <jakub@redhat.com>
373         * oldsemaphore.c (SEM_VALUE_MAX): Remove.
375 2004-04-19  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
377         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (CENABLE): Define
378         for librt.  Save the return value to a safe register.
379         (CDISABLE): Define for librt.  Set the function argument correctly.
381 2004-04-18  Jakub Jelinek  <jakub@redhat.com>
383         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
384         (PSEUDO_CANCEL): Define.
385         (PSEUDO): Use it.
386         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (CENABLE,
387         CDISABLE): For librt, append @PLT.
389 2004-04-17  Jakub Jelinek  <jakub@redhat.com>
391         * sysdeps/x86_64/tls.h [!__ASSEMBLER__]: Include tcb-offsets.h.
393         * sysdeps/pthread/timer_gettime.c (timer_gettime): For expired timer
394         return it_value { 0, 0 }.
395         * sysdeps/pthread/timer_create.c (timer_create): Handle SIGEV_NONE
396         like SIGEV_SIGNAL.
397         * sysdeps/pthread/timer_routines.c (thread_expire_timer): Remove
398         assertion for SIGEV_NONE.
399         (thread_attr_compare): Compare all attributes, not just a partial
400         subset.
402         * sysdeps/unix/sysv/linux/mq_notify.c: Include stdlib.h.
404 2004-04-17  Ulrich Drepper  <drepper@redhat.com>
406         * semaphore.h (SEM_VALUE_MAX): Just use a plain number.
408 2004-04-16  Ulrich Drepper  <drepper@redhat.com>
410         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Fix last patch.
412 2004-04-13  Jakub Jelinek  <jakub@redhat.com>
414         * sysdeps/unix/sysv/linux/mq_notify.c: Shut up GCC warning.
416 2004-04-12  Ulrich Drepper  <drepper@redhat.com>
418         * sysdeps/unix/sysv/linux/mq_notify.c: New file.
420         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (CENABLE): Define
421         for librt.
422         (CDISABLE): Likewise.
424 2004-04-08  Jakub Jelinek  <jakub@redhat.com>
426         * sysdeps/unix/sysv/linux/bits/local_lim.h (MQ_PRIO_MAX): Define.
427         * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h (MQ_PRIO_MAX): Define.
428         * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h (MQ_PRIO_MAX): Define.
429         * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h (MQ_PRIO_MAX): Define.
430         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_MESSAGE_PASSING):
431         Define.
432         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h
433         (_POSIX_MESSAGE_PASSING): Define.
435 2004-04-10  Andreas Jaeger  <aj@suse.de>
437         * sysdeps/x86_64/pt-machine.h: Add used attribute to stack_pointer
438         to avoid warnings with GCC 3.5.
440 2004-04-09  Steven Munroe  <sjmunroe@us.ibm.com>
442         * sysdeps/powerpc/tls.h (TLS_INIT_TP): Eliminate lvalue cast from
443         __thread_self assignment.
444         (THREAD_DTV): Replace __thread_register with __thread_self.
445         (INIT_THREAD_SELF): Eliminate lvalue cast from __thread_self
446         assignment.
448 2004-04-08  Alexandre Oliva  <aoliva@redhat.com>
450         * signals.c (pthread_sigmask): Don't ever block or mask
451         __pthread_sig_debug.
453 2004-03-11  Steven Munroe  <sjmunroe@us.ibm.com>
455         * sysdeps/powerpc/tls.h: Remove __powerpc64__ conditional.
457 2004-03-23  Ulrich Drepper  <drepper@redhat.com>
459         * sysdeps/ia64/pt-machine.h (BUSY_WAIT_NOP): Define.
460         * sysdeps/x86_64/pt-machine.h (BUSY_WAIT_NOP): Likewise.
462 2004-03-12  Ulrich Drepper  <drepper@redhat.com>
464         * sysdeps/unix/sysv/linux/bits/local_lim.h: Add HOST_NAME_MAX.
465         * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
466         * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
467         * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
469 2004-03-08  Andreas Jaeger  <aj@suse.de>
471         * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT_KERNEL_CHECK):
472         dl_osversion is readonly.
474 2004-03-07  Ulrich Drepper  <drepper@redhat.com>
476         * sysdeps/i386/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
477         _rtlf_global_ro.
478         * sysdeps/ia64/tls.h (INIT_SYSINFO): Likewise.
480 2004-02-20  Steven Munroe  <sjmunroe@us.ibm.com>
482         * sysdeps/unix/sysv/linux/powerpc/ptlongjmp.c [SHARED]: Code only
483         valid for SHARED case.  Correct spelling of __vmx_longjmp.
485         * sysdeps/powerpc/pspinlock.c: Move from here.
486         * sysdeps/powerpc/powerpc32/pspinlock.c: To here.
487         * sysdeps/powerpc/powerpc64/pspinlock.c: New file.
488         * sysdeps/powerpc/powerpc64/pt-machine.h: Define __compare_and_swap32
489         and __compare_and_swap32_with_release_semantics.
491 2004-02-20  Jakub Jelinek  <jakub@redhat.com>
493         * Makefile (generated): Remove tst-stack1.mtrace and tst-stack1-mem.
494         (tests): Remove $(objpfx)tst-stack1-mem.
495         (tst-stack1-ENV): Remove.
496         ($(objpfx)tst-stack1-mem): Remove.
498         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
499         (__syscall_error_handler2): Call CDISABLE.
500         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
501         (__syscall_error_handler2): Call CDISABLE.
503         * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h (DL_ARGV_NOT_RELRO): Define.
505 2004-02-10  Steven Munroe  <sjmunroe@us.ibm.com>
507         * Makefile (libpthread-routines): Add ptcleanup.
508         * ptlongjmp.c: Removed.
509         * ptcleanup.c: Copied __pthread_cleanup_upto to here. New file.
510         * sysdeps/pthread/ptlongjmp.c: Copied longjmp to here. New file.
511         * sysdeps/unix/sysv/linux/powerpc/Versions: New file.
512         Version longjmp, siglongjmp for GLIBC_2.3.4.
513         * sysdeps/unix/sysv/linux/powerpc/ptlongjmp.c: New File.
515 2004-01-22  Andreas Jaeger  <aj@suse.de>
517         * spinlock.c (__pthread_lock): Fix contraint to avoid warning.
518         (__pthread_release): Likewise.
520 2004-01-16  Richard Henderson  <rth@redhat.com>
522         * attr.c: Include ldsodefs.h.
523         (pthread_getattr_np): Don't declare __libc_stack_end.
525 2004-01-09  Steven Munroe  <sjmunroe@us.ibm.com>
527         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
528         [!HAVE_TLS_SUPPORT]: Define SINGLE_THREAD_P using static
529         __lib*_multiple_threads.
530         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
531         [!HAVE_TLS_SUPPORT]: Likewise.
533 2004-01-13  Roland McGrath  <roland@redhat.com>
535         * sysdeps/powerpc/tcb-offsets.sym: Put -- separator line before any
536         conditionals.
538 2004-01-10  Andreas Jaeger  <aj@suse.de>
540         * sysdeps/unix/sysv/linux/x86_64/vfork.S: Add cfi directives.
542 2004-01-01  Andreas Jaeger  <aj@suse.de>
544         * Makefile (generated): Add missing files.
546 2003-12-31  Ulrich Drepper  <drepper@redhat.com>
548         * attr.c (pthread_getattr_np): Make sure stack info returned for
549         main thread does not overlap with any other VMA.
550         Patch by Jakub Jelinek.
552 2003-12-29  Jakub Jelinek  <jakub@redhat.com>
554         * sysdeps/ia64/tls.h: Include dl-sysdep.h.
555         (INIT_SYSINFO): Define.
556         (TLS_INIT_TP): Use it.
558 2003-12-28  Carlos O'Donell  <carlos@baldric.uwo.ca>
560         * attr.c (pthread_getattr_np): Add _STACK_GROWS_UP case.
562 2003-12-26  Jakub Jelinek  <jakub@redhat.com>
564         * sysdeps/pthread/pthread.h (pthread_setcancelstate,
565         pthread_setcanceltype, pthread_cancel, pthread_testcancel): Remove
566         __THROW.
567         * semaphore.h (sem_wait, sem_timedwait): Likewise.
569 2003-12-17  Jakub Jelinek  <jakub@redhat.com>
571         * manager.c (pthread_free): Call _dl_deallocate_tls even for
572         p_userstack threads.
573         * pthread.c (__pthread_initialize_manager): Call _dl_deallocate_tls
574         on error.
575         (pthread_onexit_process): Update comment.
576         * Makefile (tests): Add tst-stack1.  Depend on $(objpfx)tst-stack1-mem.
577         (generated): Add tst-stack1.mtrace and tst-stack1-mem.
578         (tst-stack1-ENV): Set.
579         ($(objpfx)tst-stack1-mem): New.
580         * tst-stack1.c: New test.
582 2003-12-16  Steven Munroe  <sjmunroe@us.ibm.com>
584         * sysdeps/powerpc/tcb-offsets.sym [!__powerpc64__]: Remove
585         conditional so MULTIPLE_THREADS_OFFSET is generated for both.
586         * sysdeps/powerpc/tls.h [!__powerpc64__]: Remove conditional
587         so TLS_MULTIPLE_THREADS_IN_TCB is generated for both.
588         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h:
589         Include tls.h.
591 2003-12-04  Steven Munroe  <sjmunroe@us.ibm.com>
593         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
594         (SINGLE_THREAD_P): Test using thread local p_multiple_threads field.
596 2003-12-10  David Mosberger  <davidm@hpl.hp.com>
598         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Update copyright
599         message.  Add include of <stddef.h>.
600         (INIT_NEW_WAY): New macro.
601         (INIT_OLD_WAY): Likewise.
602         (_init): Add unwind directives.  Invoke
603         __pthread_initialize_minimal() via INIT_NEW_WAY or INIT_OLD_WAY,
604         respectively.
605         (_init_EPILOG_BEGINS): Add unwind-directives.  Drop unused .regstk
606         directive.
607         (_fini): Add unwind directives.  Drop unnecessary .align 16
608         directive (bundles are always 16-byte aligned).
609         (_fini_EPILOG_BEGINS): Add unwind-directives.
611 2003-11-19  David Mosberger  <davidm@hpl.hp.com>
613         * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: New file.
615 2003-12-10  Andreas Jaeger  <aj@suse.de>
616             Ruediger Oertel  <ro@suse.de>
618         * sysdeps/alpha/elf/pt-initfini.c (__asm__): Remove extra .prologue.
620 2003-11-30  Andreas Jaeger  <aj@suse.de>
622         * Makefile (CFLAGS-pt-initfini.s): Add $(fno_unit_at_a_time).
623         * sysdeps/unix/sysv/linux/x86_64/Makefile (CFLAGS-pt-initfini.s):
624         Likewise.
626 2003-11-04  Jakub Jelinek  <jakub@redhat.com>
628         * signals.c (__pthread_sigaction): Set __sighandler[sig].old before
629         __libc_sigaction if it has been one of the special values before.
631 2003-10-06  Carlos O'Donell <carlos@baldric.uwo.ca>
633         * pthread.c (__pthread_self_stack): _STACK_GROWS_UP case added.
634         (__pthread_find_self): Likewise.
635         * manager.c (thread_segment): _STACK_GROWS_UP case added.
637 2003-10-10  Carlos O'Donell  <carlos@baldric.uwo.ca>
639         * linuxthreads/sysdeps/unix/sysv/linux/hppa/malloc-machine.h: New file.
641 2003-10-10  Carlos O'Donell  <carlos@baldric.uwo.ca>
643         * sysdeps/unix/sysv/linux/hppa/sysdep-cancel.h: New file.
645 2003-10-07  Jakub Jelinek  <jakub@redhat.com>
647         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Backout 2003-10-02
648         changes.
649         (SAVE_OLDTYPE_0): Fix a typo.
651 2003-10-02  Ulrich Drepper  <drepper@redhat.com>
653         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (DOCARGS_1): Use
654         correct offset.
656 2003-10-02  Jakub Jelinek  <jakub@redhat.com>
658         * Makefile (tests): Add tst-cancel8.
659         * tst-cancel8.c: New test.
661 2003-10-02  Ulrich Drepper  <drepper@redhat.com>
663         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Fix saving and
664         restoring of the old cancellation type.
666 2003-09-10  Chris Demetriou  <cgd@broadcom.com>
668         * sysdeps/unix/sysv/linux/mips/mips64/sysdep-cancel.h: New file.
670 2003-09-30  Jakub Jelinek  <jakub@redhat.com>
672         * sysdeps/pthread/malloc-machine.h [!__libc_maybe_call2] (mutex_init,
673         mutex_lock, mutex_trylock, mutex_unlock): Remove.
675 2003-09-27  Wolfram Gloger  <wg@malloc.de>
677         * sysdeps/pthread/malloc-machine.h: New file.
679 2003-09-18  H.J. Lu  <hongjiu.lu@intel.com>
681         * attr.c (__pthread_attr_init_2_1): Double __guardsize size
682         if NEED_SEPARATE_REGISTER_STACK is defined.
684 2003-09-22  Philip Blundell  <philb@gnu.org>
686         * forward.c: Add _pthread_cleanup_push, _pthread_cleanup_pop.
687         * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
688         Likewise.
689         * pthread.c (__pthread_elements): Initialise these new elements.
690         * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_push): Use
691         __libc_maybe_call.
692         (__libc_cleanup_pop): Likewise.
694 2003-09-22  Jakub Jelinek  <jakub@redhat.com>
696         * attr.c: Include stdlib.h.
698 2003-09-18  Jakub Jelinek  <jakub@redhat.com>
700         * sysdeps/pthread/pthread.h (pthread_getattr_np): Clarify usage.
702         * tst-attr1.c: New test.
703         * Makefile (tests): Add tst-attr1.
705 2003-09-17  Philip Blundell  <philb@gnu.org>
707         * sysdeps/unix/sysv/linux/arm/vfork.S: Branch to fork if
708         libpthread is loaded.  Elide backwards compatibility code when not
709         required.
711 2003-09-17  Jakub Jelinek  <jakub@redhat.com>
713         * descr.h (manager_thread): Rename to...
714         (__pthread_manager_threadp): ... this.
715         * pthread.c (manager_thread): Define to __pthread_manager_threadp.
716         (__pthread_manager_threadp): New variable.
717         * internals.h (__manager_thread): Define to
718         __pthread_manager_threadp if USE_TLS.
720 2003-09-15  Jakub Jelinek  <jakub@redhat.com>
722         * sysdeps/i386/Makefile (CFLAGS-cancel.c, CFLAGS-manager.c,
723         CFLAGS-pthread.c, CFLAGS-sighandler.c): Add
724         -mpreferred-stack-boundary=4.
726 2003-09-16  Ulrich Drepper  <drepper@redhat.com>
728         * attr.c (pthread_getattr_np): Correctly fill in the stack-related
729         values for the initial thread.
731 2003-09-17  Jakub Jelinek  <jakub@redhat.com>
733         * pthread.c (manager_thread): Remove static, add attribute_hidden.
734         (thread_self_stack): Rename to...
735         (__pthread_self_stack): ... this.  Remove static.
736         (pthread_handle_sigcancel): Use check_thread_self ().
737         (pthread_handle_sigrestart): Likewise.
738         * sighandler.c (__pthread_sighandler, __pthread_sighandler_rt):
739         Likewise.
740         * descr.h (manager_thread): Declare.
741         * internals.h (__pthread_self_stack): New prototype.
742         (__manager_thread): Define.
743         (check_thread_self): New function.
745 2003-09-15  Jakub Jelinek  <jakub@redhat.com>
747         * Makefile (CFLAGS-mutex.c): Add $(uses-callbacks).
748         (CFLAGS-sighandler.c): Change $(exceptions) into $(uses-callbacks).
750 2003-09-12  Jakub Jelinek  <jakub@redhat.com>
752         * sysdeps/unix/sysv/linux/s390/bits/typesizes.h: New.
753         (__SSIZE_T_TYPE): Define to __SWORD_TYPE for gcc 2.95.x and
754         __SLONGWORD_TYPE otherwise.
756 2003-09-11  Steven Munroe  <sjmunroe@us.ibm.com>
758         * sysdeps/powerpc/powerpc64/pt-machine.h [MEMORY_BARRIER]: Use lwsync.
759         [READ_MEMORY_BARRIER]: Define.
760         [WRITE_MEMORY_BARRIER]: Define.
762 2003-09-10  Jakub Jelinek  <jakub@redhat.com>
764         * sysdeps/pthread/pthread-functions.h (struct pthread_functions): Move
765         ptr___pthread_cond_timedwait to the end of the structure to avoid
766         breaking Wine unnecessarily.
768 2003-09-08  Jakub Jelinek  <jakub@redhat.com>
770         * sysdeps/unix/sysv/linux/s390/bits/typesizes.h: Remove.
772 2003-09-02  Jakub Jelinek  <jakub@redhat.com>
774         * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: New file.
775         * sysdeps/unix/sysv/linux/alpha/Versions: New file.
776         * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: New file.
777         * sysdeps/unix/sysv/linux/ia64/Versions: New file.
778         * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: New file.
779         * sysdeps/unix/sysv/linux/sparc/Versions: New file.
780         * attr.c (__old_pthread_attr_setstacksize,
781         __old_pthread_attr_setstack): New functions.
782         (pthread_attr_setstacksize): If PTHREAD_STACK_MIN != 16384, export
783         as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.1.
784         (pthread_attr_setstack): If PTHREAD_STACK_MIN != 16384, export
785         as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.2.
786         * tststack.c: Include limits.h and sys/param.h.
787         (main): Set size to MAX (70 * 1024, PTHREAD_STACK_MIN).
789         * barrier.c (__pthread_barrierattr_getpshared): Always
790         return PTHREAD_PROCESS_PRIVATE.
791         (pthread_barrierattr_setpshared): Return EINVAL if pshared
792         is neither PTHREAD_PROCESS_PRIVATE nor PTHREAD_PROCESS_SHARED.
794 2003-09-02  Ulrich Drepper  <drepper@redhat.com>
796         * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
797         (DL_SYSINFO_IMPLEMENTATION): Add CFI and make sure the code ends
798         up in .text.
800         * barrier.c (pthread_barrierattr_setpshared): We don't handle
801         inter-process barriers.
803 2003-09-01  Jakub Jelinek  <jakub@redhat.com>
805         * Makefile (tests): Add tst-tls1.
806         (module-names): Add tst-tls1mod{,a,b,c,d,e,f}.
807         ($(objpfx)tst-tls1mod{,a,b,c,d,e,f}.so-no-z-defs): Set to yes.
808         ($(objpfx)tst-tls1): New.
809         ($(objpfx)tst-tls2.out): Likewise.
810         (tests): Depend on $(objpfx)tst-tls2.out.
811         * tst-tls1.c: New test.
812         * tst-tls1.h: New.
813         * tst-tls1mod.c: New.
814         * tst-tls1moda.c: New.
815         * tst-tls1modb.c: New.
816         * tst-tls1modc.c: New.
817         * tst-tls1modd.c: New.
818         * tst-tls1mode.c: New.
819         * tst-tls1modf.c: New.
820         * tst-tls2.sh: New test.
822         * internals.h (__pthread_cond_timedwait): New prototype.
823         * sysdeps/pthread/pthread-functions.h (struct pthread_functions): Add
824         ptr___pthread_cond_timedwait.
825         * pthread.c (__pthread_functions): Initialize them.
826         * forward.c (pthread_cond_timedwait@GLIBC_2.0,
827         pthread_cond_timedwait@@GLIBC_2.3.2): New forwards.
828         * Versions (libc): Export pthread_cond_timedwait@GLIBC_2.0,
829         pthread_cond_timedwait@@GLIBC_2.3.2.
831 2003-08-27  Ulrich Drepper  <drepper@redhat.com>
833         * sysdeps/pthread/pthread.h: Don't mark pthread_exit,
834         pthread_join, pthread_cond_wait, and pthread_cond_timedwait with
835         __THROW to match NPTL.
837 2003-08-13  Ulrich Drepper  <drepper@redhat.com>
839         * sysdeps/pthread/Makefile [subdir=rt] (CPPFLAGS): Add
840         -DBROKEN_THREAD_SIGNALS.
842 2003-08-11  Steven Munroe  <sjmunroe@us.ibm.com>
844         * manager.c (pthread_start_thread) [!(USE_TLS && HAVE___THREAD)]:
845         Correct spelling of per thread resolver state.
847 2003-08-07  Jakub Jelinek  <jakub@redhat.com>
849         * sysdeps/pthread/bits/libc-lock.h [_LIBC && SHARED]
850         (__rtld_lock_default_lock_recursive,
851         __rtld_lock_default_unlock_recursive): Define.
852         [_LIBC && SHARED] (__rtld_lock_lock_recursive,
853         __rtld_lock_unlock_recursive): Define using
854         GL(_dl_rtld_*lock_recursive).
855         * pthread.c (pthread_initialize): Initialize _dl_rtld_lock_recursive
856         and _dl_rtld_unlock_recursive.  Lock GL(_dl_load_lock) the same
857         number of times as GL(_dl_load_lock) using non-mt implementation was
858         nested.
860 2003-07-31  Jakub Jelinek  <jakub@redhat.com>
862         * sysdeps/pthread/bits/typesizes.h (__SSIZE_T_TYPE): Define.
863         * sysdeps/unix/sysv/linux/alpha/bits/typesizes.h (__SSIZE_T_TYPE):
864         Likewise.
865         * sysdeps/unix/sysv/linux/sparc/bits/typesizes.h (__SSIZE_T_TYPE):
866         Likewise.
867         * sysdeps/unix/sysv/linux/s390/bits/typesizes.h: New file.
869         * sysdeps/pthread/pthread.h (pthread_attr_setstackaddr,
870         pthread_attr_setstacksize): Change PTHREAD_STACK_SIZE to
871         PTHREAD_STACK_MIN in comments.
873         * sysdeps/alpha/pt-machine.h (PT_EI): Add
874         __attribute__((always_inline)).
875         * sysdeps/arm/pt-machine.h (PT_EI): Likewise.
876         * sysdeps/cris/pt-machine.h (PT_EI): Likewise.
877         * sysdeps/hppa/pt-machine.h (PT_EI): Likewise.
878         * sysdeps/i386/i686/pt-machine.h (PT_EI): Likewise.
879         * sysdeps/i386/pt-machine.h (PT_EI): Likewise.
880         * sysdeps/ia64/pt-machine.h (PT_EI): Likewise.
881         * sysdeps/m68k/pt-machine.h (PT_EI): Likewise.
882         * sysdeps/mips/pt-machine.h (PT_EI): Likewise.
883         * sysdeps/powerpc/powerpc32/pt-machine.h (PT_EI): Likewise.
884         * sysdeps/powerpc/powerpc64/pt-machine.h (PT_EI): Likewise.
885         * sysdeps/s390/s390-32/pt-machine.h (PT_EI): Likewise.
886         * sysdeps/s390/s390-64/pt-machine.h (PT_EI): Likewise.
887         * sysdeps/sh/pt-machine.h (PT_EI): Likewise.
888         * sysdeps/sparc/sparc32/pt-machine.h (PT_EI): Likewise.
889         * sysdeps/sparc/sparc64/pt-machine.h (PT_EI): Likewise.
890         * sysdeps/x86_64/pt-machine.h (PT_EI): Likewise.
891         * spinlock.h (__pthread_set_own_extricate_if): Likewise.
892         * sysdeps/ia64/tls.h (TLS_INIT_TP): Cast tcbp to __typeof
893         (__thread_self).
894         * Examples/ex13.c (main): Change res type to void * to avoid
895         warnings.
896         * tst-cancel.c (cleanup, inner, tf1, tf2, tf3): Comment out.
898 2003-07-30  Jakub Jelinek  <jakub@redhat.com>
900         * pthread.c (init_one_static_tls, __pthread_init_static_tls): New
901         functions.
902         (pthread_initialize): Initialize GL(dl_init_static_tls).
904 2003-06-19  Daniel Jacobowitz  <drow@mvista.com>
906         * sysdeps/pthread/timer_create.c (timer_create): Call timer_delref
907         before __timer_dealloc.
908         * sysdeps/pthread/timer_routines.c (__timer_thread_find_matching):
909         Don't call list_unlink.
911 2003-07-29  Roland McGrath  <roland@redhat.com>
913         * Makefile [$(build-shared) = yes] (tests): Depend on $(test-modules).
915 2003-07-25  Roland McGrath  <roland@redhat.com>
917         * manager.c (pthread_start_thread): Fix typo in last change.
919 2003-07-14  Guido Guenther  <agx@sigxcpu.org>
921         * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h: Add IS_IN_librt,
922         use L() for local labels.
924 2003-07-22  Jakub Jelinek  <jakub@redhat.com>
926         * descr.h (struct _pthread_descr_struct): Provide p_res member
927         even if USE_TLS && HAVE___THREAD.
928         * sysdeps/pthread/res-state.c (__res_state): Return __resp
929         if USE___THREAD.
930         * manager.c: Include resolv.h.
931         (pthread_start_thread): Initialize __resp.
932         * libc-tls-loc.c (__res_state): Return __resp.
933         * Makefile (tests): Add tst-_res1.
934         (modules-names, extra-objs, test-extras, test-modules): Add support
935         for test modules.
936         ($(objpfx)tst-_res1mod2.so): Depend on $(objpfx)tst-_res1mod1.so.
937         ($(objpfx)tst-_res1): Depend on $(objpfx)tst-_res1mod2.so and
938         -lpthread.
939         * tst-_res1.c: New test.
940         * tst-_res1mod1.c: New test.
941         * tst-_res1mod2.c: New test.
943 2003-07-20  Ulrich Drepper  <drepper@redhat.com>
945         * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_push and
946         __libc_cleanup_pop.
948         * tst-cancel-wrappers.sh: lseek and llseek are no cancellation points.
950 2003-07-14  Ulrich Drepper  <drepper@redhat.com>
952         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Fix typo
953         in test for compilation in libc.
955 2003-07-04  Jakub Jelinek  <jakub@redhat.com>
957         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO): Use
958         different symbol for the cancellation syscall wrapper and
959         non-cancellation syscall wrapper.
960         (PSEUDO_END): Define.
962 2003-07-05  Richard Henderson  <rth@redhat.com>
964         * sysdeps/alpha/elf/pt-initfini.c: Avoid .ent/.end.
966 2003-06-20  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
968         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Support cancellation
969         in librt.
971 2003-06-21  Andreas Schwab  <schwab@suse.de>
973         * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h: Support cancellation
974         in librt.
976 2003-06-20  Richard Henderson  <rth@redhat.com>
978         * sysdeps/unix/sysv/linux/alpha/Makefile (libpthread-routines):
979         Remove ptw-osf_sigprocmask.
981 2003-06-18  Jakub Jelinek  <jakub@redhat.com>
983         * internals.h (__librt_multiple_threads, __librt_enable_asynccancel,
984         __librt_disable_asynccancel): Declare.
985         (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET, LIBC_CANCEL_HANDLED): Define
986         for IS_IN_librt.
987         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Support cancellation
988         in librt.
989         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
990         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
991         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
992         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
993         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
994         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
995         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
996         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
997         * sysdeps/x86_64/tcb-offsets.sym: New file.
998         * sysdeps/x86_64/Makefile: New file.
999         * sysdeps/x86_64/tls.h (tcbhead_t): Add multiple_threads.
1000         * Versions (libc): Export __librt_enable_asynccancel,
1001         __librt_disable_asynccancel and __librt_multiple_threads as
1002         GLIBC_PRIVATE.
1003         * libc-cancellation.c (__librt_multiple_threads,
1004         __librt_enable_asynccancel, __librt_disable_asynccancel): New aliases.
1006 2003-06-12  Steven Munroe  <sjmunroe@us.ibm.com>
1008         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
1009         (SINGLE_THREAD_P): Replace @ got notation with @toc.
1011 2003-06-11  Ulrich Drepper  <drepper@redhat.com>
1013         * sysdeps/powerpc/pspinlock.c (__pthread_spin_init): Fix
1014         initializer [PR libc/5052].
1016 2003-06-09  Andreas Schwab  <schwab@suse.de>
1018         * Makefile: Move inclusion of ../Rules down after extra-objs is
1019         fully known.
1021 2003-06-06  Ulrich Drepper  <drepper@redhat.com>
1023         * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h: New sequences for
1024         5+ arg syscalls only needed for PIC.
1025         Patch by Ralph Siemsen <ralphs@netwinder.org>.
1027 2003-06-05  Richard Henderson  <rth@redhat.com>
1029         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (PSEUDO): Use
1030         and require CFI assembler directives.
1031         * sysdeps/unix/sysv/linux/alpha/vfork.S: Likewise.
1033 2003-05-30  Andreas Jaeger  <aj@suse.de>
1035         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h
1036         (SAVESTK_0): Add CFI directives.
1037         (SAVESTK_3): Likewise.
1038         (SAVESTK_5): Likewise.
1039         (RESTSTK_0): Likewise.
1040         (RESTSTK_3): Likewise.
1041         (RESTSTK_5): Likewise.
1043 2003-05-05  Ulrich Drepper  <drepper@redhat.com>
1045         * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Add \n to error
1046         messages.
1048 2003-05-04  Roland McGrath  <roland@redhat.com>
1050         * Makefile ($(objpfx)../libc.so): New target.
1052 2003-04-26  Ulrich Drepper  <drepper@redhat.com>
1054         * pthread.c (__pthread_initialize_manager): Remove one last
1055         p_multiple_threads call.
1057 2003-04-22  Jakub Jelinek  <jakub@redhat.com>
1059         * pthread.c (__pthread_initialize_manager): Subtract
1060         TLS_PRE_TCB_SIZE bytes from tcbp to get to descr.
1061         * manager.c (pthread_handle_create): Subtract or add TLS_PRE_TCB_SIZE
1062         instead of sizeof (pthread_descr).
1063         (pthread_free): Add TLS_PRE_TCB_SIZE instead of sizeof (pthread_descr).
1064         * sysdeps/powerpc/tls.h (TLS_INIT_TCB_SIZE, TLS_TCB_SIZE): Define to 0.
1065         (TLS_INIT_TCB_ALIGN, TLS_TCB_ALIGN): Define to alignment of
1066         pthread_descr.
1067         (TLS_PRE_TCB_SIZE): Increase to cover tcbhead_t preceeded by pad
1068         to TLS_TCB_ALIGN.
1069         (INSTALL_DTV, GET_DTV, THREAD_DTV): tcbhead_t is immediately before
1070         tcbp.
1071         (TLS_INIT_TP, THREAD_SELF, INIT_THREAD_SELF): Don't add TLS_TCB_SIZE
1072         unneccessarily.
1073         (NO_TLS_OFFSET): Define.
1075 2003-04-22  Roland McGrath  <roland@redhat.com>
1077         * Makeconfig (shared-thread-library): Reverse link order to work
1078         around linker bug.
1080 2003-04-20  Ulrich Drepper  <drepper@redhat.com>
1082         * sysdeps/i386/useldt.h (DO_SET_THREAD_AREA): Make sure the
1083         compiler knows we use the ldt_entry variable and that the syscall
1084         modifies the memory.
1086         * internals.h: Split pthread_functions definition into...
1087         * sysdeps/pthread/pthread-functions.h: ...new file.
1089         * sysdeps/i386/useldt.h: Include <sysdep.h>.
1091 2003-04-13  Jakub Jelinek  <jakub@redhat.com>
1093         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Rename macros to
1094         match changes in NPTL sysdep-cancel.h.
1096 2003-04-11  Roland McGrath  <roland@redhat.com>
1098         * Makefile (multidir): Don't set the variable here with $(shell ...).
1099         ($(objpfx)multidir.mk): New target, generated makefile; include that.
1100         (generated): Append it.
1102 2003-04-10  Jakub Jelinek  <jakub@redhat.com>
1104         * Makefile (multidir, crti-objs, crtn-objs): New variables.
1105         (generated-dirs): Add pathname component of multidir.
1106         (omit-deps, extra-objs): Include $(multidir)/crt? as well.
1107         ($(objpfx)libpthread.so): Depend on $(multidir)/crt?.o as well.
1108         ($(objpfx)$(multidir), $(objpfx)$(multidir)/crti.o,
1109         $(objpfx)$(multidir)/crtn.o): New.
1110         * sysdeps/unix/sysv/linux/sparc/Makefile: Removed.
1111         * sysdeps/unix/sysv/linux/x86_64/Makefile (LDFLAGS-pthread.so,
1112         before-compile, generated): Don't generate and use specs.
1113         ($(objpfx)specs): Remove.
1115 2003-04-11  Martin Schwidefsky  <schwidefsky@de.ibm.com>
1117         * sysdeps/s390/pspinlock.c (__pthread_spin_unlock): Fix asm contraints.
1119 2003-04-03  Ulrich Drepper  <drepper@redhat.com>
1121         * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h (PSEUDO): Add
1122         missing ; after ENTRY use [PR libc/4997].
1124 2003-04-03  Jakub Jelinek  <jakub@redhat.com>
1126         * pthread.c (pthread_initialize): Unblock __pthread_sig_cancel
1127         in case the parent blocked it.
1129 2003-04-02  Jakub Jelinek  <jakub@redhat.com>
1131         * Makefile (libpthread-routines): Add pthread_atfork.
1132         (libpthread-static-only-routines): Add pthread_atfork.
1134 2003-04-01  Jakub Jelinek  <jakub@redhat.com>
1136         * pthread.c (__pthread_wait_for_restart_signal): Use
1137         __pthread_sigsuspend instead of sigsuspend.
1138         * internals.h (__pthread_sigsuspend): New prototype.
1139         * Makefile (libpthread-routines): Add pt-sigsuspend.
1140         (tests): Add tst-cancel7.
1141         * sysdeps/unix/sysv/linux/pt-sigsuspend.c: New file.
1142         * sysdeps/unix/sysv/linux/alpha/pt-sigsuspend.S: New file.
1143         * sysdeps/unix/sysv/linux/ia64/pt-sigsuspend.c: New file.
1144         * sysdeps/unix/sysv/linux/s390/s390-64/pt-sigsuspend.c: New file.
1145         * sysdeps/unix/sysv/linux/sparc/sparc64/pt-sigsuspend.c: New file.
1146         * sysdeps/unix/sysv/linux/x86_64/pt-sigsuspend.c: New file.
1147         * tst-cancel7.c: New test.
1149 2003-03-31  Alexandre Oliva  <aoliva@redhat.com>
1151         * alloca_cutoff.c: Include internals.h.
1152         * sysdeps/pthread/errno-loc.c: Include linuxthreads/internals.h.
1153         * sysdeps/pthread/herrno-loc.c: Likewise.
1154         * sysdeps/pthread/res-state.c: Likewise.
1156 2003-03-25  Ulrich Drepper  <drepper@redhat.com>
1158         * sysdeps/pthread/bits/typesizes.h: New file.
1159         * sysdeps/unix/sysv/linux/alpha/bits/typesizes.h: New file.
1160         * sysdeps/unix/sysv/linux/sparc/bits/typesizes.h: New file.
1162 2003-03-24  Daniel Jacobowitz  <drow@mvista.com>
1164         * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h
1165         (DOARGS_5, DOARGS_6, DOARGS_7): Rewritten.
1167 2003-03-22  Jakub Jelinek  <jakub@redhat.com>
1169         * sysdeps/unix/sysv/linux/fork.c (__fork): Add libc_hidden_def.
1171 2003-03-21  Daniel Jacobowitz  <drow@mvista.com>
1173         * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h
1174         (SINGLE_THREAD_P_PIC): Use "reg" instead of "lr".
1176 2003-03-21  Jakub Jelinek  <jakub@redhat.com>
1178         * sysdeps/i386/tls.h [__ASSUME_SET_THREAD_AREA_SYSCALL]
1179         (TLS_SETUP_GS_SEGMENT): Fix a typo.
1181 2003-03-19  Ulrich Drepper  <drepper@redhat.com>
1183         * sysdeps/pthread/Makefile: Fix cut&paste error.
1185 2003-03-18  Roland McGrath  <roland@redhat.com>
1187         * Versions (libpthread: GLIBC_2.2): Remove
1188         pthread_barrierattr_getpshared, never really existed.
1189         (libpthread: GLIBC_2.0): Move __pthread_initialize to ...
1190         (libpthread: GLIBC_PRIVATE): ... here.
1192 2003-03-14  Jakub Jelinek  <jakub@redhat.com>
1194         * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: New file.
1195         * sysdeps/unix/sysv/linux/sparc/Makefile ($(objpfx)specs): Use full
1196         path for crt[in].o.
1198 2003-03-14  Alexandre Oliva  <aoliva@redhat.com>
1200         * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Don't .set
1201         mips2 on new abi.
1202         * sysdeps/mips/pt-machine.h (__compare_and_swap): Likewise.
1203         Handle 64-bit longs on n64.
1205 2003-03-07  Jakub Jelinek  <jakub@redhat.com>
1207         * sysdeps/ia64/pspinlock.c (__pthread_spin_lock,
1208         __pthread_spin_trylock): Rewritten.
1210 2003-03-06  Ulrich Drepper  <drepper@redhat.com>
1212         * tst-cancel4.c (tf_sleep): Lower sleep time a bit to not upset
1213         recent kernels.
1215 2003-03-02  Ulrich Drepper  <drepper@redhat.com>
1217         * sysdeps/pthread/timer_create.c (timer_create): Return correct
1218         error for CPU clocks.
1220         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1221         _POSIX_MONOTONIC_CLOCK.
1222         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
1224 2003-03-01  Roland McGrath  <roland@redhat.com>
1226         * sysdeps/powerpc/powerpc64/pt-machine.h
1227         (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM, THREAD_SETMEM_NC):
1228         New macros.
1229         * sysdeps/powerpc/tls.h: Don't define those here.
1231         * sysdeps/powerpc/tls.h [! USE_TLS && !__powerpc64__]: Define
1232         tcbhead_t with multiple_threads member.
1233         [USE_TLS] (tcbhead_t): Define minimal one-word version.
1234         [USE_TLS && !__powerpc64__] (TLS_MULTIPLE_THREADS_IN_TCB): Define.
1235         * sysdeps/powerpc/tcb-offsets.sym [USE_TLS]: Use tls.h macros to
1236         derive thread register offset of p_multiple_threads member.
1238         * descr.h (struct _pthread_descr_struct) [!USE_TLS || !TLS_DTV_AT_TP]:
1239         Conditionalize p_header member on this.
1240         [TLS_MULTIPLE_THREADS_IN_TCB]: Add p_multiple_threads alternatively.
1241         * sysdeps/ia64/tls.h [USE_TLS] (TLS_MULTIPLE_THREADS_IN_TCB): Define.
1242         * sysdeps/sh/tls.h: Likewise.
1243         * sysdeps/ia64/tcb-offsets.sym [USE_TLS]: Use p_multiple_threads.
1244         * sysdeps/sh/tcb-offsets.sym: Likewise.
1245         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
1246         (SINGLE_THREAD_P): Likewise.
1247         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1248         (SINGLE_THREAD_P): Likewise.
1249         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
1250         (SINGLE_THREAD_P): Likewise.
1251         * pthread.c (__pthread_initialize_manager): Likewise.
1252         * manager.c (pthread_handle_create): Likewise.
1254         * sysdeps/powerpc/tls.h [HAVE_TLS_SUPPORT]: Define USE_TLS and all
1255         related macros.
1257 2003-01-31  Steven Munroe  <sjmunroe@us.ibm.com>
1259         * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S [SHARED]:
1260         Conditionalize .toc section magic on this.
1262 2003-02-21  Roland McGrath  <roland@redhat.com>
1264         * cancel.c (__pthread_perform_cleanup): Call __libc_thread_freeres
1265         instead of __rpc_thread_destroy.
1267 2003-02-21  Jakub Jelinek  <jakub@redhat.com>
1269         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Call
1270         __fork instead of branching to it if BROKEN_SPARC_WDISP22.
1271         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h (PSEUDO):
1272         Fix typo.
1273         * sysdeps/unix/sysv/linux/sparc/Makefile (specs): Add ./ prefix
1274         to crti.o and crtn.o.
1275         * sysdeps/unix/sysv/linux/x86_64/Makefile (specs): Likewise.
1277 2003-02-21  Roland McGrath  <roland@redhat.com>
1279         * Makefile (install-lib-ldscripts): New variable.
1281 2003-02-20  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
1283         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: Avoid short
1284         interprocedure branches.
1286 2003-02-19  Ulrich Drepper  <drepper@redhat.com>
1288         * specific.c (pthread_key_delete_helper): Don't use GETMEM, we
1289         need the target thread's lock.
1291 2003-02-17  Ulrich Drepper  <drepper@redhat.com>
1293         * sysdeps/unix/sysv/linux/bits/local_lim.h: Define TTY_NAME_MAX
1294         and LOGIN_NAME_MAX.
1296 2003-02-17  Kevin B. Hendricks  <kevin.hendricks@sympatico.ca>
1297             Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
1299         * sysdeps/powerpc/Makefile: Handle tcb-offsets.sym.
1300         * sysdeps/powerpc/tcb-offsets.sym: New file.
1301         * sysdeps/powerpc/tls.h: New file.
1302         * sysdeps/powerpc/powerpc32/pt-machine.h (FLOATING_STACKS): Define.
1303         (ARCH_STACK_MAX_SIZE): Define.
1304         (THREAD_SELF): Define.
1305         (INIT_THREAD_SELF): Define.
1306         (THREAD_GETMEM): Define.
1307         (THREAD_GETMEM_NC): Define.
1308         (THREAD_SETMEM): Define.
1309         (THREAD_SETMEM_NC): Define.
1310         (__thread_self): Declare.
1311         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Adjust
1312         for thread register.
1314 2003-02-14  Steven Munroe  <sjmunroe@us.ibm.com>
1316         * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S (__vfork):
1317         Check pthread_create existance, not __pthread_fork.
1319 2003-02-12  Ulrich Drepper  <drepper@redhat.com>
1321         * sysdeps/pthread/Makefile: Define CFLAGS-confstr.c.
1323 2003-02-10  Jakub Jelinek  <jakub@redhat.com>
1325         * sysdeps/unix/sysv/linux/alpha/vfork.S (__vfork): Check
1326         pthread_create existance, not __pthread_fork.
1327         * sysdeps/unix/sysv/linux/i386/vfork.S (__vfork): Likewise.
1328         * sysdeps/unix/sysv/linux/ia64/vfork.S (__vfork): Likewise.
1329         * sysdeps/unix/sysv/linux/m68k/vfork.S (__vfork): Likewise.
1330         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
1331         Likewise.
1332         * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Likewise.
1333         * sysdeps/unix/sysv/linux/x86_64/vfork.S (__vfork): Likewise.
1334         * sysdeps/unix/sysv/linux/sh/vfork.S (__vfork): Likewise.
1335         Add .weak pthread_create.
1336         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Fix a typo.
1337         Check pthread_create existance, not __pthread_fork.
1338         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
1339         * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S (__vfork): Branch to
1340         __fork whenever libpthread.so is loaded.
1342 2003-02-09  Andreas Jaeger  <aj@suse.de>
1344         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h:
1345         Rework: %r9 is destroyed by functions so don't use it as
1346         temporary, align stack correctly, fix parameter for CDISABLE.
1348 2003-02-07  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1350         * sysdeps/sh/Makefile: New file.
1351         * sysdeps/sh/tcb-offsets.sym: Likewise.
1352         * sysdeps/sh/tls.h: Don't include sysdep.h. Move include
1353         of linuxthreads/descr.h after the definition of THREAD_SELF.
1354         (tcbhead_t): Use IA64 type tcbhead_t for TLS case.
1355         (TLS_TCB_SIZE): Set size of tcbhead_t.
1356         (TLS_PRE_TCB_SIZE): Define.
1357         (INSTALL_NEW_DTV): Set dtv of tcbhead_t structure instead of
1358         a member of thread structure.
1359         (THREAD_DTV): Likewise.
1360         (TLS_INIT_TP_EXPENSIVE): Remove.
1361         (TLS_INIT_TP): Set gbr register only.
1362         (THREAD_SELF): New.
1363         (INIT_THREAD_SELF): Likewise.
1364         (NONTLS_INIT_TP): New.
1365         * sysdeps/unix/sysv/linux/sh/pt-initfini.c (__fpscr_values):
1366         Remove.
1367         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (PSEUDO): Add
1368         SYSCALL_INST_PAD macro after DO_CALL.
1369         (SINGLE_THREAD_P): Fix non-PIC and TLS case so to read the
1370         correct variable.
1371         * sysdeps/unix/sysv/linux/sh/vfork.S (__vfork): Branch to __fork
1372         whenever libpthread.so is loaded.
1374 2003-02-08  Andreas Schwab  <schwab@suse.de>
1376         * sysdeps/unix/sysv/linux/m68k/vfork.S: Branch to __fork whenever
1377         libpthread.so is loaded.
1379 2003-02-07  Ulrich Drepper  <drepper@redhat.com>
1381         * sysdeps/unix/sysv/linux/i386/vfork.S: Make sure
1382         __ASSUME_VFORK_SYSCALL is not defined if the kernel headers have
1383         no __NR_vfork definition.
1385 2003-02-07  Jakub Jelinek  <jakub@redhat.com>
1387         * tst-popen2.c: New test.
1388         * Makefile (tests): Add tst-popen2.
1389         * sysdeps/unix/sysv/linux/alpha/vfork.S (__vfork): Branch to __fork
1390         whenever libpthread.so is loaded.
1391         * sysdeps/unix/sysv/linux/i386/vfork.S (__vfork): Likewise.
1392         * sysdeps/unix/sysv/linux/ia64/vfork.S (__vfork): Likewise.
1393         * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Likewise.
1394         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
1395         Likewise.
1396         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Likewise.
1397         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
1398         * sysdeps/unix/sysv/linux/x86_64/vfork.S (__vfork): Likewise.
1400 2003-02-05  Ulrich Drepper  <drepper@redhat.com>
1402         * sysdeps/pthread/bits/libc-lock.h (__libc_once): Set control
1403         variable for non-libpthread case to the same value the
1404         pthread_once function would use.
1406 2003-02-03  Jakub Jelinek  <jakub@redhat.com>
1408         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): If
1409         BROKEN_SPARC_WDISP22, handle SHARED the same way as non-SHARED.
1411 2003-02-04  Andreas Jaeger  <aj@suse.de>
1413         * sysdeps/unix/sysv/linux/hppa/pt-initfini.c: Do not use
1414         multi-line strings.
1416 2003-01-30  Jakub Jelinek  <jakub@redhat.com>
1418         * sysdeps/s390/tls.h (TLS_INIT_TP): Return NULL, not 0.
1420 2003-01-30  Jakub Jelinek  <jakub@redhat.com>
1422         * sysdeps/alpha/tls.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1423         THREAD_SETMEM, THREAD_SETMEM_NC): Avoid warnings about unused self
1424         variable.
1425         * sysdeps/ia64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1426         THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1427         * sysdeps/s390/s390-32/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1428         THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1429         * sysdeps/s390/s390-64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1430         THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1431         * sysdeps/sh/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1432         THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1433         * sysdeps/sparc/sparc32/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1434         THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1435         * sysdeps/sparc/sparc64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1436         THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
1438 2003-01-27  Martin Schwidefsky  <schwidefsky@de.ibm.com>
1440         * sysdeps/s390/s390-32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
1441         Define TLS versions.
1442         * sysdeps/s390/s390-64/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
1443         Likewise.
1444         * sysdeps/s390/tls.h [HAVE_TLS_SUPPORT] (USE_TLS, TLS_INIT_TCB_SIZE,
1445         TLS_INIT_TCB_ALIGN, TLS_TCB_SIZE, TLS_TCB_ALIGN, TLS_TCB_AT_TP,
1446         INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV, TLS_INIT_TP, THREAD_DTV):
1447         Define.
1448         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO): Use
1449         branch with 32 bit offset.
1450         * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S: Likewise.
1452 2003-01-24  Jakub Jelinek  <jakub@redhat.com>
1454         * sysdeps/sparc/sparc32/pt-machine.h (__thread_self): Change to %g7,
1455         as required by TLS ABI.
1456         * sysdeps/sparc/sparc64/pt-machine.h (__thread_self): Likewise.
1457         * sysdeps/sparc/tls.h [HAVE_TLS_SUPPORT] (USE_TLS, TLS_INIT_TCB_SIZE,
1458         TLS_INIT_TCB_ALIGN, TLS_TCB_SIZE, TLS_TCB_ALIGN, TLS_TCB_AT_TP,
1459         INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV, TLS_INIT_TP, THREAD_DTV):
1460         Define.
1461         [HAVE_TLS_SUPPORT]: Include descr.h and sysdep.h.
1462         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Use %g7
1463         instead of %g6 for thread pointer.
1464         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: Likewise.
1465         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
1466         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: Likewise.
1468 2003-01-25  Guido Guenther  <agx@sigxcpu.org>
1470         * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h: New file.
1471         * sysdeps/unix/sysv/linux/mips/Makefile: New file.
1473 2003-01-20  Martin Schwidefsky  <schwidefsky@de.ibm.com>
1475         * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S: Avoid non pc relative
1476         reference to __fork.
1478 2003-01-17  Richard Henderson  <rth@redhat.com>
1480         * sysdeps/alpha/tls.h (tcbhead_t): Clarify second member.
1481         (TLS_TCB_SIZE, TLS_TCB_ALIGN): Set for tcbhead_t.
1482         (TLS_PRE_TCB_SIZE): New.
1483         (TLS_INIT_TP, THREAD_SELF, INIT_THREAD_SELF): Update for
1484         new ia64-style thread pointer layout.
1485         (THREAD_GETMEM, THREAD_GETMEM_NC): New.
1486         (THREAD_SETMEM, THREAD_SETMEM_NC): New.
1487         * sysdeps/unix/sysv/linux/alpha/vfork.S: Don't tail-call to __fork
1488         if !SHARED.
1490 2003-01-15  Jakub Jelinek  <jakub@redhat.com>
1492         * sysdeps/ia64/tls.h (tcbhead_t): Use the TLS ABI required layout
1493         if USE_TLS only.
1494         (NONTLS_INIT_TP): Revert last change.
1495         * sysdeps/ia64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Define to
1496         offsetof (tcbhead_t, multiple_threads) if USE_TLS not defined.
1498 2003-01-16  Jakub Jelinek  <jakub@redhat.com>
1500         * pthread.c (_pthread_initialize_minimal): Use
1501         GL(dl_tls_dtv_slotinfo_list) != NULL to check whether TLS has
1502         been already initialized.
1504 2003-01-16  Jakub Jelinek  <jakub@redhat.com>
1506         * sysdeps/i386/tls.h (INIT_SYSINFO): Initialize head->sysinfo even
1507         if not SHARED.
1509 2003-01-15  Jakub Jelinek  <jakub@redhat.com>
1511         * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init,
1512         __libc_lock_init_recursive): Initialize fields directly.
1514 2003-01-15  Jakub Jelinek  <jakub@redhat.com>
1516         * sysdeps/unix/sysv/linux/alpha/vfork.S (__vfork): Allow
1517         __fork to be far away from __vfork ifndef SHARED.
1518         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
1519         Likewise.
1520         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Likewise.
1521         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
1522         Add a missing instruction.
1523         * sysdeps/unix/sysv/linux/arm/vfork.S (__vfork): Conditionally
1524         branch to __fork even if __NR_vfork is not defined.
1526 2003-01-14  Ulrich Drepper  <drepper@redhat.com>
1528         * tst-cancel-wrappers.sh: Allow .__*_asynccancel functions names
1529         as well.
1531 2003-01-14  Steven Munroe  <sjmunroe@us.ibm.com>
1533         * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: New file.
1535 2003-01-14  Jakub Jelinek  <jakub@redhat.com>
1537         * sysdeps/unix/sysv/linux/ia64/vfork.S (JUMPTARGET): Remove.
1539 2003-01-13  Martin Schwidefsky  <schwidefsky@de.ibm.com>
1541         * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c: Avoid
1542         unterminated string literals.
1543         * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: Likewise.
1545 2003-01-13  Martin Schwidefsky  <schwidefsky@de.ibm.com>
1547         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
1548         (PSEUDO): Code reordering.  Move CENABLE and CDISABLE literals from
1549         PSEUDO_END to PSEUDO.
1550         (PSEUDO_END): Remove.
1551         (SINGLE_THREAD_P): Save an instruction.
1552         * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S (__vfork): Add missing
1553         parameter to SINGLE_THREAD_P call.
1554         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
1555         Code reordering.
1557 2003-01-10  Andreas Schwab  <schwab@suse.de>
1559         * sysdeps/unix/sysv/linux/m68k/vfork.S: New file.
1561 2003-01-10  Martin Schwidefsky  <schwidefsky@de.ibm.com>
1563         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO): Setup
1564         backchain in pseudo_cancel.  Minor code improvements.
1565         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
1566         Likewise.
1568 2003-01-10  Martin Schwidefsky  <schwidefsky@de.ibm.com>
1570         * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S: New file.
1571         * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S: New file.
1573 2002-01-12  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
1575         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: New file.
1577 2002-01-09  Richard Henderson  <rth@redhat.com>
1579         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Assume only
1580         ret follows pseudo, and thus avoid branch-to-branch in cancel
1581         case.  Use SYSCALL_ERROR_LABEL.
1583 2003-01-11  Philip Blundell  <philb@gnu.org>
1585         * sysdeps/unix/sysv/linux/arm/vfork.S: New file.
1586         * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h (PSEUDO_RET):
1587         Correctly unstack lr.
1588         (UNDOARGS_5): Fix ordering of pushes and pops.
1589         (SINGLE_THREAD_P_PIC): New.
1590         (SINGLE_THREAD_P_INT): New.
1591         (SINGLE_THREAD_P): Implement in terms of above.  Restore lr if it
1592         was stacked.
1593         (PSEUDO): Use SINGLE_THREAD_P_INT.
1595 2003-01-11  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1597         * sysdeps/unix/sysv/linux/sh/vfork.S: New file.
1599 2003-01-11  Jakub Jelinek  <jakub@redhat.com>
1601         * sysdeps/ia64/tls.h (tcbhead_t): Change into dtv_t *, void *.
1602         [HAVE_TLS_SUPPORT] (USE_TLS, TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN,
1603         TLS_TCB_SIZE, TLS_PRE_TCB_SIZE, TLS_TCB_ALIGN, TLS_DTV_AT_TP,
1604         INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV, TLS_INIT_TP, THREAD_SELF,
1605         INIT_THREAD_SELF): Define.
1606         [HAVE_TLS_SUPPORT]: Include descr.h.
1607         (NONTLS_INIT_TP): Point __thread_self at the end of dummy
1608         struct _pthread_descr_struct.
1609         * sysdeps/ia64/pt-machine.h (THREAD_GETMEM, THREAD_GETMEM_NC,
1610         THREAD_SETMEM, THREAD_SETMEM_NC): Define using THREAD_SELF,
1611         not __thread_self.
1612         * sysdeps/ia64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Adjust
1613         computation.
1614         * pthread.c (__pthread_initialize_minimal): Use tcbp, not self
1615         for TCB pointer.
1616         (__pthread_initialize_manager): Rename tcb to mgr.
1617         Use tcbp for TCB pointer, if TLS_DTV_AT_TP set mgr to sizeof (struct
1618         _pthread_descr) below tcbp, otherwise to tcbp.
1619         * manager.c (pthread_handle_create): If TLS_DTV_AT_TP, set
1620         new_thread to be below _dl_allocate_tls ().  Adjust new_thread back
1621         before freeing.  Fix clone arguments if report_events and USE_TLS.
1622         (pthread_free): Adjust th back before freeing.
1624 2003-01-10  Steven Munroe  <sjmunroe@us.ibm.com>
1626         * sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile: Moved to ...
1627         * sysdeps/unix/sysv/linux/powerpc/Makefile: ...here.
1628         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: New File.
1630 2003-01-09  Jakub Jelinek  <jakub@redhat.com>
1632         * sysdeps/unix/sysv/linux/i386/vfork.S: New file.
1633         * sysdeps/unix/sysv/linux/ia64/vfork.S: New file.
1634         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1635         [__ASSEMBLER__] (SINGLE_THREAD_P): Remove trailing ;;.
1636         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: New file.
1637         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: New file.
1638         * sysdeps/unix/sysv/linux/x86_64/vfork.S: New file.
1639         * sysdeps/unix/sysv/linux/alpha/vfork.S: New file.
1640         * tst-popen.c: New test.
1641         * Makefile (tests): Add tst-popen.
1643 2003-01-06  Jakub Jelinek  <jakub@redhat.com>
1645         * sysdeps/unix/sysv/linux/sigwait.c (do_sigwait): Add
1646         INTERNAL_SYSCALL_DECL, add err argument to INTERNAL_SYSCALL* macros.
1648 2003-01-06  Jakub Jelinek  <jakub@redhat.com>
1650         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (PSEUDO): Use
1651         PSEUDO_PREPARE_ARGS.  Fix branch condition after SINGLE_THREAD_P.
1653 2003-01-06  Philip Blundell  <philb@gnu.org>
1655         * sysdeps/unix/sysv/linux/arm/sysdep-cancel.h: New file.
1657 2003-01-06  Jakub Jelinek  <jakub@redhat.com>
1659         * internals.h (LIBC_CANCEL_HANDLED): Define.
1660         * sysdeps/unix/sysv/linux/sigwait.c (LIBC_CANCEL_HANDLED): Add.
1661         * signals.c (LIBC_CANCEL_HANDLED): Add.
1662         * pt-system.c (LIBC_CANCEL_HANDLED): Add.
1663         * tst-cancel-wrappers.sh: Remove all exceptions.
1665         * sysdeps/unix/sysv/linux/alpha/Makefile: New file.
1667 2003-01-05  Andreas Schwab  <schwab@suse.de>
1669         * sysdeps/m68k/Makefile: New file, use -fPIC for nonshared
1670         objects.
1672         * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h (SINGLE_THREAD_P):
1673         Fix for PIC.
1674         (CENABLE): Likewise.
1675         (CDISABLE): Likewise.
1677 2003-01-05  Ulrich Drepper  <drepper@redhat.com>
1679         * tst-cancel-wrappers.sh: Invoke gawk not awk since we use GNU awk
1680         features.  Reported by Marijn Ros <marijn@mad.scientist.com>.
1682         * Makefile (libc.so-no-z-defs): Define to yes.
1684 2003-01-05  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1686         * sysdeps/sh/tls.h: Include dl-sysdep.h and stdint.h.
1687         (tcbhead_t): Add multiple_threads member.
1688         (TLS_INIT_TP_EXPENSIVE): Define.
1689         * sysdeps/unix/sysv/linux/sh/pt-initfini.c: Don't use multi-line
1690         strings.  Remove unused code.
1691         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: New file.
1693 2003-01-04  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
1695         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: New file.
1696         * sysdeps/unix/sysv/linux/powerpc/powerpc32/Makefile: New file.
1698 2003-01-04  Jakub Jelinek  <jakub@redhat.com>
1700         * internals.h (LIBC_THREAD_GETMEM, LIBC_THREAD_SETMEM): Define
1701         even if NOT_IN_libc is defined.
1703 2003-01-05  Jakub Jelinek  <jakub@redhat.com>
1705         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: New file.
1706         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: New file.
1707         * sysdeps/s390/Makefile: New file.
1708         * sysdeps/s390/tcb-offsets.sym: New file.
1709         * sysdeps/s390/tls.h: New file.
1711 2003-01-03  Richard Henderson  <rth@redhat.com>
1713         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: New file.
1715 2003-01-03  Andreas Jaeger  <aj@suse.de>
1717         * sysdeps/pthread/bits/libc-tsd.h: Declare weak_extern functions.
1719 2003-01-03  Jakub Jelinek  <jakub@redhat.com>
1721         * Makefile ($(objpfx)libpthread.so): Depend on ld.so.
1723 2003-01-02  Ulrich Drepper  <drepper@redhat.com>
1725         * tst-cancel-wrappers.sh: Exclude sigwait.c as well, it does not have
1726         cancellation tests.
1728 2003-01-02  Jakub Jelinek  <jakub@redhat.com>
1730         * internals.h (struct pthread_functions): Rename
1731         ptr_pthread_cond_* fields to ptr___pthread_cond_*.
1732         * pthread.c (pthread_functions): Adjust.
1733         * forward.c: Export both pthread_cond_*@@GLIBC_2.3.2 and
1734         pthread_cond_*@GLIBC_2.0 compatibility symbols.
1735         * Versions [libc] (GLIBC_2.3.2): Export pthread_cond_broadcast,
1736         pthread_cond_destroy, pthread_cond_init, pthread_cond_signal
1737         and pthread_cond_wait.
1739         * sysdeps/pthread/bits/pthreadtypes.h (__pthread_cond_align_t): New
1740         type.
1741         (pthread_cond_t): Add __align member, shorten __padding.
1742         * sysdeps/pthread/pthread.h (PHTREAD_COND_INITIALIZER): Initialize
1743         __padding and __align too.
1745         * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call2): Add
1746         __builtin_expect.
1747         * sysdeps/pthread/sigaction.c: New file.
1748         * sysdeps/unix/sysv/linux/raise.c: New file.
1749         * sysdeps/unix/sysv/linux/sigwait.c: New file.
1750         * sysdeps/unix/sysv/linux/fork.c (__pthread_fork): Protect
1751         weak_extern with #ifndef SHARED.
1752         * sysdeps/unix/sysv/linux/jmp-unwind.c (__pthread_cleanup_upto):
1753         Likewise.
1754         * signals.c (__sigaction): Renamed to...
1755         (__pthread_sigaction): ... this.
1756         (__sigaction): New strong alias, #ifdef SHARED only.
1757         (sigaction): Protect with #ifdef SHARED.
1758         (sigwait): Renamed to...
1759         (__pthread_sigwait): ... this.
1760         (sigwait): New strong alias, #ifdef SHARED only.
1761         (raise): Renamed to...
1762         (__pthread_raise): ... this.
1763         (raise): New strong alias, #ifdef SHARED only.
1764         * internals.h (__pthread_sigaction, __pthread_sigwait,
1765         __pthread_raise): New prototypes.
1766         (struct pthread_functions): Add ptr_pthread_sigaction,
1767         ptr_pthread_sigwait, ptr_pthread_raise.
1768         * pthread.c (pthread_functions): Renamed to...
1769         (__pthread_functions): ... this.  No longer static, no longer
1770         SHARED only.  Initialize ptr_pthread_sigaction, ptr_pthread_sigwait
1771         and ptr_pthread_raise.
1772         [SHARED] (ptr_pthread_functions): Change to &__pthread_functions.
1773         * libc-cancellation.c (__pthread_thread_self): Remove weak_extern.
1774         * ptfork.c (__fork, __vfork): Protect with #ifdef SHARED.
1775         * ptlongjmp.c (siglongjmp, longjmp): Protect with #ifdef SHARED.
1777         * Makefile (tests, tests-static): Add tst-cancel-static.
1778         * tst-cancel-static.c: New test.
1780 2003-01-02  Jakub Jelinek  <jakub@redhat.com>
1782         * Makefile (CFLAGS-pthread_atfork.c): Add -DNOT_IN_libc.
1784 2003-01-02  Ulrich Drepper  <drepper@redhat.com>
1786         * sysdeps/pthread/bits/pthreadtypes.h (pthread_cond_t): Add padding.
1787         * condvar.c: Add symbol versioning.  The compatibility versions
1788         are the same as the change in the interface does not effect this
1789         implementation.
1790         * Versions [libpthread]: Add definitions for new pthread_cond_*
1791         interfaces for version GLIBC_2.3.2.
1793 2002-12-31  Ulrich Drepper  <drepper@redhat.com>
1795         * sysdeps/unix/sysv/linux/fork.h: Add libc_hidden_proto for
1796         __register_atfork.
1797         * sysdeps/unix/sysv/linux/register-atfork.c: Add libc_hidden_def
1798         for __register_atfork.
1800 2002-12-31  Jakub Jelinek  <jakub@redhat.com>
1802         * sysdeps/i386/i686/pt-machine.h: Use __ASSEMBLER__ instead of
1803         ASSEMBLER test macro.
1804         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Likewise.
1805         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
1806         * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h: Likewise.
1807         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
1808         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
1809         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
1811         * sysdeps/pthread/errno-loc.c (__errno_location): Add
1812         libc_hidden_def.
1813         * sysdeps/pthread/herrno-loc.c (__h_errno_location): Likewise.
1814         * sysdeps/pthread/res-state.c (__res_state): Likewise.
1815         * sysdeps/unix/sysv/linux/allocrtsig.c (__libc_current_sigrtmin,
1816         __libc_current_sigrtmax): Likewise.
1817         * Versions [libc] (GLIBC_PRIVATE): Remove __libc_internal_tsd_get,
1818         __libc_internal_tsd_set, __libc_internal_tsd_address,
1819         __libc_alloca_cutoff.
1820         [libpthread] (GLIBC_PRIVATE): Remove __libc_internal_tsd_get,
1821         __libc_internal_tsd_set, __libc_internal_tsd_address.
1823         * sysdeps/pthread/list.h: Remove assert.h include.
1824         * sysdeps/unix/sysv/linux/fork.c: Include <fork.h>, not "fork.h".
1826         * sysdeps/pthread/list.h: New file.
1827         * sysdeps/unix/sysv/linux/jmp-unwind.c: New file.
1828         * sysdeps/unix/sysv/linux/fork.c: New file.
1829         * sysdeps/unix/sysv/linux/fork.h: New file.
1830         * sysdeps/unix/sysv/linux/ia64/fork.h: New file.
1831         * sysdeps/unix/sysv/linux/sparc/fork.h: New file.
1832         * sysdeps/unix/sysv/linux/register-atfork.c: New file.
1833         * sysdeps/unix/sysv/linux/unregister-atfork.c: New file.
1834         * sysdeps/unix/sysv/linux/Makefile: New file.
1835         * sysdeps/unix/sysv/linux/Versions: New file.
1836         * ptlongjmp.c (pthread_cleanup_upto): Rename to...
1837         (__pthread_cleanup_upto): ...this. Add targetframe argument,
1838         use it instead of currentframe.  No longer static.
1839         (siglongjmp, longjmp): Remove pthread_cleanup_upto calls.
1840         * internals.h (__pthread_cleanup_upto, __pthread_fork): New prototypes.
1841         (struct pthread_functions): Add ptr_pthread_fork,
1842         ptr_pthread_cleanup_upto.
1843         * pthread.c (pthread_functions): Initialize ptr_pthread_fork and
1844         ptr_pthread_cleanup_upto.
1845         * ptfork.c: Include fork.h.
1846         (struct handler_list, struct handler_list_block): Remove.
1847         (pthread_atfork_lock, pthread_atfork_prepare, pthread_atfork_parent,
1848         pthread_atfork_child): Remove.
1849         (pthread_insert_list, __pthread_atfork, pthread_call_handlers): Remove.
1850         (__pthread_fork): New function.
1851         (__fork, __vfork): Call __libc_fork.
1852         * Makefile (libpthread-routines): Add old_pthread_atfork.
1853         (libpthread-nonshared): Add pthread_atfork.
1854         (others): Depend on $(objpfx)libpthread_nonshared.a.
1855         ($(objpfx)libpthread_nonshared.a): New rule.
1856         (install): Depend on $(inst_libdir)/libpthread.so.
1857         ($(inst_libdir)/libpthread.so, $(inst_libdir)/libpthread_nonshared.a):
1858         New rules.
1859         (tests): Depend on libpthread_nonshared.a too.
1860         * old_pthread_atfork.c: New file.
1861         * pthread_atfork.c: New file.
1862         * Makeconfig (shared-thread-library): Include libpthread_nonshared.a
1863         too.
1865 2002-12-30  Jakub Jelinek  <jakub@redhat.com>
1867         * forward.c: Make all functions available by default again.  It
1868         caused too much trouble.
1869         * internals.h (struct pthread_functions): Rename ptr_pthread_exit
1870         and ptr_pthread_attr_init_2_* to ptr___pthread_exit and
1871         ptr___pthread_attr_init_2_*.
1872         * pthread.c (pthread_functions): Adjust.
1874 2002-12-28  Jakub Jelinek  <jakub@redhat.com>
1876         * libc_pthread_init.c (__libc_pthread_init): Remove
1877         MULTIPLE_THREADS_OFFSET check.
1878         * sysdeps/i386/tls.h: Include tcb-offsets.h in assembler.
1879         (SYSINFO_OFFSET): Remove.
1880         * sysdeps/i386/Makefile [csu] (gen-as-const-headers): Add
1881         tcb-offsets.sym.
1882         * sysdeps/i386/tcb-offsets.sym: New file.
1883         * sysdeps/pthread/tcb-offsets.h: New file.
1884         * sysdeps/sparc/sparc32/tls.h: Removed.
1885         * sysdeps/sparc/sparc64/tls.h: Move...
1886         * sysdeps/sparc/tls.h: ...here.  Include tcb-offsets.h in assembler.
1887         * sysdeps/sparc/Makefile: New file.
1888         * sysdeps/sparc/tcb-offsets.sym: New file.
1889         * sysdeps/ia64/tls.h: Include tcb-offsets.h in assembler.
1890         * sysdeps/ia64/Makefile: New file.
1891         * sysdeps/ia64/tcb-offsets.sym: New file.
1892         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
1893         (MULTIPLE_THREADS_OFFSET): Remove.
1894         Replace defined MULTIPLE_THREADS_OFFSET
1895         with defined FLOATING_STACKS && USE___THREAD.
1896         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1897         (MULTIPLE_THREADS_OFFSET): Remove.
1898         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
1899         (MULTIPLE_THREADS_OFFSET): Remove.
1900         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
1901         (MULTIPLE_THREADS_OFFSET): Remove.
1902         * pthread.c (__pthread_initialize_manager): Remove
1903         MULTIPLE_THREADS_OFFSET cbeck.
1905         * tst-cancel-wrappers.sh: Add line continuations.
1907 2002-12-27  Jakub Jelinek  <jakub@redhat.com>
1909         * sysdeps/pthread/bits/libc-tsd.h: Include linuxthreads/descr.h
1910         and bits/libc-lock.h.
1911         (__libc_internal_tsd_get, __libc_internal_tsd_set,
1912         __libc_internal_tsd_address): Remove.
1913         (__pthread_internal_tsd_address, __pthread_internal_tsd_get,
1914         __pthread_internal_tsd_set): New weak_externs.
1915         (__libc_tsd_address, __libc_tsd_get, __libc_tsd_set): Define
1916         using __libc_maybe_call2.
1917         (__libc_tsd_key_t): Move to ...
1918         * descr.h (__libc_tsd_key_t): ...here.
1919         Remove bits/libc-tsd.h include.
1920         * sysdeps/pthread/errno-loc.c: New file.
1921         * sysdeps/pthread/herrno-loc.c: New file.
1922         * sysdeps/pthread/res-state.c: New file.
1923         * libc-cancellation.c (THREAD_GETMEM, THREAD_SETMEM): Remove.
1924         (__libc_enable_asynccancel, __libc_disable_asynccancel): Use
1925         thread_self unconditionally.  Use LIBC_THREAD_[SG]ETMEM instead
1926         of THREAD_[SG]ETMEM.
1927         * specific.c (libc_internal_tsd_set): Renamed to...
1928         __pthread_internal_tsd_set.  Remove static.
1929         (libc_internal_tsd_get): Renamed to...
1930         __pthread_internal_tsd_get.  Remove static.
1931         (libc_internal_tsd_address): Renamed to...
1932         __pthread_internal_tsd_address.  Remove static.
1933         (__libc_internal_tsd_set, __libc_internal_tsd_get,
1934         __libc_internal_tsd_address, __libc_alloca_cutoff): Remove.
1935         * internals.h [!NOT_IN_libc] (LIBC_THREAD_GETMEM, LIBC_THREAD_SETMEM):
1936         Define.
1937         (__pthread_internal_tsd_set, __pthread_internal_tsd_get,
1938         __pthread_internal_tsd_address): New prototypes.
1939         (struct pthread_functions): Add
1940         ptr_pthread_internal_tsd_([sg]et|address) fields.
1941         [!NOT_IN_libc && !FLOATING_STACKS] (thread_self): Define.
1942         * pthread.c (pthread_functions) [!USE_TLS && !HAVE___THREAD]:
1943         Initialize ptr_pthread_internal_tsd_([sg]et|address) fields.
1944         * Versions (libpthread): Remove __libc_alloca_cutoff@GLIBC_PRIVATE.
1945         * alloca_cutoff.c: New file.
1946         * no-tsd.c: Removed.
1947         * Makefile (routines): Remove no-tsd.  Add alloca_cutoff.
1948         * pt-system.c (system): Remove cancellation handling.
1949         * tst-cancel-wrappers.sh: Allow pt-system.o* to not use the
1950         cancellation routines.
1952         * sysdeps/i386/tls.h: Include dl-sysdep.h and stdint.h.
1953         (tcbhead_t): Add sysinfo field.
1954         (SYSINFO_OFFSET, INIT_SYSINFO): Define.
1955         (TLS_INIT_TP): Use INIT_SYSINFO.
1956         * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: New file.
1957         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
1958         (MULTIPLE_THREADS_OFFSET): Adjust.
1959         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h
1960         (MULTIPLE_THREADS_OFFSET): Likewise.
1961         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
1962         (MULTIPLE_THREADS_OFFSET): Likewise.
1963         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
1964         (MULTIPLE_THREADS_OFFSET): Likewise.
1965         * descr.h: Include stdint.h.
1966         (struct _pthread_descr_struct): Add p_header.data.sysinfo field.
1968 2002-12-22  Jakub Jelinek  <jakub@redhat.com>
1970         * libc_pthread_init.c: Include stdlib.h.
1971         * sysdeps/i386/tls.h (tcbhead_t): Add multiple_threads member.
1972         (TLS_INIT_TP_EXPENSIVE): Define.
1973         * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call,
1974         __libc_maybe_call2): In _LIBC check SHARED define.
1975         * sysdeps/ia64/tls.h: New file.
1976         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: New file.
1977         * sysdeps/unix/sysv/linux/ia64/Makefile: New file.
1978         * sysdeps/x86_64/tls.h (TLS_INIT_TP_EXPENSIVE): Define.
1979         * sysdeps/sparc/sparc32/tls.h: New file.
1980         * sysdeps/sparc/sparc64/tls.h: New file.
1981         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: New file.
1982         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: New file.
1983         * Makefile (tests): Add tst-cancel[1-6].
1984         (tests-reverse): Add tst-cancel5.
1985         Link libc.so before libpthread.so for tests-reverse.
1986         * tst-cancel1.c: New file.
1987         * tst-cancel2.c: New file.
1988         * tst-cancel3.c: New file.
1989         * tst-cancel4.c: New file.
1990         * tst-cancel5.c: New file.
1991         * tst-cancel6.c: New file.
1993 2002-12-27  Andreas Schwab  <schwab@suse.de>
1995         * sysdeps/unix/sysv/linux/m68k/sysdep-cancel.h: New file.
1997 2002-12-22  Roland McGrath  <roland@redhat.com>
1999         * Makefile (omit-deps): Add $(unix-syscalls:%=ptw-%).
2001 2002-12-21  Ulrich Drepper  <drepper@redhat.com>
2003         * pthread.c (init_rtsigs): Remove incomplete __builtin_expect.
2004         Reported by Art Hass <ahaas@airmail.net>.
2006 2002-12-19  Jakub Jelinek  <jakub@redhat.com>
2008         * forward.c (pthread_attr_init_2_0, pthread_attr_init_2_1):
2009         Use return 0 as 6th argument to FORWARD4.
2011 2002-12-18  Jakub Jelinek  <jakub@redhat.com>
2013         * sysdeps/i386/useldt.h (FLOATING_STACKS, ARCH_STACK_MAX_SIZE): Only
2014         define if __ASSUME_LDT_WORKS > 0.
2015         * libc-cancellation.c (THREAD_GETMEM, THREAD_SETMEM): Redefine to
2016         struct member access if !FLOATING_STACKS.
2017         * sysdeps/pthread/flockfile.c (flockfile): Change into weak alias.
2019 2002-12-18  Jakub Jelinek  <jakub@redhat.com>
2021         * internals.h (__pthread_thread_self): New prototype.
2022         (struct pthread_functions): Add ptr_pthread_thread_self field.
2023         * pthread.c (pthread_functions): Initialize ptr_pthread_thread_self.
2024         (__pthread_thread_self): New function.
2025         * libc-cancellation.c (__pthread_thread_self): Add weak_extern.
2026         (__libc_enable_asynccancel, __libc_disable_asynccancel): Don't
2027         use thread_self() directly if not FLOATING_STACKS.
2029 2002-12-18  Jakub Jelinek  <jakub@redhat.com>
2031         * sysdeps/x86_64/pt-machine.h: Guard most of the header
2032         with #ifndef __ASSEMBLER__.
2033         * pthread.c (pthread_functions): Use SHLIB_COMPAT around
2034         pthread_attr_init_2_0 use.
2036 2002-12-17  Jakub Jelinek  <jakub@redhat.com>
2038         * wrapsyscall.c: Removed.
2039         * weaks.c: Removed.
2040         * Makefile (distribute): Add tst-cancel-wrappers.sh.
2041         (routines): Remove weaks.  Add forward,
2042         libc_pthread_init, libc-cancellation.
2043         (shared-only-routines): Remove weaks.  Add forward.
2044         (libpthread-routines): Remove wrapsyscall.
2045         Add ptw-write, ptw-read, ptw-close, ptw-fcntl, ptw-accept,
2046         ptw-connect, ptw-recv, ptw-recvfrom, ptw-recvmsg, ptw-send,
2047         ptw-sendmsg, ptw-sendto, ptw-fsync, ptw-lseek, ptw-lseek64,
2048         ptw-llseek, ptw-msync, ptw-nanosleep, ptw-open, ptw-open64,
2049         ptw-pause, ptw-pread, ptw-pread64, ptw-pwrite, ptw-pwrite64,
2050         ptw-tcdrain, ptw-wait, ptw-waitpid, pt-system, pt-allocrtsig.
2051         (libpthread-shared-only-routines): Add pt-allocrtsig.
2052         (tests): Depend on $(objpfx)tst-cancel-wrappers.out.
2053         ($(objpfx)tst-cancel-wrappers.out): New rule.
2054         * sysdeps/pthread/bits/libc-lock.h: Include linuxthreads/internals.h
2055         if in libc.
2056         (__libc_maybe_call): In libpthread.* don't check for existance
2057         of the function.
2058         (__libc_maybe_call2): Define.
2059         (__libc_lock_init, __libc_lock_fini, __libc_lock_lock,
2060         __libc_lock_trylock, __libc_lock_unlock): Use it.
2061         * sysdeps/pthread/flockfile.c: New file.
2062         * sysdeps/pthread/ftrylockfile.c: New file.
2063         * sysdeps/pthread/funlockfile.c: New file.
2064         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: New file.
2065         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: New file.
2066         * sysdeps/unix/sysv/linux/allocrtsig.c: New file.
2067         * libc-cancellation.c: New file.
2068         * forward.c: New file.
2069         * libc_pthread_init.c: New file.
2070         * pt-system.c: New file.
2071         * pthread.c: Remove locale.h.
2072         (__pthread_manager_thread): Initialize multiple_threads.
2073         (__pthread_multiple_threads): Declare.
2074         (pthread_functions): New variable.
2075         (__pthread_initialize_minimal): Remove __uselocale call.
2076         Call __libc_pthread_init.
2077         (__pthread_initialize_manager): Initialize __pthread_multiple_threads,
2078         initial thread's multiple_threads and __libc_multiple_threads.
2079         Check MULTIPLE_THREADS_OFFSET value. Initialize manager thread's
2080         multiple_threads.
2081         (pthread_setschedparam, pthread_getschedparam): Rename to __
2082         prefixed variants.  Add strong_alias.
2083         (current_rtmin, current_rtmax, __libc_current_sigrtmin,
2084         __libc_current_sigrtmax, __libc_allocate_rtsig): Remove.
2085         (init_rtsigs): Use __libc_current_sigrtmin_private.
2086         (pthread_initialize): Only call init_rtsigs if
2087         !__ASSUME_REALTIME_SIGNALS.
2088         (__pthread_require_wrappers, __pthread_require_lockfile): Remove.
2089         * internals.h (__pthread_attr_destroy, __pthread_attr_setdetachstate,
2090         __pthread_attr_getdetachstate, __pthread_attr_setschedparam,
2091         __pthread_attr_getschedparam, __pthread_attr_setschedpolicy,
2092         __pthread_attr_getschedpolicy, __pthread_attr_setinheritsched,
2093         __pthread_attr_getinheritsched, __pthread_attr_setscope,
2094         __pthread_attr_getscope, __pthread_cond_init,
2095         __pthread_cond_destroy, __pthread_cond_wait,
2096         __pthread_cond_signal, __pthread_cond_broadcast,
2097         __pthread_condattr_init, __pthread_condattr_destroy,
2098         __pthread_equal, __pthread_getschedparam,
2099         __pthread_setschedparam, __pthread_setcancelstate,
2100         __pthread_setcanceltype, __pthread_enable_asynccancel,
2101         __libc_enable_asynccancel, __libc_pthread_init): New prototype.
2102         (__pthread_mutex_init, __pthread_mutex_destroy,
2103         __pthread_mutex_lock, __pthread_mutex_unlock,
2104         __pthread_mutex_trylock): Likewise.
2105         Add hidden_proto.
2106         (struct pthread_functions): New type.
2107         (__libc_pthread_functions): New variable.
2108         (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): Define.
2109         * descr.h (struct _pthread_descr_struct): Add
2110         p_header.data.multiple_threads field.
2111         * manager.c (pthread_handle_create): Initialize multiple_threads.
2112         * cancel.c (__pthread_enable_asynccancel,
2113         __pthread_disable_asynccancel): New functions.
2114         (__pthread_provide_wrappers): Remove.
2115         (pthread_setcancelstate, pthread_setcanceltype): Rename to __
2116         prefixed variants.  Add strong_alias.
2117         * condvar.c (pthread_cond_init, pthread_cond_destroy,
2118         pthread_cond_wait, pthread_cond_signal, pthread_cond_broadcast,
2119         pthread_condattr_init, pthread_condattr_destroy): Likewise.
2120         * join.c (pthread_exit): Likewise.
2121         * attr.c (pthread_attr_destroy, pthread_attr_setdetachstate,
2122         pthread_attr_getdetachstate, pthread_attr_setschedparam,
2123         pthread_attr_getschedparam, pthread_attr_setschedpolicy,
2124         pthread_attr_getschedpolicy, pthread_attr_setinheritsched,
2125         pthread_attr_getinheritsched, pthread_attr_setscope,
2126         pthread_attr_getscope): Likewise.
2127         * mutex.c (__pthread_mutex_init, __pthread_mutex_destroy,
2128         __pthread_mutex_lock, __pthread_mutex_unlock,
2129         __pthread_mutex_trylock): Add hidden_def.
2130         * Versions (libc): Add __libc_pthread_init,
2131         __libc_current_sigrtmin_private, __libc_current_sigrtmax_private,
2132         __libc_allocate_rtsig_private @@GLIBC_PRIVATE.
2133         * lockfile.c: Remove some USE_IN_LIBIO guards.
2134         (__pthread_provide_lockfile): Remove.
2135         * pt-allocrtsig.c: New file.
2136         * tst-cancel-wrappers.sh: New test.
2138 2002-12-15  Ulrich Drepper  <drepper@redhat.com>
2140         * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect,
2141         readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev.
2142         * wrapsyscall.c: Remove creat, poll, pselect, readv, select,
2143         sigpause, sigsuspend, sigwaitinfo, waitid, and writev wrappers.
2145 2002-12-10  Ulrich Drepper  <drepper@redhat.com>
2147         * wrapsyscall.c (CANCELABLE_SYSCALL): Don't define function as
2148         weak.  There is no reason for that.
2149         (CANCELABLE_SYSCALL_VA): Likewise.
2151 2002-12-09  Ulrich Drepper  <drepper@redhat.com>
2153         * wrapsyscall.c: Add wrappers for creat, poll, pselect, readv, select,
2154         sigpause, __xpg_sigpause, sigsuspend, sigwaitinfo, waitid, and writev.
2155         * Versions: Export creat, poll, pselect, readv, select, sigpause,
2156         __xpg_sigpause, sigsuspend, sigwaitinfo, waitid, and writev from
2157         libpthread in version GLIBC_2.3.2.
2159 2002-12-06  Ulrich Drepper  <drepper@redhat.com>
2161         * sysdeps/pthread/bits/libc-lock.h: Define __rtld_lock_* macros.
2163 2002-12-05  Roland McGrath  <roland@redhat.com>
2165         * pthread.c (__pthread_initialize_minimal)
2166         [USE_TLS && SHARED && !USE___THREAD]: Initialize TLS and set up the
2167         TCB if the dynamic linker didn't do it at startup.
2169         * sysdeps/i386/tls.h (TLS_INIT_TP): Make it return zero or an error
2170         string.
2171         (TLS_DO_SET_THREAD_AREA, TLS_DO_MODIFY_LDT, TLS_SETUP_GS_SEGMENT):
2172         Submacros updated.
2173         * sysdeps/x86_64/tls.h (TLS_INIT_TP): Likewise.
2174         * sysdeps/alpha/tls.h (TLS_INIT_TP): Likewise (always zero).
2176 2002-12-03  Roland McGrath  <roland@redhat.com>
2178         * pthread.c (pthread_initialize) [SHARED]: Copy dl_error_tsd value
2179         from dynamic linker internal cell to new libc cell.
2181 2002-11-28  Roland McGrath  <roland@redhat.com>
2183         * tst-context.c: #define IS_IN_libpthread around #include <tls.h>
2184         before other headers, so FLOATING_STACKS is not defined wrongly.
2186         * sysdeps/i386/tls.h [!IS_IN_libpthread]: Enable TLS support
2187         even if [! FLOATING_STACKS].
2188         (TLS_DO_MODIFY_LDT_KERNEL_CHECK): New macro.
2189         If not under [__ASSUME_LDT_WORKS > 0], then do a runtime check of
2190         dl_osversion >= 2.3.99 and fatal if not.
2191         (TLS_DO_MODIFY_LDT): Use it.
2193 2002-11-28  Ulrich Drepper  <drepper@redhat.com>
2195         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define macros which
2196         require it to 200112L.  Remove _POSIX_POLL and _POSIX_SELECT.
2197         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
2199 2002-11-19  Ulrich Drepper  <drepper@redhat.com>
2201         * Versions (libc: GLIBC_2.0): Remove names of functions which are
2202         not defined in libc.
2203         * Makefile (shared-only-routines): Add weaks.
2204         * weaks.c: Remove functions which are not exported from libc.so.
2206 2002-11-14  Roland McGrath  <roland@redhat.com>
2208         * libc-tsd.c: New file.
2209         * Makefile (distribute): Add it.
2210         (libc-link.so): New variable.
2211         ($(objpfx)libpthread.so): Depend on that instead of libc.so file name.
2212         (libc-ok-for-link): New variable.
2213         [$(versioning) = yes]: Include $(common-objpfx)tls.make and define
2214         libc-ok-for-link to $(use-thread).
2215         [$(libc-ok-for-link) = no]
2216         (libc-link.so): Set to $(objpfx)libc.so, not $(common-objpfx)libc.so.
2217         ($(objpfx)libc_pic_lite.a,$(objpfx)libc_pic_lite.os, $(objpfx)libc.so):
2218         New targets.
2219         (generated): Append them.
2220         (extra-objs): Append libc-tsd.os.
2222         * libc-tls-loc.c: New file.
2223         * Makefile (libpthread-routines): Add it.
2225 2002-11-14  Andreas Schwab  <schwab@suse.de>
2227         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Fix unterminated
2228         string.
2230 2002-11-13  Roland McGrath  <roland@redhat.com>
2232         * Examples/ex6.c (main): Improve error reporting.
2234 2002-11-04  Ulrich Drepper  <drepper@redhat.com>
2236         * sysdeps/i386/Makefile: Compile pthread.c and sighandler.c with
2237         -fno-omit-frame-pointer.  Patch by Andreas Steinmetz <ast@domdv.de>.
2239         * sysdeps/i386/useldt.h [PIC] (USETLS_LOAD_EBX): Use correct input
2240         register number.
2241         (DO_SET_THREAD_AREA): Mark asm output specifiers correctly.
2243 2002-10-22  Jakub Jelinek  <jakub@redhat.com>
2245         * manager.c (pthread_start_thread): Call __uselocale even
2246         if [! SHARED].  Patch by Leon Kanter <leon@geon.donetsk.ua>.
2248 2002-10-17  Roland McGrath  <roland@redhat.com>
2250         * Makefile (unload): Don't link in libpthread.so.
2251         ($(objpfx)unload.out): Do depend on it.
2252         * unload.c (main): Improve error reporting.
2254 2002-10-09  Roland McGrath  <roland@redhat.com>
2256         * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call): New macro.
2257         Under [__PIC__], call the function via the pointer fetched for
2258         comparison rather than a call by name that uses the PLT.
2259         (__libc_lock_init, __libc_rwlock_init, __libc_lock_fini)
2260         (__libc_rwlock_fini, __libc_lock_lock, __libc_rwlock_rdlock)
2261         (__libc_rwlock_wrlock, __libc_lock_trylock, __libc_rwlock_tryrdlock)
2262         (__libc_rwlock_trywrlock, __libc_lock_unlock, __libc_rwlock_unlock)
2263         (__libc_key_create, __libc_getspecific, __libc_setspecific)
2264         (__libc_atfork): Use it.
2266         * pthread.c [SHARED] (__libc_dl_error_tsd): New function.
2267         (pthread_initialize) [SHARED]: Set _dl_error_catch_tsd to that.
2268         * Versions (libc: GLIBC_PRIVATE): Add __libc_dl_error_tsd.
2269         (ld: GLIBC_PRIVATE): Set removed.
2271 2002-10-11  Ulrich Drepper  <drepper@redhat.com>
2273         * sysdeps/unix/sysv/linux/execve.c: New file.
2275 2002-10-09  Jakub Jelinek  <jakub@redhat.com>
2277         * no-tsd.c: Include stdlib.h.
2279 2002-10-07  Jakub Jelinek  <jakub@redhat.com>
2281         * sysdeps/unix/sysv/linux/allocalim.h: New file.
2282         * descr.h (struct _pthread_descr_struct): Add p_alloca_cutoff
2283         field.
2284         * manager.c (__pthread_allocate_stack): Add out_stacksize argument.
2285         Pass stack size to caller.
2286         (pthread_handle_create): Set p_alloca_cutoff.
2287         * pthread.c (__pthread_initial_thread): Use C99 designated
2288         initializers.  Set p_alloca_cutoff.
2289         (__pthread_manager_thread): Likewise.
2290         (__pthread_initialize_minimal) [USE_TLS]: Set p_alloca_cutoff
2291         for initial thread.
2292         (__pthread_init_max_stacksize): Possibly decrease p_alloca_cutoff
2293         for initial thread.
2294         (__pthread_initialize_manager) [USE_TLS]: Set p_alloca_cutoff
2295         for manager thread.
2296         * specific.c (__libc_alloca_cutoff): New function.
2297         * no-tsd.c (__libc_alloca_cutoff): New function.
2298         * Versions: Export __libc_alloca_cutoff@@GLIBC_PRIVATE from libc
2299         and libpthread.
2301 2002-10-02  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2303         * sysdeps/sh/pt-machine.h: Make C code ifndef'ed with __ASSEMBLER__.
2304         * sysdeps/sh/tls.h: Likewise.
2305         * sysdeps/unix/sysv/linux/sh/smp.h: New file.
2307 2002-09-29  Jakub Jelinek  <jakub@redhat.com>
2309         * sysdeps/pthread/tst-timer.c (main): Clear
2310         SIGEV2.sigev_notify_attributes.
2312 2002-09-29  Ulrich Drepper  <drepper@redhat.com>
2314         * sysdeps/i386/useldt.h (DO_SET_THREAD_AREA): Don't use
2315         INLINE_SYSCALL for set_thread_area syscall.
2317 2002-09-28  Roland McGrath  <roland@redhat.com>
2319         * pthread.c (__pthread_reset_main_thread) [FLOATING_STACKS]:
2320         Don't call setrlimit, since we did no prior bogon we need to undo.
2322 2002-09-27  Roland McGrath  <roland@redhat.com>
2324         * sysdeps/x86_64/tls.h [__ASSEMBLER__]: Don't include <pt-machine.h>.
2326 2002-09-24  Roland McGrath  <roland@redhat.com>
2328         * sysdeps/x86_64/tls.h: New file.
2330 2002-09-23  Roland McGrath  <roland@redhat.com>
2332         * Examples/ex13.c (dump_mut): int -> size_t for counter.
2334 2002-09-18  Bruno Haible  <bruno@clisp.org>
2336         * Examples/ex10.c (thread): Fail if pthread_mutex_timedlock() returns
2337         an unexpected error code.
2339         * internals.h (__pthread_message): Add const to first parameter type.
2340         * pthread.c (__pthread_message): Likewise.
2342         * sysdeps/unix/sysv/linux/configure: Moved to ../sysdeps/pthread.
2344 2002-09-17  Roland McGrath  <roland@redhat.com>
2346         * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT, TLS_DO_SET_THREAD_AREA):
2347         Set the descriptor limit to the full 4GB, so %gs:OFFSET works for any
2348         offset (positive or negative) relative to the thread struct.
2349         * sysdeps/i386/useldt.h (DO_MODIFY_LDT, DO_SET_THREAD_AREA): Likewise.
2351 2002-09-12  Jakub Jelinek  <jakub@redhat.com>
2353         * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: Move...
2354         * sysdeps/unix/sysv/linux/sparc/Makefile: ...here.
2355         Replace /usr/lib/crt[in].o with crt[in].o too.
2357 2002-09-11  Steven Munroe  <sjmunroe@us.ibm.com>
2359         * sysdeps/powerpc/powerpc64/pt-machine.h: New file.
2361 2002-09-04  Bruno Haible  <bruno@clisp.org>
2363         * pthread.c: Include <sys/time.h>.
2364         (is_smp_system): Move to sysdeps/unix/sysv/linux/smp.h.
2365         * sysdeps/unix/sysv/linux/smp.h: New file, extracted from pthread.c.
2366         * Makefile (distribute): Add smp.h to the list.
2368 2002-09-04  Bruno Haible  <bruno@clisp.org>
2370         * sysdeps/alpha/pt-machine.h: Choose different include file location
2371         on non-Linux platforms.
2373         * wrapsyscall.c (PROMOTE_INTEGRAL_TYPE): New macro.
2374         (open, open64): Change va_arg argument type to the integral type to
2375         which mode_t promotes.
2377         * sysdeps/pthread/tst-timer.c (main): Don't assume anything about
2378         the structure of 'struct sigevent'.
2380         * errno.c (__errno_location, __h_errno_location, __res_state):
2381         Use prototype function definitions.
2383 2002-07-29  Steven Munroe  <sjmunroe@us.ibm.com>
2385         * shlib-versions: Set libpthread version to 2.3 for powerpc64.
2386         * sysdeps/powerpc/pt-machine.h: moved to...
2387         * sysdeps/powerpc/powerpc32/pt-machine.h: ...here
2388         * sysdeps/powerpc/powerpc64/pt-machine.h: New file.
2390 2002-09-02  Roland McGrath  <roland@redhat.com>
2392         * sysdeps/powerpc/Makefile (CFLAGS-pt-initfini.s): New variable.
2394 2002-09-01  Roland McGrath  <roland@redhat.com>
2396         * sysdeps/pthread/bits/libc-tsd.h (enum __libc_tsd_key_t): Add new keys
2397         CTYPE_B, CTYPE_TOLOWER, CTYPE_TOUPPER.
2399         * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_address): New macro.
2400         (__libc_internal_tsd_address): Declare it.
2401         * Versions (libc, ld, libpthread: GLIBC_PRIVATE): Add
2402         __libc_internal_tsd_address.
2403         * specific.c (libc_internal_tsd_address): New function.
2404         (__libc_internal_tsd_address): New variable.
2405         * no-tsd.c (__libc_internal_tsd_address): New variable.
2407 2002-08-31  Ulrich Drepper  <drepper@redhat.com>
2409         * Makefile: Don't use rule for crt%.o, spell it out as rules for
2410         crti.o and crtn.o.
2412 2002-08-30  Roland McGrath  <roland@redhat.com>
2414         * Makefile (extra-objs, omit-deps): Add crtn.
2415         ($(objpfx)libpthread.so): Depend on $(objpfx)crtn.o.
2416         ($(objpfx)libpthread.so: +postinit): Append $(objpfx)crtn.o.
2417         ($(objpfx)crtn.S): New target.
2418         ($(objpfx)crt%.o): Pattern rule replaces crti.o target.
2419         (generated): Add crtn.S.
2421         * sysdeps/unix/sysv/linux/x86_64/Makefile ($(objpfx)specs): Massage
2422         crtn.o pathname too.
2424 2002-08-30  Jakub Jelinek  <jakub@redhat.com>
2426         * pthread.c (__pthread_initialize_minimal): Call __uselocale even
2427         if [! SHARED].
2429 2002-08-30  Roland McGrath  <roland@redhat.com>
2431         * tst-static-locale.c: New file.
2432         * Makefile (tests, tests-static): Add it.
2434 2002-04-24  Steven Munroe  <sjmunroe@us.ibm.com>
2436         * spinlock.c (__pthread_lock): Fix spurious wakeup
2437         handling.  Don't clear lowest bit of list pointer as sign the thread
2438         is still on the wait list.  Don't restart after spurious wakeup
2439         with spinning to get the lock.
2440         (__pthread_unlock): Take set lowest bit into account when handling
2441         pointer to list elements.
2442         Patch by Steve Munroe <sjmunroe@us.ibm.com>.
2444 2002-08-28  Roland McGrath  <roland@redhat.com>
2446         * sysdeps/pthread/timer_routines.c (thread_func): Fix type in cast.
2448 2002-08-28  Jakub Jelinek  <jakub@redhat.com>
2450         * sysdeps/unix/sysv/linux/hppa/aio_cancel.c: New file.
2451         * sysdeps/unix/sysv/linux/sparc/aio_cancel.c: New file.
2452         * sysdeps/unix/sysv/linux/alpha/aio_cancel.c: New file.
2454 2002-08-28  Ulrich Drepper  <drepper@redhat.com>
2456         * sysdeps/pthread/timer_routines.c (thread_func): Change return
2457         type to void and add casts in use to avoid warnings with all gcc
2458         versions.
2460 2002-08-08  Jakub Jelinek  <jakub@redhat.com>
2462         * sysdeps/unix/sysv/linux/bits/local_lim.h (PTHREAD_THREADS_MAX):
2463         Bump to 16384.
2464         * manager.c (__pthread_handles): Remove.
2465         * pthandles.c: New file.
2466         * pthread.c (__pthread_initialize_minimal): Initialize
2467         __pthread_handles[0] and __pthread_handles[1].
2468         * Makefile (libpthread-routines): Add pthandles (must be last).
2470 2002-08-26  Brian Youmans  <3diff@gnu.org>
2472         * Examples/ex10.c: Corrected version number in Lesser GPL copying
2473         permission notice from 2 to 2.1.
2474         * Examples/ex11.c: Likewise.
2475         * Examples/ex13.c: Likewise.
2476         * Examples/ex8.c: Likewise.
2477         * Examples/ex9.c: Likewise.
2478         * barrier.c: Likewise.
2479         * events.c: Likewise.
2480         * lockfile.c: Likewise.
2481         * no-tsd.c: Likewise.
2482         * pt-machine.c: Likewise.
2483         * ptclock_gettime.c: Likewise.
2484         * ptclock_settime.c: Likewise.
2485         * rwlock.c: Likewise.
2486         * sysdeps/alpha/pspinlock.c: Likewise.
2487         * sysdeps/alpha/pt-machine.h: Likewise.
2488         * sysdeps/arm/pspinlock.c: Likewise.
2489         * sysdeps/arm/pt-machine.h: Likewise.
2490         * sysdeps/cris/pspinlock.c: Likewise.
2491         * sysdeps/cris/pt-machine.h: Likewise.
2492         * sysdeps/hppa/pspinlock.c: Likewise.
2493         * sysdeps/hppa/pt-machine.h: Likewise.
2494         * sysdeps/i386/i686/pt-machine.h: Likewise.
2495         * sysdeps/i386/pspinlock.c: Likewise.
2496         * sysdeps/i386/pt-machine.h: Likewise.
2497         * sysdeps/i386/useldt.h: Likewise.
2498         * sysdeps/ia64/pspinlock.c: Likewise.
2499         * sysdeps/ia64/pt-machine.h: Likewise.
2500         * sysdeps/m68k/pspinlock.c: Likewise.
2501         * sysdeps/m68k/pt-machine.h: Likewise.
2502         * sysdeps/mips/pspinlock.c: Likewise.
2503         * sysdeps/mips/pt-machine.h: Likewise.
2504         * sysdeps/powerpc/pspinlock.c: Likewise.
2505         * sysdeps/powerpc/pt-machine.h: Likewise.
2506         * sysdeps/pthread/bits/initspin.h: Likewise.
2507         * sysdeps/pthread/bits/libc-lock.h: Likewise.
2508         * sysdeps/pthread/bits/libc-tsd.h: Likewise.
2509         * sysdeps/pthread/getcpuclockid.c: Likewise.
2510         * sysdeps/pthread/posix-timer.h: Likewise.
2511         * sysdeps/pthread/timer_create.c: Likewise.
2512         * sysdeps/pthread/timer_delete.c: Likewise.
2513         * sysdeps/pthread/timer_getoverr.c: Likewise.
2514         * sysdeps/pthread/timer_gettime.c: Likewise.
2515         * sysdeps/pthread/timer_routines.c: Likewise.
2516         * sysdeps/pthread/timer_settime.c: Likewise.
2517         * sysdeps/pthread/tst-timer.c: Likewise.
2518         * sysdeps/s390/pspinlock.c: Likewise.
2519         * sysdeps/s390/s390-32/pt-machine.h: Likewise.
2520         * sysdeps/s390/s390-64/pt-machine.h: Likewise.
2521         * sysdeps/sh/pspinlock.c: Likewise.
2522         * sysdeps/sh/pt-machine.h: Likewise.
2523         * sysdeps/sparc/sparc32/pspinlock.c: Likewise.
2524         * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
2525         * sysdeps/sparc/sparc32/sparcv9/pspinlock.c: Likewise.
2526         * sysdeps/sparc/sparc64/pspinlock.c: Likewise.
2527         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
2528         * sysdeps/unix/sysv/linux/bits/local_lim.h: Likewise.
2529         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
2530         * sysdeps/unix/sysv/linux/bits/sigthread.h: Likewise.
2531         * sysdeps/unix/sysv/linux/hppa/bits/initspin.h: Likewise.
2532         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
2533         * tststack.c: Likewise.
2534         * unload.c: Likewise.
2535         * weaks.c: Likewise.
2536         * wrapsyscall.c: Likewise.
2538         * sysdeps/pthread/pt-initfini.c: Changed copying
2539         permission notice to Lesser GPL from Library GPL, including the
2540         references in the special exception.
2541         * sysdeps/unix/sysv/linux/hppa/pt-initfini.c: Likewise.
2542         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Likewise.
2543         * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c:
2544         Likewise.
2545         * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c:
2546         Likewise.
2547         * sysdeps/unix/sysv/linux/sh/pt-initfini.c: Likewise.
2549 2002-08-26  Ulrich Drepper  <drepper@redhat.com>
2551         * Examples/ex10.c (thread): tv_nsec == 1000000000 is already
2552         overflow [PR libc/4244].
2554 2002-08-25  Ulrich Drepper  <drepper@redhat.com>
2556         * sysdeps/pthread/timer_routines.c (thread_func): Make the
2557         compiler happy by adding a return statement which will never be
2558         reached.
2560         * tst-context.c (main): Cast to long before casting to pointer.
2562         * Examples/ex17.c (main): Use correct format string.
2564         * Examples/ex9.c (thread): Remove incorrect return statement.
2566 2002-08-23  Ulrich Drepper  <drepper@redhat.com>
2568         * pthread.c (__linuxthreads_version): New global constant.
2570 2002-08-23  Andreas Jaeger  <aj@suse.de>
2572         * sysdeps/x86_64/pt-machine.h: Use %fs instead of %gs
2573         as thread specific register.
2574         (testandset): Fix inline asm.
2575         (THREAD_GETMEM): Fix inline asm.
2577 2002-08-22  Roland McGrath  <roland@redhat.com>
2579         * sysdeps/i386/useldt.h (INIT_THREAD_SELF): Remove [HAVE_TLS_SUPPORT]
2580         conditional.
2581         (INIT_THREAD_SELF): Pass second arg to DO_SET_THREAD_AREA.
2582         (DO_SET_THREAD_AREA): Take second arg, pass to DO_SET_THREAD_AREA_REUSE
2583         macro.  That chooses whether to reuse %gs value or let kernel set it.
2584         [USE_TLS] (DO_SET_THREAD_AREA_REUSE): New macro, always 1.
2585         [!USE_TLS] (DO_SET_THREAD_AREA_REUSE): New macro, true if arg is
2586         not constant 0.
2588 2002-08-21  Ulrich Drepper  <drepper@redhat.com>
2590         * sysdeps/i386/tls.h (TLS_SETUP_GS_SEGMENT): Add new parameter
2591         also to the third definition of this macro.
2593 2002-06-17  Andreas Jaeger  <aj@suse.de>
2595         * sysdeps/unix/sysv/linux/x86_64/Makefile (CFLAGS-pt-initfini.s):
2596         Set it.
2598 2002-08-20  Ulrich Drepper  <drepper@redhat.com>
2600         * sysdeps/i386/useldt.h: Go back to using 16-bit instructions when
2601         loading/reading segment registers.  Some old hardware doesn't
2602         handle the 32-bit instructions as expected.
2603         * sysdeps/i386/tls.h: Likewise.
2605         * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Second parameter is
2606         renamed to secondcall and use is negated.
2607         (TLS_SETUP_GS_SEGMENT): Likewise.
2608         (TLS_INIT_TP): Likewise.
2609         * sysdeps/sh/tls.h (TLS_INIT_TP): Second parameter is renamed to
2610         secondcall.
2612         * sysdeps/i386/tls.h: Use 32-bit operations when handling segment
2613         registers.  No need to mask upper 16 bits in this case.
2614         * sysdeps/i386/useldt.h: Likewise.
2615         (DO_SET_THREAD_AREA): We have to load %gs again even if the value
2616         is the same since the GDT content changed.
2618         * sysdeps/i386/tls.h (TLS_INIT_TP): Add new parameter and pass it on
2619         to TLS_SETUP_GS_SEGMENT.
2620         (TLS_SETUP_GS_SEGMENT): Add new parameter and pass it on to
2621         TLS_DO_SET_THREAD_AREA.
2622         (TLS_DO_SET_THREAD_AREA): If new parameter is zero determine
2623         entry number from %gs value.
2624         * sysdeps/sh/tls.h (TLS_INIT_TP): Add new parameter and simply
2625         ignore it.
2627         * manager.c (pthread_handle_create): Pass NULL to _dl_allocate_tls.
2628         Pass true to _dl_deallocate_tls.
2629         (pthread_free): Likewise.
2630         * pthread.c (__pthread_initialize_manager): Likewise.
2632 2002-08-19  Ulrich Drepper  <drepper@redhat.com>
2634         * sysdeps/i386/useldt.h (DO_SET_THREAD_AREA): Use correct shift when
2635         computing index from %gs value.
2637 2002-08-16  Roland McGrath  <roland@redhat.com>
2639         * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Calculate segment
2640         register value from entry number properly.
2642         * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT): Rewrite asm to use %ebx
2643         optimally conditional on [__PIC__].
2644         (TLS_DO_SET_THREAD_AREA): New macro, implement inline syscall
2645         without touching errno, and use latest modify_ldt-like interface.
2646         (TLS_SETUP_GS_SEGMENT): Use that instead of INLINE_SYSCALL.
2647         * sysdeps/i386/useldt.h (DO_MODIFY_LDT): Set %gs in this macro.
2648         (DO_SET_THREAD_AREA): New macro, uses current syscall interface with
2649         existing %gs value as the segment to set.
2650         (INIT_THREAD_SELF): Rewritten using those.  Use set_thread_area only
2651         under [HAVE_TLS_SUPPORT] so we can rely on the initialization done
2652         by the first thread's early TLS setup.
2654 2002-08-15  Roland McGrath  <roland@redhat.com>
2656         * sysdeps/i386/tls.h (TLS_INIT_TP): Use statement expression and
2657         return a value as callers now expect.
2659 2002-08-11  Roland McGrath  <roland@redhat.com>
2661         * pthread.c (__pthread_initialize_manager): Initialize
2662         p_header.data.tcb field of manager thread's descriptor.
2663         (__pthread_initialize_minimal): Don't initialize p_header.data.self
2664         field, already done by TLS_INIT_TP.
2666         * manager.c (pthread_handle_create): Move p_header field initializers
2667         together.
2669 2002-08-08  Ulrich Drepper  <drepper@redhat.com>
2671         * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Removed.
2673 2002-08-07  Ulrich Drepper  <drepper@redhat.com>
2675         * pthread.c (__linuxthreads_initial_report_events): New variable.
2676         (__pthread_initialize_manager): Use it to initialize p_report_events
2677         of initial thread.
2678         [TLS]: Store pointer to descriptor of manager in __pthread_handles.
2680 2002-08-07  Roland McGrath  <roland@redhat.com>
2682         * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT): Add an extra argument with
2683         an "m" constraint to the asm so the compiler knows LDT_ENTRY was used.
2685 2002-08-02  Roland McGrath  <roland@redhat.com>
2687         * sysdeps/pthread/bits/libc-tsd.h (enum __libc_tsd_key_t):
2688         Add _LIBC_TSD_KEY_LOCALE.
2689         * manager.c (pthread_start_thread) [!(USE_TLS && HAVE___THREAD)]:
2690         Call __uselocale to initialize our per-thread locale pointer to
2691         the global one.
2692         * pthread.c (__pthread_initialize_minimal): Likewise.
2694         * sysdeps/i386/tls.h (TLS_DO_SET_THREAD_AREA): Add missing \s.
2696 2002-08-02  Ulrich Drepper  <drepper@redhat.com>
2698         * pthread.c: Declare _errno, _h_errno, and _res unless we use TLS
2699         internally.
2701         * cancel.c (__pthread_perform_cleanup) [USE_TLS && HAVE___THREAD]:
2702         Don't use p_libc_specific element in thread descriptor.
2704 2002-07-30  Roland McGrath  <roland@redhat.com>
2706         * sysdeps/pthread/bits/libc-tsd.h: Include <tls.h>.
2707         [USE_TLS && HAVE___THREAD]: Just include the sysdeps/generic file,
2708         which does the right thing when __thread support is available.
2709         * descr.h (struct _pthread_descr_struct) [USE_TLS && HAVE___THREAD]:
2710         Omit `p_libc_specific', `p_errnop', `p_errno', `p_h_errnop',
2711         `p_h_errno', `p_resp', and `p_res' members.
2712         * pthread.c (__pthread_initialize_minimal) [USE_TLS && HAVE___THREAD]:
2713         Don't initialize `p_errnop' and `p_h_errnop' members.
2714         (__pthread_reset_main_thread): Likewise.
2715         (__pthread_initialize_manager): Likewise.
2716         * manager.c (__pthread_manager, pthread_handle_create): Likewise.
2717         * pthread.c (pthread_initialize) [USE_TLS && HAVE___THREAD]:
2718         Don't initialize `p_resp' member.
2719         (__pthread_reset_main_thread): Likewise.
2720         * manager.c (pthread_handle_create): Likewise.
2721         * specific.c (libc_internal_tsd_set, libc_internal_tsd_get):
2722         Conditionalize these on [!(USE_TLS && HAVE___THREAD)].
2723         * no-tsd.c: Conditionalize contents on [!(USE_TLS && HAVE___THREAD)].
2724         * errno.c [USE_TLS && HAVE___THREAD]
2725         (__h_errno_location, __res_state): Don't define these at all.
2727         * sysdeps/i386/tls.h (INSTALL_DTV): Add parens around arguments!
2728         (INSTALL_NEW_DTV, GET_DTV): Likewise.
2729         * sysdeps/sh/tls.h (INSTALL_DTV, INSTALL_NEW_DTV, GET_DTV): Likewise.
2731         * weaks.c: Don't include <errno.h> here.
2733 2002-08-01  Roland McGrath  <roland@redhat.com>
2735         * sysdeps/i386/tls.h (TLS_DO_MODIFY_LDT): New macro, broken out of
2736         TLS_INIT_TP.
2737         (TLS_DO_SET_THREAD_AREA): New macro, uses thread_set_area syscall.
2738         (TLS_SETUP_GS_SEGMENT): New macro, try one or the other or both.
2739         (TLS_INIT_TP): Use that.
2741 2002-08-02  Jakub Jelinek  <jakub@redhat.com>
2743         * sysdeps/i386/useldt.h (DO_MODIFY_LDT): Move from INIT_THREAD_SELF.
2744         (INIT_THREAD_SELF): Use sys_thread_area syscall instead if available.
2745         (FREE_THREAD): Avoid modify_ldt if using GDT.
2746         * sysdeps/i386/pspinlock.c (__have_no_set_thread_area): New variable.
2748 2002-07-25  Jakub Jelinek  <jakub@redhat.com>
2750         * sysdeps/i386/tls.h: Use __ASSEMBLER__ test macro not ASSEMBLER.
2751         * sysdeps/i386/pt-machine.h: Likewise.
2752         * sysdeps/i386/useldt.h: Likewise.
2754 2002-07-22  Ulrich Drepper  <drepper@redhat.com>
2756         * pthread.c (__pthread_initialize_minimal): If !SHARED and TLS
2757         call __libc_setup_tls first.
2758         * Makefile: Actually create tst-signal.out file when running the test.
2759         (tests): Add tststatic.
2760         * Examples/tststatic.c: New file.
2762 2002-07-19  Ulrich Drepper  <drepper@redhat.com>
2764         * errno.c (__errno_location): Don't define unless !USE_TLS
2765         || !HAVE___THREAD.
2766         * sysdeps/i386/pt-machine.c: Protect C code with #ifndef ASSEMBLER.
2767         * sysdeps/i386/tls.h: Likewise.
2768         * sysdeps/i386/useldt.h: Likewise.
2769         * sysdeps/i386/i686/pt-machine.h: Likewise.
2771 2002-07-02  H.J. Lu  <hjl@gnu.org>
2773         * sysdeps/mips/pspinlock.c: Don't include <sgidefs.h>.  Always
2774         use ll/sc.
2775         * sysdeps/mips/pt-machine.h: Likewise.
2777 2002-07-14  Ulrich Drepper  <drepper@redhat.com>
2779         * manager.c (pthread_handle_create): Initialize self-reference in
2780         descriptor.
2782 2002-07-01  Jakub Jelinek  <jakub@redhat.com>
2784         * Examples/ex9.c (main): Remove unused th variable.
2786 2002-07-10  Ulrich Drepper  <drepper@redhat.com>
2788         * wrapsyscall.c: Add __nanosleep alias.
2789         * Versions (GLIBC_2.2.6): Add __nanosleep.
2790         * bug-sleep.c: New file.
2791         * Makefile (tests): Add bug-sleep.
2793 2002-06-19  Steven Munroe  <sjmunroe@vnet.ibm.com>
2795         * Examples/ex9.c (main):  Use list of children and join them.
2796         (thread): Do not call exit.
2798 2002-06-20  Ulrich Drepper  <drepper@redhat.com>
2800         * spinlock.c (wait_node_alloc): We cannot use compare-and-exchange.
2801         Unconditionally use the code using spinlock.  Use __pthread_release
2802         to free a spinlock.
2803         (wait_node_free): Likewise.
2804         (__pthread_acquire, __pthread_release): Unconditionally define.
2806 2002-06-07  Jakub Jelinek  <jakub@redhat.com>
2808         * sysdeps/ia64/pt-machine.h (MEMORY_BARRIER): Fix typo.
2810 2002-05-24  Ulrich Drepper  <drepper@redhat.com>
2812         * sysdeps/ia64/pt-machine.h (MEMORY_BARRIER): Use __sync_synchronize.
2814 2002-05-21  Ulrich Drepper  <drepper@redhat.com>
2816         * sysdeps/pthread/pthread.h (pthread_create): Rename first
2817         parameter.
2818         (pthread_cancel): Likewise.
2819         * internals.h (__pthread_create_2_1): Likewise.
2820         * sysdeps/unix/sysv/linux/bits/sigthread.h (pthread_kill): Likewise.
2822 2002-05-20  Ulrich Drepper  <drepper@redhat.com>
2824         * sysdeps/alpha/pt-machine.c (THREAD_SELF): Remove clobber.
2825         Patch by Glen Nakamura <gen@flex.com>.
2827 2002-05-03  Ulrich Drepper  <drepper@redhat.com>
2829         * signals.c: Move sighandler functions to...
2830         * sighandler.c: ...here.  New file.
2831         * signals.c: Move signal handler related type definitions to...
2832         * internals.h: ...here.  Add prototypes for signal handlers.
2833         * Makefile (libpthread-routines): Add sighandler.
2834         (CFLAGS-sighandler.c): Add $(exceptions).
2836 2002-04-30  Jakub Jelinek  <jakub@redhat.com>
2838         * sysdeps/unix/sysv/linux/x86_64/Makefile: New file.
2840 2002-04-08  Ulrich Drepper  <drepper@redhat.com>
2842         * sysdeps/pthread/timer_getoverr.c: Return real overrun.
2843         * sysdeps/pthread/posix-timer.h (struct timer_node): Add overrun_count.
2844         * sysdeps/pthread/timer_routines.c (thread_func): Schedule next timeout
2845         based on previous one and not on current time.  Count overruns.
2846         Patch by Eric F. Sorton <eric@cctcorp.com>.
2848         * sysdeps/unix/sysv/linux/bits/local_lim.h: Add DELAYTIMER_MAX.
2850 2002-04-08  kaz Kojima  <kkojima@rr.iij4u.or.jp>
2852         * sysdeps/sh/pt-machine.h: Define _PT_MACHINE_H
2853         if it isn't defined yet.
2854         (FLOATING_STACKS, ARCH_STACK_MAX_SIZE): Defined.
2855         (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM, THREAD_SETMEM_NC):
2856         Likewise.
2857         * sysdeps/sh/tls.h: New file.
2859 2002-04-08  Jakub Jelinek  <jakub@redhat.com>
2861         * manager.c (__pthread_manager_event): Use self instead of arg
2862         for INIT_THREAD_SELF.
2863         * sysdeps/i386/useldt.h (INIT_THREAD_SELF): Use sizeof (struct
2864         _pthread_descr_struct) instead of sizeof (*descr).
2866 2002-04-05  Ulrich Drepper  <drepper@redhat.com>
2868         * sysdeps/ia64/pt-machine.h: Protect against multiple inclusion.
2869         * sysdeps/alpha/pt-machine.h: Likewise.
2870         * sysdeps/arm/pt-machine.h: Likewise.
2871         * sysdeps/cris/pt-machine.h: Likewise.
2872         * sysdeps/hppa/pt-machine.h: Likewise.
2873         * sysdeps/m68k/pt-machine.h: Likewise.
2874         * sysdeps/mips/pt-machine.h: Likewise.
2875         * sysdeps/powerpc/pt-machine.h: Likewise.
2876         * sysdeps/s390/s390-32/pt-machine.h: Likewise.
2877         * sysdeps/s390/s390-64/pt-machine.h: Likewise.
2878         * sysdeps/sh/pt-machine.h: Likewise.
2879         * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
2880         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
2881         * sysdeps/x86_64/pt-machine.h: Likewise.
2883 2002-04-05  Jakub Jelinek  <jakub@redhat.com>
2885         * man/pthread_mutexattr_init.man (pthread_mutexattr_settype): Document
2886         instead of pthread_mutexattr_setkind_np.
2887         (pthread_mutexattr_gettype): Similarly.
2888         * man/pthread_mutexattr_setkind_np.man: New.
2889         * man/Makefile (SOURCES): Add pthread_mutexattr_setkind_np.man.
2891 2002-04-02  Ulrich Drepper  <drepper@redhat.com>
2893         * sysdeps/ia64/pt-machine.h (MEMORY_BARRIER): Define.
2895 2002-03-22  Jakub Jelinek  <jakub@redhat.com>
2897         * sysdeps/mips/pt-machine.h (MEMORY_BARRIER): Remove.
2899 2002-03-22  Ulrich Drepper  <drepper@redhat.com>
2901         * internals.h (MEMORY_BARRIER): Define as asm with memory as clobber.
2903 2002-03-17  Andreas Jaeger  <aj@suse.de>
2905         * sysdeps/i386/pt-machine.h: Add testandset and __compare_and_swap
2906         prototpyes.
2907         * sysdeps/alpha/pt-machine.h: Likewise.
2908         * sysdeps/arm/pt-machine.h: Likewise.
2909         * sysdeps/cris/pt-machine.h: Likewise.
2910         * sysdeps/hppa/pt-machine.h: Likewise.
2911         * sysdeps/i386/i686/pt-machine.h: Likewise.
2912         * sysdeps/ia64/pt-machine.h: Likewise.
2913         * sysdeps/m68k/pt-machine.h: Likewise.
2914         * sysdeps/mips/pt-machine.h: Likewise.
2915         * sysdeps/powerpc/pt-machine.h: Likewise.
2916         * sysdeps/s390/s390-32/pt-machine.h: Likewise.
2917         * sysdeps/s390/s390-64/pt-machine.h: Likewise.
2918         * sysdeps/sh/pt-machine.h: Likewise.
2919         * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
2920         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
2921         * sysdeps/x86_64/pt-machine.h: Likewise.
2923         * internals.h: Move testandset and __compare_and_swap prototypes
2924         to pt-machine.h.
2926 2002-03-03  Andreas Jaeger  <aj@suse.de>
2928         * errno.c: Include resolv.h to avoid warning.
2930 2002-02-27  Ulrich Drepper  <drepper@redhat.com>
2932         * pthread.c [USE_TLS] (thread_self_stack): Correct check for upper
2933         stack limit.
2935 2002-02-23  Ulrich Drepper  <drepper@redhat.com>
2937         * attr.c (pthread_getattr_np): Don't take thread descriptor size
2938         into account if USE_TLS.
2939         * manager.c (pthread_handle_create): Free TLS data structures if call
2940         failed.  Pass correct stack to clone if USE_TLS.
2941         * sysdeps/i386/pt-machine.h: Handle multiple inclusion.
2942         * sysdeps/i386/i686/pt-machine.h: Likewise.
2943         * sysdeps/i386/tls.h: Unconditionally include <pt-machine.h>.
2945         * descr.h (struct _pthread_descr_struct): Update p_header for TLS.
2946         Add p_stackaddr element #if USE_TLS.
2947         * internals.c: Include <tls.h>.
2948         * manager.c: Integrate creating and handling of thread descriptor
2949         for TLS.
2950         * pthread.c: Likewise.
2951         * sysdeps/i386/tls.h (tcbhead_t): Add self pointer.
2952         Include <linuxthreads/descr.h> only if TLS is really used.
2953         (GET_DTV): New macro.
2954         (TLS_INIT_TP): Initialize self pointer.
2956 2002-02-17  Andreas Schwab  <schwab@suse.de>
2958         * signals.c (sigwait): Check for old sighandler being SIG_ERR,
2959         not NULL.
2961 2002-02-12  Ulrich Drepper  <drepper@redhat.com>
2963         * sysdeps/i386/tls.c (INSTALL_NEW_DTV): Define.
2964         (INSTALL_DTV): Adjust for being passed pointer to element with length.
2966 2002-02-08  Ulrich Drepper  <drepper@redhat.com>
2968         * sysdeps/i386/tls.h (TLS_INIT_TP): Also initialize %gs.
2970 2002-02-08  Richard Henderson  <rth@redhat.com>
2972         * sysdeps/alpha/elf/pt-initfini.c: Use \n\ for multiline string.
2974 2002-02-08  Ulrich Drepper  <drepper@redhat.com>
2976         * sysdeps/i386/tls.h: TLS cannot be supported with FLOATING_STACKS
2977         after all.
2979 2002-02-07  H.J. Lu  <hjl@gnu.org>
2981         * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Silence the
2982         gcc warning.
2983         (__pthread_spin_lock): Remove ".set noreorder".
2984         * sysdeps/mips/pt-machine.h (__compare_and_swap): Liekwise.
2986 2002-02-05  H.J. Lu  <hjl@gnu.org>
2988         * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Not use
2989         branch likely.
2990         * sysdeps/mips/pt-machine.h (testandset): Likewise.
2991         (__compare_and_swap): Likewise.
2993 2002-02-07  Ulrich Drepper  <drepper@redhat.com>
2995         * internals.h: Move declarations/definitions of
2996         __pthread_initial_thread_bos, __pthread_initial_thread,
2997         __pthread_manager_thread_bos, __pthread_manager_thread_tos,
2998         __pthread_manager_thread, __pthread_nonstandard_stacks, STACK_SIZE,
2999         CURRENT_STACK_FRAME, __pthread_find_self, and thread_self...
3000         * descr.h: ...here.
3001         * sysdeps/i386/tls.h: Add TLS definitions also for !FLOATING_STACKS.
3002         Define THREAD_GETMEM accordingly.
3004 2002-02-06  Ulrich Drepper  <drepper@redhat.com>
3006         * sysdeps/i386/tls.h: Include <stddef.h> for size_t.
3008         * sysdeps/i386/tls.h: Define THREAD_DTV.
3010 2002-02-04  Ulrich Drepper  <drepper@redhat.com>
3012         * internals.h: Move thread descriptor definition...
3013         * descr.h.: ...here.  New file.
3014         * sysdeps/i386/tls.h: New file.
3016 2002-02-01  H.J. Lu  <hjl@gnu.org>
3018         * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Use a
3019         different register in the delayed slot.  Use branch likely.
3021         * sysdeps/mips/pt-machine.h (testandset): Call _test_and_set.
3022         (__compare_and_swap): Return 0 only when failed to compare. Use
3023         branch likely.
3025 2002-02-01  Jakub Jelinek  <jakub@redhat.com>
3027         * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set,
3028         __pthread_kill_other_threads_np): Move to GLIBC_PRIVATE.
3029         * sysdeps/i386/i586/Versions: Move all symbols to GLIBC_PRIVATE.
3030         * sysdeps/i386/i686/Versions: Move all symbols to GLIBC_PRIVATE.
3031         * sysdeps/sparc/sparc32/sparcv9/Versions: New file.
3032         * sysdeps/sparc/sparc64/Versions: New file.
3033         * sysdeps/ia64/Versions: Move all symbols to GLIBC_PRIVATE.
3035 2002-01-31  Ulrich Drepper  <drepper@redhat.com>
3037         * pthread.c: _dl_cpuclock_offset is not any longer a global variable
3038         in SHARED code, use GL(dl_cpuclock_offset).
3040 2002-01-28  Andreas Jaeger  <aj@suse.de>
3042         * sysdeps/mips/pspinlock.c (__pthread_spin_init): Clear *LOCK to
3043         0. Patch by Machida Hiroyuki <machida@sm.sony.co.jp>.
3045 2002-01-16  Martin Schwidefsky  <schwidefsky@de.ibm.com>
3047         * sysdeps/s390/s390-32/pt-machine.h (MEMORY_BARRIER): Define.
3048         (CURRENT_STACK_FRAME): Remove duplicate definition.
3049         * sysdeps/s390/s390-64/pt-machine.h: Likewise.
3051 2002-01-14  Martin Schwidefsky  <schwidefsky@de.ibm.com>
3053         * Makefile (CFLAGS-tst-cancel.c): Add -fno-inline-functions to prevent
3054         automatic inline.
3056 2002-01-12  Andreas Schwab  <schwab@suse.de>
3058         * Makefile (test-srcs): Add tst-signal.
3059         (tests): Run tst-signal.
3060         (distribute): Add tst-signal.sh.
3061         * tst-signal.c, tst-signal.sh: New files.
3063 2002-01-14  Andreas Jaeger  <aj@suse.de>
3065         * sysdeps/x86_64/pt-machine.h (INIT_THREAD_SELF): Avoid warning.
3067 2002-01-11  Andreas Schwab  <schwab@suse.de>
3069         * signals.c (sighandler): Initialize all elements to SIG_ERR.
3070         (__sigaction): Don't use value from sighandler if it is SIG_ERR.
3072 2002-01-06  Richard Henderson  <rth@redhat.com>
3074         * sysdeps/alpha/elf/pt-initfini.c: New file.
3076 2001-12-29  Andreas Jaeger  <aj@suse.de>
3078         * Examples/ex9.c: Add noreturn attribute for thread.
3079         * Examples/ex10.c: Likewise.
3080         * Examples/ex13.c (thread_start): Likewise.
3081         * Examples/ex15.c (worker): Likewise.
3083         * Examples/ex18.c: Include unistd.h for prototype of sleep.
3085 2001-12-14  Ulrich Drepper  <drepper@redhat.com>
3087         * man/pthread_atfork.man: Adjust description of mutex handling
3088         after fork for current implementation.
3089         * linuxthreads.texi: Likewise [PR libc/2519].
3091 2001-12-13  Andreas Schwab  <schwab@suse.de>
3093         * specific.c (pthread_key_delete): Don't contact the thread
3094         manager if no threads have been created yet.
3096 2001-12-12  NIIBE Yutaka  <gniibe@m17n.org>
3098         * sysdeps/sh/pt-machine.h (INIT_THREAD_SELF): Added __volatile__
3099         qualifier to be safe.
3101 2001-11-30  Andreas Schwab  <schwab@suse.de>
3103         * pthread.c (pthread_handle_sigcancel) [THREAD_SELF]: Double check
3104         that self is the manager thread, and initialize the thread
3105         register if not.
3106         (thread_self_stack) [THREAD_SELF]: New function to find self via
3107         stack pointer.
3108         * manager.c (pthread_handle_create): Don't block cancel signal any
3109         more.
3111 2001-11-29  Andreas Jaeger  <aj@suse.de>
3113         * sysdeps/x86_64/pt-machine.h: Use %gs as thread specific register.
3114         (THREAD_SELF): New.
3115         (INIT_THREAD_SELF): New.
3116         (THREAD_GETMEM): New.
3117         (THREAD_GETMEM_NC):
3118         (THREAD_SETMEM): New.
3119         (THREAD_SETMEM_NC): New.
3120         (FLOATING_STACKS): Define.
3121         (ARCH_STACK_MAX_SIZE): Define.
3123 2001-11-28  Kaz Kylheku  <kaz@ashi.footprints.net>
3125         Bugfix to pthread_key_delete. It was iterating over the thread
3126         manager's linked list of threads, behind the thread manager's
3127         back causing a race. The fix is to have the manager iterate over
3128         the threads instead, using a new request type for doing so.
3129         * internals.h (struct pthread_request): New manager request type
3130         REQ_FOR_EACH_THREAD.
3131         * manager.c (pthread_for_each_thread): New function.
3132         (__pthread_manager): Handle new REQ_FOR_EACH_THREAD request.
3133         * specific.c (struct pthread_key_delete_helper_args): New type.
3134         (pthread_key_delete_helper): New static function.
3135         (pthread_key_delete): Use the new thread manager
3136         REQ_FOR_EACH_THREAD function to iterate over the threads and set
3137         the delete key slot to a null value in each thread.
3138         * Examples/ex18.c: New test.
3139         * Makefile (tests): Add ex18.
3141 2001-11-22  Wolfram Gloger  <wg@malloc.de>
3143         * pthread.c (pthread_onexit_process): Don't call free
3144         after threads have been asynchronously terminated.
3146         * manager.c (pthread_handle_exit): Surround cancellation
3147         of threads with __flockfilelist()/__funlockfilelist().
3149 2001-11-26  Andreas Schwab  <schwab@suse.de>
3151         * manager.c (pthread_handle_create): Start the child thread with
3152         the cancel signal blocked, so that it does not handle it before
3153         the thread register is set up.  Save errno from failed clone call.
3155 2001-11-15  Ulrich Drepper  <drepper@redhat.com>
3157         * sysdeps/i386/i686/Implies: Removed.
3158         * sysdeps/i386/i686/Versions: New file.
3160 2001-10-31  Andreas Jaeger  <aj@suse.de>
3162         * sysdeps/x86_64/Makefile: Remove, we do not need it anymore.
3164 2001-10-05  Kevin Buettner  <kevinb@cygnus.com>
3166         * pthread.c (__linuxthread_pthread_sizeof_descr): Change name
3167         to __linuxthreads_pthread_sizeof_descr to match name used by
3168         symbol_list_arr[LINUXTHREADS_PTHREAD_SIZEOF_DESCR] in
3169         linuxthreads_db/td_symbol_list.c.
3171 2001-09-22  Andreas Jaeger  <aj@suse.de>
3173         * linuxthreads/tst-context.c: Avoid compile warning.
3175 2001-09-20  Andreas Jaeger  <aj@suse.de>
3177         * shlib-versions: Add x86-64.
3179 2001-09-19  Andreas Jaeger  <aj@suse.de>
3181         * sysdeps/x86_64/Makefile: New file.
3182         * sysdeps/x86_64/pspinlock.c: New file.
3183         * sysdeps/x86_64/pt-machine.h: New file.
3185 2001-09-12  Jakub Jelinek  <jakub@redhat.com>
3187         * sysdeps/pthread/timer_delete.c (timer_delete): Thread may be NULL
3188         for SIGEV_NONE.
3189         * sysdeps/pthread/timer_settime.c (timer_settime): Likewise.
3191 2001-09-11  Ulrich Drepper  <drepper@redhat.com>
3192             Wolfram Gloger <wg@malloc.de>
3194         * join.c: Protect all communications from and to manager with
3195         TEMP_FAILURE_RETRY.
3196         * manager.c: Likewise.
3197         * pthread.c: Likewise.
3198         * smeaphore.c: Likewise.
3200 2001-08-29  Ulrich Drepper  <drepper@redhat.com>
3202         * spinlock.c (__pthread_lock): Top max_count value with
3203         MAX_ADAPTIVE_SPIN_COUNT.
3204         * internals.h (MAX_ADAPTIVE_SPIN_COUNT): Define if not already done.
3206         * sysdeps/i386/i686/pt-machine.h (BUSY_WAIT_NOP): New macro to
3207         help P4.
3209 2001-08-27  Jakub Jelinek  <jakub@redhat.com>
3211         * sysdeps/pthread/bits/libc-lock.h (__libc_rwlock_t): Only define to
3212         non-opaque type if __USE_UNIX98.
3214 2001-08-26  Jakub Jelinek  <jakub@redhat.com>
3216         * sysdeps/pthread/bits/libc-lock.h (__libc_lock_t): Define
3217         non-opaque lock types also if _IO_MTSAFE_IO is defined.
3219 2001-08-23  Roland McGrath  <roland@frob.com>
3221         * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start): Take
3222         new first argument, skip the cleanup handler if it's zero.
3223         (_LIBC_LOCK_RECURSIVE_INITIALIZER): New macro.
3224         (__libc_lock_define_initialized_recursive): Use it.
3225         * sysdeps/pthread/bits/stdio-lock.h: File removed.
3226         The sysdeps/generic file from the main tree now suffices.
3228 2001-08-22  Roland McGrath  <roland@frob.com>
3230         * sysdeps/pthread/bits/stdio-lock.h: Include <bits/libc-lock.h>
3231         instead of <pthread.h>.
3232         (_IO_lock_t): Define this typedef using __libc_lock_define_recursive.
3233         (_IO_lock_initializer): Add braces.
3234         (_IO_lock_lock): Use __libc_lock_lock_recursive.
3235         (_IO_lock_unlock): Use __libc_lock_unlock_recursive.
3237         * sysdeps/pthread/bits/libc-lock.h (__libc_lock_recursive_t): New type.
3238         (__libc_lock_define_initialized_recursive): Use it.
3239         (__libc_lock_init_recursive): Likewise.
3240         (__libc_lock_fini_recursive): Likewise.
3241         (__libc_lock_lock_recursive): Likewise.
3242         (__libc_lock_trylock_recursive): Likewise.
3243         (__libc_lock_unlock_recursive): Likewise.
3244         (__libc_lock_define_recursive): New macro.
3246 2001-08-14  Jakub Jelinek  <jakub@redhat.com>
3248         * lockfile.c (__pthread_provide_lockfile): New variable.
3249         * pthread.c (__pthread_require_lockfile): New variable.
3250         * cancel.c (__pthread_require_lockfile): New variable.
3252 2001-07-31  Ulrich Drepper  <drepper@redhat.com>
3254         * tst-context.c (threadfct): Initialize context before calling
3255         makecontext.
3257         * Examples/ex17.c: Make sure test thread is around long enough.
3259 2001-07-26  kaz Kojima  <kkojima@rr.iij4u.or.jp>
3261         * sysdeps/sh/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF): Defined.
3263 2001-07-24  Ulrich Drepper  <drepper@redhat.com>
3265         * tst-context.c (main): Print explanation before bailing out
3266         because context handling is not supported.
3268 2001-07-23  Ulrich Drepper  <drepper@redhat.com>
3270         * Makefile (tests): Add tst-context.
3271         * tst-context.c: New file.
3273         * sysdeps/pthread/bits/stdio-lock.h: Define
3274         _IO_cleanup_region_start_noarg.
3276 2001-07-23  Jakub Jelinek  <jakub@redhat.com>
3278         * sysdeps/alpha/pt-machine.h (FLOATING_STACKS): Define.
3279         (ARCH_STACK_MAX_SIZE): Define.
3280         * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
3281         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
3283 2001-07-19  Jakub Jelinek  <jakub@redhat.com>
3285         * sysdeps/i386/useldt.h: Fix typo in ARCH_STACK_MAX_SIZE comment.
3287         * sysdeps/ia64/pt-machine.h (FLOATING_STACKS): Define.
3288         (ARCH_STACK_MAX_SIZE): Define.
3289         * manager.c (pthread_allocate_stack): Handle FLOATING_STACKS with
3290         NEED_SEPARATE_REGISTER_STACK.
3292 2001-07-16  Andreas Schwab  <schwab@suse.de>
3294         * Makefile (before-compile): Don't add $(objpfx)crti.o.
3295         (omit-deps): Add crti.
3296         ($(objpfx)libpthread.so): Depend on $(objpfx)crti.o, but make sure
3297         it is filtered out of the link command.
3299 2001-07-16  Ulrich Drepper  <drepper@redhat.com>
3301         * pthread.c (pthread_initialize): For FLOATING_STACKS don't bother
3302         to find the right value for __pthread_initial_thread_bos, it's not
3303         used.  If not FLOATING_STACKS first run
3304         __pthread_init_max_stacksize.
3306 2001-06-16  H.J. Lu  <hjl@gnu.org>
3308         * internals.h: Include <stackinfo.h>.
3310         * attr.c: Don't include <stackinfo.h> here.
3311         * cancel.c: Likewise.
3312         * manager.c: Likewise.
3313         * pthread.c: Likewise.
3314         * ptlongjmp.c: Likewise.
3316 2001-03-23  Matthew Wilcox  <willy@ldl.fc.hp.com>
3318         * attr.c: Make _STACK_GROWS_UP work.
3319         * internals.h: Likewise.
3320         * manager.c: Likewise.
3321         * pthread.c: Likewise.
3323 2001-06-15  H.J. Lu  <hjl@gnu.org>
3325         * pthread.c (__pthread_reset_main_thread): Fix a typo.
3327 2001-02-02  John S. Marvin  <jsm@udlkern.fc.hp.com>
3329         * semaphore.h: Use struct _pthread_fastlock as an element of
3330         sem_t instead of an identical struct.
3331         * rwlock.c: Remove casts.
3332         * semaphore.c: Likewise.
3334 2001-04-30  Alan Modra  <amodra@one.net.au>
3336         * sysdeps/unix/sysv/linux/hppa/pt-initfini.c: New.
3338 2001-05-25  Bruce Mitchener  <bruce@cubik.org>
3340         * linuxthreads.texi: Spelling corrections.
3342 2001-05-25  Ulrich Drepper  <drepper@redhat.com>
3344         * oldsemaphore.c (__old_sem_wait): Clear p_nextwaiting before
3345         returning successfully.
3346         Patch by Gene Cooperman <gene@ccs.neu.edu>.
3348 2001-05-24  Ulrich Drepper  <drepper@redhat.com>
3350         * spinlock.c (__pthread_lock) [HAS_COMPARE_AND_SWAP]: Before doing any
3351         serious work try once whether the lock is uncontested.
3352         Remove duplicate reading of __status before loop.
3353         Change suggested by Hans Boehm <hans_boehm@hp.com>.
3355         * spinlock.h (__pthread_trylock): Remove need for oldstatus variable.
3356         (__pthread_alt_trylock): Likewise.
3358 2001-05-01  Kaz Kylheku  <kaz@ashi.footprints.net>
3360         Memory barrier overhaul following line by line inspection.
3361         * mutex.c (pthread_once): Missing memory barriers added.
3362         * pthread.c (__pthread_wait_for_restart_signal,
3363         __pthread_timedsuspend_new, __pthread_restart_new): Added
3364         memory barriers ``just in case'' and for documentary value.
3365         * spinlock.c (__pthread_release): New inline function for releasing
3366         spinlock, to complement __pthread_acquire.  Includes memory
3367         barrier prior to assignment to spinlock, and __asm __volatile
3368         dance to prevent reordering or optimization of the spinlock access.
3369         * spinlock.c (__pthread_unlock, __pthread_alt_lock,
3370         __pthread_alt_timedlock, __pthread_alt_unlock,
3371         __pthread_compare_and_swap): Updated to use new __pthread_release
3372         instead of updating spinlock directly.
3373         * spinlock.c (__pthread_lock, __pthread_unlock, wait_node_alloc,
3374         wait_node_free, wait_node_dequeue, __pthread_alt_lock,
3375         __pthread_alt_timedlock, __pthread_alt_unlock, __pthread_acquire):
3376         Memory barrier overhaul.  Lots of missing memory barriers added,
3377         a couple needless ones removed.
3378         * spinlock.c (__pthread_compare_and_swap): testandset optimization
3379         removed, just calls __pthread_acquire, which has the new read
3380         barrier in it before its testandset.
3382 2001-05-20  Roland McGrath  <roland@frob.com>
3384         * Makeconfig: New file, variables used to be in main libc Makeconfig.
3386 2001-05-09  Geoff Keating  <geoffk@redhat.com>
3388         * sysdeps/powerpc/pt-machine.h
3389         (HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS): Define.
3390         (__compare_and_swap): Remove memory barriers.
3391         (__compare_and_swap_with_release_semantics): New function.
3393 2001-04-24  Andreas Jaeger  <aj@suse.de>
3395         * wrapsyscall.c: send* and recv* return ssize_t.
3397         * sysdeps/pthread/timer_getoverr.c (timer_getoverrun): Unlock the
3398         mutex instead of double locking it.
3399         Reported by Pierre Artaud <partaud@sodatec.com>.
3401 2001-04-23  Ulrich Drepper  <drepper@redhat.com>
3403         * sysdeps/pthread/getcpuclockid.c: Make function generic, test
3404         using #ifdef whether the clock is available.
3405         * sysdeps/unix/sysv/linux/i386/getcpuclockid.c: Removed.
3407         * sysdeps/ia64/Versions: New file.
3409         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c (_init): We don't
3410         have to call __gmon_start__ in the libpthread DSO.
3411         * sysdeps/pthread/pt-initfini.c (_init): Likewise.
3413         * Makefile (libpthread-routines): Add ptclock_gettime and
3414         ptclock_settime.
3415         * internals.h: Don't use cpuclock-init.h definitions, use
3416         hp-timing.h definitions.
3417         * pthread.c: Likewise.
3418         * manager.c: Likewise.
3419         * ptclock_gettime.c: New file.
3420         * ptclock_settime.c: New file.
3421         * internals.h: Fix parameter type for __pthread_clock_gettime and
3422         __pthread_clock_settime.
3424         * sysdeps/i386/i586/ptclock_gettime.c: Removed.
3425         * sysdeps/i386/i586/ptclock_settime.c: Removed.
3426         * sysdeps/i386/i586/Makefile: Removed.
3428 2001-04-22  Ulrich Drepper  <drepper@redhat.com>
3430         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define _POSIX_ASYNCH_IO.
3431         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
3433 2001-04-21  Andreas Jaeger  <aj@suse.de>
3435         * sysdeps/pthread/timer_routines.c (thread_func): Add noreturn
3436         attribute, remove statements that will never be executed.
3437         (thread_func): Remove mutex_unlock call since it's never executed.
3438         (thread_func): Fix comment as suggested by Jakub Jelinek.
3440         * manager.c (__pthread_manager): Add noreturn
3441         attribute.
3442         (pthread_start_thread): Likewise, remove return statement.
3443         (pthread_start_thread_event): Likewise.
3444         Add noreturn attribute for pthread_handle_exit.
3445         * weaks.c: Add noreturn attribute for pthread_exit.
3447         * internals.h: Add __pthread_clock_gettime and
3448         __pthread_clock_settime prototypes.
3450 2001-04-21  Ulrich Drepper  <drepper@redhat.com>
3452         * internals.h: Include <cpuclock-init.h>.
3453         (struct _pthread_descr_struct): Add p_cpuclock_offset field if
3454         CPUCLOCK_VARDEF is defined.
3455         * pthread.c (__pthread_initialize_minimal): Initialize
3456         p_cpuclock_offset field for main thread if CPUCLOCK_INIT is defined.
3457         * manager.c (pthread_start_thread): Set p_cpuclock_offset field
3458         for new thread to current CPU clock value.
3460         * sysdeps/i386/useldt.h: Extend all the macros to handle 8-byte values.
3462         * sysdeps/i386/i586/Makefile: New file.
3463         * sysdeps/i386/i586/Versions: New file.
3464         * sysdeps/i386/i586/ptclock_gettime.c: New file.
3465         * sysdeps/i386/i586/ptclock_settime.c: New file.
3466         * sysdeps/i386/i686/Implies: New file.
3468 2001-04-18  Jakub Jelinek  <jakub@redhat.com>
3470         * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: Put specs into
3471         $generated, not $postclean-generated.
3473 2001-04-18  Andreas Jaeger  <aj@suse.de>
3475         * Makefile (otherlibs): Added.
3477 2001-04-18  Jakub Jelinek  <jakub@redhat.com>
3479         * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: New file.
3481 2001-04-16  Ulrich Drepper  <drepper@redhat.com>
3483         * signals.c (sigwait): NSIG is no signal number.  Block all
3484         signals while in signal handler for signals in SET.
3485         Patch by Manfred Spraul <manfred@colorfullife.com>.
3487 2001-04-12  Ulrich Drepper  <drepper@redhat.com>
3489         * tst-cancel.c: Disable most tests.  Add new test where all
3490         cleanup handlers must run.
3491         * Makefile (tests): Add tst-cancel again.
3493         * cancel.c (__pthread_perform_cleanup): Correct condition for
3494         leaving cleanup loop early.
3496         * sysdeps/i386/Makefile: Make sure gcc uses a frame pointer for
3497         all the files which use CURRENT_STACK_FRAME.
3498         * sysdeps/i386/pt-machine.h (CURRENT_STACK_FRAME): Define using
3499         __builtin_frame_address.
3500         * sysdeps/i386/i686/pt-machine.h: Likewise.
3502 2001-04-11  Ulrich Drepper  <drepper@redhat.com>
3504         * Makefile (tests): Comment out tst-cancel for now.
3506         * tst-cancel.c (main): Cleanup 4 is supposed to run.  Create
3507         temporary file in object directory.
3508         * Makefile: Don't allow inlining when compiling tst-cancel.c.
3509         Pass $(objpfx) to tst-cancel.
3511 2001-04-11  David S. Miller  <davem@redhat.com>
3513         * sysdeps/sparc/sparc32/pt-machine.h (stack_pointer): Advance
3514         up closer to user local variables so that new cleanup heuristics work.
3515         * sysdeps/sparc/sparc64/pt-machine.h (stack_pointer): Likewise.
3517 2001-04-11  Ulrich Drepper  <drepper@redhat.com>
3519         * cancel.c (_pthread_cleanup_push): Catch invalid __prev buffer
3520         and remove it.
3521         (_pthread_cleanup_push_defer): Likewise.
3523         * tst-cancel.c (main): Fix loop printing cleanup output.
3525 2001-04-10  kaz Kojima  <kkojima@rr.iij4u.or.jp>
3527         * sysdeps/sh/pspinlock.c (__pthread_spin_lock): Fix a reverse
3528         test.
3529         (__pthread_spin_trylock): Likewise.
3530         * sysdeps/sh/pt-machine.h (testandset): Likewise.
3532 2001-04-10  Ulrich Drepper  <drepper@redhat.com>
3534         * join.c (pthread_exit): Move code to new function __pthread_do_exit
3535         which takes an extra parameter with the current frame pointer.
3536         Call new function with CURRENT_STACK_FRAME.
3537         (__pthread_do_exit): New function.  Call __pthread_perform_cleanup
3538         with the new parameter.
3539         (pthread_join): Call __pthread_do_exit instead of pthread_exit.
3540         * cancel.c (__pthread_perform_cleanup): Takes extra parameter.  Use
3541         this parameter as the initial value the cleanup handler records are
3542         compared against.  No active cleanup handler record must have an
3543         address lower than the previous one and the initial record must be
3544         above (below on PA) the frame address passed in.
3545         (pthread_setcancelstate): Call __pthread_do_exit instead of
3546         pthread_exit.
3547         (pthread_setcanceltype): Likewise.
3548         (pthread_testcancel): Likewise.
3549         (_pthread_cleanup_pop_restore): Likewise.
3550         * condvar.c (pthread_cond_wait): Likewise.
3551         (pthread_cond_timedwait_relative): Likewise.
3552         * manager.c (pthread_start_thread): Likewise.
3553         * oldsemaphore.c (__old_sem_wait): Likewise.
3554         * pthread.c (pthread_handle_sigcancel): Likewise.
3555         * semaphore.c (__new_sem_wait): Likewise.
3556         (sem_timedwait): Likewise.
3557         * ptlongjmp.c (pthread_cleanup_upto): Also use current stack frame
3558         to limit the cleanup handlers which get run.
3559         * internals.h: Add prototype for __pthread_do_exit.  Adjust prototype
3560         for __pthread_perform_cleanup.
3562         * Makefile (tests): Add tst-cancel.
3563         * tst-cancel.c: New file.
3565 2001-04-08  Hans-Peter Nilsson  <hp@axis.com>
3567         * sysdeps/cris/pt-machine.h: New file.
3568         * sysdeps/cris/pspinlock.c: New file.
3570 2001-04-09  Hans-Peter Nilsson  <hp@axis.com>
3572         * shlib-versions: Add case for Linux on CRIS.
3574 2001-03-26  Ulrich Drepper  <drepper@redhat.com>
3576         * attr.c (pthread_getattr_np): Correct computation of stack size
3577         for machiens with register stack.
3579         * Examples/ex17.c (main): Correct detection of failed mmap call.
3581 2001-03-21  Jakub Jelinek  <jakub@redhat.com>
3583         * pthread.c (__pthread_initialize_manager): Fix a typo.
3585 2001-03-21  Jakub Jelinek  <jakub@redhat.com>
3587         * attr.c (__pthread_attr_setstack): Fix alignment check.
3588         (pthread_getattr_np): __stackaddr is top of stack, not bottom.
3589         * Makefile (tests): Add ex17 test.
3590         * Examples/ex17.c: New test.
3592 2001-03-20  Ulrich Drepper  <drepper@redhat.com>
3594         * Makefile: Define -D_RPC_THREAD_SAFE_ for cancel.c.
3595         * cancel.c (__pthread_perform_cleanup): Call __rpc_thread_destroy.
3596         * sysdeps/pthread/bits/libc-tsd.h: Define _LIBC_TSD_KEY_VARS.
3598 2001-03-18  Ulrich Drepper  <drepper@redhat.com>
3600         * Makefile: When generating DSO link with libc_nonshared.a.
3602 2001-02-26  Jakub Jelinek  <jakub@redhat.com>
3604         * signals.c (pthread_sighandler): Use CALL_SIGHANDLER.
3606 2001-02-23  Jakub Jelinek  <jakub@redhat.com>
3608         * internals.h (__pthread_init_max_stacksize): New prototype.
3609         * attr.c (__pthread_attr_setstacksize): Call
3610         __pthread_init_max_stacksize if not yet initialized.
3611         * pthread.c (__pthread_init_max_stacksize): New function.
3612         (__pthread_initialize_manager): Call it.
3613         Patch by <dtc@cmucl.cons.org>.
3615 2001-03-16  Ulrich Drepper  <drepper@redhat.com>
3617         * attr.c (pthread_getattr_np): Fix __stacksize computation for IA-64.
3619 2001-03-13  Martin Schwidefsky  <schwidefsky@de.ibm.com>
3621         * shlib-versions: Add rule for Linux on 64 bit S/390.
3622         * sysdeps/s390/s390-64/pt-machine.h: New file.
3623         * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: New file.
3625 2001-03-13  Martin Schwidefsky  <schwidefsky@de.ibm.com>
3627         * sysdeps/s390/pt-machine.h: Move to...
3628         * sysdeps/s390/s390-32/pt-machine.h: ...here.
3629         Add defines for FLOATING_STACK and ARCH_STACK_MAX_SIZE.
3631 2001-03-15  Ulrich Drepper  <drepper@redhat.com>
3633         * Versions [libpthread] (GLIBC_2.2.3): Add pthread_getattr_np.
3634         * attr.c: Implement pthread_getattr_np.
3635         * sysdeps/pthread/pthread.h: Add prototype for pthread_getattr_np.
3636         * internals.h (struct _pthread_descr_struct): Add p_inheritsched.
3637         * manager.c (pthread_handle_create): Initialize p_inheritsched.
3639 2001-03-09  Martin Schwidefsky  <schwidefsky@de.ibm.com>
3641         * sysdeps/unix/sysv/linux/s390/pt-initfini.c: Use 0x07 padding for
3642         code alignment.
3644 2001-02-20  Hans Boehm  <hans_boehm@hp.com>
3646         * manager.c (manager_mask): Removed static vesion.  Now always local
3647         to __pthread_manager().
3648         (manager_mask_all): Removed completely.
3649         (__pthread_manager): Remove manager_mask_all initialization.
3650         (pthread_handle_create): Remove code to set and reset signal mask
3651         around __clone2() calls.
3653 2001-02-17  Jakub Jelinek  <jakub@redhat.com>
3655         * spinlock.c (__pthread_lock): Force lock->__status to be read from
3656         memory on every spin.
3658 2001-02-10  Andreas Jaeger  <aj@suse.de>
3660         * Makefile (extra-objs): New.
3662 2001-02-09  Jakub Jelinek  <jakub@redhat.com>
3664         * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Add
3665         __pthread_initialize_minimal prototype.
3667 2001-02-08  kaz Kojima  <kkojima@rr.iij4u.or.jp>
3669         * sysdeps/unix/sysv/linux/sh/pt-initfini.c: New file.
3671 2001-02-06  Martin Schwidefsky  <schwidefsky@de.ibm.com>
3673         * sysdeps/unix/sysv/linux/s390/pt-initfini.c: New file.
3675 2001-02-06  Ulrich Drepper  <drepper@redhat.com>
3677         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: First attempt to fix the
3678         broken code.  Patch by Jes Sorensen.
3680 2001-02-06  Andreas Jaeger  <aj@suse.de>
3682         * sysdeps/pthread/pthread.h: Move __pthread_initialize from here
3683         to...
3684         * internals.h: ...here.
3686 2001-02-05  Jes Sorensen  <jes@linuxcare.com>
3688         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: New file.
3690 2001-02-02  Ulrich Drepper  <drepper@redhat.com>
3692         * Versions: Remove __pthread_initialize_minimal.
3694 2001-02-01  Ulrich Drepper  <drepper@redhat.com>
3696         * Makefile: Add rules to build crti.o and make it being used in
3697         building libpthread.so.
3698         * sysdeps/i386/Makefile: New file.
3699         * sysdeps/pthread/pt-initfini.c: New file.
3701         * pthread.c: Cleanups.
3703 2001-01-28  Andreas Jaeger  <aj@suse.de>
3705         * oldsemaphore.c (__old_sem_init): Adjust for last change.
3706         * sysdeps/pthread/bits/libc-lock.h: Likewise.
3707         * spinlock.c: Likewise.
3709 2001-01-28  Ulrich Drepper  <drepper@redhat.com>
3711         * sysdeps/pthread/bits/initspin.h: Make all names namespace clean.
3712         * sysdeps/unix/sysv/linux/hppa/bits/initspin.h: Likewise.
3713         * manager.c: Adjust for namespace cleanup in bits/initspin.h.
3714         * pthread.c: Likewise.
3715         * spinlock.h: Likewise.
3716         * sysdeps/pthread/pthread.h: Likewise.
3718 2001-01-26  Ulrich Drepper  <drepper@redhat.com>
3720         * sysdeps/pthread/bits/pthreadtypes.h: Define pthread_attr_t also
3721         as struct __pthread_attr_s.
3723         * semaphore.h (sem_t): Cleanup namespace, rename status and
3724         spinlock elements.
3726 2001-01-13  Jakub Jelinek  <jakub@redhat.com>
3728         * pthread.c (pthread_onexit_process): Clear
3729         __pthread_manager_thread_bos after freeing it.
3730         * Makefile (tests): Add ex16.
3731         * Examples/ex16.c: New file.
3733 2001-01-11  Jakub Jelinek  <jakub@redhat.com>
3735         * Makefile (CFLAGS-pthread.c): Pass -DHAVE_Z_NODELETE if ld supports
3736         -z nodelete.
3737         * pthread.c (pthread_exit_process): Rename to...
3738         (pthread_onexit_process): ...this.
3739         (pthread_atexit_process, pthread_atexit_retcode): New.
3740         (pthread_initialize): Call __cxa_atexit instead of __cxa_on_exit
3741         and only if HAVE_Z_NODELETE is not defined.
3742         (__pthread_initialize_manager): Register pthread_atexit_retcode
3743         with __cxa_atexit.
3745 2001-01-11  Ulrich Drepper  <drepper@redhat.com>
3747         * pthread.c (pthread_initialize): Use __cxs_on_exit not __cxa_atexit.
3749 2001-01-11  Jakub Jelinek  <jakub@redhat.com>
3751         * Makefile (tests): Add ex15.
3752         * Examples/ex15.c: New test.
3754 2001-01-08  Ulrich Drepper  <drepper@redhat.com>
3756         * pthread.c (pthread_exit_process): Free memory allocated for
3757         manager stack.
3759 2000-12-31  Ulrich Drepper  <drepper@redhat.com>
3761         * manager.c (pthread_alloca_stack): Remove MAP_FIXED from mmap calls.
3762         (pthread_free): Always unmap the stack.  It's safe now that we don't
3763         use MAP_FIXED to allocate stacks.
3765 2000-12-31  Ulrich Drepper  <drepper@redhat.com>
3767         * sysdeps/powerpc/pspinlock.c: Don't include pt-machine.h here.
3769         * manager.c (pthread_allocate_stack): Prepare for removal of MAP_FIXED.
3771 2000-11-15  Wolfram Gloger  <wg@malloc.de>
3773         * manager.c (pthread_free): [!FLOATING_STACKS]: Only remap the
3774         stack to PROT_NONE, don't unmap it, avoiding collisions with malloc.
3776 2000-12-27  Andreas Jaeger  <aj@suse.de>
3778         * Examples/ex13.c: Make local functions static.
3779         * ecmutex.c: Likewise.
3780         * joinrace.c: Likewise.
3781         * Examples/ex14.c: Likewise.
3783         * Examples/ex2.c: Make local functions static; reformat.
3784         * Examples/ex1.c: Likewise.
3785         * Examples/ex4.c: Likewise.
3786         * Examples/ex5.c: Likewise.
3787         * Examples/ex7.c: Likewise.
3789         * oldsemaphore.c: Add prototypes to shut up GCC.
3790         * pt-machine.c: Likewise.
3792         * weaks.c: Add prototype for pthread_exit.
3794         * internals.h: Add some prototypes, format prototypes and add
3795         missing externs.
3796         Move __libc_waitpid prototype to include/sys/wait.h.
3798         * rwlock.c: Include <bits/libc-lock.h> for prototypes.
3799         * mutex.c: Likewise.
3800         * specific.c: Likewise.
3801         * ptfork.c: Likewise.
3803         * lockfile.c: Include internals.h to get prototypes.
3804         * events.c: Likewise.
3805         * sysdeps/alpha/pspinlock.c: Likewise.
3806         * sysdeps/arm/pspinlock.c: Likewise.
3807         * sysdeps/hppa/pspinlock.c: Likewise.
3808         * sysdeps/i386/pspinlock.c: Likewise.
3809         * sysdeps/ia64/pspinlock.c: Likewise.
3810         * sysdeps/m68k/pspinlock.c: Likewise.
3811         * sysdeps/mips/pspinlock.c: Likewise.
3812         * sysdeps/powerpc/pspinlock.c: Likewise.
3813         * sysdeps/s390/pspinlock.c: Likewise.
3814         * sysdeps/sh/pspinlock.c: Likewise.
3815         * sysdeps/sparc/sparc32/pspinlock.c: Likewise.
3816         * sysdeps/sparc/sparc32/sparcv9/pspinlock.c: Likewise.
3817         * sysdeps/sparc/sparc64/pspinlock.c: Likewise.
3819 2000-12-27  Ulrich Drepper  <drepper@redhat.com>
3821         * attr.c (__pthread_attr_setstack): Fix setting of __stackaddr element.
3822         (__pthread_attr_getstack): Return correct address.
3823         Add warnings for using pthread_attr_getstackaddr and
3824         pthread_attr_setstackaddr.
3826 2000-12-26  Ulrich Drepper  <drepper@redhat.com>
3828         * Examples/ex6.c (test_thread): Make static.
3829         * Examples/ex12.c (test_thread): Make static and add noreturn
3830         attribute.
3832 2000-12-18  Jes Sorensen  <jes@linuxcare.com>
3834         * linuxthreads/sysdeps/ia64/pt-machine.h: __compare_and_swap
3835         and compare_and_swap_with_release_semantics returns int not long.
3837 2000-12-17  Andreas Jaeger  <aj@suse.de>
3839         * sysdeps/s390/pt-machine.h (testandset): Use long int as return
3840         value.
3841         * sysdeps/arm/pt-machine.h (testandset): Likewise.
3842         * sysdeps/hppa/pt-machine.h (testandset): Likewise.
3843         * sysdeps/m68k/pt-machine.h (testandset): Likewise.
3844         * sysdeps/sh/pt-machine.h (testandset): Likewise.
3845         * sysdeps/sparc/sparc32/pt-machine.h (testandset): Likewise.
3846         * sysdeps/sparc/sparc64/pt-machine.h (testandset): Likewise.
3848 2000-12-17  Ulrich Drepper  <drepper@redhat.com>
3850         * sysdeps/i386/pt-machine.h (testandset): Adjust for prototype change.
3851         * sysdeps/i386/i686/pt-machine.h (testandset): Likewise.
3853 2000-12-17  Andreas Jaeger  <aj@suse.de>
3855         * internals.h: Add prototypes for testandset and
3856         __compare_and_swap to shut up gcc warnings.
3858 2000-12-06  Wolfram Gloger  <wg@malloc.de>
3860         * join.c (pthread_detach): Allow case where the thread has already
3861         terminated.
3863 2000-12-05  Andreas Jaeger  <aj@suse.de>
3865         * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Don't set mips2.
3866         * sysdeps/mips/pt-machine.h (testandset): Likewise.
3867         (__compare_and_swap): Likewise.
3868         Patches by Maciej W. Rozycki <macro@ds2.pg.gda.pl>.
3870 2000-11-20  Jakub Jelinek  <jakub@redhat.com>
3872         * Examples/ex3.c (main): Cast int to long before casting to void *.
3873         (search): Cast void * to long, not int.
3874         * Examples/ex8.c (main, thread): Similarly.
3875         * Examples/ex11.c (main): Similarly.
3876         * Examples/ex14.c (worker, do_test): Similarly.
3877         * ecmutex.c (worker, do_test): Similarly.
3878         (nlocks): Cast to int.
3880 2000-11-08  Bruce Mitchener  <bruce@cubik.org>
3882         * linuxthreads.texi:  Add documentation for pthreads attributes
3883         guardsize, stackaddr, stacksize, and stack.  Fix typo in previous
3884         patch.  Document pthread_[sg]etconcurrency().  Mark
3885         pthread_mutexattr_[sg]ettype() as POSIX rather than GNU.
3887 2000-11-07  Ulrich Drepper  <drepper@redhat.com>
3889         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_MESSAGE_PASSING):
3890         Don't define it.
3891         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
3892         Reported by Christopher Yeoh <cyeoh@linuxcare.com.au>.
3894 2000-11-06  Ulrich Drepper  <drepper@redhat.com>
3896         * cancel.c (pthread_cancel): Always set p_canceled, even if we are
3897         not doing it right now.
3898         Reported by Kaz Kylheku <kaz@ashi.footprints.net>.
3900 2000-10-30  Ulrich Drepper  <drepper@redhat.com>
3902         * Examples/ex4.c (main): Don't use exit() to avoid warning with
3903         broken compilers.
3905 2000-10-29  Ulrich Drepper  <drepper@redhat.com>
3907         * attr.c (__pthread_attr_setguardsize): Don't round guardsize
3908         here.  Reported by Bruce Mitchener <bruce@cubik.org>.
3910         * linuxthreads.texi: Changes terminology to 'type' from 'kind' when
3911         discussing mutexes. (As per the Unix98 name for the API.)
3912         Changes documentation for pthread_mutexattr_setkind_np() and
3913         pthread_mutexattr_getkind_np() over to the Unix98 APIs for the
3914         same: pthread_mutexattr_settype() and pthread_mutexattr_gettype().
3915         Changes references to PTHREAD_MUTEXATTR_FAST_NP to
3916         PTHREAD_MUTEXATTR_ADAPTIVE_NP.
3917         Begins to introduce discussion of the ``timed'' mutex type.  This
3918         discussion is currently incomplete.
3919         Patch by Bruce Mitchener <bruce@cubik.org>.
3921 2000-10-26  Kazumoto Kojima  <kkojima@rr.iij4u.or.jp>
3922             Yutaka Niibe  <gniibe@chroot.org>
3924         * sysdeps/sh/pt-machine.h (testandset): Since the operand of TAS.B
3925         has restrictions, use register.
3927 2000-10-23  Andreas Schwab  <schwab@suse.de>
3929         * Examples/ex14.c (TIMEOUT): Override default timeout.
3931 2000-10-16  Ulrich Drepper  <drepper@redhat.com>
3933         * specific.c: Protect tsd array modification in thread data
3934         structures by getting the thread lock in pthread_key_delete and
3935         __pthread_destroy_specifics.
3936         Patch by Wolfram Gloger <Wolfram.Gloger@dent.med.uni-muenchen.de>.
3938 2000-10-12  Alan Modra <alan@linuxcare.com.au>
3940         * sysdeps/pthread/bits/initspin.h: New file.
3941         * spinlock.h: Move LOCK_INITIALIZER definition to <bits/initspin.h>.
3942         (__pthread_init_lock): Initialize lock with LT_SPINLOCK_INIT.
3943         (__pthread_alt_init_lock): Likewise.
3944         (__pthread_alt_trylock): Release lock with LT_SPINLOCK_INIT.
3946 2000-10-12  David Huggins-Daines  <dhd@linuxcare.com>
3948         * oldsemaphore.c (__old_sem_init): Release lock with
3949         LT_SPINLOCK_INIT, not zero.
3950         * spinlock.c (__pthread_unlock): Likewise.
3951         (__pthread_alt_lock): Likewise.
3952         (__pthread_alt_timedlock): Likewise.
3953         (__pthread_alt_unlock): Likewise.
3954         * sysdeps/pthread/bits/libc-lock.h: Initialize locks with
3955         LT_SPINLOCK_INIT if it is non-zero.  Likewise for init-once flags.
3956         * sysdeps/pthread/pthread.h: Include bits/initspin.h.  Use
3957         LT_SPINLOCK_INIT do initialize spinlocks not 0.
3959 2000-10-12  David Huggins-Daines <dhd@linuxcare.com>
3961         * shlib-versions: Add version definitions for hppa-linux.
3963 2000-10-12  Alan Modra <alan@linuxcare.com.au>
3965         * sysdeps/hppa/pspinlock.c: New file.
3966         * sysdeps/hppa/pt-machine.h: New file.
3967         * sysdeps/unix/sysv/linux/hppa/bits/initspin.h: New file.
3969 2000-10-05  Jakub Jelinek  <jakub@redhat.com>
3971         * mutex.c (__pthread_mutex_destroy): Correct test of
3972         busy mutex for mutexes using alternate fastlocks.
3973         Patch by dtc@cmucl.cons.org.
3975 2000-09-28  Martin Schwidefsksy    <schwidefsky@de.ibm.com>
3977         * sysdeps/s390/pt-machine.h: Make %a0 the thread register.
3979 2000-09-28  Ulrich Drepper  <drepper@redhat.com>
3981         * mutex.c (__pthread_mutex_unlock): For PTHREAD_MUTEX_RECURSIVE_NP
3982         test for owner first.
3983         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
3985         * cancel.c (pthread_cancel): Don't do anything if cancelation is
3986         disabled.
3988 2000-09-26  Ulrich Drepper  <drepper@redhat.com>
3990         * spinlock.h (__pthread_set_own_extricate_if): Optimize a bit.
3991         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
3993         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remove
3994         _POSIX_MONOTONIC_CLOCK.
3996         * spinlock.h (__pthread_set_own_extricate_if): Add back locking
3997         and explain why.
3999 2000-09-20  Andreas Jaeger  <aj@suse.de>
4001         * pthread.c [!__ASSUME_REALTIME_SIGNALS]: Make inclusion of
4002         "testrtsig.h" conditional.
4004 2000-09-11  Ulrich Drepper  <drepper@redhat.com>
4006         * sysdeps/pthread/pthread.h: Declare pthread_attr_getstack and
4007         pthread_attr_setstack.
4008         * Versions [libpthread] (GLIBC_2.2): Export pthread_attr_getstack and
4009         pthread_attr_setstack.
4010         * attr.c (pthread_attr_getstack, pthread_attr_setstack): New functions.
4012 2000-09-05  Ulrich Drepper  <drepper@redhat.com>
4014         * Examples/ex14.c: New file.
4015         * Makefile (tests): Add ex14.
4017         * mutex.c (__pthread_mutex_unlock): Correct test for already unlocked
4018         mutex.  Patch by dtc@cmucl.cons.org.
4020         * ecmutex.c: New file.
4021         * Makefile (tests): Add ecmutex.
4023 2000-09-04  H.J. Lu  <hjl@gnu.org>
4025         * attr.c (__pthread_attr_setguardsize): Use page_roundup
4026         instead of roundup to round up to the page size.
4028 2000-09-03  Mark Kettenis  <kettenis@gnu.org>
4030         * manager.c (pthread_exited): Correctly report event as TD_REAP
4031         instead of TD_DEATH.  Fix comments.
4033 2000-09-03  Ulrich Drepper  <drepper@redhat.com>
4035         * spinlock.h (testandset): Add cast to avoid warning.
4036         Patch by Franz Sirl <Franz.Sirl-kernel@lauterbach.com>.
4038 2000-09-02  Andreas Jaeger  <aj@suse.de>
4040         * sysdeps/pthread/timer_routines.c: Include stdlib.h for abort
4041         prototype.
4043 2000-09-01  Ulrich Drepper  <drepper@redhat.com>
4045         * sysdeps/pthread/bits/stdio-lock.h (_IO_cleanup_region_start):
4046         Fix typo in last patch (_mode -> _flags).
4048         * sysdeps/pthread/bits/stdio-lock.h (_IO_cleanup_region_start):
4049         Provide definition which respects _IO_USER_LOCK flag.
4051 2000-08-30  Ulrich Drepper  <drepper@redhat.com>
4053         * manager.c (pthread_allocate_stack): Clear descriptor only if not
4054         mmaped.
4056 2000-08-25  Ulrich Drepper  <drepper@redhat.com>
4058         * Makefile: Add rules to build and run unload.
4059         * unload.c: New file.
4061         * pthread.c (pthread_exit_process): Move thread_self use inside `if'.
4063         * sysdeps/pthread/pthread.h
4064         (PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP): Defined.
4065         (PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP: Defined.
4067 2000-08-24  Andreas Jaeger  <aj@suse.de>
4069         * Examples/ex13.c: Include <string.h> for strerror prototype and
4070         <stdlib.h> for abort prototype.
4071         (pthr_cond_signal_mutex): Rewrite to silence GCC.
4072         (thread_start): Remove unused variable err.
4073         (main): Silence GCC warnings.
4075 2000-08-22  Andreas Jaeger  <aj@suse.de>
4077         * Examples/ex13.c: New test by Kurt Garloff <garloff@suse.de>.
4079         * Makefile (tests): Add ex13.
4081 2000-08-20  Ulrich Drepper  <drepper@redhat.com>
4083         * semaphore.h: Add restrict where required by AGd4.
4084         * sysdeps/pthread/pthread.h: Likewise.
4085         * sysdeps/pthread/unix/sysv/linux/bits/sigthread.h: Likewise.
4087 2000-08-15  Ulrich Drepper  <drepper@redhat.com>
4089         * Makefile (tests): Add ex12.  Add rule to build it.
4090         * Examples/ex12.c: New file.
4092 2000-08-13  Ulrich Drepper  <drepper@redhat.com>
4094         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define _POSIX_SEMAPHORES
4095         even though the implementation is not quite complete (but it reports
4096         it).  Define _POSIX_MESSAGE_PASSING to -1.
4097         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4099 2000-08-12  Andreas Jaeger  <aj@suse.de>
4101         * sysdeps/mips/pt-machine.h (testandset): Add .set mips2 for
4102         assembler.
4103         (__compare_and_swap): Likewise.
4104         * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Likewise.
4106 2000-08-10  Ulrich Drepper  <drepper@redhat.com>
4108         * pthread.c (__pthread_initial_thread): Initialize p_errnop and
4109         p_h_errnop correctly and not to NULL.
4111 2000-08-05  Ulrich Drepper  <drepper@redhat.com>
4113         * Banner: Bump version number to 0.9.
4115 2000-08-04  Ulrich Drepper  <drepper@redhat.com>
4117         * Makefile (tests): Add tststack.  Add rule to build the program.
4118         * tststack.c: New file.
4120         * internals.h: Declare __pthread_max_stacksize.
4121         * pthread.c (__pthread_max_stacksize): New variable.
4122         (__pthread_initialize_manager): Determine __pthread_initialize_manager
4123         value.
4124         * manager.c (thread_segment): Return always NULL if FLOATING_STACKS.
4125         (pthread_allocate_stack): Allow kernel to choose stack address if
4126         FLOATING_STACKS.  This also handles variable-sized stacks.
4127         Always allocate stack and guardpage together.  Use mprotect to
4128         change guardpage access.
4129         * sysdeps/i386/useldt.h: Define FLOATING_STACKS and
4130         ARCH_STACK_MAX_SIZE.
4132         * attr.c (__pthread_attr_setstacksize): Also test value against
4133         upper limit.
4135         * manager.c (__pthread_nonstandard_stacks): Define only if
4136         THREAD_SELF is not defined.
4137         (pthread_allocate_stack): Always initialize gardaddr to a correct
4138         value.
4139         (pthread_handle_create): Unmap thread with one call.
4140         (pthread_free): Remove test for initial thread before removing stack.
4141         Unmap stack with one call.
4143         * pthread.c (__pthread_initial_thread): Initialize p_userstack to
4144         1 to avoid removing the stack.
4146 2000-07-27  Jes Sorensen  <jes@linuxcare.com>
4148         * sysdeps/ia64/pspinlock.c (__pthread_spin_lock): Add
4149         load of spin lock to prime the cache before the atomic compare and
4150         exchange operation (cmpxchg4). This avoids the spinning on the
4151         cmpxchg4 instruction and reduces movement of the cache line back
4152         and forth between the processors (explanation by Asis K. Mallick
4153         from Intel). This basically makes the implementation operate the
4154         same as the Linux kernel implementation.
4156         * shlib-versions: Use GLIBC_2_2 for Linux/ia64.
4157         * sysdeps/ia64/pspinlock.c: New file.
4159 2000-08-03  Ulrich Drepper  <drepper@redhat.com>
4161         * pthread.c: Move definition of __pthread_set_own_extricate_if...
4162         * spinlock.h: ...here.  Remove locking.
4163         * internals.h: Remove __pthread_set_own_extricate_if prototype.
4165         * rwlock.c: Use THREAD_GETMEM And THREAD_SETMEM.
4166         (rwlock_rd_extricate_func): Don't determine self, let
4167         __pthread_lock do it.
4168         (rwlock_wr_extricate_func): Likewise.
4169         (rwlock_have_already): Optimize *pself handling a bit.
4171         * mutex.c: Use __builtin_expect.
4172         * pthread.c: Likewise.
4174 2000-08-02  Andreas Jaeger  <aj@suse.de>
4176         * sysdeps/s390/pspinlock.c: New file.
4177         * sysdeps/s390/pt-machine.h: New file.
4178         Patches by Martin Schwidefsky <schwidefsky@de.ibm.com>.
4180 2000-07-12  Maciej W. Rozycki  <macro@ds2.pg.gda.pl>
4182         * sysdeps/mips/pspinlock.c (__pthread_spin_lock): Implement for
4183         R3K.
4184         * sysdeps/mips/pt-machine.h (testandset): Likewise.
4186 2000-07-26  Andreas Jaeger  <aj@suse.de>
4188         * pthread.c: Initialize p_sem_avail.
4190 2000-07-25  Ulrich Drepper  <drepper@redhat.com>
4192         * internals.h (struct __pthread_descr_struct): Add p_sem_avail.
4193         * semaphore.c: Handle spurious wakeups.
4195         * sysdeps/pthread/pthread.h: Add back PTHREAD_MUTX_FAST_NP as an alias
4196         for PTHREAD_MUTEX_ADAPTIVE_NP for source code compatibility.
4198         * pthread.c (__pthread_set_own_extricate): Use THREAD_GETMEM.
4199         (__pthread_wait_for_restart): Likewise.
4201         * condvar.c (pthread_cond_wait): Also check whether thread is
4202         cancelable before aborting loop.
4203         (pthread_cond_timedwait): Likewise.
4205         * signals.c (pthread_sighandler): Remove special code to restrore
4206         %gs on x86.
4207         (pthread_sighandler_t): Likewise.
4209 2000-07-25  Mark Kettenis  <kettenis@gnu.org>
4211         * internals.h (__RES_PTHREAD_INTERNAL): Remove define.
4212         * pthread.c: Include <resolv.h>.
4213         (_res): Undefine.  Add extern declaration.
4215 2000-07-24  Ulrich Drepper  <drepper@redhat.com>
4217         * pthread.c (__pthread_initial_thread): Update initializer.
4218         (__pthread_manager_thread): Likewise.
4219         (pthread_initialize): Move setrlimit call to...
4220         (__pthread_initialize_manager): ...here.
4221         (__pthread_reset_main_thread): Reset also soft limit on stack size.
4223         * condvar.c: Handle spurious wakeups.  [PR libc/1749].
4224         * internals.h (struct _pthread_descr_struct): Add p_condvar_avail.
4226 2000-07-21  Ulrich Drepper  <drepper@redhat.com>
4228         * spinlock.h: If IMPLEMENT_TAS_WITH_CAS is defined use
4229         __compare_and_swap to define testandset.
4230         * sysdeps/powerpc/pt-machine.h: Add volatile to asms.
4231         Define IMPLEMENT_TAS_WITH_CAS.
4233 2000-07-20  Ulrich Drepper  <drepper@redhat.com>
4235         * Makefile: Pass -z nodelete to linker for libpthread.so
4236         generation if it understand this option.
4238 2000-07-18  Mark Kettenis  <kettenis@gnu.org>
4240         * manager.c (pthread_handle_create): Remove initialization of
4241         new_thread->p_res._sock.
4243 2000-07-19  Kaz Kylheku  <kaz@ashi.footprints.net>
4245         Bugfixes to the variant of the code for machines with no compare
4246         and swap.
4248         * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Wait
4249         node was not being properly enqueued, due to failing to update
4250         the lock->__status field.
4252         * spinlock.c (__pthread_alt_timedlock): The oldstatus variable was
4253         being set inappropriately, causing the suspend function to be called
4254         with a null self pointer and crash.
4256 2000-07-18  Ulrich Drepper  <drepper@redhat.com>
4258         * spinlock.h (__pthread_alt_trylock): Fix code used if no
4259         compare&swap is available.
4261         * spinlock.h (__pthread_trylock): Use __compare_and_swap, not
4262         compare_and_swap.
4264         * pthread.c (pthread_initialize): Don't use sysconf to determine
4265         whether the machine has more than one processor.
4267         * spinlock.c (__pthread_alt_timedlock): Add back one of the
4268         removed thread_self calls.
4270 2000-07-18  Kaz Kylheku  <kaz@ashi.footprints.net>
4272         * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Changed
4273         __compare_and_swap to compare_and_swap in code which assumes
4274         compare swap is available.
4276 2000-07-18  Kaz Kylheku  <kaz@ashi.footprints.net>
4278         * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Fixed
4279         bug whereby thr field of waitnode structure would not be correctly
4280         set unless a null self pointer is passed to the functions.
4281         Eliminated redundant calls to thread_self().
4283 2000-07-18  Jakub Jelinek  <jakub@redhat.com>
4285         * pthread.c (__pthread_initialize_manager): Lock
4286         __pthread_manager_thread.p_lock before calling clone.
4288 2000-05-05  H.J. Lu  <hjl@gnu.org>
4290         * sysdeps/ia64/pt-machine.h (__compare_and_swap): Change it to
4291         have acquire semantics.
4292         (__compare_and_swap_with_release_semantics): New inline
4293         function.
4294         (HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS): New macro.
4296 2000-01-28  Hans Boehm  <hboehm@exch.hpl.hp.com>
4298         * manager.c: Fix the problem with signals at startup.
4299         Change the way that thread stacks are allocated on IA64.
4300         Clean up some of the guard page allocation stuff.
4302 1999-12-19  H.J. Lu  <hjl@gnu.org>
4304         * internals.h (page_roundup): New.
4305         * attr.c (__pthread_attr_setguardsize); Use page_roundup
4306         instead of roundup.
4307         * manager.c (pthread_allocate_stack): Make sure guardaddr is
4308         page aligned with page_roundup if NEED_SEPARATE_REGISTER_STACK
4309         is define.
4311 1999-12-17  Hans Boehm  <hboehm@exch.hpl.hp.com>
4313         * manager.c (pthread_allocate_stack): Unmap the stack top
4314         if failed to map the stack bottom.
4315         Fix the guard page.
4316         (pthread_free): Fix the guard page.
4318         * pthread.c (pthread_initialize): Set rlimit correctly for
4319         NEED_SEPARATE_REGISTER_STACK.
4321 1999-12-16  H.J. Lu  <hjl@gnu.org>
4323         * pthread.c (__pthread_initialize_manager): Pass
4324         __pthread_manager_thread_bos instead of
4325         __pthread_manager_thread_tos to __clone2.
4327 1999-12-16  H.J. Lu  <hjl@gnu.org>
4329         * manager.c (pthread_allocate_stack): Correct the calculation
4330         of "new_thread_bottom". Remove MAP_GROWSDOWN from mmap for
4331         stack bottom.
4333 1999-12-13  H.J. Lu  <hjl@gnu.org>
4335         * sysdeps/ia64/pt-machine.h (__compare_and_swap): Added a stop
4336         bit after setting ar.ccv.
4338 1999-12-12  H.J. Lu  <hjl@gnu.org>
4340         * manager.c (pthread_allocate_stack): Make the starting
4341         address of the stack bottom page aligned. FIXME: it may
4342         need changes in other places.
4343         (pthread_handle_create): Likewise.
4345 1999-12-11  Hans Boehm  <hboehm@exch.hpl.hp.com>
4347         * manager.c (pthread_allocate_stack): Handle
4348         NEED_SEPARATE_REGISTER_STACK.
4349         (pthread_handle_create): Likewise.
4350         * pthread.c (__pthread_initialize_manager): Likewise.
4352         * sysdeps/ia64/pt-machine.h: Use r13 for thread pointer.
4354 1999-12-02  H.J. Lu  <hjl@gnu.org>
4356         * sysdeps/ia64/pt-machine.h: New.
4358 2000-07-13  Ulrich Drepper  <drepper@redhat.com>
4360         * wrapsyscall.c: Mark non-__ protected names as weak.
4361         PR libc/1466.
4363 2000-07-12  Bruno Haible  <haible@clisp.cons.org>
4365         * Examples/ex8.c: Include <sys/wait.h>, not <wait.h>.
4367 2000-07-12  Ulrich Drepper  <drepper@redhat.com>
4369         * spinlock.c: Fix code for TEST_FOR_COMPARE_AND_SWAP being defined.
4370         Add tests also to new alternative spinlock implementation.
4371         * spinlock.h: Likewise.
4372         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4374 2000-07-06  Ulrich Drepper  <drepper@redhat.com>
4376         * Version: Export __sigaction.
4377         * signals.c: Define __sigaction alias.  Use __libc_sigaction instead
4378         of __sigaction.
4379         * pthread.c: Use __libc_sigaction instead of __sigaction.
4381         * condvar.c: Implement pthread_condattr_getpshared and
4382         pthread_condattr_setpshared.
4383         * mutex.c: Implement pthread_mutexattr_getpshared and
4384          pthread_mutexattr_setpshared.
4385         * Versions: Export new functions.
4386         * sysdeps/pthread/pthread.h: Add prototypes for new functions.
4388         * rwlock.c (pthread_rwlockattr_init): Use PTHREAD_PROCESS_PRIVATE.
4389         (pthread_rwlockattr_setpshared): Fail if PTHREAD_PROCESS_PRIVATE
4390         is not selected.
4392 2000-07-04  Greg McGary  <greg@mcgary.org>
4394         * sysdeps/pthread/bits/libc-lock.h: Remove BP_SYM from
4395         pragmas.  Include bp-sym.h only if _LIBC.
4397 2000-07-04  Ulrich Drepper  <drepper@redhat.com>
4399         * spinlock.c (__pthread_unlock): Properly place write barrier.
4400         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4402 2000-07-03  Ulrich Drepper  <drepper@redhat.com>
4404         * spinlock.c: Replace fast spinlocks by adaptive spinlocks which are
4405         faster on SMP systems.  No more emulation of compare&swap for adaptive
4406         spinlocks.
4407         * spinlock.h: Likewise.
4408         * sysdeps/pthread/pthread.h: Shuffle PTHREAD_MUTEX_* values around.
4409         Replace fast with adaptive mutex.
4410         * mutex.c: Rewrite for replacement of fast by adaptive mutex.
4411         * condvar.c: Likewise.
4412         * pthread.c: Define and initialize __pthread_smp_kernel variable.
4413         * internals.h: Declare __pthread_smp_kernel.
4414         * sysdeps/pthread/bits/pthreadtypes.h: Update comment of
4415         _pthread_fastlock structure.
4416         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4418         * pthread.c: Remove initialization to zero from global variables.
4420 2000-06-29  Jakub Jelinek  <jakub@redhat.com>
4422         * shlib-versions: Make sparc64 GLIBC_2.2+ only.
4424 2000-06-28  Greg McGary  <greg@mcgary.org>
4426         * weaks.c: Wrap BP_SYM () around weak extern declarations of
4427         pthread functions that have pointers in their return+arg signatures.
4429 2000-06-27  Greg McGary  <greg@mcgary.org>
4431         * sysdeps/pthread/bits/libc-lock.h: Wrap BP_SYM () around weak
4432         extern declarations of pthread functions that have pointers in
4433         their return+arg signatures.
4435 2000-06-26  Ulrich Drepper  <drepper@redhat.com>
4437         * Makefile (tests): Add ex11.  Add rules to build it.
4438         * Examples/ex11.c: New file.
4439         * rwlock.c: Fix complete braindamaged previous try to implement
4440         timedout functions.
4442         * spinlock.c: Pretty print.
4444 2000-06-25  Ulrich Drepper  <drepper@redhat.com>
4446         * Makefile (tests): Add ex10.  Add rules to build it.
4447         * Versions [GLIBC_2.2] (libpthread): Add pthread_mutex_timedlock,
4448         pthread_rwlock_timedrdlock, and pthread_rwlock_timedwrlock.
4449         * condvar.c (pthread_cond_wait): Allow mutex of kind
4450         PTHREAD_MUTEX_TIMED_NP.
4451         (pthread_cond_timedwait_relative): Likewise.
4452         * mutex.c (__pthread_mutex_init): Default is PTHREAD_MUTEX_TIMED_NP.
4453         (__pthread_mutex_trylock): Use __pthread_alt_trylock for
4454         PTHREAD_MUTEX_ERRORCHECK_NP.  Handle PTHREAD_MUTEX_TIMED_NP.
4455         (__pthread_mutex_lock): Use __pthread_alt_lock for
4456         PTHREAD_MUTEX_ERRORCHECK_NP.  Handle PTHREAD_MUTEX_TIMED_NP.
4457         (__pthread_mutex_timedlock): New function.
4458         (__pthread_mutex_unlock): Use __pthread_alt_unlock for
4459         PTHREAD_MUTEX_ERRORCHECK_NP.  Handle PTHREAD_MUTEX_TIMED_NP.
4460         (__pthread_mutexattr_init): Use PTHREAD_MUTEX_TIMED_NP.
4461         (__pthread_mutexattr_settype): Allow PTHREAD_MUTEX_TIMED_NP.
4462         * spinlock.c: Implement alternate fastlocks.
4463         * spinlock.h: Add prototypes.
4464         * Examples/ex10.c: New file.
4465         * sysdeps/pthread/pthread.h: Add prototypes for new functions.
4466         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4468         * rwlock.c (__pthread_rwlock_rdlock): Optimize loop a bit.
4469         (__pthread_rwlock_timedrdlock): New function.
4470         (__pthread_rwlock_timedwrlock): New function.
4471         Use laternate fastlock function everywhere.
4473 2000-06-21  Andreas Jaeger  <aj@suse.de>
4475         * sysdeps/pthread/timer_routines.c: Include <string.h> for memset
4476         prototype.
4478         * join.c: Include <stdlib.h> for exit prototype.
4480 2000-06-20  Ulrich Drepper  <drepper@redhat.com>
4482         * sysdeps/i386/useldt.h: Include <stdlib.h>.
4484         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define _POSIX_BARRIERS.
4485         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4487         * Makefile (libpthread-routines): Add barrier.
4488         (tests): Add ex9.  Add rule to build ex9.
4489         * Versions: Export barrier functions.
4490         * barrier.c: New file.
4491         * Examples/ex9.c: New file.
4492         * sysdeps/pthread/pthread.h: Add barrier data types and declarations.
4493         * sysdeps/pthread/bits/pthreadtypes.h: Likewise.
4494         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4496 2000-06-19  H.J. Lu  <hjl@gnu.org>
4498         * spinlock.h (HAS_COMPARE_AND_SWAP): Defined if
4499         HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS is defined.
4500         (compare_and_swap_with_release_semantics): New. Default to
4501         compare_and_swap if HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS
4502         is not defined.
4504         * spinlock.c (__pthread_unlock): Call
4505         compare_and_swap_with_release_semantics () instead of
4506         compare_and_swap ().
4508 2000-06-19  Ulrich Drepper  <drepper@redhat.com>
4510         * sysdeps/pthread/timer_create.c: Use _set_errno instead of assigning
4511         to errno directly.
4512         * sysdeps/pthread/timer_delete.c: Likewise.
4513         * sysdeps/pthread/timer_getoverr.c: Likewise.
4514         * sysdeps/pthread/timer_gettime.c: Likewise.
4515         * sysdeps/pthread/timer_settime.c: Likewise.
4517 2000-06-13  Kaz Kylheku  <kaz@ashi.footprints.net>
4519         Timer nodes are now reference counted, and can be marked
4520         as deleted. This allows for the safe release of the global mutex
4521         in the middle without losing the timer being operated on.
4523         * sysdeps/pthread/posix-timer.h (struct timer_node):  The inuse
4524         member is now an enum with three values, so that an intermediate
4525         state can be represented (deleted but not free for reuse yet).
4526         New refcount member added.
4527         * sysdeps/pthread/timer_routines.c: Likewise.
4529         * sysdeps/pthread/posix-timer.h (timer_addref, timer_delref,
4530         timer_valid): New inline functions added.
4532         * sysdeps/pthread/timer_gettime.c (timer_gettime): Function
4533         restructured, recursive deadlock bug fixed.
4535         * sysdeps/pthread/timer_gettime.c (timer_gettime): Uses new
4536         timer_addref to ensure that timer won't be deleted while mutex is not
4537         held. Also uses timer_invalid to perform validation of timer handle.
4538         * sysdeps/pthread/timer_settime.c (timer_settime): Likewise.
4539         * sysdeps/pthread/timer_getoverr.c (timer_getoverrun): Likewise.
4541 2000-06-14  Ulrich Drepper  <drepper@redhat.com>
4543         * shlib-versions: Add entry for SH.
4544         Patch by Kaz Kojima <kkojima@rr.iij4u.or.jp>.
4546 2000-06-13  Kaz Kylheku  <kaz@ashi.footprints.net>
4548         A few optimizations.  Got rid of unnecessary wakeups of timer threads,
4549         tightened up some critical regions and micro-optimized some list
4550         manipulation code.
4552         * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
4553         Returns int value now to indicate whether timer was queued at head.
4554         * sysdeps/pthread/posix-timer.h: Likewise.
4555         * sysdeps/pthread/timer_settime.c (timer_settime): Takes advantage of
4556         new return value from __timer_thread_queue_timer to avoid waking
4557         up timer thread unnecessarily.
4559         * sysdeps/pthread/posix-timer.h (timer_id2ptr): No longer checks
4560         inuse flag, because this requires mutex to be held.  Callers updated
4561         to do the check when they have the mutex.
4562         * sysdeps/pthread/timer_getoverr.c: Add check for inuse here.
4564         * sysdeps/pthread/timer_settime.c (timer_settime): Tighter critical
4565         regions: avoids making system calls while holding timer mutex, and
4566         a few computations were moved outside of the mutex as well.
4567         * sysdeps/pthread/timer_gettime.c (timer_gettime): Likewise.
4569         * sysdeps/pthread/posix-timer.h (list_unlink_ip): Function name changed
4570         to list_unlink_ip, meaning idempotent.  Pointer manipulation
4571         changed to get better better code out of gcc.
4572         * sysdeps/pthread/timer_routines.c (list_unlink): Non-idempotent
4573         version of list_unlink added here.
4574         * sysdeps/pthread/timer_delete.c: Use appropriate list unlink
4575         function in all places: idempotent one for timers, non-idempotent
4576         one for thread nodes.
4577         * sysdeps/pthread/timer_settime: Likewise.
4578         * sysdeps/pthread/timer_routines.c: Likewise.
4580 2000-06-13  Ulrich Drepper  <drepper@redhat.com>
4582         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_TIMERS): Define.
4583         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4585         * sysdeps/pthread/Makefile: Remove tests definition.
4587 2000-06-12  Kazumoto Kojima  <kkojima@rr.iij4u.or.jp>
4588             Yutaka Niibe  <gniibe@chroot.org>
4590         * sysdeps/sh/pspinlock.c: New file.
4591         * sysdeps/sh/pt-machine.h: New file.
4593 2000-06-12  Ulrich Drepper  <drepper@redhat.com>
4595         * Makefile (tests): Add joinrace.
4597         * Examples/ex6.c: Test return value of pthread_join.
4599 2000-06-11  Geoff Keating  <geoffk@cygnus.com>
4601         * sysdeps/powerpc/pspinlock.c (__pthread_spin_lock): Implement.
4602         (__pthread_spin_trylock): Implement.
4603         (__pthread_spin_unlock): Implement.
4604         (__pthread_spin_init): Implement.
4605         (__pthread_spin_destroy): Implement.
4607 2000-06-10  Ulrich Drepper  <drepper@redhat.com>
4609         * sysdeps/pthread/timer_routines.c (list_append): Little fix to
4610         really append the entry.
4612 2000-06-10  Andreas Jaeger  <aj@suse.de>
4614         * lockfile.c (__fresetlockfiles): Remove unused variable fp.
4616 2000-06-10  Kaz Kylheku  <kaz@ashi.footprints.net>
4618         * sysdeps/pthread/timer_create.c: Thread matching now done on
4619         clock type as well as thread attributes.
4620         There are individual global signal-delivering threads for
4621         different clock types.
4622         * sysdeps/pthread/posix-timer.h: Likewise.
4623         * sysdeps/pthread/timer_routines.c: Likewise.
4625         * sysdeps/pthread/timer_routines.c: Thread allocation and
4626         deallocation function now remembers to put thread on active
4627         list and remove from active list.
4628         Thus now the feature of binding multiple timers
4629         to a single thread actually works.
4631 2000-06-10  Ulrich Drepper  <drepper@redhat.com>
4633         * pthread.c (__pthread_create_2_1): Optimize a bit.
4635         * internals.h (invalid_handle): Also test for p_terminated != 0.
4636         (nonexisting_handle): New function.  Same as old invalid_handle.
4637         * join.c (pthread_join): Use nonexisting_handle instead of
4638         invalid_handle to test for acceptable thread handle.
4639         * manager.c (pthread_handle_free): Likewise.
4640         * joinrace.c: New file.
4641         Reported by Permaine Cheung <pcheung@cygnus.com>.
4643 2000-06-08  Ulrich Drepper  <drepper@redhat.com>
4645         * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
4646         Correct handling of matching variable.
4648         * sysdeps/pthread/tst-timer.c (main): Rewrite initializers to
4649         avoid warnings.
4651         * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
4652         Be prepared for empty timer list.
4654         * sysdeps/pthread/timer_create.c (timer_create): Correct names of
4655         CPUTIME clock ID.  Add support for thread clocks.
4657         * sysdeps/pthread/posix-timer.h (timer_ptr2id): Operands in
4658         subtraction were switched.
4660         * sysdeps/pthread/timer_routines.c (init_module): Use
4661         THREAD_MAXNODES threads.
4663         * sysdeps/pthread/posix-timer.h (struct timer_node): Add creator_pid.
4664         * sysdeps/pthread/timer_create.c: Fill in creator_pid.
4665         * sysdeps/pthread/timer_routines.c (thread_expire_timer): Send signal
4666         with sigqueueinfo is this system call is available.
4668         * sysdeps/pthread/timer_create.c (timer_create): Allow
4669         CLOCK_CPUTIME if _POSIX_CPUTIME is defined.
4671         * sysdeps/pthread/Makefile: New file.  Add rules to build timer
4672         functionality.
4673         * sysdeps/unix/sysv/linux/bits/local_lim.h: Add TIMER_MAX.
4675 2000-06-04  Kaz Kylheku  <kaz@ashi.footprints.net>
4677         * sysdeps/pthread/posix-timer.h: New file.
4678         * sysdeps/pthread/timer_create.c: New file.
4679         * sysdeps/pthread/timer_delete.c: New file.
4680         * sysdeps/pthread/timer_getoverr.c: New file.
4681         * sysdeps/pthread/timer_gettime.c: New file.
4682         * sysdeps/pthread/timer_routines.c: New file.
4683         * sysdeps/pthread/timer_settime.c: New file.
4684         * sysdeps/pthread/tst-timer.c: New file.
4686 2000-06-08  Ulrich Drepper  <drepper@redhat.com>
4688         * sysdeps/unix/sysv/linux/bits/local_lim.h: Remove OPEN_MAX and
4689         LINK_MAX definitions if necessary.
4691 2000-06-04  Kaz Kylheku  <kaz@ashi.footprints.net>
4693         Added missing fork time handling of global libio lock.
4695         * lockfile.c (__fresetlockfiles): Now also resets the list lock,
4696         not just the individual stream locks. Rewritten to use new
4697         iterator interface provided by libio rather than accessing
4698         global variable.
4700         * lockfile.c (__flockfilelist, _funlockfilelist): New functions
4701         which lock and unlock the stream list using the new interface
4702         provied by libio.
4703         * internals.h: Likewise.
4705         * ptfork.c (__fork): Now calls __flockfilelist before fork,
4706         and __funlockfilelist in the parent after the fork.
4707         Child still calls __fresetlockfiles as before.
4709         * linuxthreads.texi: Now explains what happens to streams at
4710         fork time. Also whole new section on forking and thread added.
4711         Definition of pthread_atfork moved out of Miscellaneous Functions
4712         to this new section.
4714 2000-06-04  Jakub Jelinek  <jakub@redhat.com>
4716         * sysdeps/sparc/sparc32/sparcv9/pspinlock.c (__pthread_spin_lock):
4717         Add missing register.
4718         * sysdeps/sparc/sparc64/pspinlock.c (__pthread_spin_lock): Likewise.
4720 2000-06-02  Jakub Jelinek  <jakub@redhat.com>
4722         * sysdeps/sparc/sparc32/pspinlock.c: Implement spinlocks.
4723         * sysdeps/sparc/sparc32/sparcv9/pspinlock.c: New.
4724         * sysdeps/sparc/sparc64/pspinlock.c: Implement spinlocks.
4726 2000-05-31  Andreas Jaeger  <aj@suse.de>
4728         * sysdeps/mips/pspinlock.c: Implement spinlocks.
4730 2000-05-28  Ulrich Drepper  <drepper@redhat.com>
4732         * spinlock.c (__pthread_lock): Remove ASSERT.
4734         * Makefile (tests): Add ex8.
4735         * Examples/ex8.c: New file.
4737 2000-05-12  Kaz Kylheku  <kaz@ashi.footprints.net>
4739         Bugfix: The pthread_atfork mechanism now takes care of its
4740         own internal mutex at fork time.
4742         * ptfork.c (__fork): Revised so that the mutex is held across
4743         the fork operation and while the handlers are called, and so that
4744         the child resets the mutex.
4746         * linuxthreads.texi: Updated pthread_atfork documentation to make
4747         it clear that fork and pthread_atfork can't be reentered from
4748         atfork handlers, that pthread_atfork and fork are mutually atomic,
4749         and that the handlers are inherited by the child process.
4751 2000-05-24  Ulrich Drepper  <drepper@redhat.com>
4753         * Makefile (libpthread-routines): Add pspinlock.
4754         * cancel.c: Rename __pthread_spin_unlock back to __pthread_unlock.
4755         Use struct _pthread_fastlock instead of pthread_spinlock_t.
4756         * condvar.c: Likewise.
4757         * internals.h: Likewise.
4758         * join.c: Likewise.
4759         * manager.c: Likewise.
4760         * mutex.c: Likewise.
4761         * pthread.c: Likewise.
4762         * rwlock.c: Likewise.
4763         * semaphore.c: Likewise.
4764         * signals.c: Likewise.
4765         * spinlock.h: Likewise.
4766         * spinlock.c: Likewise.  Remove pthread_spin_lock functions.
4767         * sysdeps/alpha/pspinlock.c: New file.
4768         * sysdeps/arm/pspinlock.c: New file.
4769         * sysdeps/i386/pspinlock.c: New file.
4770         * sysdeps/m68k/pspinlock.c: New file.
4771         * sysdeps/mips/pspinlock.c: New file.
4772         * sysdeps/powerpc/pspinlock.c: New file.
4773         * sysdeps/sparc/sparc32/pspinlock.c: New file.
4774         * sysdeps/sparc/sparc64/pspinlock.c: New file.
4775         * sysdeps/pthread/bits/pthreadtypes.h: Remove pthread_spinlock_t
4776         back to _pthread_fastlock.  Define new pthread_spinlock_t.
4778 2000-05-24  Andreas Jaeger  <aj@suse.de>
4780         * sysdeps/i386/i686/pt-machine.h: Only use LDT on newer kernels.
4782 2000-05-21  Jakub Jelinek  <jakub@redhat.com>
4784         * manager.c (pthread_handle_create): Initialize p_res._sock to -1.
4786 2000-05-13  Jakub Jelinek  <jakub@redhat.com>
4788         * internals.h (__RES_PTHREAD_INTERNAL): Define.
4790 2000-05-06  Kaz Kylheku  <kaz@ashi.footprints.net>
4792         * mutex.c (pthread_once): IN_PROGRESS state of pthread_once_t
4793         object state is represented with additional bits which distinguish
4794         whether that state was set up in the current process, or
4795         in an ancestor process. If that state was set in an ancestor,
4796         it means that a fork happened while thread was executing the init
4797         function. In that case, the state is reset to NEVER.
4798         * mutex.c (__pthread_once_fork_prepare): New function.
4799         (__pthread_once_fork_child): Likewise
4800         (__pthread_once_fork_parent): Likewise
4801         (__pthread_reset_pthread_once): Removed.
4802         * ptfork.c (__fork): Call new handlers in mutex.c.
4803         * internals.h: Declarations of new mutex.c functions added.
4804         Declaration of removed function deleted.
4805         * linuxthreads.texi: Updated documentation about pthread_once
4806         to clarify what happens under cancellation and forking.
4808 2000-05-06  Kaz Kylheku  <kaz@ashi.footprints.net>
4810         * internals.h: New thread manager request type, REQ_KICK.
4811         * join.c (pthread_exit): main thread now calls exit() instead
4812         of _exit() in order to proper process cleanup.
4813         * manager.c (__pthread_manager): Do not terminate manager
4814         after unblocking main thread; wait for main thread's
4815         REQ_PROCESS_EXIT request instead.
4816         Also, added REQ_KICK case to handle new request; this just does
4817         nothing.
4818         * manager.c (pthread_exited): Do not terminate manager after
4819         unblocking main thread.
4820         * manager.c (__pthread_manager_sighandler): If the main thread
4821         is waiting for all other threads to die, send a REQ_KICK into
4822         the thread manager request pipe to get it to clean out the threads
4823         and unblock the main thread as soon as possible. This fixes
4824         the 2000 millisecond hang on shutdown bug.
4825         * Examples/ex7.c: New file, tests shutdown behavior when all threads
4826         including the main one call pthread_exit(), or implicitly do so.
4827         * Makefile (tests): Add ex7.
4829 2000-05-05  Andreas Jaeger  <aj@suse.de>
4831         * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
4832         (pthread_getcpuclockid): Correct test for ourselves.
4834 2000-05-05  Ulrich Drepper  <drepper@redhat.com>
4836         * internals.h (struct _pthread_descr_struct): Reorganization.
4837         Allocate room for 16 pointers at head of the structure for future
4838         thread-local data handling.  Move p_self member in this area.
4839         * manager.c (pthread_handle_create): Adjust use of p_self.
4840         * sysdeps/i386/useldt.h (THREAD_SELF): Likewise.
4841         * pthread.c (__pthread_initial_thread): Adjust initialization.
4842         (__pthread_manager_thread): Likewise.
4844 2000-04-29  Bruno Haible  <haible@clisp.cons.org>
4846         * join.c (pthread_exit): Use THREAD_GETMEM_NC instead of THREAD_GETMEM
4847         for eventmask larger than 1 word.
4849 2000-04-27  Ulrich Drepper  <drepper@redhat.com>
4851         * Versions [libpthread] (GLIBC_2.2): Add __pthread_initialize_minimal.
4852         * pthread.c (__pthread_initialize_minimal): New function.  Perform
4853         minimal initialization.
4854         (pthread_initialize): Remove this code here.
4855         * sysdeps/i386/i686/pt-machine.h: Include "../useldt.h" again.  We
4856         are working around the problem in glibc.
4858 2000-04-25  Ulrich Drepper  <drepper@redhat.com>
4860         * sysdeps/i386/i686/pt-machine.h: Do not use "../useldt.h" for
4861         now.  First gcc must be fixed (more concrete: libgcc).
4863 2000-04-24  Ulrich Drepper  <drepper@redhat.com>
4865         * pthread.c: Remove special treatement for interrupt handlers on x86.
4866         * manager.c (pthread_free): Use FREE_THREAD not FREE_THREAD_SELF.
4867         * sysdeps/i386/useldt.h: Use "q" constraint instead of "r" where
4868         necessary.
4869         * sysdeps/i386/i686/pt-machine.h: Include "../useldt.h".
4871 2000-04-24  Mark Kettenis  <kettenis@gnu.org>
4873         * join.c (pthread_exit): Set p_terminated after reporting the
4874         termination event instead of before.
4876 2000-04-20  Jakub Jelinek  <jakub@redhat.com>
4878         * sysdeps/pthread/bits/libc-lock.h: Only declare __pthread_rwlock_*
4879         if __USE_UNIX98.
4881 2000-04-18  Andreas Jaeger  <aj@suse.de>
4883         * Versions: Use ld instead of ld.so.
4885 2000-04-18  Jakub Jelinek  <jakub@redhat.com>
4887         * sysdeps/unix/sysv/linux/sparc/bits/sigcontext.h (struct sigcontext):
4888         Remove the typedef keyword.
4890 2000-04-18  Jakub Jelinek  <jakub@redhat.com>
4892         * sysdeps/sparc/sparc64/pt-machine.h (MEMORY_BARRIER): Use membar,
4893         not stbar.
4894         (READ_MEMORY_BARRIER): Define.
4895         * spinlock.c (__pthread_spin_unlock): Use READ_MEMORY_BARRIER, not
4896         MEMORY_BARRIER.
4897         * internals.h (READ_MEMORY_BARRIER): Define if not defined in sysdep
4898         headers.
4900 2000-04-17  Ulrich Drepper  <drepper@redhat.com>
4902         * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
4903         (pthread_getcpuclockid): Don't compare thread_id with thread_self,
4904         use thread_handle().
4906 2000-04-16  Ulrich Drepper  <drepper@redhat.com>
4908         * condvar.c (pthread_cond_timedwait_relative): Don't test for owner
4909         if fast mutex is used.  Don't initialize `already_canceled' twice.
4910         Correctly test for return value of timedsuspend.
4912         * pthread.c: Correct long-time braino.  We never set SA_SIGINFO and
4913         therefore don't need the _rt versions of the signal handlers.
4915 2000-04-15  Ulrich Drepper  <drepper@redhat.com>
4917         * pthread.c (pthread_yield): New function.
4918         * sysdeps/pthread/pthread.h (pthread_yield): Add prototype.
4919         * Versions [libpthread] (GLIBC_2.2): Add pthread_yield.
4920         * internals.h: Declare __pthread_yield.
4922         * pthread.c (pthread_initialize): Avoid a bit more code if
4923         realtime signals are known to exist.
4925         * pthread.c: Is __ASSUME_REALTIME_SIGNALS then avoid generating code
4926         to dynamically detect RT signals and avoid generating compatibility
4927         functions with old kernel.
4928         * restart.h (restart) [__ASSUME_REALTIME_SIGNALS]: Use
4929         __pthread_restart_new directly.
4930         (suspend) [__ASSUME_REALTIME_SIGNALS]: Use
4931         __pthread_wait_for_restart_signal directly.
4932         (timedsuspend) [__ASSUME_REALTIME_SIGNALS]: Use
4933         __pthread_timedsuspend_new directly.
4935 2000-04-15  Ulrich Drepper  <drepper@redhat.com>
4937         * condvar.c: Remove all the special code to handle cond_timedwait.
4938         Use timedsuspend instead.
4939         * internals.h: Declare __pthread_timedsuspend_old,
4940         __pthread_timedsuspend_new, and __pthread_timedsuspend.
4941         Remove declaration of __pthread_init_condvar.
4942         * pthread.c: Define __pthread_timedsuspend variable.
4943         (__pthread_timedsuspend_old): New function.  Timed suspension
4944         implementation for old Linux kernels.
4945         (__pthread_timedsuspend_new): New function.  Timed suspension
4946         implementation for new Linux kernels.
4947         * restart.h (timedsuspend): New function.  Call appropriate
4948         suspension function through __pthread_timedsuspend.
4949         * semaphore.c (sem_timedwait): Use timedsuspend, don't duplicate
4950         the code.
4951         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
4953         * internals.h (WRITE_MEMORY_BARRIER): Define as MEMORY_BARRIER if
4954         undefined.
4955         * spinlock.c: Use WRITE_MEMORY_BARRIER instead of MEMORY_BARRIER
4956         where possible.
4957         * sysdeps/alpha/pt-machine.h: Define WRITE_MEMORY_BARRIER.
4958         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
4960         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _POSIX_SPAWN.
4961         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4963 2000-04-14  Andreas Jaeger  <aj@suse.de>
4965         * weaks.c: Fix typo.
4967         * shlib-versions (mips.*-.*-linux.*): Support only GLIBC 2.0 and
4968         2.2 for linuxthreads.
4970 2000-04-13  Ulrich Drepper  <drepper@redhat.com>
4972         * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
4973         (pthread_getcpuclockid): Fix typo.
4975 2000-04-12  Ulrich Drepper  <drepper@redhat.com>
4977         * Makefile (libpthread-routines): Add getcpuclockid.
4978         * Versions [libpthread] (GLIBC_2.2): Add pthread_getcpuclockid.
4979         * sysdeps/pthread/getcpuclockid.c: New file.
4980         * sysdeps/unix/sysv/linux/i386/getcpuclockid.c: New file.
4981         * sysdeps/pthread/pthread.h: Add prototype for pthread_getcpuclockid.
4983         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_SPIN_LOCKS):
4984         Defined.
4985         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4987         * sysdeps/pthread/pthread.h: Add prototypes for pthread_spin_init,
4988         pthread_spin_destroy, pthread_spin_lock, pthread_spin_trylock,
4989         and pthread_spin_unlock.
4990         * sysdeps/pthread/bits/pthreadtypes.h: Change struct _pthread_fastlock
4991         into pthread_spinlock_t.  Change all uses.
4992         * spinlock.c: Implement pthread_spin_lock.
4993         Rename __pthread_unlock to __pthread_spin_unlock and define weak
4994         alias for real name.
4995         Define pthread_spin_trylock, pthread_spin_init, and
4996         pthread_spin_destroy.
4997         Change all uses of _pthread_fastlock to pthread_spinlock_t.
4998         * spinlock.h: Rename __pthread_unlock to __pthread_spin_unlock.
4999         Change all uses of _pthread_fastlock to pthread_spinlock_t.
5000         * Versions [libpthread] (GLIBC_2.2): Add pthread_spin_init,
5001         pthread_spin_destroy, pthread_spin_lock, pthread_spin_trylock,
5002         and pthread_spin_unlock.
5003         * cancel.c: Use __pthread_spin_unlock instead of __pthread_unlock.
5004         Change all uses of _pthread_fastlock to pthread_spinlock_t.
5005         * condvar.c: Likewise.
5006         * internals.h: Likewise.
5007         * join.c: Likewise.
5008         * manager.c: Likewise.
5009         * mutex.c: Likewise.
5010         * pthread.c: Likewise.
5011         * rwlock.c: Likewise.
5012         * semaphore.c: Likewise.
5013         * signals.c: Likewise.
5015         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add various new POSIX
5016         macros.
5017         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: New file.
5019 2000-04-11  Ulrich Drepper  <drepper@redhat.com>
5021         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add
5022         _POSIX_SHARED_MEMORY_OBJECTS.
5024 2000-04-11  Andreas Jaeger  <aj@suse.de>
5026         * sysdeps/mips/pt-machine.h (MEMORY_BARRIER): Define.
5027         (__compare_and_swap): Mark as modifying memory.
5029 2000-04-11  Geoff Keating  <geoffk@cygnus.com>
5031         * sysdeps/powerpc/pt-machine.h (MEMORY_BARRIER): Don't be
5032         __volatile__.
5033         (__compare_and_swap): Replace other 'sync' with MEMORY_BARRIER.
5034         Don't have the 'asm' __volatile__.
5036 2000-04-11  Ulrich Drepper  <drepper@redhat.com>
5038         * internals.h: Define MEMORY_BARRIER as empty if not defined already.
5039         * spinlock.c (__pthread_lock): Add memory barriers.
5040         (__pthread_unlock): Likewise.
5041         * sysdeps/alpha/pt-machine.h (MEMORY_BARRIER): Define using mb
5042         instruction.
5043         (RELEASE): Not needed anymore.
5044         (__compare_and_swap): Mark asm as modifying memory.
5045         * sysdeps/powerpc/pt-machine.h (sync): Remove.  Replace with definition
5046         of MEMORY_BARRIER.
5047         (__compare_and_swap): Use MEMORY_BARRIER instead of sync.
5048         * sysdeps/sparc/sparc32/pt-machine.h (RELEASE): Not needed anymore.
5049         (MEMORY_BARRIER): Define using stbar.
5050         * sysdeps/sparc/sparc64/pt-machine.h (MEMORY_BARRIER): Define using
5051         stbar.
5052         (__compare_and_swap): Use MEMORY_BARRIER to ensure ordering.
5053         Patch by Xavier Leroy <Xavier.Leroy@inria.fr> based on comments by
5054         Mike Burrows <m3b@pa.dec.com>.
5056 2000-04-09  Ulrich Drepper  <drepper@redhat.com>
5058         * signals.c (sigaction): Fix return value for the case SIG is one
5059         of the signals the implementation uses.
5060         Patch by Xavier.Leroy@inria.fr.
5062 2000-04-01  Andreas Jaeger  <aj@suse.de>
5064         * attr.c: Use shlib-compat macros.
5065         * oldsemaphore.c: Likewise.
5066         * pthread.c: Likewise.
5067         * weaks.c: Likewise.
5069 2000-03-26  Ulrich Drepper  <drepper@redhat.com>
5071         * semaphore.c (sem_timedwait): New function.
5072         Patch by Carl Mailloux <carlm@oricom.ca>.
5073         * semaphore.h: Declare sem_timedwait.
5074         * Versions [libpthread] (GLIBC_2.2): Add sem_timedwait.
5076 2000-03-26  Roland McGrath  <roland@baalperazim.frob.com>
5078         * sysdeps/pthread/Makefile: File removed.
5080 2000-03-23  Ulrich Drepper  <drepper@redhat.com>
5082         * mutex.c (__pthread_reset_pthread_once): Reset once_masterlock.
5083         * internals.h (__pthread_reset_pthread_once): Add prototype.
5084         * ptfork.c (__fork): Call __pthread_reset_pthread_once.
5086         * manager.c (pthread_handle_create): Store ID of new thread before
5087         clone call.
5089 2000-03-21  Ulrich Drepper  <drepper@redhat.com>
5091         * attr.c: Use new macros from shlib-compat.h to define versions.
5092         * oldsemaphore.c: Likewise.
5093         * semaphore.c: Likewise.
5094         * weaks.c: Likewise.
5096         * pthread.c: Update for new SHLIB_COMPAT definition.
5098         * manager.c (__pthread_manager): Unmask debug signal.
5100         * pthread.c (pthread_initialize): Test for address of __dso_handle
5101         being NULL, not value.  Use __on_exit, not on_exit.
5102         Patch by Andreas Jaeger <aj@suse.de>.
5104         * pthread.c: Use new macros from shlib-compat.h to define versions.
5106 2000-03-19  Ulrich Drepper  <drepper@redhat.com>
5108         * pthread.c (pthread_initialize): Instead of on_exit use
5109         __cxa_atexit if __dso_label is available to allow unloading the
5110         libpthread shared library.
5112 2000-03-16  Ulrich Drepper  <drepper@redhat.com>
5114         * condvar.c: Make tests for ownership of mutex less strict.
5116 2000-03-14  Ulrich Drepper  <drepper@redhat.com>
5118         * condvar.c (pthread_cond_wait): Check whether mutex is owned by
5119         current thread and return error if not.
5120         (pthread_cond_timedwait_relative_old): Likewise.
5121         (pthread_cond_timedwait_relative_new): Likewise.
5123         * mutex.c (__pthread_once): Handle cancelled init function correctly.
5124         (pthread_once_cancelhandler): New function.
5125         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
5127 2000-03-14  Andreas Jaeger  <aj@suse.de>
5129         * pthread.c (pthread_handle_sigcancel_rt): GS has been renamed to
5130         REG_GS.
5131         (pthread_handle_sigrestart_rt): Likewise.
5132         * signals.c (pthread_sighandler_rt): Likewise.
5134 2000-03-02  Andreas Jaeger  <aj@suse.de>
5136         * sysdeps/pthread/bits/libc-lock.h: Fix typo.
5137         Reported by Sean Chen <sean.chen@turbolinux.com>.
5139 2000-02-28  Andreas Jaeger  <aj@suse.de>
5141         * rwlock.c: Fix typo.
5143 2000-02-27  Ulrich Drepper  <drepper@redhat.com>
5145         * rwlock.c: Define __* variants of the functions and make old names
5146         aliases.
5147         * Versions [GLIBC_2.2]: Export the __pthread_rwlock_* functions.
5148         * sysdeps/pthread/bits/libc-lock.h: Define __libc_rwlock_* macros.
5150 2000-02-25  Andreas Jaeger  <aj@suse.de>
5152         * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
5153         pwrite64, lseek64, open64, and __open64 with version 2.2.
5155 2000-02-22  Ulrich Drepper  <drepper@redhat.com>
5157         * semaphore.h (SEM_FAILED): Use 0 not NULL.
5159 2000-02-14  Ulrich Drepper  <drepper@redhat.com>
5161         * condvar.c (pthread_cond_timedwait_relative_old): Tight loop with
5162         nanosleep does not work either.  Get absolute time inside the
5163         loop.
5164         (pthread_cond_timedwait_relative_new): Likewise.
5165         Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
5167 2000-02-13  Andreas Jaeger  <aj@suse.de>
5169         * condvar.c (pthread_cond_timedwait_relative_new): Fix last patch.
5170         (pthread_cond_timedwait_relative_old): Likewise.
5172 2000-02-13  Ulrich Drepper  <drepper@redhat.com>
5174         * condvar.c (pthread_cond_timedwait_relative_old): Undo last patch
5175         but keep the code around.  A bug in the kernel prevent us from
5176         using the code.
5177         (pthread_cond_timedwait_relative_new): Likewise.
5178         (PR libc/1597 and libc/1598).
5180 2000-02-01  Kaz Kylheku  <kaz@ashi.footprints.net>
5182         * condvar.c (pthread_cond_timedwait_relative_old): Do tight
5183         loop around nanosleep calls instead of around most of the function
5184         (pthread_cond_timedwait_relative_new): Likewise.
5185         body.  Got rid of backwards goto and one local.
5187 2000-01-31  Ulrich Drepper  <drepper@redhat.com>
5189         * condvar.c (pthread_cond_timedwait_relative_old): Recompute time
5190         before every nanosleep call to account for time spent in the rest
5191         of the function.
5192         (pthread_cond_timedwait_relative_new): Likewise.
5193         Patch by khendricks@ivey.uwo.ca (PR libc/1564).
5195 2000-01-29  Ulrich Drepper  <drepper@redhat.com>
5197         * condvar.c (pthread_cond_timedwait_relative_old): Get remaining time
5198         from nanosleep call so that in case we restart we only wait for the
5199         remaining time.
5200         (pthread_cond_timedwait_relative_new): Likewise.
5201         Patch by khendricks@ivey.uwo.ca (PR libc/1561).
5203 2000-01-18  Ulrich Drepper  <drepper@cygnus.com>
5205         * manager.c (pthread_allocate_stack): Compute guard page address
5206         correctly.  Patch by HJ Lu.
5208         * sysdeps/pthread/pthread.h: Define
5209         PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP.
5211 2000-01-16  Ulrich Drepper  <drepper@cygnus.com>
5213         * rwlock.c (pthread_rwlock_unlock): Correct one more problem with
5214         preference handling.
5215         (pthread_rwlockattr_setkind_np): Allow
5216         PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP.
5217         Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
5219 2000-01-12  Ulrich Drepper  <drepper@cygnus.com>
5221         * internals.h (pthread_readlock_info): New structure.
5222         (_pthread_descr_struct): Add p_readlock_list, p_readlock_free, and
5223         p_untracked_readlock_count.
5224         * pthread.c (__pthread_initial_thread, pthread_manager_thread):
5225         Add initializers for new fields.
5226         * manager.c (pthread_free): Free read/write lock lists.
5227         * queue.h (queue_is_empty): New function.
5228         * rwlock.c: Implement requirements about when readers should get
5229         locks assigned.
5230         * sysdeps/pthread/pthread.h
5231         (PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP): New definition.
5232         * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_rwlock_t):
5233         Define this name as well.
5234         Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
5236 2000-01-05  Ulrich Drepper  <drepper@cygnus.com>
5238         * pthread.c (__pthread_initial_thread, pthread_manager_thread):
5239         Adjust initializers for struct _pthread_descr_struct change.
5240         * internals.h (struct _pthread_descr_struct): Move new elements to
5241         the end.
5243 2000-01-03  Kaz Kylheku  <kaz@ashi.footprints.net>
5245         Redesigned how cancellation unblocks a thread from internal
5246         cancellation points (sem_wait, pthread_join,
5247         pthread_cond_{wait,timedwait}).
5248         Cancellation won't eat a signal in any of these functions
5249         (*required* by POSIX and Single Unix Spec!).
5250         * condvar.c: Spontaneous wakeup on pthread_cond_timedwait won't eat a
5251         simultaneous condition variable signal (not required by POSIX
5252         or Single Unix Spec, but nice).
5253         * spinlock.c: __pthread_lock queues back any received restarts
5254         that don't belong to it instead of assuming ownership of lock
5255         upon any restart; fastlock can no longer be acquired by two threads
5256         simultaneously.
5257         * restart.h: Restarts queue even on kernels that don't have
5258         queued real time signals (2.0, early 2.1), thanks to atomic counter,
5259         avoiding a rare race condition in pthread_cond_timedwait.
5261 1999-12-31  Andreas Jaeger  <aj@suse.de>
5263         * internals.h: Remove duplicate prototype declarations.
5265         * weaks.c: Remove __THROW from prototypes since the file is not
5266         compiled by a C++ compiler.
5267         * internals.h: Likewise.
5269 1999-12-30  Andreas Jaeger  <aj@suse.de>
5271         * sysdeps/pthread/pthread.h: Move internal functions to...
5272         * sysdeps/pthread/bits/libc-lock.h: ...here.
5274 1999-12-29  Andreas Jaeger  <aj@suse.de>
5276         * sysdeps/pthread/pthread.h: Fix typos, reformat comments.
5278 1999-12-28  Ulrich Drepper  <drepper@cygnus.com>
5280         * sysdeps/alpha/pt-machine.h: Move stack_pointer definition to the
5281         beginning.
5283         * manager.c (__pthread_start): Add one more cast to prevent
5284         warning on 64bit machines.
5286 1999-12-21  Ulrich Drepper  <drepper@cygnus.com>
5288         * manager.c (pthread_handle_create): Set p_pid of new thread
5289         before calling the callback function to report a new thread.
5291 1999-12-20  Andreas Jaeger  <aj@suse.de>
5293         * pthread.c (pthread_initialize): Move getrlimit call after
5294         setting of errno.
5296 1999-12-18  Ulrich Drepper  <drepper@cygnus.com>
5298         * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
5299         pwrite64, lseek64, open64, and __open64.
5300         * wrapsyscall.c: Define pread, __pread64, pread64, pwrite, __pwrite64,
5301         pwrite64, lseek64, open64, and __open64.
5303         * manager.c (pthread_allocate_stack): Correct computation of
5304         new_thread_bottom.  Correct handling of stack size and when the
5305         rlimit method to guard for stack growth is used.
5306         * pthread.c (pthread_initialize): Stack limit must be STACK_SIZE
5307         minus one pagesize (not two).
5309 1999-12-03  Andreas Jaeger  <aj@suse.de>
5311         * Versions: Add __res_state with version GLIBC_2.2.
5313         * errno.c (__res_state): New function to return thread specific
5314         resolver state.
5316         * pthread.c (pthread_initialize): Initialize p_resp.
5317         (__pthread_reset_main_thread): Also set p_resp.
5319         * manager.c (pthread_handle_create): Initialize p_resp.
5321         * internals.h: Add thread specific resolver state.
5322         Based on patches by Adam D. Bradley <artdodge@cs.bu.edu>.
5324 1999-12-01  Ulrich Drepper  <drepper@cygnus.com>
5326         * sysdeps/i386/pt-machine.h: Move stack_pointer definition to the
5327         beginning.
5328         * sysdeps/i386/i686/pt-machine.h: Likewise.
5329         Patches by Alan Modra <alan@SPRI.Levels.UniSA.Edu.Au>.
5331 1999-11-23  Ulrich Drepper  <drepper@cygnus.com>
5333         * manager.c (pthread_start_thread_event): Initialize p_pid already
5334         here.
5336 1999-11-22  Ulrich Drepper  <drepper@cygnus.com>
5338         * internals.h: Add prototype for __pthread_manager_event.
5339         * manager.c (__pthread_manager_event): New function.
5340         (pthread_start_thread_event): Correct computation of self.
5341         Use INIT_THREAD_SELF.
5342         * pthread.c (__pthread_manager_thread): Initialize p_lock.
5343         (__pthread_initialize_manager): Respect event flags also for creation
5344         of the manager thread.
5346 1999-11-08  Ulrich Drepper  <drepper@cygnus.com>
5348         * pthread.c (__pthread_initialize_manager): Initialize
5349         __pthread_manager_thread.p_tid.
5351 1999-11-02  Ulrich Drepper  <drepper@cygnus.com>
5353         * internals.h: Declare __pthread_last_event.
5354         * manager.c: Define __pthread_last_event.
5355         (pthread_handle_create): Set __pthread_last_event.
5356         (pthread_exited): Likewise.
5357         * join.c (pthread_exit): Likewise.
5359         * Makefile (libpthread-routines): Add events.
5360         * events.c: New file.
5361         * internals.h: Protect against multiple inclusion.
5362         Include thread_dbP.h header.
5363         (struct _pthread_descr_struct): Add new fields p_report_events and
5364         p_eventbuf.
5365         Declare event reporting functions.
5366         * join.c (pthread_exit): Signal event if this is wanted.
5367         * manager.c (__pthread_threads_events): New variable.
5368         (pthread_handle_create): Take new parameters with event information.
5369         Signal TD_CREATE event if wanted.
5370         (__pthread_manager): Adjust pthread_handle_create call.
5371         (pthread_start_thread_event): New function.  Block until manager is
5372         finished and then call pthread_start_thread.
5373         (pthread_exited): Signal TD_REAP event if wanted.
5375 1999-10-26  Ulrich Drepper  <drepper@cygnus.com>
5377         * restart.h (suspend_with_cancellation): Rewrite as a macro.
5379         * condvar.c (pthread_cond_timedwait_relative): Don't mark as inline.
5381 1999-10-25  Andreas Jaeger  <aj@suse.de>
5383         * internals.h: Remove K&R compatibility.
5384         * no-tsd.c: Likewise.
5385         * semaphore.h: Likewise.
5386         * signals.c: Likewise.
5387         * sysdeps/pthread/bits/libc-tsd.h: Likewise.
5388         * sysdeps/unix/sysv/linux/bits/sigthread.h: Likewise.
5389         * weaks.c: Likewise.
5391 1999-10-21  Xavier Leroy  <Xavier.Leroy@inria.fr>
5393         * pthread.c: For i386, wrap pthread_handle_sigrestart and
5394         pthread_handle_sigcancel with functions that restore %gs from the
5395         signal context.  For each signal handling function, two wrappers
5396         are required, one for a non-RT signal and one for a RT signal.
5397         * signal.c: For i386, add code to restore %gs from the signal
5398         context in pthread_sighandler and pthread_sighandler_rt.
5400 1999-10-17  Ulrich Drepper  <drepper@cygnus.com>
5402         * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add cast.
5404 1999-10-14  Ulrich Drepper  <drepper@cygnus.com>
5406         * pthread.c (__pthread_initial_thread): Pass argument to
5407         PTHREAD_START_ARGS_INITIALIZER.
5408         (__pthread_manager_thread): Likewise.
5410         * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add parameter to
5411         initialize function.
5413         * manager.c (pthread_handle_create): Remove p_startfct initialization.
5415         * internals.h (_pthread_descr_struct): We don't need p_startfct field.
5417 1999-10-12  Ulrich Drepper  <drepper@cygnus.com>
5419         * internals.h: Correct return types for __libc_read and __libc_write.
5421 1999-10-09  Andreas Jaeger  <aj@suse.de>
5423         * internals.h: Add __new_sem_post to get prototype in
5424         manager.c; include semaphore.h for needed types.
5426 1999-10-08  Ulrich Drepper  <drepper@cygnus.com>
5428         * manager.c (__pthread_manager) [REQ_POST]: Use __new_sem_post
5429         directly instead of calling sem_post which should not be necessary
5430         but is faster and might help in some case to work around problems.
5431         Patch by khendricks@ivey.uwo.ca [libc/1382].
5433 1999-10-08  Andreas Schwab  <schwab@suse.de>
5435         * sysdeps/pthread/Subdirs: New file.
5436         * Implies: Removed.
5438 1999-10-07  Ulrich Drepper  <drepper@cygnus.com>
5440         * Implies: New file.
5441         * internals.h (struct _pthread_descr_struct): Add p_startfct.
5442         * manager.c (pthread_handle_create): Initialize p_startfct.
5443         * pthread.c: Define __linuxthread_pthread_sizeof_descr variable.
5445 1999-09-25  Ulrich Drepper  <drepper@cygnus.com>
5447         * manager.c (__linuxthreads_pthread_threads_max): New variable.
5448         * specific.c (__linuxthreads_pthread_keys_max): New variable.
5449         (__linuxthreads_pthread_key_2ndlevel_size): New variable.
5451         * condvar.c (pthread_cond_timedwait_relative): Never return with
5452         EINTR.  Patch by Andreas Schwab.
5454 1999-09-19  Ulrich Drepper  <drepper@cygnus.com>
5456         * signals.c (sigaction): Correct last patch.  Don't select
5457         pthread_sighandler_rt based on the signal number but instead of
5458         the SA_SIGINFO flag.
5460 1999-09-23  Ulrich Drepper  <drepper@cygnus.com>
5462         * specific.c: Move definitions of struct pthread_key_struct and
5463         destr_function to ...
5464         * internals.h: ...here.
5466 1999-09-18  Ulrich Drepper  <drepper@cygnus.com>
5468         * pthread.c (pthread_handle_sigrestart_rt): New function.  Use
5469         this instead of pthread_handle_sigrestart if the signal is an RT
5470         signal.
5472         * signals.c: Handle passing through of sighandler arguments also
5473         for real-time signals.
5475 1999-09-03  Andreas Schwab  <schwab@suse.de>
5477         * ptfork.c (__fork): Renamed from fork and use __libc_fork.  Add
5478         fork as weak alias.
5479         (__vfork): New function, alias vfork.
5480         * Versions: Export __fork, vfork, and __vfork in libpthread.
5482 1999-08-23  Andreas Schwab  <schwab@suse.de>
5484         * signals.c (pthread_sighandler): Add SIGCONTEXT_EXTRA_ARGS to
5485         call to signal handler.
5487 1999-08-20  Ulrich Drepper  <drepper@cygnus.com>
5489         * pthread.c (__pthread_reset_main_thread): Undo last change.
5490         (__pthread_kill_other_threads_np): Reset signal handlers for the
5491         signals we used in the thread implementation here.
5493 1999-08-19  Ulrich Drepper  <drepper@cygnus.com>
5495         * pthread.c (__pthread_reset_main_thread): Reset signal handlers
5496         for the signals we used in the thread implementation [PR libc/1234].
5498         * Versions: Export __pthread_kill_other_threads_np from libpthread
5499         for GLIBC_2.1.2.
5501         * signals.c: Pass sigcontext through wrapper to the user function.
5503 1999-08-01  Ulrich Drepper  <drepper@cygnus.com>
5505         * Versions [ld.so] (GLIBC_2.0): Export __libc_internal_tsd_get and
5506         __libc_internal_tsd_set.
5508 1999-07-29  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
5510         * manager.c: Remove inclusion of <linux/tasks.h> since it's not
5511         needed anymore.
5513 1999-07-16  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
5515         * internals.h: Align _pthread_descr_struct to 32 bytes.
5516         Reported by Tim Hockin <thockin@cobaltnet.com>, close PR
5517         libc/1206.
5519 1999-07-09  Ulrich Drepper  <drepper@cygnus.com>
5521         * oldsemaphore.c (sem_compare_and_swap): Fix use of compare and
5522         swap function.
5524 1999-07-09  Cristian Gafton  <gafton@redhat.com>
5526         * Makefile (libpthread-routines): Add oldsemaphore routine.
5527         * Versions: Add sem_destroy, sem_getvalue, sem_init, sem_post,
5528         sem_trywait, and sem_wait to GLIBC_2.1.
5529         * oldsemaphore.c: New file.
5530         * semaphore.c: Add default_symbol_versions for the changed functions.
5531         (__new_sem_init): Rename from sem_init.
5532         (__new_sem_post): Rename from sem_post.
5533         (__new_sem_wait): Rename from sem_wait.
5534         (__new_sem_trywait): Rename from sem_trywait.
5535         (__new_sem_getvalue): Rename from sem_getvalue.
5536         (__new_sem_destroy): Rename from sem_destroy.
5538 1999-06-23  Robey Pointer  <robey@netscape.com>
5540         * internals.h: Added p_nextlock entry to separate queueing for a
5541         lock from queueing for a CV (sometimes a thread queues on a lock
5542         to serialize removing itself from a CV queue).
5543         * pthread.c: Added p_nextlock to initializers.
5544         * spinlock.c: Changed to use p_nextlock instead of p_nextwaiting.
5546 1999-07-09  Ulrich Drepper  <drepper@cygnus.com>
5548         * manager.c (pthread_handle_create): Free mmap region after stack
5549         if clone failed.  Patch by Kaz Kylheku <kaz@ashi.FootPrints.net>.
5551 1999-05-23  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
5553         * man/pthread_cond_init.man: Correct example.
5554         Reported by Tomas Berndtsson <tomas@nocrew.org>.
5556         * linuxthreads.texi (Condition Variables): Likewise.
5558 1999-05-18  Jakub Jelinek  <jj@ultra.linux.cz>
5560         * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): Use
5561         casx not cas, also successful casx returns the old value in rd
5562         and not the new value.
5564 1999-05-16  Xavier Leroy  <Xavier.Leroy@inria.fr>
5566         * manager.c: If pthread_create() is given a NULL attribute
5567         and the thread manager runs with a realtime policy, set the
5568         scheduling policy of the newly created thread back to SCHED_OTHER.
5569         * manager.c: If the PTHREAD_INHERIT_SCHED attribute is given,
5570         initialize the schedpolicy field of new_thread->p_start_args
5571         to that of the calling thread.
5573 1999-04-29  Ulrich Drepper  <drepper@cygnus.com>
5575         * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): cas
5576         instruction does not allow memory element to use offset.
5578 1999-04-28  Ulrich Drepper  <drepper@cygnus.com>
5580         * manager.c (pthread_allocate_stack): Optimize initialization of new
5581         thread descriptor.
5583         * sysdeps/pthread/bits/libc-lock.h (__libc_lock_define_initialized):
5584         Don't use initializer since it is all zeroes.
5585         (__libc_once_define): Likewise.
5587 1999-04-16  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
5589         * sysdeps/arm/Implies: Removed since cmpxchg/no-cmpxchg
5590         doesn't exist anymore.
5591         * sysdeps/i386/Implies: Likewise.
5592         * sysdeps/m68k/Implies: Likewise.
5593         * sysdeps/mips/Implies: Likewise.
5594         * sysdeps/powerpc/Implies: Likewise.
5595         * sysdeps/sparc/sparc32/Implies: Likewise.
5596         * sysdeps/sparc/sparc64/Implies: Likewise.
5598 1999-04-15  Ulrich Drepper  <drepper@cygnus.com>
5600         * sysdeps/alpha/bits/semaphore.h: Removed.
5601         * sysdeps/powerpc/bits/semaphore.h: Removed.
5602         * sysdeps/pthread/cmpxchg/bits/semaphore.h: Removed.
5603         * sysdeps/pthread/no-cmpxchg/bits/semaphore.h: Removed.
5604         * Makefile (headers): Remove bits/semaphore.h.
5606         * semaphore.h: Define _pthread_descr if necessary.
5607         Don't include limits.h.  Define SEM_VALUE_MAX directly.
5608         Define SEM_FAILED.
5609         (sem_t): Protect element names with leading __.
5610         Add declarations for sem_close, sem_open, and sem_unlink.
5611         * semaphore.c: Adjust all functions for new element names.
5612         Define sem_close, sem_open, and sem_unlink.
5613         * Versions (libthread): Add sem_close, sem_open, and sem_unlink for
5614         GLIBC_2.1.1.
5615         * sysdeps/pthread/bits/pthreadtypes.h: Define _pthread_descr only if
5616         necessary.
5618 1999-03-16  H.J. Lu  <hjl@gnu.org>
5620         * specific.c (pthread_key_delete): Check th->p_terminated to see
5621         if the thread is running.
5623         * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set):
5624         Added to GLIBC_2.0 for libc.so.
5626 1999-02-12  H.J. Lu  <hjl@gnu.org>
5628         * Versions (__libc_current_sigrtmin, __libc_current_sigrtmax,
5629         __libc_allocate_rtsig): Added to GLIBC_2.1.
5631         * internals.h (DEFAULT_SIG_RESTART): Removed.
5632         (DEFAULT_SIG_CANCEL): Removed.
5634         * pthread.c (init_rtsigs, __libc_current_sigrtmin,
5635         __libc_current_sigrtmax, __libc_allocate_rtsig): New functions.
5636         (__pthread_sig_restart, __pthread_sig_cancel,
5637         __pthread_sig_debug): Initialized.
5638         (pthread_initialize): Call init_rtsigs () to initialize
5639         real-time signals.
5641 1999-02-03  H.J. Lu  <hjl@gnu.org>
5643         * manager.c (__pthread_manager): Do block __pthread_sig_debug.
5644         Don't restart the thread which sent REQ_DEBUG.
5645         (pthread_start_thread): Check if __pthread_sig_debug > 0
5646         before debugging.
5648         * pthread.c (__pthread_initialize_manager): Suspend ourself
5649         after sending __pthread_sig_debug to gdb instead of
5650         __pthread_sig_cancel.
5652 1999-01-24  H.J. Lu  <hjl@gnu.org>
5654         * manager.c (__pthread_manager): Delete __pthread_sig_debug
5655         from mask if __pthread_sig_debug > 0.
5656         (pthread_handle_create): Increment __pthread_handles_num.
5658         * manager.c (pthread_handle_create): Don't pass CLONE_PTRACE to clone.
5659         * pthread.c (__pthread_initialize_manager): Likewise.
5661         * pthread.c (pthread_initialize): Use __libc_allocate_rtsig (1)
5662         instead of __libc_allocate_rtsig (2).
5663         (__pthread_initialize_manager): Send __pthread_sig_debug to gdb
5664         instead of __pthread_sig_cancel.
5665         (pthread_handle_sigdebug): Fix comments.
5667 1999-01-21  Ulrich Drepper  <drepper@cygnus.com>
5669         * manager.c (pthread_allocate_stack): Set
5670         __pthread_nonstandard_stacks if user-specified stack is used.
5672 1999-01-16  Ulrich Drepper  <drepper@cygnus.com>
5674         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _LFS_ASYNCHRONOUS_IO,
5675         _LFS_LARGEFILE, _LFS64_LARGEFILE, and _LFS64_STDIO from Unix98.
5677 1999-01-07  Xavier Leroy  <Xavier.Leroy@inria.fr>
5679         * pthread.c: Use a third signal __pthread_sig_debug distinct
5680         from __pthread_sig_cancel to notify gdb when a thread is
5681         created
5682         * manager.c: Likewise.
5683         * internals.h: Likewise.
5684         * signals.c: The implementation of sigwait(s) assumed that
5685         all signals in s have signal handlers already attached.
5686         This is not required by the standard, so make it work
5687         also if some of the signals have no handlers.
5689 1999-01-05  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
5691         * linuxthreads.texi: Remove pointers from first @node.  Move old
5692         @node spec inside comment.
5694 1998-12-31  Ulrich Drepper  <drepper@cygnus.com>
5696         * sysdeps/pthread/bits/stdio-lock.h: Define _IO_lock_lock and
5697         _IO_lock_unlock.
5699 1998-12-29  Ulrich Drepper  <drepper@cygnus.com>
5701         * semaphore.c (sem_trywait): Don't forget to unlock the semaphore
5702         lock.  Patch by Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>.
5704 1998-12-21  Ulrich Drepper  <drepper@cygnus.com>
5706         * manager.c: Threads now send __pthread_sig_cancel on termination.
5707         Change clone call and signal masks.
5708         * thread.c (pthread_handle_sigrestart): Remove special code for
5709         manager.
5710         (pthread_handle_sigcancel): In manager thread call
5711         __pthread_manager_sighandler.
5712         * sysdeps/i386/pt-machine.h (__compare_and_swap): Add memory clobber.
5713         * sysdeps/i386/i686/pt-machine.h: Likewise.
5714         Patches by Xavier Leroy.
5716 1998-12-14  Ulrich Drepper  <drepper@cygnus.com>
5718         * spinlock.c (__pthread_unlock): Don't crash if called for an
5719         untaken mutex.  Reported by Ruslan V. Brushkoff <rus@Snif.Te.Net.UA>.
5721         * Examples/ex6.c: Unbuffer stdout and reduce sleep time to reduce
5722         overall runtime.
5724 1998-12-13  Ulrich Drepper  <drepper@cygnus.com>
5726         * Examples/ex3.c: Wait until all threads are started before
5727         searching for the number to avoid race condition on very fast
5728         systems.
5730 1998-12-08  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
5732         * sysdeps/pthread/pthread.h: Remove __pthread_setcanceltype
5733         declaration since it's not needed.
5735         * sysdeps/pthread/pthread.h: Move internal functions to ...
5736         * internals.h: ...here.
5738 1998-12-02  H.J. Lu  <hjl@gnu.org>
5740         * pthread.c (__pthread_sig_restart): Initiliaze to 0 if
5741         SIGRTMIN is defined.
5742         (__pthread_sig_cancel): Likewise.
5744 1998-12-01  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
5746         * wrapsyscall.c: Include <sys/mman.h> for msync,
5747         <stdlib.h> for system and <termios.h> for tcdrain prototype.
5748         Correct msync declaration.
5750 1998-11-29  Roland McGrath  <roland@baalperazim.frob.com>
5752         * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_define, __libc_tsd_get,
5753         __libc_tsd_set): New macros for new interface.
5754         * no-tsd.c: New file, provide uninitialized defns of
5755         __libc_internal_tsd_get and __libc_internal_tsd_set.
5756         * Makefile (routines): Add no-tsd.
5758 1998-10-12  Roland McGrath  <roland@baalperazim.frob.com>
5760         * internals.h: Include <bits/libc-tsd.h>, not <bits/libc-lock.h>.
5761         * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
5762         __libc_internal_tsd_set): Move decls to ...
5763         * sysdeps/pthread/bits/libc-tsd.h: New file for __libc_internal_tsd_*
5764         declarations.
5766         * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
5767         __libc_internal_tsd_set): Make these pointers to functions, not
5768         functions; remove #pragma weak decls for them.
5769         * specific.c (__libc_internal_tsd_get, __libc_internal_tsd_set):
5770         Define static functions and initialized pointers to them.
5772 1998-11-18  Ulrich Drepper  <drepper@cygnus.com>
5774         * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES.
5775         (CFLAGS-specific.c): Likewise.
5776         (CFLAGS-pthread.c): Likewise.
5777         (CFLAGS-ptfork.c): Likewise.
5778         (CFLAGS-cancel.c): Likewise.
5779         * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions
5780         as weak references if __NO_WEAK_PTHREAD_ALIASES is defined.
5782         * mutex.c (pthread_mutex_init): Define as strong symbol.
5783         (pthread_mutex_destroy): Likewise.
5784         (pthread_mutex_trylock): Likewise.
5785         (pthread_mutex_lock): Likewise.
5786         (pthread_mutex_unlock): Likewise.
5787         (pthread_mutexattr_init): Likewise.
5788         (pthread_mutexattr_destroy): Likewise.
5789         (pthread_once): Likewise.
5790         * ptfork.c (pthread_atfork): Likewise.
5791         * specific.c (pthread_key_create): Likewise.
5792         (pthread_setspecific): Likewise.
5793         (pthread_getspecific): Likewise.
5795 1998-11-15  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
5797         * linuxthreads.texi: Fix punctuation after xref.
5799 1998-11-10  H.J. Lu  <hjl@gnu.org>
5801         * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine NR_OPEN
5802         if it is defined in <linux/limits.h>.
5804 1998-10-29 14:28  Ulrich Drepper  <drepper@cygnus.com>
5806         * spinlock.h (__pthread_trylock): Define inline.
5807         (__pthread_lock): Add extra parameter to declaration.  Declare
5808         using internal_function.
5809         (__pthread_unlock): Declare using internal_function.
5810         * spinlock.c (__pthread_lock): Add new parameter.  Use it instead
5811         of local variable self.  Avoid recomputing self.  Define using
5812         internal_function.
5813         (__pthread_trylock): Remove.
5814         (__pthread_unlock): Define using internal_function.
5815         * cancel.c: Adjust for __pthread_lock interface change.  Use already
5816         computed self value is possible.
5817         * condvar.c: Likewise.
5818         * join.c: Likewise.
5819         * manager.c: Likewise.
5820         * mutex.c: Likewise.
5821         * pthread.c: Likewise.
5822         * rwlock.c: Likewise.
5823         * semaphore.c: Likewise.
5824         * signals.c: Likewise.
5826 1998-10-27 13:46  Ulrich Drepper  <drepper@cygnus.com>
5828         * sysdeps/pthread/pthread.h (struct _pthread_cleanup_buffer): Prepend
5829         __ to field names of the struct.
5830         * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_fastlock):
5831         Likewise.
5832         (pthread_attr_t): Likewise.
5833         (pthread_cond_t): Likewise.
5834         (pthread_condattr_t): Likewise.
5835         (pthread_mutex_t): Likewise.
5836         (pthread_mutexattr_t): Likewise.
5837         (pthread_rwlock_t): Likewise.
5838         (pthread_rwlockattr_t): Likewise.
5839         * attr.c: Adjust for pthread.h and pthreadtypes.h change.
5840         * cancel.c: Likewise.
5841         * condvar.c: Likewise.
5842         * manager.c: Likewise.
5843         * mutex.c: Likewise.
5844         * pthread.c: Likewise.
5845         * ptlongjmp.c: Likewise.
5846         * rwlock.c: Likewise.
5847         * spinlock.c: Likewise.
5849 1998-10-09  Ulrich Drepper  <drepper@cygnus.com>
5851         * sysdeps/i386/pt-machine.h (get_eflags, set_eflags): Mark these
5852         also with PT_EI.
5854         * sysdeps/i386/i686/pt-machine.h: Remove unused inline
5855         definitions.
5857         * Makefile (libpthread-routines): Add pt-machine.
5858         * pt-machine.c: New file.
5859         * sysdeps/alpha/pt-machine.h: Define PT_EI as extern inline is not
5860         yet defined.  Use PT_EI in extern inline definitions.
5861         * sysdeps/arm/pt-machine.h: Likewise.
5862         * sysdeps/i386/pt-machine.h: Likewise.
5863         * sysdeps/i386/i686/pt-machine.h: Likewise.
5864         * sysdeps/m68k/pt-machine.h: Likewise.
5865         * sysdeps/mips/pt-machine.h: Likewise.
5866         * sysdeps/powerpc/pt-machine.h: Likewise.
5867         * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
5868         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
5870 1998-10-02  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
5872         * semaphore.h: Include <sys/types.h> so that _pthread_descr
5873         is declared.
5875 1998-09-15  David S. Miller  <davem@pierdol.cobaltmicro.com>
5877         * sysdeps/sparc/sparc32/pt-machine.h (INIT_THREAD_SELF): Add nr
5878         argument.
5879         * sysdeps/sparc/sparc64/pt-machine.h (INIT_THREAD_SELF): Likewise.
5881 1998-09-12 14:24 -0400  Zack Weinberg  <zack@rabi.phys.columbia.edu>
5883         * sysdeps/unix/sysv/linux/bits/sigthread.h: Add multiple inclusion
5884         guard.
5886 1998-09-02 11:08  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
5888         * signals.c (sigaction): Check that sig is less than NSIG to avoid
5889         array index overflow.
5891 1998-09-06 10:56  Ulrich Drepper  <drepper@cygnus.com>
5893         * sysdeps/pthread/semaphore.h: New file.
5895 1998-09-06 09:08  Ulrich Drepper  <drepper@cygnus.com>
5897         * sysdeps/pthread/bits/libc-lock.h (enum __libc_tsd_key_t): Add
5898         _LIBC_TSD_KEY_DL_ERROR.
5900 1998-08-31  Ulrich Drepper  <drepper@cygnus.com>
5902         * sysdeps/i386/i686/pt-machine.h (testandset): Add memory clobber.
5903         * sysdeps/i386/pt-machine.h: Likewise.
5904         Suggested by Roland McGrath.
5906 1998-08-28 13:58  Ulrich Drepper  <drepper@cygnus.com>
5908         * internals.h: Also define THREAD_GETMEM_NC and THREAD_SETMEM_NC to
5909         access thread data with non-constant offsets.
5910         * specific.c: Use THREAD_GETMEM_NC and THREAD_SETMEM_NC where
5911         necessary.
5913         * sysdeps/i386/useldt.h: Fix typo.  Add THREAD_GETMEM_NC and
5914         THREAD_SETMEM_NC definitions.
5916         * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM_NC and
5917         THREAD_SETMEM_NC.
5918         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
5920 1998-08-26 15:46  Ulrich Drepper  <drepper@cygnus.com>
5922         * internals.h: Define THREAD_GETMEM and THREAD_SETMEM to default if
5923         not already defined.
5924         (struct _pthread_descr_struct): Add p_self and p_nr field.
5925         * manager.c (__pthread_handles): Define second element to point
5926         to manager thread.
5927         (__pthread_handles_num): Initialize to 2.
5928         (__pthread_manager): Use INIT_THREAD_SELF with two arguments.
5929         (pthread_start_thread): Likewise.
5930         (pthread_handle_create): Start search for free slot at entry 2.
5931         Initialize new fields p_self and p_nr.
5932         Call __clone with CLONE_PTRACE if available.
5933         (pthread_free): Call FREE_THREAD_SELF if available.
5934         * pthread.c (__pthread_initial_thread): Initialize new fields.
5935         (__pthread_manager_thread): Likewise.
5936         (__pthread_initialize_manager): Call __clone with CLONE_PTRACE.
5938         * cancel.c: Use THREAD_GETMEM and THREAD_SETMEM to access the
5939         elements of the thread descriptor.
5940         * condvar.c: Likewise.
5941         * errno.c: Likewise.
5942         * join.c: Likewise.
5943         * manager.c: Likewise.
5944         * pthread.c: Likewise.
5945         * ptlongjmp.c: Likewise.
5946         * semaphore.c: Likewise.
5947         * signals.c: Likewise.
5948         * specific.c: Likewise.
5949         * spinlock.c: Likewise.
5951         * sysdeps/alpha/pt-machine.h (INIT_THREAD_SELF): Add extra parameter.
5953         * sysdeps/i386/useldt.h: New file.
5954         * sysdeps/i386/i686/pt-machine.h: Show how to use this file.
5956         * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM and
5957         THREAD_SETMEM using __thread_self.
5958         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
5960 1998-08-24  Geoff Keating  <geoffk@ozemail.com.au>
5962         * spinlock.c (__pthread_lock): Reset p_nextwaiting to NULL if it
5963         turned out that we didn't need to queue after all.
5965 1998-08-22  Geoff Keating  <geoffk@ozemail.com.au>
5967         * sysdeps/powerpc/pt-machine.h: Remove testandset, it's not used
5968         and wastes space; correct types.
5970 1998-08-08 11:18  H.J. Lu  <hjl@gnu.org>
5972         * signals.c (sigaction): Handle NULL argument.
5974 1998-08-04  Ulrich Drepper  <drepper@cygnus.com>
5976         * sysdeps/unix/sysv/linux/bits/sigthread.h: Use __sigset_t instead
5977         of sigset_t.
5979 1998-08-02  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
5981         * Makefile (linuxthreads-version): Extract correct number from
5982         Banner.
5984 1998-07-29  Xavier Leroy  <Xavier.Leroy@inria.fr>
5986         * Banner: Bump version number to 0.8
5987         * FAQ.html: Many updates, in particular w.r.t. debugging.
5988         * manager.c: Support for non-default stacksize for
5989         LinuxThreads-allocated stacks;
5990         don't use guard pages for stacks with default size, rely on
5991         rlimit(RLIMIT_STACK) instead (it's cheaper).
5992         * attr.c: Likewise.
5993         * cancel.c: Use __pthread_sig_cancel and __pthread_sig_restart
5994         everywhere instead of PTHREAD_SIG_CANCEL and PTHREAD_SIG_RESTART.
5995         * condvar.c: Likewise.
5996         * internals.h: Likewise.
5997         * restart.h: Likewise.
5998         * signals.c: Likewise.
5999         * pthread.c: Likewise; set rlimit(RLIMIT_STACK) as we need it.
6001 1998-07-23  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6003         * weaks.c: Define pthread_mutexattr_[sg]ettype instead of
6004         __pthread_mutexattr_[sg]ettype.  Add more weak aliases.
6005         * Versions: Put __pthread_mutexattr_settype under version
6006         GLIBC_2.0.  Don't export __pthread_mutexattr_setkind_np and
6007         __pthread_mutexattr_gettype.
6009 1998-07-23  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6011         * sysdeps/pthread/bits/libc-lock.h: Make
6012         __pthread_mutexattr_settype weak.  Don't make
6013         __pthread_mutexattr_setkind_np weak.
6015 1998-07-16 10:52  Ulrich Drepper  <drepper@cygnus.com>
6017         * manager.c (pthread_handle_create): Check whether sched_setscheduler
6018         call can succeed here.
6020         * mutex.c: Define __pthread_mutexattr_settype and make
6021         __pthread_mutexattr_setkind_np an alias.
6022         Likewise for __pthread_mutexattr_gettype.
6024 1998-07-15 11:00 -0400  Zack Weinberg  <zack@rabi.phys.columbia.edu>
6026         * attr.c (pthread_attr_setschedpolicy): Don't check whether caller
6027         is root.
6029 1998-07-14 19:38  Ulrich Drepper  <drepper@cygnus.com>
6031         * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_end.
6033 1998-07-11  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
6035         * Examples/ex6.c: Include <unistd.h> for usleep.
6037 1998-06-13 11:04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6039         * Examples/ex4.c (main): Use exit, not pthread_exit.
6041 1998-07-09 13:39  Ulrich Drepper  <drepper@cygnus.com>
6043         * Versions: Add __pthread_mutexattr_gettype and
6044         __pthread_mutexattr_settype.
6045         * lockfile.c: Use __pthread_mutexattr_settype instead of
6046         __pthread_mutexattr_setkind_np.
6047         * mutex.c: Define __pthread_mutexattr_gettype and
6048         __pthread_mutexattr_settype.
6049         * weak.c: Likewise.
6050         * sysdeps/pthread/pthread.h: Declare __pthread_mutexattr_gettype and
6051         __pthread_mutexattr_settype.
6052         * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init_recursive):
6053         Use __pthread_mutexattr_settype.
6055 1998-07-08 22:26  Ulrich Drepper  <drepper@cygnus.com>
6057         * Versions: Add pthread_mutexattr_gettype, pthread_mutexattr_settype.
6058         * mutex.c: Define weak alias pthread_mutexattr_gettype and
6059         pthread_mutexattr_settype.
6060         * sysdeps/pthread/pthread.h: Declare these functions.
6061         Move pthread_sigmask and pthread_kill declaration in separate header.
6062         * sysdeps/unix/sysv/linux/bits/sigthread.h: New file.
6064 1998-07-07 15:20  Ulrich Drepper  <drepper@cygnus.com>
6066         * Makefile: Add rules to compile and run tests.
6067         * Examples/ex1.c: Little changes to fix warnings.
6068         * Examples/ex2.c: Likewise.
6069         * Examples/ex3.c: Likewise.
6070         * Examples/ex4.c: Likewise.
6071         * Examples/ex5.c: Likewise.
6072         * Examples/ex6.c: New file.
6074 1998-07-05 11:54  Ulrich Drepper  <drepper@cygnus.com>
6076         * Versions: Add pthread_attr_init to GLIBC_2.1 version in libc.
6078 1998-07-01  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
6080         * attr.c: Include <string.h>.
6082 1998-06-30 11:47  Ulrich Drepper  <drepper@cygnus.com>
6084         * attr.c: Include errno.h.  Use memcpy to copy sched_param.
6085         * internals.h: Include limits.h.
6086         * manager.c: Use memcpy to copy sched_param.
6087         * ptfork.c: Include errno.h.
6088         * pthread.c: Likewise.
6089         * semaphore.c: Likewise.
6090         * specific.c: Likewise.
6091         * spinlock.h: Likewise.
6092         * sysdeps/pthread/pthread.h: Include only allowed headers.  Move
6093         type definition to ...
6094         * sysdeps/pthread/bits/pthreadtypes.h: ...here.  New file.
6096 1998-06-29 12:34  Ulrich Drepper  <drepper@cygnus.com>
6098         * sysdeps/pthread/pthread.h: Use __PMT not __P for function pointers.
6100         * sysdeps/pthread/pthread.h: Define various PTHREAD_* symbols also
6101         as macros as demanded in POSIX.1, Annex C.
6103 1998-06-29 12:29  Ulrich Drepper  <drepper@cygnus.com>
6105         * internals.h (struct pthread_request): For free use pthread_t
6106         instead of pthread_descr.
6107         * join.c (pthread_join): Pass thread_id, not th to manager.
6108         (pthread_detach): Likewise.
6109         * manager.c (__pthread_manager): Except thread ID in FREE_REQ case.
6110         (pthread_exited): Remove detached queue code.
6111         (pthread_handle_free): Expect thread ID parameter and use it to
6112         validate the thread decsriptor.  Don't use detached queue.
6113         Patches by Xavier Leroy.
6115 1998-06-27  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6117         * libpthread.map: Export accept, longjmp, sigaction, siglongjmp,
6118         _IO_flockfile, _IO_ftrylockfile, _IO_funlockfile,
6119         __pthread_atfork, __pthread_key_create, __pthread_once.
6120         * internals.h: Doc fix.
6121         * pthread.c (__pthread_initialize): Define again.
6123 1998-06-26  Ulrich Drepper  <drepper@cygnus.com>
6125         * manager.c (pthread_exited): If thread is not detached put it on
6126         special list.
6127         (pthread_handle_free): If thread is not on list with living threads
6128         search on list with detached threads.
6130         * sysdeps/pthread/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Correct
6131         for new definition of pthread_rwlock_t.
6133         * spinlock.c: Correct test whether to compile
6134         __pthread_compare_and_swap or not.
6136 1998-06-25 19:27  Ulrich Drepper  <drepper@cygnus.com>
6138         * attr.c: Finish user stack support.  Change locking code to be safe
6139         in situations with different priorities.
6140         * cancel.c: Likewise.
6141         * condvar.c: Likewise.
6142         * internals.h: Likewise.
6143         * join.c: Likewise.
6144         * manager.c: Likewise.
6145         * mutex.c: Likewise.
6146         * pthread.c: Likewise.
6147         * ptlongjmp.c: Likewise.
6148         * queue.h: Likewise.
6149         * rwlock.c: Likewise.
6150         * semaphore.c: Likewise.
6151         * semaphore.h: Likewise.
6152         * signals.c: Likewise.
6153         * spinlock.c: Likewise.
6154         * spinlock.h: Likewise.
6155         * sysdeps/pthread/pthread.h: Likewise.
6156         Patches by Xavier Leroy.
6158         * sysdeps/i386/i686/pt-machine.h: New file.
6160 1998-06-25  Ulrich Drepper  <drepper@cygnus.com>
6162         * sysdeps/pthread/pthread.h: Make [sg]et_stacksize and
6163         [sg]et_stackaddr prototypes always available.
6165         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
6166         _POSIX_THREAD_ATTR_STACKSIZE and _POSIX_THREAD_ATTR_STACKADDR.
6168 1998-06-24  Ulrich Drepper  <drepper@cygnus.com>
6170         * manager.c (pthread_free): Undo patch from 980430.
6171         Reported by David Wragg <dpw@doc.ic.ac.uk>.
6173 1998-06-09 15:07  Ulrich Drepper  <drepper@cygnus.com>
6175         * manager.c: Define __pthread_manager_adjust_prio and use it to
6176         increase priority when needed.
6177         * internals.h: Add prototype for __pthread_manager_adjust_prio.
6178         * mutex.c: Optimize mutexes to wake up only one thread.
6179         * pthread.c: Move PID of manager for global variable in structure
6180         element.
6181         Patches by Xavier Leroy.
6183 1998-06-07 13:47  Ulrich Drepper  <drepper@cygnus.com>
6185         * sysdeps/pthread/bits/libc-lock.h: Optimize cleanup handlers a bit.
6187 1998-06-03  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
6189         * attr.c: Correct typo.
6191 1998-05-01  Ulrich Drepper  <drepper@cygnus.com>
6193         * manager.c (pthread_free): Unmap guard before the stack.
6194         Patch by Matthias Urlichs.
6196 1998-04-30  Ulrich Drepper  <drepper@cygnus.com>
6198         * manager.c (pthread_free): Detect already free child.
6199         Patch by Xavier Leroy, reported by Matthias Urlichs.
6201 1998-04-23  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6203         * Makefile (linuxthreads-version): Renamed back from
6204         libpthread-version.
6206 1998-04-21  Ulrich Drepper  <drepper@cygnus.com>
6208         * ptlongjmp.c: Add prototypes for __libc_siglongjmp and
6209         __libc_longjmp.
6211 1998-04-20 14:55  Ulrich Drepper  <drepper@cygnus.com>
6213         * Makefile (libpthread-routines): Add ptlongjmp and spinlock.
6214         * internals.h: Add definitions for new spinlock implementation.
6215         * ptlongjmp.c: New file.
6216         * spinlock.c: New file.
6217         * spinlock.h (acquire): Don't reschedule using __sched_yield, use
6218         new function __pthread_acquire to prevent deadlocks with thread
6219         with different priorities.
6220         Patches by Xavier Leroy <Xavier.Leroy@inria.fr>.
6222 1998-03-16  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6224         * manager.c (__pthread_manager): Reduce first argument to select
6225         to include just the needed file descriptor.
6227 1998-03-17 00:06  Ulrich Drepper  <drepper@cygnus.com>
6229         * manager.c: Fix last patch which caused core dumps.
6231         * pthread.c: Correctly handle missing SIGRTMIN.
6233 1998-03-15  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6235         * libpthread.map: Add __libc_internal_tsd_get and
6236         __libc_internal_tsd_set.  Add missing cancelable functions. Export
6237         libc internal versions of the cancelable functions.
6239 1998-03-13 16:51  Ulrich Drepper  <drepper@cygnus.com>
6241         * weaks.c: Define pthread_attr_init as GLIBC_2.0 and GLIBC_2.1.
6243 1998-03-13 00:46  Ulrich Drepper  <drepper@cygnus.com>
6245         * attr.c: Implement pthread_attr_[gs]etguardsize,
6246         pthread_attr_[gs]setstackaddr, pthread_attr_[gs]etstacksize.
6247         Change pthread_attr_init to have two interfaces.
6248         * internals.h (struct _pthread_descr_struct): Add new fields for
6249         above functions.
6250         * libpthread.map: Add names in GLIBC_2.1 section.
6251         * manager.c (pthread_handle_create): Implement guardsize and
6252         user stack.
6253         (pthread_free): Likewise.
6254         * pthread.c (pthread_create): Add new interface for changed
6255         pthread_attr_t.
6256         * sysdeps/pthread/pthread.h: Add prototypes for new functions.
6257         * sysdeps/unix/sysv/linux/bits/local_lim.h: Add definition of
6258         PTHREAD_STACK_MIN.
6260 1998-03-11 00:42  Wolfram Gloger  <wmglo@dent.med.uni-muenchen.de>
6262         * manager.c: Enable resetting of the thread scheduling policy
6263         to SCHED_OTHER when the parent thread has a different one.
6265 1998-02-01 13:51  Ulrich Drepper  <drepper@cygnus.com>
6267         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
6268         _POSIX_ASYNCHRONOUS_IO.
6270         * sysdeps/pthread/pthread.h: Define bits for Unix98 variants of
6271         mutexes.
6272         * mutex.c: Implement new mutex types.
6274         * internals.h: Include <signal.h>.
6276         * libpthread.map: Add __erno_location and __h_errno_location.
6278         * errno.c: Return pointer to variable actually in use.  This might
6279         not be the one in the thread structure.
6280         * internals.h (struct _pthread_descr_struct): Add new fields p_errnop
6281         and p_h_errnop.
6282         * manager.c (__pthread_manager): Set p_errnop and p_h_errnop member
6283         of manager thread structure.
6284         (pthread_handle_create): Set p_errnop and p_h_errnop members for new
6285         thread.
6286         * pthread.c: Adapt initializer for thread structures.
6287         (__pthread_initial_thread): Set p_errnop and p_h_errnop member.
6288         (__pthread_reset_main_thread): Reset p_errnop and p_h_errnop of
6289         current thread to global variables.
6291 1998-01-31 17:27  Ulrich Drepper  <drepper@cygnus.com>
6293         * rwlock.c: New file.
6294         * Makefile (libpthread-routines): Add rwlock.
6295         * sysdeps/pthread/pthread.h: Define data structures and declare
6296         functions.
6297         * libpthread.map: Add new functions.
6299 1997-12-18 13:50  Philip Blundell  <pb@nexus.co.uk>
6301         * sysdeps/arm/pt-machine.h: New file; add ARM support.
6302         * sysdeps/arm/Implies: likewise.
6303         * README: Document it.
6305 1997-12-13  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6307         * signals.c: Remove unneeded initializer for sigwaited, saving a
6308         warning.
6310 1997-04-11 01:18  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6312         * semaphore.c (sem_init): Set sem_spinlock only if available.
6314 1997-12-04 01:48  Ulrich Drepper  <drepper@cygnus.com>
6316         * mutex.c: Implement PTHREAD_MUTEX_CHECKERROR.
6317         * sysdeps/pthread/pthread.h: Define PTHREAD_MUTEX_CHECKERROR.
6319         * Makefile: Update from LinuxThreads 0.7.
6320         * internals.h. Likewise.
6321         * manager.c: Likewise.
6322         * mutex.c: Likewise.
6323         * pthread.c: Likewise.
6324         * signals.c: Likewise.
6325         * specific.c: Likewise.
6326         * Examples/ex3.c: Likewise.
6328 1997-11-20 18:13  Ulrich Drepper  <drepper@cygnus.com>
6330         * pthread.c (__pthread_reset_main_thread): Close pipe only if still
6331         open.
6333 1997-10-29 05:38  Ulrich Drepper  <drepper@cygnus.com>
6335         * wrapsyscall.c: Add socket functions which are also cancelation
6336         points.
6338 1997-10-19 21:40  Wolfram Gloger  <wg@wolfram.dent.med.uni-muenchen.de>
6340         * specific.c (__libc_internal_tsd_set, __libc_internal_tsd_get):
6341         New functions for fast thread specific data within libc.
6343         * internals.h: Add new array p_libc_specific to struct
6344         _pthread_descr_struct.
6346         * sysdeps/pthread/bits/libc-lock.h: Declare new functions.
6348 1997-10-13 05:39  Ulrich Drepper  <drepper@cygnus.com>
6350         * semaphore.h: Add __BEGIN_DECLS/__END_DECLS.
6351         Reported by Ralf Corsepius <corsepiu@faw.uni-ulm.de>.
6353 1997-08-29 03:05  Ulrich Drepper  <drepper@cygnus.com>
6355         * internals.h (struct _pthread_descr_struct): Add definitions for
6356         two-level specific key handling.
6357         * manager.c (pthread_handle_create): Initialize specific memory array.
6358         * specific.c: Implement two-level key handling.
6359         * weaks.c: Don't provide dummy key handling.
6360         * sysdeps/pthread/bits/libc-lock.h: Typedef __libc_lock_t (no #define).
6361         Add definition of __libc_key_t.
6362         * sysdeps/unix/sysv/linux/bits/local_lim.h: Define PTHREAD_KEYS_MAX
6363         as 1024.
6364         Add definition of _POSIX_THREAD_DESTRUCTOR_ITERATIONS and
6365         PTHREAD_DESTRUCTOR_ITERATIONS.
6367         * manager.c (pthread_handle_create): Compare mmap result with
6368         MAP_FAILED.
6370         * ptfork.c: Rename to __pthread_atfork and make old name a weak alias.
6371         * sysdeps/pthread/bits/pthread.h: Add prototype for __pthread_atfork.
6373 1997-08-22 19:04  Richard Henderson  <rth@cygnus.com>
6375         sysdeps/sparc -> sysdeps/sparc/sparc32
6376         sysdeps/sparc64 -> sysdeps/sparc/sparc64
6378         * internals.h: Change definition of THREAD_SELF to be an expression,
6379         not a statement that did a return.
6380         * sysdeps/alpha/pt-machine.h (THREAD_SELF): Update accordingly.
6381         * sysdeps/sparc/sparc32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
6382         Follow Solaris and use a "system reserved" register (%g6) to hold
6383         the thread descriptor.
6384         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
6386 1997-08-03 00:09  Ulrich Drepper  <drepper@cygnus.com>
6388         * mutex.c: Correct pthread_once.  Patch by Xavier Leroy.
6389         * sysdeps/pthread/pthread.h: Add prototype for __pthread_once.
6390         * sysdeps/pthread/bits/pthread.h: Add macros for __libc_once.
6392         * semaphore.c: Include spinlock.h only when needed.
6394         * specific.c (__pthread_setsepcific, __pthread_getspecific): Reject
6395         keys for entries not in use.
6397         * weaks.c: Implement key handling functions for real.
6399 1997-06-29  01:04  Richard Henderson  <richard@gnu.ai.mit.edu>
6401         Initial sparc64-linux support:
6402         * sysdeps/sparc64/Implies: New file.
6403         * sysdeps/sparc64/pt-machine.h: Likewise.
6405 1997-06-29 00:48  Ulrich Drepper  <drepper@cygnus.com>
6407         * semaphore.c: Include spinlock.h at correct place.
6408         Patch by HJ Lu.
6410 1997-06-13 10:06  Richard Henderson  <rth@tamu.edu>
6412         The Great Bit File Move:
6413         * sysdeps/alpha/semaphorebits.h: -> .../bits/semaphore.h.
6414         * sysdeps/powerpc/semaphorebits.h: Likewise.
6415         * sysdeps/pthread/cmpxchg/semaphorebits.h: Likewise.
6416         * sysdeps/pthread/no-cmpxchg/semaphorebits.h: Likewise.
6417         * sysdeps/pthread/libc-lock.h: -> bits/
6418         * sysdeps/pthread/stdio-lock.h: Likewise.
6419         * sysdeps/unix/sysv/linux/local_lim.h: Likewise.
6420         * sysdeps/unix/sysv/linux/posix_opt.h: Likewise.
6421         * semaphore.h: Likewise.
6422         * sysdeps/pthread/pthread.h: Likewise.
6424         * lockfile.c: <foo.h> -> <bits/foo.h>.
6425         * semaphore.h: Likewise.
6427         * Makefile: (headers): foo.h -> bits/foo.h.
6428         * sysdeps/pthread/Makefile: Likewise.
6430 1997-04-11 01:18  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
6432         * semaphore.c (sem_init): Set sem_spinlock only if available.
6434         * sysdeps/m68k/pt-machine.h (testandset, __compare_and_swap): Fix
6435         asm constraints.
6437 1997-04-09 03:00  Ulrich Drepper  <drepper@cygnus.com>
6439         Update from LinuxThreads 0.6.
6441         * attr.c (pthread_attr_getdetachstate): Use __sched_get_priority_max
6442         and __sched_get_priority_min instead of names without `__'.
6444         * manager.c: Rewrite large parts to implement opaque pthread_t.
6446         * cancel.c: Adapt for opaque pthread_t type.
6447         * condvar.c: Likewise.
6448         * errno.c: Likewise.
6449         * join.c: Likewise.
6450         * mutex.c: Likewise.
6451         * pthread.c: Likewise.
6452         * signals.c: Likewise.
6453         * specific.c: Likewise.
6454         * restart.h: Likewise.
6455         * queue.h: Likewise.
6456         * Examples/ex3.c: Likewise.
6457         * Examples/ex4.c: Likewise.
6458         * sysdeps/pthread/pthread.h: Likewise.
6460         * pthread.c: Accumulate time for all threads in thread manager.
6462         * semaphore.c: Implement fallback implementation for architectures
6463         sometimes missing compare-exchange operations.
6465         * cancel.c (pthread_cancel): Validate handle argument.
6466         * join.c (pthread_join): Likewise.
6467         (pthread_detach): Likewise.
6468         * signals.c (pthread_kill): Likewise.
6470         * spinlock.h (acquire): Use __sched_yield not sched_yield.
6472         * queue.h (enqueue): Enqueue thread according to priority.
6474         * internals.c (struct pthread_start_args): New struct for passing
6475         args to cloning function.
6476         (struct _pthread): Rename to _pthread_descr_struct and adapt for
6477         opaque pthread_t.
6479         * Examples/Makefile (clean): Pass -f option to rm.
6481         * sysdeps/i386/pt-machine.h: Add check for compare-exchange instruction
6482         and define TEST_FOR_COMPARE_AND_SWAP.
6483         * sysdeps/i386/i486/pt-machine.h: Removed.
6485         * sysdeps/unix/sysv/linux/local_lim.h (PTHREAD_THREADS_MAX): Increase
6486         to 1024.
6488 1997-04-04 16:38  Ulrich Drepper  <drepper@cygnus.com>
6490         * restart.h (suspend): Clear p_signal before suspending.
6491         (suspend_with_cancellation): Likewise.
6492         Patch by Xavier Leroy <Xavier.Leroy@inria.fr>.
6494         * weaks.c: Make __pthread_key_create return 1.
6495         * sysdeps/pthread/libc-lock.h: Define __libc_key_create,
6496         __libc_getspecific, __libc_setspecific, and __libc_key_t.
6497         * sysdeps/pthread/stdio-lock.h: Don't care for implementation not
6498         using libio.
6500 1997-03-19 15:13  Miguel de Icaza  <miguel@nuclecu.unam.mx>
6502         * sysdeps/sparc/pt-machine (RELEASE): Fix.
6504 1997-03-01 07:55  Geoff Keating  <geoffk@ozemail.com.au>
6506         * sysdeps/powerpc/Implies: Added.
6507         * sysdeps/powerpc/pt-machine.h: Added.
6508         * sysdeps/powerpc/semaphorebits.h: Added.
6510 1997-01-22 01:22  Ulrich Drepper  <drepper@cygnus.com>
6512         * pthread.c (__pthread_initial_thread): Correct
6513         initializer.
6514         (__pthread_manager_thread): Likewise.
6515         Reported by Andreas Jaeger.
6517 1997-01-18 22:15  Richard Henderson  <rth@tamu.edu>
6519         Since sigset_t no longer fits in a register, we can't pass in the
6520         thread's initial mask so easily.  Take this opportunity to simplify
6521         the clone implementation by only accepting a single void* argument.
6523         * manager.c (__pthread_manager): Put thread vitals in the thread
6524         struct instead of as arguments through clone.
6525         (pthread_start_thread): Look for them there.
6526         * internals.h (struct _pthread): Add p_initial_fn,
6527         p_initial_fn_arg, p_initial_mask.  Fix __pthread_manager proto.
6528         * pthread.c (pthread_initialize_manager): Revise clone invocation.