1 1999-10-14 Ulrich Drepper <drepper@cygnus.com>
3 * pthread.c (__pthread_initial_thread): Pass argument to
4 PTHREAD_START_ARGS_INITIALIZER.
5 (__pthread_manager_thread): Likewise.
7 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add parameter to
10 * manager.c (pthread_handle_create): Remove p_startfct initialization.
12 * internals.h (_pthread_descr_struct): We don't need p_startfct field.
14 1999-10-12 Ulrich Drepper <drepper@cygnus.com>
16 * internals.h: Correct return types for __libc_read and __libc_write.
18 1999-10-09 Andreas Jaeger <aj@suse.de>
20 * internals.h: Add __new_sem_post to get prototype in
21 manager.c; include semaphore.h for needed types.
23 1999-10-08 Ulrich Drepper <drepper@cygnus.com>
25 * manager.c (__pthread_manager) [REQ_POST]: Use __new_sem_post
26 directly instead of calling sem_post which should not be necessary
27 but is faster and might help in some case to work around problems.
28 Patch by khendricks@ivey.uwo.ca [libc/1382].
30 1999-10-08 Andreas Schwab <schwab@suse.de>
32 * sysdeps/pthread/Subdirs: New file.
35 1999-10-07 Ulrich Drepper <drepper@cygnus.com>
38 * internals.h (struct _pthread_descr_struct): Add p_startfct.
39 * manager.c (pthread_handle_create): Initialize p_startfct.
40 * pthread.c: Define __linuxthread_pthread_sizeof_descr variable.
42 1999-09-25 Ulrich Drepper <drepper@cygnus.com>
44 * manager.c (__linuxthreads_pthread_threads_max): New variable.
45 * specific.c (__linuxthreads_pthread_keys_max): New variable.
46 (__linuxthreads_pthread_key_2ndlevel_size): New variable.
48 * condvar.c (pthread_cond_timedwait_relative): Never return with
49 EINTR. Patch by Andreas Schwab.
51 1999-09-19 Ulrich Drepper <drepper@cygnus.com>
53 * signals.c (sigaction): Correct last patch. Don't select
54 pthread_sighandler_rt based on the signal number but instead of
57 1999-09-23 Ulrich Drepper <drepper@cygnus.com>
59 * specific.c: Move definitions of struct pthread_key_struct and
61 * internals.h: ...here.
63 1999-09-18 Ulrich Drepper <drepper@cygnus.com>
65 * pthread.c (pthread_handle_sigrestart_rt): New function. Use
66 this instead of pthread_handle_sigrestart if the signal is an RT
69 * signals.c: Handle passing through of sighandler arguments also
70 for real-time signals.
72 1999-09-03 Andreas Schwab <schwab@suse.de>
74 * ptfork.c (__fork): Renamed from fork and use __libc_fork. Add
76 (__vfork): New function, alias vfork.
77 * Versions: Export __fork, vfork, and __vfork in libpthread.
79 1999-08-23 Andreas Schwab <schwab@suse.de>
81 * signals.c (pthread_sighandler): Add SIGCONTEXT_EXTRA_ARGS to
82 call to signal handler.
84 1999-08-20 Ulrich Drepper <drepper@cygnus.com>
86 * pthread.c (__pthread_reset_main_thread): Undo last change.
87 (__pthread_kill_other_threads_np): Reset signal handlers for the
88 signals we used in the thread implementation here.
90 1999-08-19 Ulrich Drepper <drepper@cygnus.com>
92 * pthread.c (__pthread_reset_main_thread): Reset signal handlers
93 for the signals we used in the thread implementation [PR libc/1234].
95 * Versions: Export __pthread_kill_other_threads_np from libpthread
98 * signals.c: Pass sigcontext through wrapper to the user function.
100 1999-08-01 Ulrich Drepper <drepper@cygnus.com>
102 * Versions [ld.so] (GLIBC_2.0): Export __libc_internal_tsd_get and
103 __libc_internal_tsd_set.
105 1999-07-29 Andreas Jaeger <aj@arthur.rhein-neckar.de>
107 * manager.c: Remove inclusion of <linux/tasks.h> since it's not
110 1999-07-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
112 * internals.h: Align _pthread_descr_struct to 32 bytes.
113 Reported by Tim Hockin <thockin@cobaltnet.com>, close PR
116 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
118 * oldsemaphore.c (sem_compare_and_swap): Fix use of compare and
121 1999-07-09 Cristian Gafton <gafton@redhat.com>
123 * Makefile (libpthread-routines): Add oldsemaphore routine.
124 * Versions: Add sem_destroy, sem_getvalue, sem_init, sem_post,
125 sem_trywait, and sem_wait to GLIBC_2.1.
126 * oldsemaphore.c: New file.
127 * semaphore.c: Add default_symbol_versions for the changed functions.
128 (__new_sem_init): Rename from sem_init.
129 (__new_sem_post): Rename from sem_post.
130 (__new_sem_wait): Rename from sem_wait.
131 (__new_sem_trywait): Rename from sem_trywait.
132 (__new_sem_getvalue): Rename from sem_getvalue.
133 (__new_sem_destroy): Rename from sem_destroy.
135 1999-06-23 Robey Pointer <robey@netscape.com>
137 * internals.h: Added p_nextlock entry to separate queueing for a
138 lock from queueing for a CV (sometimes a thread queues on a lock
139 to serialize removing itself from a CV queue).
140 * pthread.c: Added p_nextlock to initializers.
141 * spinlock.c: Changed to use p_nextlock instead of p_nextwaiting.
143 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
145 * manager.c (pthread_handle_create): Free mmap region after stack
146 if clone failed. Patch by Kaz Kylheku <kaz@ashi.FootPrints.net>.
148 1999-05-23 Andreas Jaeger <aj@arthur.rhein-neckar.de>
150 * man/pthread_cond_init.man: Correct example.
151 Reported by Tomas Berndtsson <tomas@nocrew.org>.
153 * linuxthreads.texi (Condition Variables): Likewise.
155 1999-05-18 Jakub Jelinek <jj@ultra.linux.cz>
157 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): Use
158 casx not cas, also successful casx returns the old value in rd
159 and not the new value.
161 1999-05-16 Xavier Leroy <Xavier.Leroy@inria.fr>
163 * manager.c: If pthread_create() is given a NULL attribute
164 and the thread manager runs with a realtime policy, set the
165 scheduling policy of the newly created thread back to SCHED_OTHER.
166 * manager.c: If the PTHREAD_INHERIT_SCHED attribute is given,
167 initialize the schedpolicy field of new_thread->p_start_args
168 to that of the calling thread.
170 1999-04-29 Ulrich Drepper <drepper@cygnus.com>
172 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): cas
173 instruction does not allow memory element to use offset.
175 1999-04-28 Ulrich Drepper <drepper@cygnus.com>
177 * manager.c (pthread_allocate_stack): Optimize initialization of new
180 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_define_initialized):
181 Don't use initializer since it is all zeroes.
182 (__libc_once_define): Likewise.
184 1999-04-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
186 * sysdeps/arm/Implies: Removed since cmpxchg/no-cmpxchg
187 doesn't exist anymore.
188 * sysdeps/i386/Implies: Likewise.
189 * sysdeps/m68k/Implies: Likewise.
190 * sysdeps/mips/Implies: Likewise.
191 * sysdeps/powerpc/Implies: Likewise.
192 * sysdeps/sparc/sparc32/Implies: Likewise.
193 * sysdeps/sparc/sparc64/Implies: Likewise.
195 1999-04-15 Ulrich Drepper <drepper@cygnus.com>
197 * sysdeps/alpha/bits/semaphore.h: Removed.
198 * sysdeps/powerpc/bits/semaphore.h: Removed.
199 * sysdeps/pthread/cmpxchg/bits/semaphore.h: Removed.
200 * sysdeps/pthread/no-cmpxchg/bits/semaphore.h: Removed.
201 * Makefile (headers): Remove bits/semaphore.h.
203 * semaphore.h: Define _pthread_descr if necessary.
204 Don't include limits.h. Define SEM_VALUE_MAX directly.
206 (sem_t): Protect element names with leading __.
207 Add declarations for sem_close, sem_open, and sem_unlink.
208 * semaphore.c: Adjust all functions for new element names.
209 Define sem_close, sem_open, and sem_unlink.
210 * Versions (libthread): Add sem_close, sem_open, and sem_unlink for
212 * sysdeps/pthread/bits/pthreadtypes.h: Define _pthread_descr only if
215 1999-03-16 H.J. Lu <hjl@gnu.org>
217 * specific.c (pthread_key_delete): Check th->p_terminated to see
218 if the thread is running.
220 * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set):
221 Added to GLIBC_2.0 for libc.so.
223 1999-02-12 H.J. Lu <hjl@gnu.org>
225 * Versions (__libc_current_sigrtmin, __libc_current_sigrtmax,
226 __libc_allocate_rtsig): Added to GLIBC_2.1.
228 * internals.h (DEFAULT_SIG_RESTART): Removed.
229 (DEFAULT_SIG_CANCEL): Removed.
231 * pthread.c (init_rtsigs, __libc_current_sigrtmin,
232 __libc_current_sigrtmax, __libc_allocate_rtsig): New functions.
233 (__pthread_sig_restart, __pthread_sig_cancel,
234 __pthread_sig_debug): Initialized.
235 (pthread_initialize): Call init_rtsigs () to initialize
238 1999-02-03 H.J. Lu <hjl@gnu.org>
240 * manager.c (__pthread_manager): Do block __pthread_sig_debug.
241 Don't restart the thread which sent REQ_DEBUG.
242 (pthread_start_thread): Check if __pthread_sig_debug > 0
245 * pthread.c (__pthread_initialize_manager): Suspend ourself
246 after sending __pthread_sig_debug to gdb instead of
247 __pthread_sig_cancel.
249 1999-01-24 H.J. Lu <hjl@gnu.org>
251 * manager.c (__pthread_manager): Delete __pthread_sig_debug
252 from mask if __pthread_sig_debug > 0.
253 (pthread_handle_create): Increment __pthread_handles_num.
255 * manager.c (pthread_handle_create): Don't pass CLONE_PTRACE to clone.
256 * pthread.c (__pthread_initialize_manager): Likewise.
258 * pthread.c (pthread_initialize): Use __libc_allocate_rtsig (1)
259 instead of __libc_allocate_rtsig (2).
260 (__pthread_initialize_manager): Send __pthread_sig_debug to gdb
261 instead of __pthread_sig_cancel.
262 (pthread_handle_sigdebug): Fix comments.
264 1999-01-21 Ulrich Drepper <drepper@cygnus.com>
266 * manager.c (pthread_allocate_stack): Set
267 __pthread_nonstandard_stacks if user-specified stack is used.
269 1999-01-16 Ulrich Drepper <drepper@cygnus.com>
271 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _LFS_ASYNCHRONOUS_IO,
272 _LFS_LARGEFILE, _LFS64_LARGEFILE, and _LFS64_STDIO from Unix98.
274 1999-01-07 Xavier Leroy <Xavier.Leroy@inria.fr>
276 * pthread.c: Use a third signal __pthread_sig_debug distinct
277 from __pthread_sig_cancel to notify gdb when a thread is
279 * manager.c: Likewise.
280 * internals.h: Likewise.
281 * signals.c: The implementation of sigwait(s) assumed that
282 all signals in s have signal handlers already attached.
283 This is not required by the standard, so make it work
284 also if some of the signals have no handlers.
286 1999-01-05 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
288 * linuxthreads.texi: Remove pointers from first @node. Move old
289 @node spec inside comment.
291 1998-12-31 Ulrich Drepper <drepper@cygnus.com>
293 * sysdeps/pthread/bits/stdio-lock.h: Define _IO_lock_lock and
296 1998-12-29 Ulrich Drepper <drepper@cygnus.com>
298 * semaphore.c (sem_trywait): Don't forget to unlock the semaphore
299 lock. Patch by Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>.
301 1998-12-21 Ulrich Drepper <drepper@cygnus.com>
303 * manager.c: Threads now send __pthread_sig_cancel on termination.
304 Change clone call and signal masks.
305 * thread.c (pthread_handle_sigrestart): Remove special code for
307 (pthread_handle_sigcancel): In manager thread call
308 __pthread_manager_sighandler.
309 * sysdeps/i386/pt-machine.h (__compare_and_swap): Add memory clobber.
310 * sysdeps/i386/i686/pt-machine.h: Likewise.
311 Patches by Xavier Leroy.
313 1998-12-14 Ulrich Drepper <drepper@cygnus.com>
315 * spinlock.c (__pthread_unlock): Don't crash if called for an
316 untaken mutex. Reported by Ruslan V. Brushkoff <rus@Snif.Te.Net.UA>.
318 * Examples/ex6.c: Unbuffer stdout and reduce sleep time to reduce
321 1998-12-13 Ulrich Drepper <drepper@cygnus.com>
323 * Examples/ex3.c: Wait until all threads are started before
324 searching for the number to avoid race condition on very fast
327 1998-12-08 Andreas Jaeger <aj@arthur.rhein-neckar.de>
329 * sysdeps/pthread/pthread.h: Remove __pthread_setcanceltype
330 declaration since it's not needed.
332 * sysdeps/pthread/pthread.h: Move internal functions to ...
333 * internals.h: ...here.
335 1998-12-02 H.J. Lu <hjl@gnu.org>
337 * pthread.c (__pthread_sig_restart): Initiliaze to 0 if
339 (__pthread_sig_cancel): Likewise.
341 1998-12-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
343 * wrapsyscall.c: Include <sys/mman.h> for msync,
344 <stdlib.h> for system and <termios.h> for tcdrain prototype.
345 Correct msync declaration.
347 1998-11-29 Roland McGrath <roland@baalperazim.frob.com>
349 * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_define, __libc_tsd_get,
350 __libc_tsd_set): New macros for new interface.
351 * no-tsd.c: New file, provide uninitialized defns of
352 __libc_internal_tsd_get and __libc_internal_tsd_set.
353 * Makefile (routines): Add no-tsd.
355 1998-10-12 Roland McGrath <roland@baalperazim.frob.com>
357 * internals.h: Include <bits/libc-tsd.h>, not <bits/libc-lock.h>.
358 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
359 __libc_internal_tsd_set): Move decls to ...
360 * sysdeps/pthread/bits/libc-tsd.h: New file for __libc_internal_tsd_*
363 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
364 __libc_internal_tsd_set): Make these pointers to functions, not
365 functions; remove #pragma weak decls for them.
366 * specific.c (__libc_internal_tsd_get, __libc_internal_tsd_set):
367 Define static functions and initialized pointers to them.
369 1998-11-18 Ulrich Drepper <drepper@cygnus.com>
371 * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES.
372 (CFLAGS-specific.c): Likewise.
373 (CFLAGS-pthread.c): Likewise.
374 (CFLAGS-ptfork.c): Likewise.
375 (CFLAGS-cancel.c): Likewise.
376 * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions
377 as weak references if __NO_WEAK_PTHREAD_ALIASES is defined.
379 * mutex.c (pthread_mutex_init): Define as strong symbol.
380 (pthread_mutex_destroy): Likewise.
381 (pthread_mutex_trylock): Likewise.
382 (pthread_mutex_lock): Likewise.
383 (pthread_mutex_unlock): Likewise.
384 (pthread_mutexattr_init): Likewise.
385 (pthread_mutexattr_destroy): Likewise.
386 (pthread_once): Likewise.
387 * ptfork.c (pthread_atfork): Likewise.
388 * specific.c (pthread_key_create): Likewise.
389 (pthread_setspecific): Likewise.
390 (pthread_getspecific): Likewise.
392 1998-11-15 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
394 * linuxthreads.texi: Fix punctuation after xref.
396 1998-11-10 H.J. Lu <hjl@gnu.org>
398 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine NR_OPEN
399 if it is defined in <linux/limits.h>.
401 1998-10-29 14:28 Ulrich Drepper <drepper@cygnus.com>
403 * spinlock.h (__pthread_trylock): Define inline.
404 (__pthread_lock): Add extra parameter to declaration. Declare
405 using internal_function.
406 (__pthread_unlock): Declare using internal_function.
407 * spinlock.c (__pthread_lock): Add new parameter. Use it instead
408 of local variable self. Avoid recomputing self. Define using
410 (__pthread_trylock): Remove.
411 (__pthread_unlock): Define using internal_function.
412 * cancel.c: Adjust for __pthread_lock interface change. Use already
413 computed self value is possible.
414 * condvar.c: Likewise.
416 * manager.c: Likewise.
418 * pthread.c: Likewise.
419 * rwlock.c: Likewise.
420 * semaphore.c: Likewise.
421 * signals.c: Likewise.
423 1998-10-27 13:46 Ulrich Drepper <drepper@cygnus.com>
425 * sysdeps/pthread/pthread.h (struct _pthread_cleanup_buffer): Prepend
426 __ to field names of the struct.
427 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_fastlock):
429 (pthread_attr_t): Likewise.
430 (pthread_cond_t): Likewise.
431 (pthread_condattr_t): Likewise.
432 (pthread_mutex_t): Likewise.
433 (pthread_mutexattr_t): Likewise.
434 (pthread_rwlock_t): Likewise.
435 (pthread_rwlockattr_t): Likewise.
436 * attr.c: Adjust for pthread.h and pthreadtypes.h change.
437 * cancel.c: Likewise.
438 * condvar.c: Likewise.
439 * manager.c: Likewise.
441 * pthread.c: Likewise.
442 * ptlongjmp.c: Likewise.
443 * rwlock.c: Likewise.
444 * spinlock.c: Likewise.
446 1998-10-09 Ulrich Drepper <drepper@cygnus.com>
448 * sysdeps/i386/pt-machine.h (get_eflags, set_eflags): Mark these
451 * sysdeps/i386/i686/pt-machine.h: Remove unused inline
454 * Makefile (libpthread-routines): Add pt-machine.
455 * pt-machine.c: New file.
456 * sysdeps/alpha/pt-machine.h: Define PT_EI as extern inline is not
457 yet defined. Use PT_EI in extern inline definitions.
458 * sysdeps/arm/pt-machine.h: Likewise.
459 * sysdeps/i386/pt-machine.h: Likewise.
460 * sysdeps/i386/i686/pt-machine.h: Likewise.
461 * sysdeps/m68k/pt-machine.h: Likewise.
462 * sysdeps/mips/pt-machine.h: Likewise.
463 * sysdeps/powerpc/pt-machine.h: Likewise.
464 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
465 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
467 1998-10-02 Andreas Jaeger <aj@arthur.rhein-neckar.de>
469 * semaphore.h: Include <sys/types.h> so that _pthread_descr
472 1998-09-15 David S. Miller <davem@pierdol.cobaltmicro.com>
474 * sysdeps/sparc/sparc32/pt-machine.h (INIT_THREAD_SELF): Add nr
476 * sysdeps/sparc/sparc64/pt-machine.h (INIT_THREAD_SELF): Likewise.
478 1998-09-12 14:24 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
480 * linuxthreads/sysdeps/unix/sysv/linux/bits/sigthread.h: Add
481 multiple inclusion guard.
483 1998-09-02 11:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
485 * signals.c (sigaction): Check that sig is less than NSIG to avoid
486 array index overflow.
488 1998-09-06 10:56 Ulrich Drepper <drepper@cygnus.com>
490 * sysdeps/pthread/semaphore.h: New file.
492 1998-09-06 09:08 Ulrich Drepper <drepper@cygnus.com>
494 * sysdeps/pthread/bits/libc-lock.h (enum __libc_tsd_key_t): Add
495 _LIBC_TSD_KEY_DL_ERROR.
497 1998-08-31 Ulrich Drepper <drepper@cygnus.com>
499 * sysdeps/i386/i686/pt-machine.h (testandset): Add memory clobber.
500 * sysdeps/i386/pt-machine.h: Likewise.
501 Suggested by Roland McGrath.
503 1998-08-28 13:58 Ulrich Drepper <drepper@cygnus.com>
505 * internals.h: Also define THREAD_GETMEM_NC and THREAD_SETMEM_NC to
506 access thread data with non-constant offsets.
507 * specific.c: Use THREAD_GETMEM_NC and THREAD_SETMEM_NC where
510 * sysdeps/i386/useldt.h: Fix typo. Add THREAD_GETMEM_NC and
511 THREAD_SETMEM_NC definitions.
513 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM_NC and
515 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
517 1998-08-26 15:46 Ulrich Drepper <drepper@cygnus.com>
519 * internals.h: Define THREAD_GETMEM and THREAD_SETMEM to default if
521 (struct _pthread_descr_struct): Add p_self and p_nr field.
522 * manager.c (__pthread_handles): Define second element to point
524 (__pthread_handles_num): Initialize to 2.
525 (__pthread_manager): Use INIT_THREAD_SELF with two arguments.
526 (pthread_start_thread): Likewise.
527 (pthread_handle_create): Start search for free slot at entry 2.
528 Initialize new fields p_self and p_nr.
529 Call __clone with CLONE_PTRACE if available.
530 (pthread_free): Call FREE_THREAD_SELF if available.
531 * pthread.c (__pthread_initial_thread): Initialize new fields.
532 (__pthread_manager_thread): Likewise.
533 (__pthread_initialize_manager): Call __clone with CLONE_PTRACE.
535 * cancel.c: Use THREAD_GETMEM and THREAD_SETMEM to access the
536 elements of the thread descriptor.
537 * condvar.c: Likewise.
540 * manager.c: Likewise.
541 * pthread.c: Likewise.
542 * ptlongjmp.c: Likewise.
543 * semaphore.c: Likewise.
544 * signals.c: Likewise.
545 * specific.c: Likewise.
546 * spinlock.c: Likewise.
548 * sysdeps/alpha/pt-machine.h (INIT_THREAD_SELF): Add extra parameter.
550 * sysdeps/i386/useldt.h: New file.
551 * sysdeps/i386/i686/pt-machine.h: Show how to use this file.
553 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM and
554 THREAD_SETMEM using __thread_self.
555 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
557 1998-08-24 Geoff Keating <geoffk@ozemail.com.au>
559 * spinlock.c (__pthread_lock): Reset p_nextwaiting to NULL if it
560 turned out that we didn't need to queue after all.
562 1998-08-22 Geoff Keating <geoffk@ozemail.com.au>
564 * sysdeps/powerpc/pt-machine.h: Remove testandset, it's not used
565 and wastes space; correct types.
567 1998-08-08 11:18 H.J. Lu <hjl@gnu.org>
569 * signals.c (sigaction): Handle NULL argument.
571 1998-08-04 Ulrich Drepper <drepper@cygnus.com>
573 * sysdeps/unix/sysv/linux/bits/sigthread.h: Use __sigset_t instead
576 1998-08-02 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
578 * Makefile (linuxthreads-version): Extract correct number from
581 1998-07-29 Xavier Leroy <Xavier.Leroy@inria.fr>
583 * Banner: Bump version number to 0.8
584 * FAQ.html: Many updates, in particular w.r.t. debugging.
585 * manager.c: Support for non-default stacksize for
586 LinuxThreads-allocated stacks;
587 don't use guard pages for stacks with default size, rely on
588 rlimit(RLIMIT_STACK) instead (it's cheaper).
590 * cancel.c: Use __pthread_sig_cancel and __pthread_sig_restart
591 everywhere instead of PTHREAD_SIG_CANCEL and PTHREAD_SIG_RESTART.
592 * condvar.c: Likewise.
593 * internals.h: Likewise.
594 * restart.h: Likewise.
595 * signals.c: Likewise.
596 * pthread.c: Likewise; set rlimit(RLIMIT_STACK) as we need it.
598 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
600 * weaks.c: Define pthread_mutexattr_[sg]ettype instead of
601 __pthread_mutexattr_[sg]ettype. Add more weak aliases.
602 * Versions: Put __pthread_mutexattr_settype under version
603 GLIBC_2.0. Don't export __pthread_mutexattr_setkind_np and
604 __pthread_mutexattr_gettype.
606 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
608 * sysdeps/pthread/bits/libc-lock.h: Make
609 __pthread_mutexattr_settype weak. Don't make
610 __pthread_mutexattr_setkind_np weak.
612 1998-07-16 10:52 Ulrich Drepper <drepper@cygnus.com>
614 * manager.c (pthread_handle_create): Check whether sched_setscheduler
615 call can succeed here.
617 * mutex.c: Define __pthread_mutexattr_settype and make
618 __pthread_mutexattr_setkind_np an alias.
619 Likewise for __pthread_mutexattr_gettype.
621 1998-07-15 11:00 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
623 * attr.c (pthread_attr_setschedpolicy): Don't check whether caller
626 1998-07-14 19:38 Ulrich Drepper <drepper@cygnus.com>
628 * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_end.
630 1998-07-11 Andreas Jaeger <aj@arthur.rhein-neckar.de>
632 * Examples/ex6.c: Include <unistd.h> for usleep.
634 1998-06-13 11:04 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
636 * Examples/ex4.c (main): Use exit, not pthread_exit.
638 1998-07-09 13:39 Ulrich Drepper <drepper@cygnus.com>
640 * Versions: Add __pthread_mutexattr_gettype and
641 __pthread_mutexattr_settype.
642 * lockfile.c: Use __pthread_mutexattr_settype instead of
643 __pthread_mutexattr_setkind_np.
644 * mutex.c: Define __pthread_mutexattr_gettype and
645 __pthread_mutexattr_settype.
647 * sysdeps/pthread/pthread.h: Declare __pthread_mutexattr_gettype and
648 __pthread_mutexattr_settype.
649 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init_recursive):
650 Use __pthread_mutexattr_settype.
652 1998-07-08 22:26 Ulrich Drepper <drepper@cygnus.com>
654 * Versions: Add pthread_mutexattr_gettype, pthread_mutexattr_settype.
655 * mutex.c: Define weak alias pthread_mutexattr_gettype and
656 pthread_mutexattr_settype.
657 * sysdeps/pthread/pthread.h: Declare these functions.
658 Move pthread_sigmask and pthread_kill declaration in separate header.
659 * sysdeps/unix/sysv/linux/bits/sigthread.h: New file.
661 1998-07-07 15:20 Ulrich Drepper <drepper@cygnus.com>
663 * Makefile: Add rules to compile and run tests.
664 * Examples/ex1.c: Little changes to fix warnings.
665 * Examples/ex2.c: Likewise.
666 * Examples/ex3.c: Likewise.
667 * Examples/ex4.c: Likewise.
668 * Examples/ex5.c: Likewise.
669 * Examples/ex6.c: New file.
671 1998-07-05 11:54 Ulrich Drepper <drepper@cygnus.com>
673 * Versions: Add pthread_attr_init to GLIBC_2.1 version in libc.
675 1998-07-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
677 * attr.c: Include <string.h>.
679 1998-06-30 11:47 Ulrich Drepper <drepper@cygnus.com>
681 * attr.c: Include errno.h. Use memcpy to copy sched_param.
682 * internals.h: Include limits.h.
683 * manager.c: Use memcpy to copy sched_param.
684 * ptfork.c: Include errno.h.
685 * pthread.c: Likewise.
686 * semaphore.c: Likewise.
687 * specific.c: Likewise.
688 * spinlock.h: Likewise.
689 * sysdeps/pthread/pthread.h: Include only allowed headers. Move
690 type definition to ...
691 * sysdeps/pthread/bits/pthreadtypes.h: ...here. New file.
693 1998-06-29 12:34 Ulrich Drepper <drepper@cygnus.com>
695 * sysdeps/pthread/pthread.h: Use __PMT not __P for function pointers.
697 * sysdeps/pthread/pthread.h: Define various PTHREAD_* symbols also
698 as macros as demanded in POSIX.1, Annex C.
700 1998-06-29 12:29 Ulrich Drepper <drepper@cygnus.com>
702 * internals.h (struct pthread_request): For free use pthread_t
703 instead of pthread_descr.
704 * join.c (pthread_join): Pass thread_id, not th to manager.
705 (pthread_detach): Likewise.
706 * manager.c (__pthread_manager): Except thread ID in FREE_REQ case.
707 (pthread_exited): Remove detached queue code.
708 (pthread_handle_free): Expect thread ID parameter and use it to
709 validate the thread decsriptor. Don't use detached queue.
710 Patches by Xavier Leroy.
712 1998-06-27 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
714 * libpthread.map: Export accept, longjmp, sigaction, siglongjmp,
715 _IO_flockfile, _IO_ftrylockfile, _IO_funlockfile,
716 __pthread_atfork, __pthread_key_create, __pthread_once.
717 * internals.h: Doc fix.
718 * pthread.c (__pthread_initialize): Define again.
720 1998-06-26 Ulrich Drepper <drepper@cygnus.com>
722 * manager.c (pthread_exited): If thread is not detached put it on
724 (pthread_handle_free): If thread is not on list with living threads
725 search on list with detached threads.
727 * sysdeps/pthread/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Correct
728 for new definition of pthread_rwlock_t.
730 * spinlock.c: Correct test whether to compile
731 __pthread_compare_and_swap or not.
733 1998-06-25 19:27 Ulrich Drepper <drepper@cygnus.com>
735 * attr.c: Finish user stack support. Change locking code to be safe
736 in situations with different priorities.
737 * cancel.c: Likewise.
738 * condvar.c: Likewise.
739 * internals.h: Likewise.
741 * manager.c: Likewise.
743 * pthread.c: Likewise.
744 * ptlongjmp.c: Likewise.
746 * rwlock.c: Likewise.
747 * semaphore.c: Likewise.
748 * semaphore.h: Likewise.
749 * signals.c: Likewise.
750 * spinlock.c: Likewise.
751 * spinlock.h: Likewise.
752 * sysdeps/pthread/pthread.h: Likewise.
753 Patches by Xavier Leroy.
755 * sysdeps/i386/i686/pt-machine.h: New file.
757 1998-06-25 Ulrich Drepper <drepper@cygnus.com>
759 * sysdeps/pthread/pthread.h: Make [sg]et_stacksize and
760 [sg]et_stackaddr prototypes always available.
762 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
763 _POSIX_THREAD_ATTR_STACKSIZE and _POSIX_THREAD_ATTR_STACKADDR.
765 1998-06-24 Ulrich Drepper <drepper@cygnus.com>
767 * manager.c (pthread_free): Undo patch from 980430.
768 Reported by David Wragg <dpw@doc.ic.ac.uk>.
770 1998-06-09 15:07 Ulrich Drepper <drepper@cygnus.com>
772 * manager.c: Define __pthread_manager_adjust_prio and use it to
773 increase priority when needed.
774 * internals.h: Add prototype for __pthread_manager_adjust_prio.
775 * mutex.c: Optimize mutexes to wake up only one thread.
776 * pthread.c: Move PID of manager for global variable in structure
778 Patches by Xavier Leroy.
780 1998-06-07 13:47 Ulrich Drepper <drepper@cygnus.com>
782 * sysdeps/pthread/bits/libc-lock.h: Optimize cleanup handlers a bit.
784 1998-06-03 Andreas Jaeger <aj@arthur.rhein-neckar.de>
786 * attr.c: Correct typo.
788 1998-05-01 Ulrich Drepper <drepper@cygnus.com>
790 * manager.c (pthread_free): Unmap guard before the stack.
791 Patch by Matthias Urlichs.
793 1998-04-30 Ulrich Drepper <drepper@cygnus.com>
795 * manager.c (pthread_free): Detect already free child.
796 Patch by Xavier Leroy, reported by Matthias Urlichs.
798 1998-04-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
800 * Makefile (linuxthreads-version): Renamed back from
803 1998-04-21 Ulrich Drepper <drepper@cygnus.com>
805 * ptlongjmp.c: Add prototypes for __libc_siglongjmp and
808 1998-04-20 14:55 Ulrich Drepper <drepper@cygnus.com>
810 * Makefile (libpthread-routines): Add ptlongjmp and spinlock.
811 * internals.h: Add definitions for new spinlock implementation.
812 * ptlongjmp.c: New file.
813 * spinlock.c: New file.
814 * spinlock.h (acquire): Don't reschedule using __sched_yield, use
815 new function __pthread_acquire to prevent deadlocks with thread
816 with different priorities.
817 Patches by Xavier Leroy <Xavier.Leroy@inria.fr>.
819 1998-03-16 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
821 * manager.c (__pthread_manager): Reduce first argument to select
822 to include just the needed file descriptor.
824 1998-03-17 00:06 Ulrich Drepper <drepper@cygnus.com>
826 * manager.c: Fix last patch which caused core dumps.
828 * pthread.c: Correctly handle missing SIGRTMIN.
830 1998-03-15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
832 * libpthread.map: Add __libc_internal_tsd_get and
833 __libc_internal_tsd_set. Add missing cancelable functions. Export
834 libc internal versions of the cancelable functions.
836 1998-03-13 16:51 Ulrich Drepper <drepper@cygnus.com>
838 * weaks.c: Define pthread_attr_init as GLIBC_2.0 and GLIBC_2.1.
840 1998-03-13 00:46 Ulrich Drepper <drepper@cygnus.com>
842 * attr.c: Implement pthread_attr_[gs]etguardsize,
843 pthread_attr_[gs]setstackaddr, pthread_attr_[gs]etstacksize.
844 Change pthread_attr_init to have two interfaces.
845 * internals.h (struct _pthread_descr_struct): Add new fields for
847 * libpthread.map: Add names in GLIBC_2.1 section.
848 * manager.c (pthread_handle_create): Implement guardsize and
850 (pthread_free): Likewise.
851 * pthread.c (pthread_create): Add new interface for changed
853 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
854 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add definition of
857 1998-03-11 00:42 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
859 * manager.c: Enable resetting of the thread scheduling policy
860 to SCHED_OTHER when the parent thread has a different one.
862 1998-02-01 13:51 Ulrich Drepper <drepper@cygnus.com>
864 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
865 _POSIX_ASYNCHRONOUS_IO.
867 * sysdeps/pthread/pthread.h: Define bits for Unix98 variants of
869 * mutex.c: Implement new mutex types.
871 * internals.h: Include <signal.h>.
873 * libpthread.map: Add __erno_location and __h_errno_location.
875 * errno.c: Return pointer to variable actually in use. This might
876 not be the one in the thread structure.
877 * internals.h (struct _pthread_descr_struct): Add new fields p_errnop
879 * manager.c (__pthread_manager): Set p_errnop and p_h_errnop member
880 of manager thread structure.
881 (pthread_handle_create): Set p_errnop and p_h_errnop members for new
883 * pthread.c: Adapt initializer for thread structures.
884 (__pthread_initial_thread): Set p_errnop and p_h_errnop member.
885 (__pthread_reset_main_thread): Reset p_errnop and p_h_errnop of
886 current thread to global variables.
888 1998-01-31 17:27 Ulrich Drepper <drepper@cygnus.com>
890 * rwlock.c: New file.
891 * Makefile (libpthread-routines): Add rwlock.
892 * sysdeps/pthread/pthread.h: Define data structures and declare
894 * libpthread.map: Add new functions.
896 1997-12-18 13:50 Philip Blundell <pb@nexus.co.uk>
898 * sysdeps/arm/pt-machine.h: New file; add ARM support.
899 * sysdeps/arm/Implies: likewise.
900 * README: Document it.
902 1997-12-13 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
904 * signals.c: Remove unneeded initializer for sigwaited, saving a
907 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
909 * semaphore.c (sem_init): Set sem_spinlock only if available.
911 1997-12-04 01:48 Ulrich Drepper <drepper@cygnus.com>
913 * mutex.c: Implement PTHREAD_MUTEX_CHECKERROR.
914 * sysdeps/pthread/pthread.h: Define PTHREAD_MUTEX_CHECKERROR.
916 * Makefile: Update from LinuxThreads 0.7.
917 * internals.h. Likewise.
918 * manager.c: Likewise.
920 * pthread.c: Likewise.
921 * signals.c: Likewise.
922 * specific.c: Likewise.
923 * Examples/ex3.c: Likewise.
925 1997-11-20 18:13 Ulrich Drepper <drepper@cygnus.com>
927 * pthread.c (__pthread_reset_main_thread): Close pipe only if still
930 1997-10-29 05:38 Ulrich Drepper <drepper@cygnus.com>
932 * wrapsyscall.c: Add socket functions which are also cancelation
935 1997-10-19 21:40 Wolfram Gloger <wg@wolfram.dent.med.uni-muenchen.de>
937 * specific.c (__libc_internal_tsd_set, __libc_internal_tsd_get):
938 New functions for fast thread specific data within libc.
940 * internals.h: Add new array p_libc_specific to struct
941 _pthread_descr_struct.
943 * sysdeps/pthread/bits/libc-lock.h: Declare new functions.
945 1997-10-13 05:39 Ulrich Drepper <drepper@cygnus.com>
947 * semaphore.h: Add __BEGIN_DECLS/__END_DECLS.
948 Reported by Ralf Corsepius <corsepiu@faw.uni-ulm.de>.
950 1997-08-29 03:05 Ulrich Drepper <drepper@cygnus.com>
952 * internals.h (struct _pthread_descr_struct): Add definitions for
953 two-level specific key handling.
954 * manager.c (pthread_handle_create): Initialize specific memory array.
955 * specific.c: Implement two-level key handling.
956 * weaks.c: Don't provide dummy key handling.
957 * sysdeps/pthread/bits/libc-lock.h: Typedef __libc_lock_t (no #define).
958 Add definition of __libc_key_t.
959 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define PTHREAD_KEYS_MAX
961 Add definition of _POSIX_THREAD_DESTRUCTOR_ITERATIONS and
962 PTHREAD_DESTRUCTOR_ITERATIONS.
964 * manager.c (pthread_handle_create): Compare mmap result with
967 * ptfork.c: Rename to __pthread_atfork and make old name a weak alias.
968 * sysdeps/pthread/bits/pthread.h: Add prototype for __pthread_atfork.
970 1997-08-22 19:04 Richard Henderson <rth@cygnus.com>
972 sysdeps/sparc -> sysdeps/sparc/sparc32
973 sysdeps/sparc64 -> sysdeps/sparc/sparc64
975 * internals.h: Change definition of THREAD_SELF to be an expression,
976 not a statement that did a return.
977 * sysdeps/alpha/pt-machine.h (THREAD_SELF): Update accordingly.
978 * sysdeps/sparc/sparc32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
979 Follow Solaris and use a "system reserved" register (%g6) to hold
980 the thread descriptor.
981 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
983 1997-08-03 00:09 Ulrich Drepper <drepper@cygnus.com>
985 * mutex.c: Correct pthread_once. Patch by Xavier Leroy.
986 * sysdeps/pthread/pthread.h: Add prototype for __pthread_once.
987 * sysdeps/pthread/bits/pthread.h: Add macros for __libc_once.
989 * semaphore.c: Include spinlock.h only when needed.
991 * specific.c (__pthread_setsepcific, __pthread_getspecific): Reject
992 keys for entries not in use.
994 * weaks.c: Implement key handling functions for real.
996 1997-06-29 01:04 Richard Henderson <richard@gnu.ai.mit.edu>
998 Initial sparc64-linux support:
999 * linuxthreads/sysdeps/sparc64/Implies: New file.
1000 * linuxthreads/sysdeps/sparc64/pt-machine.h: Likewise.
1002 1997-06-29 00:48 Ulrich Drepper <drepper@cygnus.com>
1004 * semaphore.c: Include spinlock.h at correct place.
1007 1997-06-13 10:06 Richard Henderson <rth@tamu.edu>
1009 The Great Bit File Move:
1010 * sysdeps/alpha/semaphorebits.h: -> .../bits/semaphore.h.
1011 * sysdeps/powerpc/semaphorebits.h: Likewise.
1012 * sysdeps/pthread/cmpxchg/semaphorebits.h: Likewise.
1013 * sysdeps/pthread/no-cmpxchg/semaphorebits.h: Likewise.
1014 * sysdeps/pthread/libc-lock.h: -> bits/
1015 * sysdeps/pthread/stdio-lock.h: Likewise.
1016 * sysdeps/unix/sysv/linux/local_lim.h: Likewise.
1017 * sysdeps/unix/sysv/linux/posix_opt.h: Likewise.
1018 * semaphore.h: Likewise.
1019 * sysdeps/pthread/pthread.h: Likewise.
1021 * lockfile.c: <foo.h> -> <bits/foo.h>.
1022 * semaphore.h: Likewise.
1024 * Makefile: (headers): foo.h -> bits/foo.h.
1025 * sysdeps/pthread/Makefile: Likewise.
1027 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1029 * semaphore.c (sem_init): Set sem_spinlock only if available.
1031 * sysdeps/m68k/pt-machine.h (testandset, __compare_and_swap): Fix
1034 1997-04-09 03:00 Ulrich Drepper <drepper@cygnus.com>
1036 Update from LinuxThreads 0.6.
1038 * attr.c (pthread_attr_getdetachstate): Use __sched_get_priority_max
1039 and __sched_get_priority_min instead of names without `__'.
1041 * manager.c: Rewrite large parts to implement opaque pthread_t.
1043 * cancel.c: Adapt for opaque pthread_t type.
1044 * condvar.c: Likewise.
1045 * errno.c: Likewise.
1047 * mutex.c: Likewise.
1048 * pthread.c: Likewise.
1049 * signals.c: Likewise.
1050 * specific.c: Likewise.
1051 * restart.h: Likewise.
1052 * queue.h: Likewise.
1053 * Examples/ex3.c: Likewise.
1054 * Examples/ex4.c: Likewise.
1055 * sysdeps/pthread/pthread.h: Likewise.
1057 * pthread.c: Accumulate time for all threads in thread manager.
1059 * semaphore.c: Implement fallback implementation for architectures
1060 sometimes missing compare-exchange operations.
1062 * cancel.c (pthread_cancel): Validate handle argument.
1063 * join.c (pthread_join): Likewise.
1064 (pthread_detach): Likewise.
1065 * signals.c (pthread_kill): Likewise.
1067 * spinlock.h (acquire): Use __sched_yield not sched_yield.
1069 * queue.h (enqueue): Enqueue thread according to priority.
1071 * internals.c (struct pthread_start_args): New struct for passing
1072 args to cloning function.
1073 (struct _pthread): Rename to _pthread_descr_struct and adapt for
1076 * Examples/Makefile (clean): Pass -f option to rm.
1078 * sysdeps/i386/pt-machine.h: Add check for compare-exchange instruction
1079 and define TEST_FOR_COMPARE_AND_SWAP.
1080 * sysdeps/i386/i486/pt-machine.h: Removed.
1082 * sysdeps/unix/sysv/linux/local_lim.h (PTHREAD_THREADS_MAX): Increase
1085 1997-04-04 16:38 Ulrich Drepper <drepper@cygnus.com>
1087 * restart.h (suspend): Clear p_signal before suspending.
1088 (suspend_with_cancellation): Likewise.
1089 Patch by Xavier Leroy <Xavier.Leroy@inria.fr>.
1091 * weaks.c: Make __pthread_key_create return 1.
1092 * sysdeps/pthread/libc-lock.h: Define __libc_key_create,
1093 __libc_getspecific, __libc_setspecific, and __libc_key_t.
1094 * sysdeps/pthread/stdio-lock.h: Don't care for implementation not
1097 1997-03-19 15:13 Miguel de Icaza <miguel@nuclecu.unam.mx>
1099 * sysdeps/sparc/pt-machine (RELEASE): Fix.
1101 1997-03-01 07:55 Geoff Keating <geoffk@ozemail.com.au>
1103 * sysdeps/powerpc/Implies: Added.
1104 * sysdeps/powerpc/pt-machine.h: Added.
1105 * sysdeps/powerpc/semaphorebits.h: Added.
1107 1997-01-22 01:22 Ulrich Drepper <drepper@cygnus.com>
1109 * linuxtheads/pthread.c (__pthread_initial_thread): Correct
1111 (__pthread_manager_thread): Likewise.
1112 Reported by Andreas Jaeger.
1114 1997-01-18 22:15 Richard Henderson <rth@tamu.edu>
1116 Since sigset_t no longer fits in a register, we can't pass in the
1117 thread's initial mask so easily. Take this opportunity to simplify
1118 the clone implementation by only accepting a single void* argument.
1120 * linuxthreads/manager.c (__pthread_manager): Put thread vitals
1121 in the thread struct instead of as arguments through clone.
1122 (pthread_start_thread): Look for them there.
1123 * linuxthreads/internals.h (struct _pthread): Add p_initial_fn,
1124 p_initial_fn_arg, p_initial_mask. Fix __pthread_manager proto.
1125 * linuxthreads/pthread.c (pthread_initialize_manager): Revise