Update.
[platform/upstream/glibc.git] / linuxthreads / ChangeLog
1 1999-08-19  Ulrich Drepper  <drepper@cygnus.com>
2
3         * Versions: Export __pthread_kill_other_threads_np from libpthread
4         for GLIBC_2.1.2.
5
6         * signals.c: Pass sigcontext through wrapper to the user function.
7
8 1999-08-01  Ulrich Drepper  <drepper@cygnus.com>
9
10         * Versions [ld.so] (GLIBC_2.0): Export __libc_internal_tsd_get and
11         __libc_internal_tsd_set.
12
13 1999-07-29  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
14
15         * manager.c: Remove inclusion of <linux/tasks.h> since it's not
16         needed anymore.
17
18 1999-07-16  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
19
20         * internals.h: Align _pthread_descr_struct to 32 bytes.
21         Reported by Tim Hockin <thockin@cobaltnet.com>, close PR
22         libc/1206.
23
24 1999-07-09  Ulrich Drepper  <drepper@cygnus.com>
25
26         * oldsemaphore.c (sem_compare_and_swap): Fix use of compare and
27         swap function.
28
29 1999-07-09  Cristian Gafton  <gafton@redhat.com>
30
31         * Makefile (libpthread-routines): Add oldsemaphore routine.
32         * Versions: Add sem_destroy, sem_getvalue, sem_init, sem_post,
33         sem_trywait, and sem_wait to GLIBC_2.1.
34         * oldsemaphore.c: New file.
35         * semaphore.c: Add default_symbol_versions for the changed functions.
36         (__new_sem_init): Rename from sem_init.
37         (__new_sem_post): Rename from sem_post.
38         (__new_sem_wait): Rename from sem_wait.
39         (__new_sem_trywait): Rename from sem_trywait.
40         (__new_sem_getvalue): Rename from sem_getvalue.
41         (__new_sem_destroy): Rename from sem_destroy.
42
43 1999-06-23  Robey Pointer  <robey@netscape.com>
44
45         * internals.h: Added p_nextlock entry to separate queueing for a
46         lock from queueing for a CV (sometimes a thread queues on a lock
47         to serialize removing itself from a CV queue).
48         * pthread.c: Added p_nextlock to initializers.
49         * spinlock.c: Changed to use p_nextlock instead of p_nextwaiting.
50
51 1999-07-09  Ulrich Drepper  <drepper@cygnus.com>
52
53         * manager.c (pthread_handle_create): Free mmap region after stack
54         if clone failed.  Patch by Kaz Kylheku <kaz@ashi.FootPrints.net>.
55
56 1999-05-23  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
57
58         * man/pthread_cond_init.man: Correct example.
59         Reported by Tomas Berndtsson <tomas@nocrew.org>.
60
61         * linuxthreads.texi (Condition Variables): Likewise.
62
63 1999-05-18  Jakub Jelinek  <jj@ultra.linux.cz>
64
65         * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): Use
66         casx not cas, also successful casx returns the old value in rd
67         and not the new value.
68
69 1999-05-16  Xavier Leroy  <Xavier.Leroy@inria.fr>
70
71         * manager.c: If pthread_create() is given a NULL attribute
72         and the thread manager runs with a realtime policy, set the
73         scheduling policy of the newly created thread back to SCHED_OTHER.
74         * manager.c: If the PTHREAD_INHERIT_SCHED attribute is given,
75         initialize the schedpolicy field of new_thread->p_start_args
76         to that of the calling thread.
77
78 1999-04-29  Ulrich Drepper  <drepper@cygnus.com>
79
80         * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): cas
81         instruction does not allow memory element to use offset.
82
83 1999-04-28  Ulrich Drepper  <drepper@cygnus.com>
84
85         * manager.c (pthread_allocate_stack): Optimize initialization of new
86         thread descriptor.
87
88         * sysdeps/pthread/bits/libc-lock.h (__libc_lock_define_initialized):
89         Don't use initializer since it is all zeroes.
90         (__libc_once_define): Likewise.
91
92 1999-04-16  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
93
94         * sysdeps/arm/Implies: Removed since cmpxchg/no-cmpxchg
95         doesn't exist anymore.
96         * sysdeps/i386/Implies: Likewise.
97         * sysdeps/m68k/Implies: Likewise.
98         * sysdeps/mips/Implies: Likewise.
99         * sysdeps/powerpc/Implies: Likewise.
100         * sysdeps/sparc/sparc32/Implies: Likewise.
101         * sysdeps/sparc/sparc64/Implies: Likewise.
102
103 1999-04-15  Ulrich Drepper  <drepper@cygnus.com>
104
105         * sysdeps/alpha/bits/semaphore.h: Removed.
106         * sysdeps/powerpc/bits/semaphore.h: Removed.
107         * sysdeps/pthread/cmpxchg/bits/semaphore.h: Removed.
108         * sysdeps/pthread/no-cmpxchg/bits/semaphore.h: Removed.
109         * Makefile (headers): Remove bits/semaphore.h.
110
111         * semaphore.h: Define _pthread_descr if necessary.
112         Don't include limits.h.  Define SEM_VALUE_MAX directly.
113         Define SEM_FAILED.
114         (sem_t): Protect element names with leading __.
115         Add declarations for sem_close, sem_open, and sem_unlink.
116         * semaphore.c: Adjust all functions for new element names.
117         Define sem_close, sem_open, and sem_unlink.
118         * Versions (libthread): Add sem_close, sem_open, and sem_unlink for
119         GLIBC_2.1.1.
120         * sysdeps/pthread/bits/pthreadtypes.h: Define _pthread_descr only if
121         necessary.
122
123 1999-03-16  H.J. Lu  <hjl@gnu.org>
124
125         * specific.c (pthread_key_delete): Check th->p_terminated to see
126         if the thread is running.
127
128         * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set):
129         Added to GLIBC_2.0 for libc.so.
130
131 1999-02-12  H.J. Lu  <hjl@gnu.org>
132
133         * Versions (__libc_current_sigrtmin, __libc_current_sigrtmax,
134         __libc_allocate_rtsig): Added to GLIBC_2.1.
135
136         * internals.h (DEFAULT_SIG_RESTART): Removed.
137         (DEFAULT_SIG_CANCEL): Removed.
138
139         * pthread.c (init_rtsigs, __libc_current_sigrtmin,
140         __libc_current_sigrtmax, __libc_allocate_rtsig): New functions.
141         (__pthread_sig_restart, __pthread_sig_cancel,
142         __pthread_sig_debug): Initialized.
143         (pthread_initialize): Call init_rtsigs () to initialize
144         real-time signals.
145
146 1999-02-03  H.J. Lu  <hjl@gnu.org>
147
148         * manager.c (__pthread_manager): Do block __pthread_sig_debug.
149         Don't restart the thread which sent REQ_DEBUG.
150         (pthread_start_thread): Check if __pthread_sig_debug > 0
151         before debugging.
152
153         * pthread.c (__pthread_initialize_manager): Suspend ourself
154         after sending __pthread_sig_debug to gdb instead of
155         __pthread_sig_cancel.
156
157 1999-01-24  H.J. Lu  <hjl@gnu.org>
158
159         * manager.c (__pthread_manager): Delete __pthread_sig_debug
160         from mask if __pthread_sig_debug > 0.
161         (pthread_handle_create): Increment __pthread_handles_num.
162
163         * manager.c (pthread_handle_create): Don't pass CLONE_PTRACE to clone.
164         * pthread.c (__pthread_initialize_manager): Likewise.
165
166         * pthread.c (pthread_initialize): Use __libc_allocate_rtsig (1)
167         instead of __libc_allocate_rtsig (2).
168         (__pthread_initialize_manager): Send __pthread_sig_debug to gdb
169         instead of __pthread_sig_cancel.
170         (pthread_handle_sigdebug): Fix comments.
171
172 1999-01-21  Ulrich Drepper  <drepper@cygnus.com>
173
174         * manager.c (pthread_allocate_stack): Set
175         __pthread_nonstandard_stacks if user-specified stack is used.
176
177 1999-01-16  Ulrich Drepper  <drepper@cygnus.com>
178
179         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _LFS_ASYNCHRONOUS_IO,
180         _LFS_LARGEFILE, _LFS64_LARGEFILE, and _LFS64_STDIO from Unix98.
181
182 1999-01-07  Xavier Leroy  <Xavier.Leroy@inria.fr>
183
184         * pthread.c: Use a third signal __pthread_sig_debug distinct
185         from __pthread_sig_cancel to notify gdb when a thread is
186         created
187         * manager.c: Likewise.
188         * internals.h: Likewise.
189         * signals.c: The implementation of sigwait(s) assumed that
190         all signals in s have signal handlers already attached.
191         This is not required by the standard, so make it work
192         also if some of the signals have no handlers.
193
194 1999-01-05  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
195
196         * linuxthreads.texi: Remove pointers from first @node.  Move old
197         @node spec inside comment.
198
199 1998-12-31  Ulrich Drepper  <drepper@cygnus.com>
200
201         * sysdeps/pthread/bits/stdio-lock.h: Define _IO_lock_lock and
202         _IO_lock_unlock.
203
204 1998-12-29  Ulrich Drepper  <drepper@cygnus.com>
205
206         * semaphore.c (sem_trywait): Don't forget to unlock the semaphore
207         lock.  Patch by Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>.
208
209 1998-12-21  Ulrich Drepper  <drepper@cygnus.com>
210
211         * manager.c: Threads now send __pthread_sig_cancel on termination.
212         Change clone call and signal masks.
213         * thread.c (pthread_handle_sigrestart): Remove special code for
214         manager.
215         (pthread_handle_sigcancel): In manager thread call
216         __pthread_manager_sighandler.
217         * sysdeps/i386/pt-machine.h (__compare_and_swap): Add memory clobber.
218         * sysdeps/i386/i686/pt-machine.h: Likewise.
219         Patches by Xavier Leroy.
220
221 1998-12-14  Ulrich Drepper  <drepper@cygnus.com>
222
223         * spinlock.c (__pthread_unlock): Don't crash if called for an
224         untaken mutex.  Reported by Ruslan V. Brushkoff <rus@Snif.Te.Net.UA>.
225
226         * Examples/ex6.c: Unbuffer stdout and reduce sleep time to reduce
227         overall runtime.
228
229 1998-12-13  Ulrich Drepper  <drepper@cygnus.com>
230
231         * Examples/ex3.c: Wait until all threads are started before
232         searching for the number to avoid race condition on very fast
233         systems.
234
235 1998-12-08  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
236
237         * sysdeps/pthread/pthread.h: Remove __pthread_setcanceltype
238         declaration since it's not needed.
239
240         * sysdeps/pthread/pthread.h: Move internal functions to ...
241         * internals.h: ...here.
242
243 1998-12-02  H.J. Lu  <hjl@gnu.org>
244
245         * pthread.c (__pthread_sig_restart): Initiliaze to 0 if
246         SIGRTMIN is defined.
247         (__pthread_sig_cancel): Likewise.
248
249 1998-12-01  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
250
251         * wrapsyscall.c: Include <sys/mman.h> for msync,
252         <stdlib.h> for system and <termios.h> for tcdrain prototype.
253         Correct msync declaration.
254
255 1998-11-29  Roland McGrath  <roland@baalperazim.frob.com>
256
257         * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_define, __libc_tsd_get,
258         __libc_tsd_set): New macros for new interface.
259         * no-tsd.c: New file, provide uninitialized defns of
260         __libc_internal_tsd_get and __libc_internal_tsd_set.
261         * Makefile (routines): Add no-tsd.
262
263 1998-10-12  Roland McGrath  <roland@baalperazim.frob.com>
264
265         * internals.h: Include <bits/libc-tsd.h>, not <bits/libc-lock.h>.
266         * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
267         __libc_internal_tsd_set): Move decls to ...
268         * sysdeps/pthread/bits/libc-tsd.h: New file for __libc_internal_tsd_*
269         declarations.
270
271         * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
272         __libc_internal_tsd_set): Make these pointers to functions, not
273         functions; remove #pragma weak decls for them.
274         * specific.c (__libc_internal_tsd_get, __libc_internal_tsd_set):
275         Define static functions and initialized pointers to them.
276
277 1998-11-18  Ulrich Drepper  <drepper@cygnus.com>
278
279         * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES.
280         (CFLAGS-specific.c): Likewise.
281         (CFLAGS-pthread.c): Likewise.
282         (CFLAGS-ptfork.c): Likewise.
283         (CFLAGS-cancel.c): Likewise.
284         * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions
285         as weak references if __NO_WEAK_PTHREAD_ALIASES is defined.
286
287         * mutex.c (pthread_mutex_init): Define as strong symbol.
288         (pthread_mutex_destroy): Likewise.
289         (pthread_mutex_trylock): Likewise.
290         (pthread_mutex_lock): Likewise.
291         (pthread_mutex_unlock): Likewise.
292         (pthread_mutexattr_init): Likewise.
293         (pthread_mutexattr_destroy): Likewise.
294         (pthread_once): Likewise.
295         * ptfork.c (pthread_atfork): Likewise.
296         * specific.c (pthread_key_create): Likewise.
297         (pthread_setspecific): Likewise.
298         (pthread_getspecific): Likewise.
299
300 1998-11-15  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
301
302         * linuxthreads.texi: Fix punctuation after xref.
303
304 1998-11-10  H.J. Lu  <hjl@gnu.org>
305
306         * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine NR_OPEN
307         if it is defined in <linux/limits.h>.
308
309 1998-10-29 14:28  Ulrich Drepper  <drepper@cygnus.com>
310
311         * spinlock.h (__pthread_trylock): Define inline.
312         (__pthread_lock): Add extra parameter to declaration.  Declare
313         using internal_function.
314         (__pthread_unlock): Declare using internal_function.
315         * spinlock.c (__pthread_lock): Add new parameter.  Use it instead
316         of local variable self.  Avoid recomputing self.  Define using
317         internal_function.
318         (__pthread_trylock): Remove.
319         (__pthread_unlock): Define using internal_function.
320         * cancel.c: Adjust for __pthread_lock interface change.  Use already
321         computed self value is possible.
322         * condvar.c: Likewise.
323         * join.c: Likewise.
324         * manager.c: Likewise.
325         * mutex.c: Likewise.
326         * pthread.c: Likewise.
327         * rwlock.c: Likewise.
328         * semaphore.c: Likewise.
329         * signals.c: Likewise.
330
331 1998-10-27 13:46  Ulrich Drepper  <drepper@cygnus.com>
332
333         * sysdeps/pthread/pthread.h (struct _pthread_cleanup_buffer): Prepend
334         __ to field names of the struct.
335         * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_fastlock):
336         Likewise.
337         (pthread_attr_t): Likewise.
338         (pthread_cond_t): Likewise.
339         (pthread_condattr_t): Likewise.
340         (pthread_mutex_t): Likewise.
341         (pthread_mutexattr_t): Likewise.
342         (pthread_rwlock_t): Likewise.
343         (pthread_rwlockattr_t): Likewise.
344         * attr.c: Adjust for pthread.h and pthreadtypes.h change.
345         * cancel.c: Likewise.
346         * condvar.c: Likewise.
347         * manager.c: Likewise.
348         * mutex.c: Likewise.
349         * pthread.c: Likewise.
350         * ptlongjmp.c: Likewise.
351         * rwlock.c: Likewise.
352         * spinlock.c: Likewise.
353
354 1998-10-09  Ulrich Drepper  <drepper@cygnus.com>
355
356         * sysdeps/i386/pt-machine.h (get_eflags, set_eflags): Mark these
357         also with PT_EI.
358
359         * sysdeps/i386/i686/pt-machine.h: Remove unused inline
360         definitions.
361
362         * Makefile (libpthread-routines): Add pt-machine.
363         * pt-machine.c: New file.
364         * sysdeps/alpha/pt-machine.h: Define PT_EI as extern inline is not
365         yet defined.  Use PT_EI in extern inline definitions.
366         * sysdeps/arm/pt-machine.h: Likewise.
367         * sysdeps/i386/pt-machine.h: Likewise.
368         * sysdeps/i386/i686/pt-machine.h: Likewise.
369         * sysdeps/m68k/pt-machine.h: Likewise.
370         * sysdeps/mips/pt-machine.h: Likewise.
371         * sysdeps/powerpc/pt-machine.h: Likewise.
372         * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
373         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
374
375 1998-10-02  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
376
377         * semaphore.h: Include <sys/types.h> so that _pthread_descr
378         is declared.
379
380 1998-09-15  David S. Miller  <davem@pierdol.cobaltmicro.com>
381
382         * sysdeps/sparc/sparc32/pt-machine.h (INIT_THREAD_SELF): Add nr
383         argument.
384         * sysdeps/sparc/sparc64/pt-machine.h (INIT_THREAD_SELF): Likewise.
385
386 1998-09-12 14:24 -0400  Zack Weinberg  <zack@rabi.phys.columbia.edu>
387
388         * linuxthreads/sysdeps/unix/sysv/linux/bits/sigthread.h: Add
389         multiple inclusion guard.
390
391 1998-09-02 11:08  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
392
393         * signals.c (sigaction): Check that sig is less than NSIG to avoid
394         array index overflow.
395
396 1998-09-06 10:56  Ulrich Drepper  <drepper@cygnus.com>
397
398         * sysdeps/pthread/semaphore.h: New file.
399
400 1998-09-06 09:08  Ulrich Drepper  <drepper@cygnus.com>
401
402         * sysdeps/pthread/bits/libc-lock.h (enum __libc_tsd_key_t): Add
403         _LIBC_TSD_KEY_DL_ERROR.
404
405 1998-08-31  Ulrich Drepper  <drepper@cygnus.com>
406
407         * sysdeps/i386/i686/pt-machine.h (testandset): Add memory clobber.
408         * sysdeps/i386/pt-machine.h: Likewise.
409         Suggested by Roland McGrath.
410
411 1998-08-28 13:58  Ulrich Drepper  <drepper@cygnus.com>
412
413         * internals.h: Also define THREAD_GETMEM_NC and THREAD_SETMEM_NC to
414         access thread data with non-constant offsets.
415         * specific.c: Use THREAD_GETMEM_NC and THREAD_SETMEM_NC where
416         necessary.
417
418         * sysdeps/i386/useldt.h: Fix typo.  Add THREAD_GETMEM_NC and
419         THREAD_SETMEM_NC definitions.
420
421         * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM_NC and
422         THREAD_SETMEM_NC.
423         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
424
425 1998-08-26 15:46  Ulrich Drepper  <drepper@cygnus.com>
426
427         * internals.h: Define THREAD_GETMEM and THREAD_SETMEM to default if
428         not already defined.
429         (struct _pthread_descr_struct): Add p_self and p_nr field.
430         * manager.c (__pthread_handles): Define second element to point
431         to manager thread.
432         (__pthread_handles_num): Initialize to 2.
433         (__pthread_manager): Use INIT_THREAD_SELF with two arguments.
434         (pthread_start_thread): Likewise.
435         (pthread_handle_create): Start search for free slot at entry 2.
436         Initialize new fields p_self and p_nr.
437         Call __clone with CLONE_PTRACE if available.
438         (pthread_free): Call FREE_THREAD_SELF if available.
439         * pthread.c (__pthread_initial_thread): Initialize new fields.
440         (__pthread_manager_thread): Likewise.
441         (__pthread_initialize_manager): Call __clone with CLONE_PTRACE.
442
443         * cancel.c: Use THREAD_GETMEM and THREAD_SETMEM to access the
444         elements of the thread descriptor.
445         * condvar.c: Likewise.
446         * errno.c: Likewise.
447         * join.c: Likewise.
448         * manager.c: Likewise.
449         * pthread.c: Likewise.
450         * ptlongjmp.c: Likewise.
451         * semaphore.c: Likewise.
452         * signals.c: Likewise.
453         * specific.c: Likewise.
454         * spinlock.c: Likewise.
455
456         * sysdeps/alpha/pt-machine.h (INIT_THREAD_SELF): Add extra parameter.
457
458         * sysdeps/i386/useldt.h: New file.
459         * sysdeps/i386/i686/pt-machine.h: Show how to use this file.
460
461         * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM and
462         THREAD_SETMEM using __thread_self.
463         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
464
465 1998-08-24  Geoff Keating  <geoffk@ozemail.com.au>
466
467         * spinlock.c (__pthread_lock): Reset p_nextwaiting to NULL if it
468         turned out that we didn't need to queue after all.
469
470 1998-08-22  Geoff Keating  <geoffk@ozemail.com.au>
471
472         * sysdeps/powerpc/pt-machine.h: Remove testandset, it's not used
473         and wastes space; correct types.
474
475 1998-08-08 11:18  H.J. Lu  <hjl@gnu.org>
476
477         * signals.c (sigaction): Handle NULL argument.
478
479 1998-08-04  Ulrich Drepper  <drepper@cygnus.com>
480
481         * sysdeps/unix/sysv/linux/bits/sigthread.h: Use __sigset_t instead
482         of sigset_t.
483
484 1998-08-02  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
485
486         * Makefile (linuxthreads-version): Extract correct number from
487         Banner.
488
489 1998-07-29  Xavier Leroy  <Xavier.Leroy@inria.fr>
490
491         * Banner: Bump version number to 0.8
492         * FAQ.html: Many updates, in particular w.r.t. debugging.
493         * manager.c: Support for non-default stacksize for
494         LinuxThreads-allocated stacks;
495         don't use guard pages for stacks with default size, rely on
496         rlimit(RLIMIT_STACK) instead (it's cheaper).
497         * attr.c: Likewise.
498         * cancel.c: Use __pthread_sig_cancel and __pthread_sig_restart
499         everywhere instead of PTHREAD_SIG_CANCEL and PTHREAD_SIG_RESTART.
500         * condvar.c: Likewise.
501         * internals.h: Likewise.
502         * restart.h: Likewise.
503         * signals.c: Likewise.
504         * pthread.c: Likewise; set rlimit(RLIMIT_STACK) as we need it.
505
506 1998-07-23  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
507
508         * weaks.c: Define pthread_mutexattr_[sg]ettype instead of
509         __pthread_mutexattr_[sg]ettype.  Add more weak aliases.
510         * Versions: Put __pthread_mutexattr_settype under version
511         GLIBC_2.0.  Don't export __pthread_mutexattr_setkind_np and
512         __pthread_mutexattr_gettype.
513
514 1998-07-23  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
515
516         * sysdeps/pthread/bits/libc-lock.h: Make
517         __pthread_mutexattr_settype weak.  Don't make
518         __pthread_mutexattr_setkind_np weak.
519
520 1998-07-16 10:52  Ulrich Drepper  <drepper@cygnus.com>
521
522         * manager.c (pthread_handle_create): Check whether sched_setscheduler
523         call can succeed here.
524
525         * mutex.c: Define __pthread_mutexattr_settype and make
526         __pthread_mutexattr_setkind_np an alias.
527         Likewise for __pthread_mutexattr_gettype.
528
529 1998-07-15 11:00 -0400  Zack Weinberg  <zack@rabi.phys.columbia.edu>
530
531         * attr.c (pthread_attr_setschedpolicy): Don't check whether caller
532         is root.
533
534 1998-07-14 19:38  Ulrich Drepper  <drepper@cygnus.com>
535
536         * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_end.
537
538 1998-07-11  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
539
540         * Examples/ex6.c: Include <unistd.h> for usleep.
541
542 1998-06-13 11:04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
543
544         * Examples/ex4.c (main): Use exit, not pthread_exit.
545
546 1998-07-09 13:39  Ulrich Drepper  <drepper@cygnus.com>
547
548         * Versions: Add __pthread_mutexattr_gettype and
549         __pthread_mutexattr_settype.
550         * lockfile.c: Use __pthread_mutexattr_settype instead of
551         __pthread_mutexattr_setkind_np.
552         * mutex.c: Define __pthread_mutexattr_gettype and
553         __pthread_mutexattr_settype.
554         * weak.c: Likewise.
555         * sysdeps/pthread/pthread.h: Declare __pthread_mutexattr_gettype and
556         __pthread_mutexattr_settype.
557         * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init_recursive):
558         Use __pthread_mutexattr_settype.
559
560 1998-07-08 22:26  Ulrich Drepper  <drepper@cygnus.com>
561
562         * Versions: Add pthread_mutexattr_gettype, pthread_mutexattr_settype.
563         * mutex.c: Define weak alias pthread_mutexattr_gettype and
564         pthread_mutexattr_settype.
565         * sysdeps/pthread/pthread.h: Declare these functions.
566         Move pthread_sigmask and pthread_kill declaration in separate header.
567         * sysdeps/unix/sysv/linux/bits/sigthread.h: New file.
568
569 1998-07-07 15:20  Ulrich Drepper  <drepper@cygnus.com>
570
571         * Makefile: Add rules to compile and run tests.
572         * Examples/ex1.c: Little changes to fix warnings.
573         * Examples/ex2.c: Likewise.
574         * Examples/ex3.c: Likewise.
575         * Examples/ex4.c: Likewise.
576         * Examples/ex5.c: Likewise.
577         * Examples/ex6.c: New file.
578
579 1998-07-05 11:54  Ulrich Drepper  <drepper@cygnus.com>
580
581         * Versions: Add pthread_attr_init to GLIBC_2.1 version in libc.
582
583 1998-07-01  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
584
585         * attr.c: Include <string.h>.
586
587 1998-06-30 11:47  Ulrich Drepper  <drepper@cygnus.com>
588
589         * attr.c: Include errno.h.  Use memcpy to copy sched_param.
590         * internals.h: Include limits.h.
591         * manager.c: Use memcpy to copy sched_param.
592         * ptfork.c: Include errno.h.
593         * pthread.c: Likewise.
594         * semaphore.c: Likewise.
595         * specific.c: Likewise.
596         * spinlock.h: Likewise.
597         * sysdeps/pthread/pthread.h: Include only allowed headers.  Move
598         type definition to ...
599         * sysdeps/pthread/bits/pthreadtypes.h: ...here.  New file.
600
601 1998-06-29 12:34  Ulrich Drepper  <drepper@cygnus.com>
602
603         * sysdeps/pthread/pthread.h: Use __PMT not __P for function pointers.
604
605         * sysdeps/pthread/pthread.h: Define various PTHREAD_* symbols also
606         as macros as demanded in POSIX.1, Annex C.
607
608 1998-06-29 12:29  Ulrich Drepper  <drepper@cygnus.com>
609
610         * internals.h (struct pthread_request): For free use pthread_t
611         instead of pthread_descr.
612         * join.c (pthread_join): Pass thread_id, not th to manager.
613         (pthread_detach): Likewise.
614         * manager.c (__pthread_manager): Except thread ID in FREE_REQ case.
615         (pthread_exited): Remove detached queue code.
616         (pthread_handle_free): Expect thread ID parameter and use it to
617         validate the thread decsriptor.  Don't use detached queue.
618         Patches by Xavier Leroy.
619
620 1998-06-27  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
621
622         * libpthread.map: Export accept, longjmp, sigaction, siglongjmp,
623         _IO_flockfile, _IO_ftrylockfile, _IO_funlockfile,
624         __pthread_atfork, __pthread_key_create, __pthread_once.
625         * internals.h: Doc fix.
626         * pthread.c (__pthread_initialize): Define again.
627
628 1998-06-26  Ulrich Drepper  <drepper@cygnus.com>
629
630         * manager.c (pthread_exited): If thread is not detached put it on
631         special list.
632         (pthread_handle_free): If thread is not on list with living threads
633         search on list with detached threads.
634
635         * sysdeps/pthread/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Correct
636         for new definition of pthread_rwlock_t.
637
638         * spinlock.c: Correct test whether to compile
639         __pthread_compare_and_swap or not.
640
641 1998-06-25 19:27  Ulrich Drepper  <drepper@cygnus.com>
642
643         * attr.c: Finish user stack support.  Change locking code to be safe
644         in situations with different priorities.
645         * cancel.c: Likewise.
646         * condvar.c: Likewise.
647         * internals.h: Likewise.
648         * join.c: Likewise.
649         * manager.c: Likewise.
650         * mutex.c: Likewise.
651         * pthread.c: Likewise.
652         * ptlongjmp.c: Likewise.
653         * queue.h: Likewise.
654         * rwlock.c: Likewise.
655         * semaphore.c: Likewise.
656         * semaphore.h: Likewise.
657         * signals.c: Likewise.
658         * spinlock.c: Likewise.
659         * spinlock.h: Likewise.
660         * sysdeps/pthread/pthread.h: Likewise.
661         Patches by Xavier Leroy.
662
663         * sysdeps/i386/i686/pt-machine.h: New file.
664
665 1998-06-25  Ulrich Drepper  <drepper@cygnus.com>
666
667         * sysdeps/pthread/pthread.h: Make [sg]et_stacksize and
668         [sg]et_stackaddr prototypes always available.
669
670         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
671         _POSIX_THREAD_ATTR_STACKSIZE and _POSIX_THREAD_ATTR_STACKADDR.
672
673 1998-06-24  Ulrich Drepper  <drepper@cygnus.com>
674
675         * manager.c (pthread_free): Undo patch from 980430.
676         Reported by David Wragg <dpw@doc.ic.ac.uk>.
677
678 1998-06-09 15:07  Ulrich Drepper  <drepper@cygnus.com>
679
680         * manager.c: Define __pthread_manager_adjust_prio and use it to
681         increase priority when needed.
682         * internals.h: Add prototype for __pthread_manager_adjust_prio.
683         * mutex.c: Optimize mutexes to wake up only one thread.
684         * pthread.c: Move PID of manager for global variable in structure
685         element.
686         Patches by Xavier Leroy.
687
688 1998-06-07 13:47  Ulrich Drepper  <drepper@cygnus.com>
689
690         * sysdeps/pthread/bits/libc-lock.h: Optimize cleanup handlers a bit.
691
692 1998-06-03  Andreas Jaeger  <aj@arthur.rhein-neckar.de>
693
694         * attr.c: Correct typo.
695
696 1998-05-01  Ulrich Drepper  <drepper@cygnus.com>
697
698         * manager.c (pthread_free): Unmap guard before the stack.
699         Patch by Matthias Urlichs.
700
701 1998-04-30  Ulrich Drepper  <drepper@cygnus.com>
702
703         * manager.c (pthread_free): Detect already free child.
704         Patch by Xavier Leroy, reported by Matthias Urlichs.
705
706 1998-04-23  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
707
708         * Makefile (linuxthreads-version): Renamed back from
709         libpthread-version.
710
711 1998-04-21  Ulrich Drepper  <drepper@cygnus.com>
712
713         * ptlongjmp.c: Add prototypes for __libc_siglongjmp and
714         __libc_longjmp.
715
716 1998-04-20 14:55  Ulrich Drepper  <drepper@cygnus.com>
717
718         * Makefile (libpthread-routines): Add ptlongjmp and spinlock.
719         * internals.h: Add definitions for new spinlock implementation.
720         * ptlongjmp.c: New file.
721         * spinlock.c: New file.
722         * spinlock.h (acquire): Don't reschedule using __sched_yield, use
723         new function __pthread_acquire to prevent deadlocks with thread
724         with different priorities.
725         Patches by Xavier Leroy <Xavier.Leroy@inria.fr>.
726
727 1998-03-16  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
728
729         * manager.c (__pthread_manager): Reduce first argument to select
730         to include just the needed file descriptor.
731
732 1998-03-17 00:06  Ulrich Drepper  <drepper@cygnus.com>
733
734         * manager.c: Fix last patch which caused core dumps.
735
736         * pthread.c: Correctly handle missing SIGRTMIN.
737
738 1998-03-15  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
739
740         * libpthread.map: Add __libc_internal_tsd_get and
741         __libc_internal_tsd_set.  Add missing cancelable functions. Export
742         libc internal versions of the cancelable functions.
743
744 1998-03-13 16:51  Ulrich Drepper  <drepper@cygnus.com>
745
746         * weaks.c: Define pthread_attr_init as GLIBC_2.0 and GLIBC_2.1.
747
748 1998-03-13 00:46  Ulrich Drepper  <drepper@cygnus.com>
749
750         * attr.c: Implement pthread_attr_[gs]etguardsize,
751         pthread_attr_[gs]setstackaddr, pthread_attr_[gs]etstacksize.
752         Change pthread_attr_init to have two interfaces.
753         * internals.h (struct _pthread_descr_struct): Add new fields for
754         above functions.
755         * libpthread.map: Add names in GLIBC_2.1 section.
756         * manager.c (pthread_handle_create): Implement guardsize and
757         user stack.
758         (pthread_free): Likewise.
759         * pthread.c (pthread_create): Add new interface for changed
760         pthread_attr_t.
761         * sysdeps/pthread/pthread.h: Add prototypes for new functions.
762         * sysdeps/unix/sysv/linux/bits/local_lim.h: Add definition of
763         PTHREAD_STACK_MIN.
764
765 1998-03-11 00:42  Wolfram Gloger  <wmglo@dent.med.uni-muenchen.de>
766
767         * manager.c: Enable resetting of the thread scheduling policy
768         to SCHED_OTHER when the parent thread has a different one.
769
770 1998-02-01 13:51  Ulrich Drepper  <drepper@cygnus.com>
771
772         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
773         _POSIX_ASYNCHRONOUS_IO.
774
775         * sysdeps/pthread/pthread.h: Define bits for Unix98 variants of
776         mutexes.
777         * mutex.c: Implement new mutex types.
778
779         * internals.h: Include <signal.h>.
780
781         * libpthread.map: Add __erno_location and __h_errno_location.
782
783         * errno.c: Return pointer to variable actually in use.  This might
784         not be the one in the thread structure.
785         * internals.h (struct _pthread_descr_struct): Add new fields p_errnop
786         and p_h_errnop.
787         * manager.c (__pthread_manager): Set p_errnop and p_h_errnop member
788         of manager thread structure.
789         (pthread_handle_create): Set p_errnop and p_h_errnop members for new
790         thread.
791         * pthread.c: Adapt initializer for thread structures.
792         (__pthread_initial_thread): Set p_errnop and p_h_errnop member.
793         (__pthread_reset_main_thread): Reset p_errnop and p_h_errnop of
794         current thread to global variables.
795
796 1998-01-31 17:27  Ulrich Drepper  <drepper@cygnus.com>
797
798         * rwlock.c: New file.
799         * Makefile (libpthread-routines): Add rwlock.
800         * sysdeps/pthread/pthread.h: Define data structures and declare
801         functions.
802         * libpthread.map: Add new functions.
803
804 1997-12-18 13:50  Philip Blundell  <pb@nexus.co.uk>
805
806         * sysdeps/arm/pt-machine.h: New file; add ARM support.
807         * sysdeps/arm/Implies: likewise.
808         * README: Document it.
809
810 1997-12-13  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
811
812         * signals.c: Remove unneeded initializer for sigwaited, saving a
813         warning.
814
815 1997-04-11 01:18  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
816
817         * semaphore.c (sem_init): Set sem_spinlock only if available.
818
819 1997-12-04 01:48  Ulrich Drepper  <drepper@cygnus.com>
820
821         * mutex.c: Implement PTHREAD_MUTEX_CHECKERROR.
822         * sysdeps/pthread/pthread.h: Define PTHREAD_MUTEX_CHECKERROR.
823
824         * Makefile: Update from LinuxThreads 0.7.
825         * internals.h. Likewise.
826         * manager.c: Likewise.
827         * mutex.c: Likewise.
828         * pthread.c: Likewise.
829         * signals.c: Likewise.
830         * specific.c: Likewise.
831         * Examples/ex3.c: Likewise.
832
833 1997-11-20 18:13  Ulrich Drepper  <drepper@cygnus.com>
834
835         * pthread.c (__pthread_reset_main_thread): Close pipe only if still
836         open.
837
838 1997-10-29 05:38  Ulrich Drepper  <drepper@cygnus.com>
839
840         * wrapsyscall.c: Add socket functions which are also cancelation
841         points.
842
843 1997-10-19 21:40  Wolfram Gloger  <wg@wolfram.dent.med.uni-muenchen.de>
844
845         * specific.c (__libc_internal_tsd_set, __libc_internal_tsd_get):
846         New functions for fast thread specific data within libc.
847
848         * internals.h: Add new array p_libc_specific to struct
849         _pthread_descr_struct.
850
851         * sysdeps/pthread/bits/libc-lock.h: Declare new functions.
852
853 1997-10-13 05:39  Ulrich Drepper  <drepper@cygnus.com>
854
855         * semaphore.h: Add __BEGIN_DECLS/__END_DECLS.
856         Reported by Ralf Corsepius <corsepiu@faw.uni-ulm.de>.
857
858 1997-08-29 03:05  Ulrich Drepper  <drepper@cygnus.com>
859
860         * internals.h (struct _pthread_descr_struct): Add definitions for
861         two-level specific key handling.
862         * manager.c (pthread_handle_create): Initialize specific memory array.
863         * specific.c: Implement two-level key handling.
864         * weaks.c: Don't provide dummy key handling.
865         * sysdeps/pthread/bits/libc-lock.h: Typedef __libc_lock_t (no #define).
866         Add definition of __libc_key_t.
867         * sysdeps/unix/sysv/linux/bits/local_lim.h: Define PTHREAD_KEYS_MAX
868         as 1024.
869         Add definition of _POSIX_THREAD_DESTRUCTOR_ITERATIONS and
870         PTHREAD_DESTRUCTOR_ITERATIONS.
871
872         * manager.c (pthread_handle_create): Compare mmap result with
873         MAP_FAILED.
874
875         * ptfork.c: Rename to __pthread_atfork and make old name a weak alias.
876         * sysdeps/pthread/bits/pthread.h: Add prototype for __pthread_atfork.
877
878 1997-08-22 19:04  Richard Henderson  <rth@cygnus.com>
879
880         sysdeps/sparc -> sysdeps/sparc/sparc32
881         sysdeps/sparc64 -> sysdeps/sparc/sparc64
882
883         * internals.h: Change definition of THREAD_SELF to be an expression,
884         not a statement that did a return.
885         * sysdeps/alpha/pt-machine.h (THREAD_SELF): Update accordingly.
886         * sysdeps/sparc/sparc32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
887         Follow Solaris and use a "system reserved" register (%g6) to hold
888         the thread descriptor.
889         * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
890
891 1997-08-03 00:09  Ulrich Drepper  <drepper@cygnus.com>
892
893         * mutex.c: Correct pthread_once.  Patch by Xavier Leroy.
894         * sysdeps/pthread/pthread.h: Add prototype for __pthread_once.
895         * sysdeps/pthread/bits/pthread.h: Add macros for __libc_once.
896
897         * semaphore.c: Include spinlock.h only when needed.
898
899         * specific.c (__pthread_setsepcific, __pthread_getspecific): Reject
900         keys for entries not in use.
901
902         * weaks.c: Implement key handling functions for real.
903
904 1997-06-29  01:04  Richard Henderson  <richard@gnu.ai.mit.edu>
905
906         Initial sparc64-linux support:
907         * linuxthreads/sysdeps/sparc64/Implies: New file.
908         * linuxthreads/sysdeps/sparc64/pt-machine.h: Likewise.
909
910 1997-06-29 00:48  Ulrich Drepper  <drepper@cygnus.com>
911
912         * semaphore.c: Include spinlock.h at correct place.
913         Patch by HJ Lu.
914
915 1997-06-13 10:06  Richard Henderson  <rth@tamu.edu>
916
917         The Great Bit File Move:
918         * sysdeps/alpha/semaphorebits.h: -> .../bits/semaphore.h.
919         * sysdeps/powerpc/semaphorebits.h: Likewise.
920         * sysdeps/pthread/cmpxchg/semaphorebits.h: Likewise.
921         * sysdeps/pthread/no-cmpxchg/semaphorebits.h: Likewise.
922         * sysdeps/pthread/libc-lock.h: -> bits/
923         * sysdeps/pthread/stdio-lock.h: Likewise.
924         * sysdeps/unix/sysv/linux/local_lim.h: Likewise.
925         * sysdeps/unix/sysv/linux/posix_opt.h: Likewise.
926         * semaphore.h: Likewise.
927         * sysdeps/pthread/pthread.h: Likewise.
928
929         * lockfile.c: <foo.h> -> <bits/foo.h>.
930         * semaphore.h: Likewise.
931
932         * Makefile: (headers): foo.h -> bits/foo.h.
933         * sysdeps/pthread/Makefile: Likewise.
934
935 1997-04-11 01:18  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
936
937         * semaphore.c (sem_init): Set sem_spinlock only if available.
938
939         * sysdeps/m68k/pt-machine.h (testandset, __compare_and_swap): Fix
940         asm constraints.
941
942 1997-04-09 03:00  Ulrich Drepper  <drepper@cygnus.com>
943
944         Update from LinuxThreads 0.6.
945
946         * attr.c (pthread_attr_getdetachstate): Use __sched_get_priority_max
947         and __sched_get_priority_min instead of names without `__'.
948
949         * manager.c: Rewrite large parts to implement opaque pthread_t.
950
951         * cancel.c: Adapt for opaque pthread_t type.
952         * condvar.c: Likewise.
953         * errno.c: Likewise.
954         * join.c: Likewise.
955         * mutex.c: Likewise.
956         * pthread.c: Likewise.
957         * signals.c: Likewise.
958         * specific.c: Likewise.
959         * restart.h: Likewise.
960         * queue.h: Likewise.
961         * Examples/ex3.c: Likewise.
962         * Examples/ex4.c: Likewise.
963         * sysdeps/pthread/pthread.h: Likewise.
964
965         * pthread.c: Accumulate time for all threads in thread manager.
966
967         * semaphore.c: Implement fallback implementation for architectures
968         sometimes missing compare-exchange operations.
969
970         * cancel.c (pthread_cancel): Validate handle argument.
971         * join.c (pthread_join): Likewise.
972         (pthread_detach): Likewise.
973         * signals.c (pthread_kill): Likewise.
974
975         * spinlock.h (acquire): Use __sched_yield not sched_yield.
976
977         * queue.h (enqueue): Enqueue thread according to priority.
978
979         * internals.c (struct pthread_start_args): New struct for passing
980         args to cloning function.
981         (struct _pthread): Rename to _pthread_descr_struct and adapt for
982         opaque pthread_t.
983
984         * Examples/Makefile (clean): Pass -f option to rm.
985
986         * sysdeps/i386/pt-machine.h: Add check for compare-exchange instruction
987         and define TEST_FOR_COMPARE_AND_SWAP.
988         * sysdeps/i386/i486/pt-machine.h: Removed.
989
990         * sysdeps/unix/sysv/linux/local_lim.h (PTHREAD_THREADS_MAX): Increase
991         to 1024.
992
993 1997-04-04 16:38  Ulrich Drepper  <drepper@cygnus.com>
994
995         * restart.h (suspend): Clear p_signal before suspending.
996         (suspend_with_cancellation): Likewise.
997         Patch by Xavier Leroy <Xavier.Leroy@inria.fr>.
998
999         * weaks.c: Make __pthread_key_create return 1.
1000         * sysdeps/pthread/libc-lock.h: Define __libc_key_create,
1001         __libc_getspecific, __libc_setspecific, and __libc_key_t.
1002         * sysdeps/pthread/stdio-lock.h: Don't care for implementation not
1003         using libio.
1004
1005 1997-03-19 15:13  Miguel de Icaza  <miguel@nuclecu.unam.mx>
1006
1007         * sysdeps/sparc/pt-machine (RELEASE): Fix.
1008
1009 1997-03-01 07:55  Geoff Keating  <geoffk@ozemail.com.au>
1010
1011         * sysdeps/powerpc/Implies: Added.
1012         * sysdeps/powerpc/pt-machine.h: Added.
1013         * sysdeps/powerpc/semaphorebits.h: Added.
1014
1015 1997-01-22 01:22  Ulrich Drepper  <drepper@cygnus.com>
1016
1017         * linuxtheads/pthread.c (__pthread_initial_thread): Correct
1018         initializer.
1019         (__pthread_manager_thread): Likewise.
1020         Reported by Andreas Jaeger.
1021
1022 1997-01-18 22:15  Richard Henderson  <rth@tamu.edu>
1023
1024         Since sigset_t no longer fits in a register, we can't pass in the
1025         thread's initial mask so easily.  Take this opportunity to simplify
1026         the clone implementation by only accepting a single void* argument.
1027
1028         * linuxthreads/manager.c (__pthread_manager): Put thread vitals
1029         in the thread struct instead of as arguments through clone.
1030         (pthread_start_thread): Look for them there.
1031         * linuxthreads/internals.h (struct _pthread): Add p_initial_fn,
1032         p_initial_fn_arg, p_initial_mask.  Fix __pthread_manager proto.
1033         * linuxthreads/pthread.c (pthread_initialize_manager): Revise
1034         clone invocation.