1 2000-04-01 Andreas Jaeger <aj@suse.de>
3 * attr.c: Use shlib-compat macros.
4 * oldsemaphore.c: Likewise.
8 2000-03-26 Ulrich Drepper <drepper@redhat.com>
10 * semaphore.c (sem_timedwait): New function.
11 Patch by Carl Mailloux <carlm@oricom.ca>.
12 * semaphore.h: Declare sem_timedwait.
13 * Versions [libpthread] (GLIBC_2.2): Add sem_timedwait.
15 2000-03-26 Roland McGrath <roland@baalperazim.frob.com>
17 * sysdeps/pthread/Makefile: File removed.
19 2000-03-23 Ulrich Drepper <drepper@redhat.com>
21 * mutex.c (__pthread_reset_pthread_once): Reset once_masterlock.
22 * internals.h (__pthread_reset_pthread_once): Add prototype.
23 * ptfork.c (__fork): Call __pthread_reset_pthread_once.
25 * manager.c (pthread_handle_create): Store ID of new thread before
28 2000-03-21 Ulrich Drepper <drepper@redhat.com>
30 * attr.c: Use new macros from shlib-compat.h to define versions.
31 * oldsemaphore.c: Likewise.
32 * semaphore.c: Likewise.
35 * pthread.c: Update for new SHLIB_COMPAT definition.
37 * manager.c (__pthread_manager): Unmask debug signal.
39 * pthread.c (pthread_initialize): Test for address of __dso_handle
40 being NULL, not value. Use __on_exit, not on_exit.
41 Patch by Andreas Jaeger <aj@suse.de>.
43 * pthread.c: Use new macros from shlib-compat.h to define versions.
45 2000-03-19 Ulrich Drepper <drepper@redhat.com>
47 * pthread.c (pthread_initialize): Instead of on_exit use
48 __cxa_atexit if __dso_label is available to allow unloading the
49 libpthread shared library.
51 2000-03-16 Ulrich Drepper <drepper@redhat.com>
53 * condvar.c: Make tests for ownership of mutex less strict.
55 2000-03-14 Ulrich Drepper <drepper@redhat.com>
57 * condvar.c (pthread_cond_wait): Check whether mutex is owned by
58 current thread and return error if not.
59 (pthread_cond_timedwait_relative_old): Likewise.
60 (pthread_cond_timedwait_relative_new): Likewise.
62 * mutex.c (__pthread_once): Handle cancelled init function correctly.
63 (pthread_once_cancelhandler): New function.
64 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
66 2000-03-14 Andreas Jaeger <aj@suse.de>
68 * pthread.c (pthread_handle_sigcancel_rt): GS has been renamed to
70 (pthread_handle_sigrestart_rt): Likewise.
71 * signals.c (pthread_sighandler_rt): Likewise.
73 2000-03-02 Andreas Jaeger <aj@suse.de>
75 * sysdeps/pthread/bits/libc-lock.h: Fix typo.
76 Reported by Sean Chen <sean.chen@turbolinux.com>.
78 2000-02-28 Andreas Jaeger <aj@suse.de>
82 2000-02-27 Ulrich Drepper <drepper@redhat.com>
84 * rwlock.c: Define __* variants of the functions and make old names
86 * Versions [GLIBC_2.2]: Export the __pthread_rwlock_* functions.
87 * sysdeps/pthread/bits/libc-lock.h: Define __libc_rwlock_* macros.
89 2000-02-25 Andreas Jaeger <aj@suse.de>
91 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
92 pwrite64, lseek64, open64, and __open64 with version 2.2.
94 2000-02-22 Ulrich Drepper <drepper@redhat.com>
96 * semaphore.h (SEM_FAILED): Use 0 not NULL.
98 2000-02-14 Ulrich Drepper <drepper@redhat.com>
100 * condvar.c (pthread_cond_timedwait_relative_old): Tight loop with
101 nanosleep does not work either. Get absolute time inside the
103 (pthread_cond_timedwait_relative_new): Likewise.
104 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
106 2000-02-13 Andreas Jaeger <aj@suse.de>
108 * condvar.c (pthread_cond_timedwait_relative_new): Fix last patch.
109 (pthread_cond_timedwait_relative_old): Likewise.
111 2000-02-13 Ulrich Drepper <drepper@redhat.com>
113 * condvar.c (pthread_cond_timedwait_relative_old): Undo last patch
114 but keep the code around. A bug in the kernel prevent us from
116 (pthread_cond_timedwait_relative_new): Likewise.
117 (PR libc/1597 and libc/1598).
119 2000-02-01 Kaz Kylheku <kaz@ashi.footprints.net>
121 * condvar.c (pthread_cond_timedwait_relative_old): Do tight
122 loop around nanosleep calls instead of around most of the function
123 (pthread_cond_timedwait_relative_new): Likewise.
124 body. Got rid of backwards goto and one local.
126 2000-01-31 Ulrich Drepper <drepper@redhat.com>
128 * condvar.c (pthread_cond_timedwait_relative_old): Recompute time
129 before every nanosleep call to account for time spent in the rest
131 (pthread_cond_timedwait_relative_new): Likewise.
132 Patch by khendricks@ivey.uwo.ca (PR libc/1564).
134 2000-01-29 Ulrich Drepper <drepper@redhat.com>
136 * condvar.c (pthread_cond_timedwait_relative_old): Get remaining time
137 from nanosleep call so that in case we restart we only wait for the
139 (pthread_cond_timedwait_relative_new): Likewise.
140 Patch by khendricks@ivey.uwo.ca (PR libc/1561).
142 2000-01-18 Ulrich Drepper <drepper@cygnus.com>
144 * manager.c (pthread_allocate_stack): Compute guard page address
145 correctly. Patch by HJ Lu.
147 * sysdeps/pthread/pthread.h: Define
148 PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP.
150 2000-01-16 Ulrich Drepper <drepper@cygnus.com>
152 * rwlock.c (pthread_rwlock_unlock): Correct one more problem with
154 (pthread_rwlockattr_setkind_np): Allow
155 PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP.
156 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
158 2000-01-12 Ulrich Drepper <drepper@cygnus.com>
160 * internals.h (pthread_readlock_info): New structure.
161 (_pthread_descr_struct): Add p_readlock_list, p_readlock_free, and
162 p_untracked_readlock_count.
163 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
164 Add initializers for new fields.
165 * manager.c (pthread_free): Free read/write lock lists.
166 * queue.h (queue_is_empty): New function.
167 * rwlock.c: Implement requirements about when readers should get
169 * sysdeps/pthread/pthread.h
170 (PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP): New definition.
171 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_rwlock_t):
172 Define this name as well.
173 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
175 2000-01-05 Ulrich Drepper <drepper@cygnus.com>
177 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
178 Adjust initializers for struct _pthread_descr_struct change.
179 * internals.h (struct _pthread_descr_struct): Move new elements to
182 2000-01-03 Kaz Kylheku <kaz@ashi.footprints.net>
184 Redesigned how cancellation unblocks a thread from internal
185 cancellation points (sem_wait, pthread_join,
186 pthread_cond_{wait,timedwait}).
187 Cancellation won't eat a signal in any of these functions
188 (*required* by POSIX and Single Unix Spec!).
189 * condvar.c: Spontaneous wakeup on pthread_cond_timedwait won't eat a
190 simultaneous condition variable signal (not required by POSIX
191 or Single Unix Spec, but nice).
192 * spinlock.c: __pthread_lock queues back any received restarts
193 that don't belong to it instead of assuming ownership of lock
194 upon any restart; fastlock can no longer be acquired by two threads
196 * restart.h: Restarts queue even on kernels that don't have
197 queued real time signals (2.0, early 2.1), thanks to atomic counter,
198 avoiding a rare race condition in pthread_cond_timedwait.
200 1999-12-31 Andreas Jaeger <aj@suse.de>
202 * internals.h: Remove duplicate prototype declarations.
204 * weaks.c: Remove __THROW from prototypes since the file is not
205 compiled by a C++ compiler.
206 * internals.h: Likewise.
208 1999-12-30 Andreas Jaeger <aj@suse.de>
210 * sysdeps/pthread/pthread.h: Move internal functions to...
211 * sysdeps/pthread/bits/libc-lock.h: ...here.
213 1999-12-29 Andreas Jaeger <aj@suse.de>
215 * sysdeps/pthread/pthread.h: Fix typos, reformat comments.
217 1999-12-28 Ulrich Drepper <drepper@cygnus.com>
219 * sysdeps/alpha/pt-machine.h: Move stack_pointer definition to the
222 * manager.c (__pthread_start): Add one more cast to prevent
223 warning on 64bit machines.
225 1999-12-21 Ulrich Drepper <drepper@cygnus.com>
227 * manager.c (pthread_handle_create): Set p_pid of new thread
228 before calling the callback function to report a new thread.
230 1999-12-20 Andreas Jaeger <aj@suse.de>
232 * pthread.c (pthread_initialize): Move getrlimit call after
235 1999-12-18 Ulrich Drepper <drepper@cygnus.com>
237 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
238 pwrite64, lseek64, open64, and __open64.
239 * wrapsyscall.c: Define pread, __pread64, pread64, pwrite, __pwrite64,
240 pwrite64, lseek64, open64, and __open64.
242 * manager.c (pthread_allocate_stack): Correct computation of
243 new_thread_bottom. Correct handling of stack size and when the
244 rlimit method to guard for stack growth is used.
245 * pthread.c (pthread_initialize): Stack limit must be STACK_SIZE
246 minus one pagesize (not two).
248 1999-12-03 Andreas Jaeger <aj@suse.de>
250 * Versions: Add __res_state with version GLIBC_2.2.
252 * errno.c (__res_state): New function to return thread specific
255 * pthread.c (pthread_initialize): Initialize p_resp.
256 (__pthread_reset_main_thread): Also set p_resp.
258 * manager.c (pthread_handle_create): Initialize p_resp.
260 * internals.h: Add thread specific resolver state.
261 Based on patches by Adam D. Bradley <artdodge@cs.bu.edu>.
263 1999-12-01 Ulrich Drepper <drepper@cygnus.com>
265 * sysdeps/i386/pt-machine.h: Move stack_pointer definition to the
267 * sysdeps/i386/i686/pt-machine.h: Likewise.
268 Patches by Alan Modra <alan@SPRI.Levels.UniSA.Edu.Au>.
270 1999-11-23 Ulrich Drepper <drepper@cygnus.com>
272 * manager.c (pthread_start_thread_event): Initialize p_pid already
275 1999-11-22 Ulrich Drepper <drepper@cygnus.com>
277 * internals.h: Add prototype for __pthread_manager_event.
278 * manager.c (__pthread_manager_event): New function.
279 (pthread_start_thread_event): Correct computation of self.
280 Use INIT_THREAD_SELF.
281 * pthread.c (__pthread_manager_thread): Initialize p_lock.
282 (__pthread_initialize_manager): Respect event flags also for creation
283 of the manager thread.
285 1999-11-08 Ulrich Drepper <drepper@cygnus.com>
287 * pthread.c (__pthread_initialize_manager): Initialize
288 __pthread_manager_thread.p_tid.
290 1999-11-02 Ulrich Drepper <drepper@cygnus.com>
292 * internals.h: Declare __pthread_last_event.
293 * manager.c: Define __pthread_last_event.
294 (pthread_handle_create): Set __pthread_last_event.
295 (pthread_exited): Likewise.
296 * join.c (pthread_exit): Likewise.
298 * Makefile (libpthread-routines): Add events.
299 * events.c: New file.
300 * internals.h: Protect against multiple inclusion.
301 Include thread_dbP.h header.
302 (struct _pthread_descr_struct): Add new fields p_report_events and
304 Declare event reporting functions.
305 * join.c (pthread_exit): Signal event if this is wanted.
306 * manager.c (__pthread_threads_events): New variable.
307 (pthread_handle_create): Take new parameters with event information.
308 Signal TD_CREATE event if wanted.
309 (__pthread_manager): Adjust pthread_handle_create call.
310 (pthread_start_thread_event): New function. Block until manager is
311 finished and then call pthread_start_thread.
312 (pthread_exited): Signal TD_REAP event if wanted.
314 1999-10-26 Ulrich Drepper <drepper@cygnus.com>
316 * restart.h (suspend_with_cancellation): Rewrite as a macro.
318 * condvar.c (pthread_cond_timedwait_relative): Don't mark as inline.
320 1999-10-25 Andreas Jaeger <aj@suse.de>
322 * internals.h: Remove K&R compatibility.
323 * no-tsd.c: Likewise.
324 * semaphore.h: Likewise.
325 * signals.c: Likewise.
326 * sysdeps/pthread/bits/libc-tsd.h: Likewise.
327 * sysdeps/unix/sysv/linux/bits/sigthread.h: Likewise.
330 1999-10-21 Xavier Leroy <Xavier.Leroy@inria.fr>
332 * linuxthreads/pthread.c: For i386, wrap pthread_handle_sigrestart
333 and pthread_handle_sigcancel with functions that restore
334 %gs from the signal context. For each signal handling function,
335 two wrappers are required, one for a non-RT signal and one for
337 * linuxthreads/signal.c: For i386, add code to restore %gs
338 from the signal context in pthread_sighandler and
339 pthread_sighandler_rt.
341 1999-10-17 Ulrich Drepper <drepper@cygnus.com>
343 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add cast.
345 1999-10-14 Ulrich Drepper <drepper@cygnus.com>
347 * pthread.c (__pthread_initial_thread): Pass argument to
348 PTHREAD_START_ARGS_INITIALIZER.
349 (__pthread_manager_thread): Likewise.
351 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add parameter to
354 * manager.c (pthread_handle_create): Remove p_startfct initialization.
356 * internals.h (_pthread_descr_struct): We don't need p_startfct field.
358 1999-10-12 Ulrich Drepper <drepper@cygnus.com>
360 * internals.h: Correct return types for __libc_read and __libc_write.
362 1999-10-09 Andreas Jaeger <aj@suse.de>
364 * internals.h: Add __new_sem_post to get prototype in
365 manager.c; include semaphore.h for needed types.
367 1999-10-08 Ulrich Drepper <drepper@cygnus.com>
369 * manager.c (__pthread_manager) [REQ_POST]: Use __new_sem_post
370 directly instead of calling sem_post which should not be necessary
371 but is faster and might help in some case to work around problems.
372 Patch by khendricks@ivey.uwo.ca [libc/1382].
374 1999-10-08 Andreas Schwab <schwab@suse.de>
376 * sysdeps/pthread/Subdirs: New file.
379 1999-10-07 Ulrich Drepper <drepper@cygnus.com>
382 * internals.h (struct _pthread_descr_struct): Add p_startfct.
383 * manager.c (pthread_handle_create): Initialize p_startfct.
384 * pthread.c: Define __linuxthread_pthread_sizeof_descr variable.
386 1999-09-25 Ulrich Drepper <drepper@cygnus.com>
388 * manager.c (__linuxthreads_pthread_threads_max): New variable.
389 * specific.c (__linuxthreads_pthread_keys_max): New variable.
390 (__linuxthreads_pthread_key_2ndlevel_size): New variable.
392 * condvar.c (pthread_cond_timedwait_relative): Never return with
393 EINTR. Patch by Andreas Schwab.
395 1999-09-19 Ulrich Drepper <drepper@cygnus.com>
397 * signals.c (sigaction): Correct last patch. Don't select
398 pthread_sighandler_rt based on the signal number but instead of
401 1999-09-23 Ulrich Drepper <drepper@cygnus.com>
403 * specific.c: Move definitions of struct pthread_key_struct and
404 destr_function to ...
405 * internals.h: ...here.
407 1999-09-18 Ulrich Drepper <drepper@cygnus.com>
409 * pthread.c (pthread_handle_sigrestart_rt): New function. Use
410 this instead of pthread_handle_sigrestart if the signal is an RT
413 * signals.c: Handle passing through of sighandler arguments also
414 for real-time signals.
416 1999-09-03 Andreas Schwab <schwab@suse.de>
418 * ptfork.c (__fork): Renamed from fork and use __libc_fork. Add
420 (__vfork): New function, alias vfork.
421 * Versions: Export __fork, vfork, and __vfork in libpthread.
423 1999-08-23 Andreas Schwab <schwab@suse.de>
425 * signals.c (pthread_sighandler): Add SIGCONTEXT_EXTRA_ARGS to
426 call to signal handler.
428 1999-08-20 Ulrich Drepper <drepper@cygnus.com>
430 * pthread.c (__pthread_reset_main_thread): Undo last change.
431 (__pthread_kill_other_threads_np): Reset signal handlers for the
432 signals we used in the thread implementation here.
434 1999-08-19 Ulrich Drepper <drepper@cygnus.com>
436 * pthread.c (__pthread_reset_main_thread): Reset signal handlers
437 for the signals we used in the thread implementation [PR libc/1234].
439 * Versions: Export __pthread_kill_other_threads_np from libpthread
442 * signals.c: Pass sigcontext through wrapper to the user function.
444 1999-08-01 Ulrich Drepper <drepper@cygnus.com>
446 * Versions [ld.so] (GLIBC_2.0): Export __libc_internal_tsd_get and
447 __libc_internal_tsd_set.
449 1999-07-29 Andreas Jaeger <aj@arthur.rhein-neckar.de>
451 * manager.c: Remove inclusion of <linux/tasks.h> since it's not
454 1999-07-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
456 * internals.h: Align _pthread_descr_struct to 32 bytes.
457 Reported by Tim Hockin <thockin@cobaltnet.com>, close PR
460 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
462 * oldsemaphore.c (sem_compare_and_swap): Fix use of compare and
465 1999-07-09 Cristian Gafton <gafton@redhat.com>
467 * Makefile (libpthread-routines): Add oldsemaphore routine.
468 * Versions: Add sem_destroy, sem_getvalue, sem_init, sem_post,
469 sem_trywait, and sem_wait to GLIBC_2.1.
470 * oldsemaphore.c: New file.
471 * semaphore.c: Add default_symbol_versions for the changed functions.
472 (__new_sem_init): Rename from sem_init.
473 (__new_sem_post): Rename from sem_post.
474 (__new_sem_wait): Rename from sem_wait.
475 (__new_sem_trywait): Rename from sem_trywait.
476 (__new_sem_getvalue): Rename from sem_getvalue.
477 (__new_sem_destroy): Rename from sem_destroy.
479 1999-06-23 Robey Pointer <robey@netscape.com>
481 * internals.h: Added p_nextlock entry to separate queueing for a
482 lock from queueing for a CV (sometimes a thread queues on a lock
483 to serialize removing itself from a CV queue).
484 * pthread.c: Added p_nextlock to initializers.
485 * spinlock.c: Changed to use p_nextlock instead of p_nextwaiting.
487 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
489 * manager.c (pthread_handle_create): Free mmap region after stack
490 if clone failed. Patch by Kaz Kylheku <kaz@ashi.FootPrints.net>.
492 1999-05-23 Andreas Jaeger <aj@arthur.rhein-neckar.de>
494 * man/pthread_cond_init.man: Correct example.
495 Reported by Tomas Berndtsson <tomas@nocrew.org>.
497 * linuxthreads.texi (Condition Variables): Likewise.
499 1999-05-18 Jakub Jelinek <jj@ultra.linux.cz>
501 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): Use
502 casx not cas, also successful casx returns the old value in rd
503 and not the new value.
505 1999-05-16 Xavier Leroy <Xavier.Leroy@inria.fr>
507 * manager.c: If pthread_create() is given a NULL attribute
508 and the thread manager runs with a realtime policy, set the
509 scheduling policy of the newly created thread back to SCHED_OTHER.
510 * manager.c: If the PTHREAD_INHERIT_SCHED attribute is given,
511 initialize the schedpolicy field of new_thread->p_start_args
512 to that of the calling thread.
514 1999-04-29 Ulrich Drepper <drepper@cygnus.com>
516 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): cas
517 instruction does not allow memory element to use offset.
519 1999-04-28 Ulrich Drepper <drepper@cygnus.com>
521 * manager.c (pthread_allocate_stack): Optimize initialization of new
524 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_define_initialized):
525 Don't use initializer since it is all zeroes.
526 (__libc_once_define): Likewise.
528 1999-04-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
530 * sysdeps/arm/Implies: Removed since cmpxchg/no-cmpxchg
531 doesn't exist anymore.
532 * sysdeps/i386/Implies: Likewise.
533 * sysdeps/m68k/Implies: Likewise.
534 * sysdeps/mips/Implies: Likewise.
535 * sysdeps/powerpc/Implies: Likewise.
536 * sysdeps/sparc/sparc32/Implies: Likewise.
537 * sysdeps/sparc/sparc64/Implies: Likewise.
539 1999-04-15 Ulrich Drepper <drepper@cygnus.com>
541 * sysdeps/alpha/bits/semaphore.h: Removed.
542 * sysdeps/powerpc/bits/semaphore.h: Removed.
543 * sysdeps/pthread/cmpxchg/bits/semaphore.h: Removed.
544 * sysdeps/pthread/no-cmpxchg/bits/semaphore.h: Removed.
545 * Makefile (headers): Remove bits/semaphore.h.
547 * semaphore.h: Define _pthread_descr if necessary.
548 Don't include limits.h. Define SEM_VALUE_MAX directly.
550 (sem_t): Protect element names with leading __.
551 Add declarations for sem_close, sem_open, and sem_unlink.
552 * semaphore.c: Adjust all functions for new element names.
553 Define sem_close, sem_open, and sem_unlink.
554 * Versions (libthread): Add sem_close, sem_open, and sem_unlink for
556 * sysdeps/pthread/bits/pthreadtypes.h: Define _pthread_descr only if
559 1999-03-16 H.J. Lu <hjl@gnu.org>
561 * specific.c (pthread_key_delete): Check th->p_terminated to see
562 if the thread is running.
564 * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set):
565 Added to GLIBC_2.0 for libc.so.
567 1999-02-12 H.J. Lu <hjl@gnu.org>
569 * Versions (__libc_current_sigrtmin, __libc_current_sigrtmax,
570 __libc_allocate_rtsig): Added to GLIBC_2.1.
572 * internals.h (DEFAULT_SIG_RESTART): Removed.
573 (DEFAULT_SIG_CANCEL): Removed.
575 * pthread.c (init_rtsigs, __libc_current_sigrtmin,
576 __libc_current_sigrtmax, __libc_allocate_rtsig): New functions.
577 (__pthread_sig_restart, __pthread_sig_cancel,
578 __pthread_sig_debug): Initialized.
579 (pthread_initialize): Call init_rtsigs () to initialize
582 1999-02-03 H.J. Lu <hjl@gnu.org>
584 * manager.c (__pthread_manager): Do block __pthread_sig_debug.
585 Don't restart the thread which sent REQ_DEBUG.
586 (pthread_start_thread): Check if __pthread_sig_debug > 0
589 * pthread.c (__pthread_initialize_manager): Suspend ourself
590 after sending __pthread_sig_debug to gdb instead of
591 __pthread_sig_cancel.
593 1999-01-24 H.J. Lu <hjl@gnu.org>
595 * manager.c (__pthread_manager): Delete __pthread_sig_debug
596 from mask if __pthread_sig_debug > 0.
597 (pthread_handle_create): Increment __pthread_handles_num.
599 * manager.c (pthread_handle_create): Don't pass CLONE_PTRACE to clone.
600 * pthread.c (__pthread_initialize_manager): Likewise.
602 * pthread.c (pthread_initialize): Use __libc_allocate_rtsig (1)
603 instead of __libc_allocate_rtsig (2).
604 (__pthread_initialize_manager): Send __pthread_sig_debug to gdb
605 instead of __pthread_sig_cancel.
606 (pthread_handle_sigdebug): Fix comments.
608 1999-01-21 Ulrich Drepper <drepper@cygnus.com>
610 * manager.c (pthread_allocate_stack): Set
611 __pthread_nonstandard_stacks if user-specified stack is used.
613 1999-01-16 Ulrich Drepper <drepper@cygnus.com>
615 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _LFS_ASYNCHRONOUS_IO,
616 _LFS_LARGEFILE, _LFS64_LARGEFILE, and _LFS64_STDIO from Unix98.
618 1999-01-07 Xavier Leroy <Xavier.Leroy@inria.fr>
620 * pthread.c: Use a third signal __pthread_sig_debug distinct
621 from __pthread_sig_cancel to notify gdb when a thread is
623 * manager.c: Likewise.
624 * internals.h: Likewise.
625 * signals.c: The implementation of sigwait(s) assumed that
626 all signals in s have signal handlers already attached.
627 This is not required by the standard, so make it work
628 also if some of the signals have no handlers.
630 1999-01-05 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
632 * linuxthreads.texi: Remove pointers from first @node. Move old
633 @node spec inside comment.
635 1998-12-31 Ulrich Drepper <drepper@cygnus.com>
637 * sysdeps/pthread/bits/stdio-lock.h: Define _IO_lock_lock and
640 1998-12-29 Ulrich Drepper <drepper@cygnus.com>
642 * semaphore.c (sem_trywait): Don't forget to unlock the semaphore
643 lock. Patch by Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>.
645 1998-12-21 Ulrich Drepper <drepper@cygnus.com>
647 * manager.c: Threads now send __pthread_sig_cancel on termination.
648 Change clone call and signal masks.
649 * thread.c (pthread_handle_sigrestart): Remove special code for
651 (pthread_handle_sigcancel): In manager thread call
652 __pthread_manager_sighandler.
653 * sysdeps/i386/pt-machine.h (__compare_and_swap): Add memory clobber.
654 * sysdeps/i386/i686/pt-machine.h: Likewise.
655 Patches by Xavier Leroy.
657 1998-12-14 Ulrich Drepper <drepper@cygnus.com>
659 * spinlock.c (__pthread_unlock): Don't crash if called for an
660 untaken mutex. Reported by Ruslan V. Brushkoff <rus@Snif.Te.Net.UA>.
662 * Examples/ex6.c: Unbuffer stdout and reduce sleep time to reduce
665 1998-12-13 Ulrich Drepper <drepper@cygnus.com>
667 * Examples/ex3.c: Wait until all threads are started before
668 searching for the number to avoid race condition on very fast
671 1998-12-08 Andreas Jaeger <aj@arthur.rhein-neckar.de>
673 * sysdeps/pthread/pthread.h: Remove __pthread_setcanceltype
674 declaration since it's not needed.
676 * sysdeps/pthread/pthread.h: Move internal functions to ...
677 * internals.h: ...here.
679 1998-12-02 H.J. Lu <hjl@gnu.org>
681 * pthread.c (__pthread_sig_restart): Initiliaze to 0 if
683 (__pthread_sig_cancel): Likewise.
685 1998-12-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
687 * wrapsyscall.c: Include <sys/mman.h> for msync,
688 <stdlib.h> for system and <termios.h> for tcdrain prototype.
689 Correct msync declaration.
691 1998-11-29 Roland McGrath <roland@baalperazim.frob.com>
693 * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_define, __libc_tsd_get,
694 __libc_tsd_set): New macros for new interface.
695 * no-tsd.c: New file, provide uninitialized defns of
696 __libc_internal_tsd_get and __libc_internal_tsd_set.
697 * Makefile (routines): Add no-tsd.
699 1998-10-12 Roland McGrath <roland@baalperazim.frob.com>
701 * internals.h: Include <bits/libc-tsd.h>, not <bits/libc-lock.h>.
702 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
703 __libc_internal_tsd_set): Move decls to ...
704 * sysdeps/pthread/bits/libc-tsd.h: New file for __libc_internal_tsd_*
707 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
708 __libc_internal_tsd_set): Make these pointers to functions, not
709 functions; remove #pragma weak decls for them.
710 * specific.c (__libc_internal_tsd_get, __libc_internal_tsd_set):
711 Define static functions and initialized pointers to them.
713 1998-11-18 Ulrich Drepper <drepper@cygnus.com>
715 * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES.
716 (CFLAGS-specific.c): Likewise.
717 (CFLAGS-pthread.c): Likewise.
718 (CFLAGS-ptfork.c): Likewise.
719 (CFLAGS-cancel.c): Likewise.
720 * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions
721 as weak references if __NO_WEAK_PTHREAD_ALIASES is defined.
723 * mutex.c (pthread_mutex_init): Define as strong symbol.
724 (pthread_mutex_destroy): Likewise.
725 (pthread_mutex_trylock): Likewise.
726 (pthread_mutex_lock): Likewise.
727 (pthread_mutex_unlock): Likewise.
728 (pthread_mutexattr_init): Likewise.
729 (pthread_mutexattr_destroy): Likewise.
730 (pthread_once): Likewise.
731 * ptfork.c (pthread_atfork): Likewise.
732 * specific.c (pthread_key_create): Likewise.
733 (pthread_setspecific): Likewise.
734 (pthread_getspecific): Likewise.
736 1998-11-15 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
738 * linuxthreads.texi: Fix punctuation after xref.
740 1998-11-10 H.J. Lu <hjl@gnu.org>
742 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine NR_OPEN
743 if it is defined in <linux/limits.h>.
745 1998-10-29 14:28 Ulrich Drepper <drepper@cygnus.com>
747 * spinlock.h (__pthread_trylock): Define inline.
748 (__pthread_lock): Add extra parameter to declaration. Declare
749 using internal_function.
750 (__pthread_unlock): Declare using internal_function.
751 * spinlock.c (__pthread_lock): Add new parameter. Use it instead
752 of local variable self. Avoid recomputing self. Define using
754 (__pthread_trylock): Remove.
755 (__pthread_unlock): Define using internal_function.
756 * cancel.c: Adjust for __pthread_lock interface change. Use already
757 computed self value is possible.
758 * condvar.c: Likewise.
760 * manager.c: Likewise.
762 * pthread.c: Likewise.
763 * rwlock.c: Likewise.
764 * semaphore.c: Likewise.
765 * signals.c: Likewise.
767 1998-10-27 13:46 Ulrich Drepper <drepper@cygnus.com>
769 * sysdeps/pthread/pthread.h (struct _pthread_cleanup_buffer): Prepend
770 __ to field names of the struct.
771 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_fastlock):
773 (pthread_attr_t): Likewise.
774 (pthread_cond_t): Likewise.
775 (pthread_condattr_t): Likewise.
776 (pthread_mutex_t): Likewise.
777 (pthread_mutexattr_t): Likewise.
778 (pthread_rwlock_t): Likewise.
779 (pthread_rwlockattr_t): Likewise.
780 * attr.c: Adjust for pthread.h and pthreadtypes.h change.
781 * cancel.c: Likewise.
782 * condvar.c: Likewise.
783 * manager.c: Likewise.
785 * pthread.c: Likewise.
786 * ptlongjmp.c: Likewise.
787 * rwlock.c: Likewise.
788 * spinlock.c: Likewise.
790 1998-10-09 Ulrich Drepper <drepper@cygnus.com>
792 * sysdeps/i386/pt-machine.h (get_eflags, set_eflags): Mark these
795 * sysdeps/i386/i686/pt-machine.h: Remove unused inline
798 * Makefile (libpthread-routines): Add pt-machine.
799 * pt-machine.c: New file.
800 * sysdeps/alpha/pt-machine.h: Define PT_EI as extern inline is not
801 yet defined. Use PT_EI in extern inline definitions.
802 * sysdeps/arm/pt-machine.h: Likewise.
803 * sysdeps/i386/pt-machine.h: Likewise.
804 * sysdeps/i386/i686/pt-machine.h: Likewise.
805 * sysdeps/m68k/pt-machine.h: Likewise.
806 * sysdeps/mips/pt-machine.h: Likewise.
807 * sysdeps/powerpc/pt-machine.h: Likewise.
808 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
809 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
811 1998-10-02 Andreas Jaeger <aj@arthur.rhein-neckar.de>
813 * semaphore.h: Include <sys/types.h> so that _pthread_descr
816 1998-09-15 David S. Miller <davem@pierdol.cobaltmicro.com>
818 * sysdeps/sparc/sparc32/pt-machine.h (INIT_THREAD_SELF): Add nr
820 * sysdeps/sparc/sparc64/pt-machine.h (INIT_THREAD_SELF): Likewise.
822 1998-09-12 14:24 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
824 * linuxthreads/sysdeps/unix/sysv/linux/bits/sigthread.h: Add
825 multiple inclusion guard.
827 1998-09-02 11:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
829 * signals.c (sigaction): Check that sig is less than NSIG to avoid
830 array index overflow.
832 1998-09-06 10:56 Ulrich Drepper <drepper@cygnus.com>
834 * sysdeps/pthread/semaphore.h: New file.
836 1998-09-06 09:08 Ulrich Drepper <drepper@cygnus.com>
838 * sysdeps/pthread/bits/libc-lock.h (enum __libc_tsd_key_t): Add
839 _LIBC_TSD_KEY_DL_ERROR.
841 1998-08-31 Ulrich Drepper <drepper@cygnus.com>
843 * sysdeps/i386/i686/pt-machine.h (testandset): Add memory clobber.
844 * sysdeps/i386/pt-machine.h: Likewise.
845 Suggested by Roland McGrath.
847 1998-08-28 13:58 Ulrich Drepper <drepper@cygnus.com>
849 * internals.h: Also define THREAD_GETMEM_NC and THREAD_SETMEM_NC to
850 access thread data with non-constant offsets.
851 * specific.c: Use THREAD_GETMEM_NC and THREAD_SETMEM_NC where
854 * sysdeps/i386/useldt.h: Fix typo. Add THREAD_GETMEM_NC and
855 THREAD_SETMEM_NC definitions.
857 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM_NC and
859 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
861 1998-08-26 15:46 Ulrich Drepper <drepper@cygnus.com>
863 * internals.h: Define THREAD_GETMEM and THREAD_SETMEM to default if
865 (struct _pthread_descr_struct): Add p_self and p_nr field.
866 * manager.c (__pthread_handles): Define second element to point
868 (__pthread_handles_num): Initialize to 2.
869 (__pthread_manager): Use INIT_THREAD_SELF with two arguments.
870 (pthread_start_thread): Likewise.
871 (pthread_handle_create): Start search for free slot at entry 2.
872 Initialize new fields p_self and p_nr.
873 Call __clone with CLONE_PTRACE if available.
874 (pthread_free): Call FREE_THREAD_SELF if available.
875 * pthread.c (__pthread_initial_thread): Initialize new fields.
876 (__pthread_manager_thread): Likewise.
877 (__pthread_initialize_manager): Call __clone with CLONE_PTRACE.
879 * cancel.c: Use THREAD_GETMEM and THREAD_SETMEM to access the
880 elements of the thread descriptor.
881 * condvar.c: Likewise.
884 * manager.c: Likewise.
885 * pthread.c: Likewise.
886 * ptlongjmp.c: Likewise.
887 * semaphore.c: Likewise.
888 * signals.c: Likewise.
889 * specific.c: Likewise.
890 * spinlock.c: Likewise.
892 * sysdeps/alpha/pt-machine.h (INIT_THREAD_SELF): Add extra parameter.
894 * sysdeps/i386/useldt.h: New file.
895 * sysdeps/i386/i686/pt-machine.h: Show how to use this file.
897 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM and
898 THREAD_SETMEM using __thread_self.
899 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
901 1998-08-24 Geoff Keating <geoffk@ozemail.com.au>
903 * spinlock.c (__pthread_lock): Reset p_nextwaiting to NULL if it
904 turned out that we didn't need to queue after all.
906 1998-08-22 Geoff Keating <geoffk@ozemail.com.au>
908 * sysdeps/powerpc/pt-machine.h: Remove testandset, it's not used
909 and wastes space; correct types.
911 1998-08-08 11:18 H.J. Lu <hjl@gnu.org>
913 * signals.c (sigaction): Handle NULL argument.
915 1998-08-04 Ulrich Drepper <drepper@cygnus.com>
917 * sysdeps/unix/sysv/linux/bits/sigthread.h: Use __sigset_t instead
920 1998-08-02 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
922 * Makefile (linuxthreads-version): Extract correct number from
925 1998-07-29 Xavier Leroy <Xavier.Leroy@inria.fr>
927 * Banner: Bump version number to 0.8
928 * FAQ.html: Many updates, in particular w.r.t. debugging.
929 * manager.c: Support for non-default stacksize for
930 LinuxThreads-allocated stacks;
931 don't use guard pages for stacks with default size, rely on
932 rlimit(RLIMIT_STACK) instead (it's cheaper).
934 * cancel.c: Use __pthread_sig_cancel and __pthread_sig_restart
935 everywhere instead of PTHREAD_SIG_CANCEL and PTHREAD_SIG_RESTART.
936 * condvar.c: Likewise.
937 * internals.h: Likewise.
938 * restart.h: Likewise.
939 * signals.c: Likewise.
940 * pthread.c: Likewise; set rlimit(RLIMIT_STACK) as we need it.
942 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
944 * weaks.c: Define pthread_mutexattr_[sg]ettype instead of
945 __pthread_mutexattr_[sg]ettype. Add more weak aliases.
946 * Versions: Put __pthread_mutexattr_settype under version
947 GLIBC_2.0. Don't export __pthread_mutexattr_setkind_np and
948 __pthread_mutexattr_gettype.
950 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
952 * sysdeps/pthread/bits/libc-lock.h: Make
953 __pthread_mutexattr_settype weak. Don't make
954 __pthread_mutexattr_setkind_np weak.
956 1998-07-16 10:52 Ulrich Drepper <drepper@cygnus.com>
958 * manager.c (pthread_handle_create): Check whether sched_setscheduler
959 call can succeed here.
961 * mutex.c: Define __pthread_mutexattr_settype and make
962 __pthread_mutexattr_setkind_np an alias.
963 Likewise for __pthread_mutexattr_gettype.
965 1998-07-15 11:00 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
967 * attr.c (pthread_attr_setschedpolicy): Don't check whether caller
970 1998-07-14 19:38 Ulrich Drepper <drepper@cygnus.com>
972 * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_end.
974 1998-07-11 Andreas Jaeger <aj@arthur.rhein-neckar.de>
976 * Examples/ex6.c: Include <unistd.h> for usleep.
978 1998-06-13 11:04 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
980 * Examples/ex4.c (main): Use exit, not pthread_exit.
982 1998-07-09 13:39 Ulrich Drepper <drepper@cygnus.com>
984 * Versions: Add __pthread_mutexattr_gettype and
985 __pthread_mutexattr_settype.
986 * lockfile.c: Use __pthread_mutexattr_settype instead of
987 __pthread_mutexattr_setkind_np.
988 * mutex.c: Define __pthread_mutexattr_gettype and
989 __pthread_mutexattr_settype.
991 * sysdeps/pthread/pthread.h: Declare __pthread_mutexattr_gettype and
992 __pthread_mutexattr_settype.
993 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init_recursive):
994 Use __pthread_mutexattr_settype.
996 1998-07-08 22:26 Ulrich Drepper <drepper@cygnus.com>
998 * Versions: Add pthread_mutexattr_gettype, pthread_mutexattr_settype.
999 * mutex.c: Define weak alias pthread_mutexattr_gettype and
1000 pthread_mutexattr_settype.
1001 * sysdeps/pthread/pthread.h: Declare these functions.
1002 Move pthread_sigmask and pthread_kill declaration in separate header.
1003 * sysdeps/unix/sysv/linux/bits/sigthread.h: New file.
1005 1998-07-07 15:20 Ulrich Drepper <drepper@cygnus.com>
1007 * Makefile: Add rules to compile and run tests.
1008 * Examples/ex1.c: Little changes to fix warnings.
1009 * Examples/ex2.c: Likewise.
1010 * Examples/ex3.c: Likewise.
1011 * Examples/ex4.c: Likewise.
1012 * Examples/ex5.c: Likewise.
1013 * Examples/ex6.c: New file.
1015 1998-07-05 11:54 Ulrich Drepper <drepper@cygnus.com>
1017 * Versions: Add pthread_attr_init to GLIBC_2.1 version in libc.
1019 1998-07-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1021 * attr.c: Include <string.h>.
1023 1998-06-30 11:47 Ulrich Drepper <drepper@cygnus.com>
1025 * attr.c: Include errno.h. Use memcpy to copy sched_param.
1026 * internals.h: Include limits.h.
1027 * manager.c: Use memcpy to copy sched_param.
1028 * ptfork.c: Include errno.h.
1029 * pthread.c: Likewise.
1030 * semaphore.c: Likewise.
1031 * specific.c: Likewise.
1032 * spinlock.h: Likewise.
1033 * sysdeps/pthread/pthread.h: Include only allowed headers. Move
1034 type definition to ...
1035 * sysdeps/pthread/bits/pthreadtypes.h: ...here. New file.
1037 1998-06-29 12:34 Ulrich Drepper <drepper@cygnus.com>
1039 * sysdeps/pthread/pthread.h: Use __PMT not __P for function pointers.
1041 * sysdeps/pthread/pthread.h: Define various PTHREAD_* symbols also
1042 as macros as demanded in POSIX.1, Annex C.
1044 1998-06-29 12:29 Ulrich Drepper <drepper@cygnus.com>
1046 * internals.h (struct pthread_request): For free use pthread_t
1047 instead of pthread_descr.
1048 * join.c (pthread_join): Pass thread_id, not th to manager.
1049 (pthread_detach): Likewise.
1050 * manager.c (__pthread_manager): Except thread ID in FREE_REQ case.
1051 (pthread_exited): Remove detached queue code.
1052 (pthread_handle_free): Expect thread ID parameter and use it to
1053 validate the thread decsriptor. Don't use detached queue.
1054 Patches by Xavier Leroy.
1056 1998-06-27 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1058 * libpthread.map: Export accept, longjmp, sigaction, siglongjmp,
1059 _IO_flockfile, _IO_ftrylockfile, _IO_funlockfile,
1060 __pthread_atfork, __pthread_key_create, __pthread_once.
1061 * internals.h: Doc fix.
1062 * pthread.c (__pthread_initialize): Define again.
1064 1998-06-26 Ulrich Drepper <drepper@cygnus.com>
1066 * manager.c (pthread_exited): If thread is not detached put it on
1068 (pthread_handle_free): If thread is not on list with living threads
1069 search on list with detached threads.
1071 * sysdeps/pthread/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Correct
1072 for new definition of pthread_rwlock_t.
1074 * spinlock.c: Correct test whether to compile
1075 __pthread_compare_and_swap or not.
1077 1998-06-25 19:27 Ulrich Drepper <drepper@cygnus.com>
1079 * attr.c: Finish user stack support. Change locking code to be safe
1080 in situations with different priorities.
1081 * cancel.c: Likewise.
1082 * condvar.c: Likewise.
1083 * internals.h: Likewise.
1085 * manager.c: Likewise.
1086 * mutex.c: Likewise.
1087 * pthread.c: Likewise.
1088 * ptlongjmp.c: Likewise.
1089 * queue.h: Likewise.
1090 * rwlock.c: Likewise.
1091 * semaphore.c: Likewise.
1092 * semaphore.h: Likewise.
1093 * signals.c: Likewise.
1094 * spinlock.c: Likewise.
1095 * spinlock.h: Likewise.
1096 * sysdeps/pthread/pthread.h: Likewise.
1097 Patches by Xavier Leroy.
1099 * sysdeps/i386/i686/pt-machine.h: New file.
1101 1998-06-25 Ulrich Drepper <drepper@cygnus.com>
1103 * sysdeps/pthread/pthread.h: Make [sg]et_stacksize and
1104 [sg]et_stackaddr prototypes always available.
1106 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1107 _POSIX_THREAD_ATTR_STACKSIZE and _POSIX_THREAD_ATTR_STACKADDR.
1109 1998-06-24 Ulrich Drepper <drepper@cygnus.com>
1111 * manager.c (pthread_free): Undo patch from 980430.
1112 Reported by David Wragg <dpw@doc.ic.ac.uk>.
1114 1998-06-09 15:07 Ulrich Drepper <drepper@cygnus.com>
1116 * manager.c: Define __pthread_manager_adjust_prio and use it to
1117 increase priority when needed.
1118 * internals.h: Add prototype for __pthread_manager_adjust_prio.
1119 * mutex.c: Optimize mutexes to wake up only one thread.
1120 * pthread.c: Move PID of manager for global variable in structure
1122 Patches by Xavier Leroy.
1124 1998-06-07 13:47 Ulrich Drepper <drepper@cygnus.com>
1126 * sysdeps/pthread/bits/libc-lock.h: Optimize cleanup handlers a bit.
1128 1998-06-03 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1130 * attr.c: Correct typo.
1132 1998-05-01 Ulrich Drepper <drepper@cygnus.com>
1134 * manager.c (pthread_free): Unmap guard before the stack.
1135 Patch by Matthias Urlichs.
1137 1998-04-30 Ulrich Drepper <drepper@cygnus.com>
1139 * manager.c (pthread_free): Detect already free child.
1140 Patch by Xavier Leroy, reported by Matthias Urlichs.
1142 1998-04-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1144 * Makefile (linuxthreads-version): Renamed back from
1147 1998-04-21 Ulrich Drepper <drepper@cygnus.com>
1149 * ptlongjmp.c: Add prototypes for __libc_siglongjmp and
1152 1998-04-20 14:55 Ulrich Drepper <drepper@cygnus.com>
1154 * Makefile (libpthread-routines): Add ptlongjmp and spinlock.
1155 * internals.h: Add definitions for new spinlock implementation.
1156 * ptlongjmp.c: New file.
1157 * spinlock.c: New file.
1158 * spinlock.h (acquire): Don't reschedule using __sched_yield, use
1159 new function __pthread_acquire to prevent deadlocks with thread
1160 with different priorities.
1161 Patches by Xavier Leroy <Xavier.Leroy@inria.fr>.
1163 1998-03-16 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1165 * manager.c (__pthread_manager): Reduce first argument to select
1166 to include just the needed file descriptor.
1168 1998-03-17 00:06 Ulrich Drepper <drepper@cygnus.com>
1170 * manager.c: Fix last patch which caused core dumps.
1172 * pthread.c: Correctly handle missing SIGRTMIN.
1174 1998-03-15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1176 * libpthread.map: Add __libc_internal_tsd_get and
1177 __libc_internal_tsd_set. Add missing cancelable functions. Export
1178 libc internal versions of the cancelable functions.
1180 1998-03-13 16:51 Ulrich Drepper <drepper@cygnus.com>
1182 * weaks.c: Define pthread_attr_init as GLIBC_2.0 and GLIBC_2.1.
1184 1998-03-13 00:46 Ulrich Drepper <drepper@cygnus.com>
1186 * attr.c: Implement pthread_attr_[gs]etguardsize,
1187 pthread_attr_[gs]setstackaddr, pthread_attr_[gs]etstacksize.
1188 Change pthread_attr_init to have two interfaces.
1189 * internals.h (struct _pthread_descr_struct): Add new fields for
1191 * libpthread.map: Add names in GLIBC_2.1 section.
1192 * manager.c (pthread_handle_create): Implement guardsize and
1194 (pthread_free): Likewise.
1195 * pthread.c (pthread_create): Add new interface for changed
1197 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
1198 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add definition of
1201 1998-03-11 00:42 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
1203 * manager.c: Enable resetting of the thread scheduling policy
1204 to SCHED_OTHER when the parent thread has a different one.
1206 1998-02-01 13:51 Ulrich Drepper <drepper@cygnus.com>
1208 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1209 _POSIX_ASYNCHRONOUS_IO.
1211 * sysdeps/pthread/pthread.h: Define bits for Unix98 variants of
1213 * mutex.c: Implement new mutex types.
1215 * internals.h: Include <signal.h>.
1217 * libpthread.map: Add __erno_location and __h_errno_location.
1219 * errno.c: Return pointer to variable actually in use. This might
1220 not be the one in the thread structure.
1221 * internals.h (struct _pthread_descr_struct): Add new fields p_errnop
1223 * manager.c (__pthread_manager): Set p_errnop and p_h_errnop member
1224 of manager thread structure.
1225 (pthread_handle_create): Set p_errnop and p_h_errnop members for new
1227 * pthread.c: Adapt initializer for thread structures.
1228 (__pthread_initial_thread): Set p_errnop and p_h_errnop member.
1229 (__pthread_reset_main_thread): Reset p_errnop and p_h_errnop of
1230 current thread to global variables.
1232 1998-01-31 17:27 Ulrich Drepper <drepper@cygnus.com>
1234 * rwlock.c: New file.
1235 * Makefile (libpthread-routines): Add rwlock.
1236 * sysdeps/pthread/pthread.h: Define data structures and declare
1238 * libpthread.map: Add new functions.
1240 1997-12-18 13:50 Philip Blundell <pb@nexus.co.uk>
1242 * sysdeps/arm/pt-machine.h: New file; add ARM support.
1243 * sysdeps/arm/Implies: likewise.
1244 * README: Document it.
1246 1997-12-13 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1248 * signals.c: Remove unneeded initializer for sigwaited, saving a
1251 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1253 * semaphore.c (sem_init): Set sem_spinlock only if available.
1255 1997-12-04 01:48 Ulrich Drepper <drepper@cygnus.com>
1257 * mutex.c: Implement PTHREAD_MUTEX_CHECKERROR.
1258 * sysdeps/pthread/pthread.h: Define PTHREAD_MUTEX_CHECKERROR.
1260 * Makefile: Update from LinuxThreads 0.7.
1261 * internals.h. Likewise.
1262 * manager.c: Likewise.
1263 * mutex.c: Likewise.
1264 * pthread.c: Likewise.
1265 * signals.c: Likewise.
1266 * specific.c: Likewise.
1267 * Examples/ex3.c: Likewise.
1269 1997-11-20 18:13 Ulrich Drepper <drepper@cygnus.com>
1271 * pthread.c (__pthread_reset_main_thread): Close pipe only if still
1274 1997-10-29 05:38 Ulrich Drepper <drepper@cygnus.com>
1276 * wrapsyscall.c: Add socket functions which are also cancelation
1279 1997-10-19 21:40 Wolfram Gloger <wg@wolfram.dent.med.uni-muenchen.de>
1281 * specific.c (__libc_internal_tsd_set, __libc_internal_tsd_get):
1282 New functions for fast thread specific data within libc.
1284 * internals.h: Add new array p_libc_specific to struct
1285 _pthread_descr_struct.
1287 * sysdeps/pthread/bits/libc-lock.h: Declare new functions.
1289 1997-10-13 05:39 Ulrich Drepper <drepper@cygnus.com>
1291 * semaphore.h: Add __BEGIN_DECLS/__END_DECLS.
1292 Reported by Ralf Corsepius <corsepiu@faw.uni-ulm.de>.
1294 1997-08-29 03:05 Ulrich Drepper <drepper@cygnus.com>
1296 * internals.h (struct _pthread_descr_struct): Add definitions for
1297 two-level specific key handling.
1298 * manager.c (pthread_handle_create): Initialize specific memory array.
1299 * specific.c: Implement two-level key handling.
1300 * weaks.c: Don't provide dummy key handling.
1301 * sysdeps/pthread/bits/libc-lock.h: Typedef __libc_lock_t (no #define).
1302 Add definition of __libc_key_t.
1303 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define PTHREAD_KEYS_MAX
1305 Add definition of _POSIX_THREAD_DESTRUCTOR_ITERATIONS and
1306 PTHREAD_DESTRUCTOR_ITERATIONS.
1308 * manager.c (pthread_handle_create): Compare mmap result with
1311 * ptfork.c: Rename to __pthread_atfork and make old name a weak alias.
1312 * sysdeps/pthread/bits/pthread.h: Add prototype for __pthread_atfork.
1314 1997-08-22 19:04 Richard Henderson <rth@cygnus.com>
1316 sysdeps/sparc -> sysdeps/sparc/sparc32
1317 sysdeps/sparc64 -> sysdeps/sparc/sparc64
1319 * internals.h: Change definition of THREAD_SELF to be an expression,
1320 not a statement that did a return.
1321 * sysdeps/alpha/pt-machine.h (THREAD_SELF): Update accordingly.
1322 * sysdeps/sparc/sparc32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
1323 Follow Solaris and use a "system reserved" register (%g6) to hold
1324 the thread descriptor.
1325 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
1327 1997-08-03 00:09 Ulrich Drepper <drepper@cygnus.com>
1329 * mutex.c: Correct pthread_once. Patch by Xavier Leroy.
1330 * sysdeps/pthread/pthread.h: Add prototype for __pthread_once.
1331 * sysdeps/pthread/bits/pthread.h: Add macros for __libc_once.
1333 * semaphore.c: Include spinlock.h only when needed.
1335 * specific.c (__pthread_setsepcific, __pthread_getspecific): Reject
1336 keys for entries not in use.
1338 * weaks.c: Implement key handling functions for real.
1340 1997-06-29 01:04 Richard Henderson <richard@gnu.ai.mit.edu>
1342 Initial sparc64-linux support:
1343 * linuxthreads/sysdeps/sparc64/Implies: New file.
1344 * linuxthreads/sysdeps/sparc64/pt-machine.h: Likewise.
1346 1997-06-29 00:48 Ulrich Drepper <drepper@cygnus.com>
1348 * semaphore.c: Include spinlock.h at correct place.
1351 1997-06-13 10:06 Richard Henderson <rth@tamu.edu>
1353 The Great Bit File Move:
1354 * sysdeps/alpha/semaphorebits.h: -> .../bits/semaphore.h.
1355 * sysdeps/powerpc/semaphorebits.h: Likewise.
1356 * sysdeps/pthread/cmpxchg/semaphorebits.h: Likewise.
1357 * sysdeps/pthread/no-cmpxchg/semaphorebits.h: Likewise.
1358 * sysdeps/pthread/libc-lock.h: -> bits/
1359 * sysdeps/pthread/stdio-lock.h: Likewise.
1360 * sysdeps/unix/sysv/linux/local_lim.h: Likewise.
1361 * sysdeps/unix/sysv/linux/posix_opt.h: Likewise.
1362 * semaphore.h: Likewise.
1363 * sysdeps/pthread/pthread.h: Likewise.
1365 * lockfile.c: <foo.h> -> <bits/foo.h>.
1366 * semaphore.h: Likewise.
1368 * Makefile: (headers): foo.h -> bits/foo.h.
1369 * sysdeps/pthread/Makefile: Likewise.
1371 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1373 * semaphore.c (sem_init): Set sem_spinlock only if available.
1375 * sysdeps/m68k/pt-machine.h (testandset, __compare_and_swap): Fix
1378 1997-04-09 03:00 Ulrich Drepper <drepper@cygnus.com>
1380 Update from LinuxThreads 0.6.
1382 * attr.c (pthread_attr_getdetachstate): Use __sched_get_priority_max
1383 and __sched_get_priority_min instead of names without `__'.
1385 * manager.c: Rewrite large parts to implement opaque pthread_t.
1387 * cancel.c: Adapt for opaque pthread_t type.
1388 * condvar.c: Likewise.
1389 * errno.c: Likewise.
1391 * mutex.c: Likewise.
1392 * pthread.c: Likewise.
1393 * signals.c: Likewise.
1394 * specific.c: Likewise.
1395 * restart.h: Likewise.
1396 * queue.h: Likewise.
1397 * Examples/ex3.c: Likewise.
1398 * Examples/ex4.c: Likewise.
1399 * sysdeps/pthread/pthread.h: Likewise.
1401 * pthread.c: Accumulate time for all threads in thread manager.
1403 * semaphore.c: Implement fallback implementation for architectures
1404 sometimes missing compare-exchange operations.
1406 * cancel.c (pthread_cancel): Validate handle argument.
1407 * join.c (pthread_join): Likewise.
1408 (pthread_detach): Likewise.
1409 * signals.c (pthread_kill): Likewise.
1411 * spinlock.h (acquire): Use __sched_yield not sched_yield.
1413 * queue.h (enqueue): Enqueue thread according to priority.
1415 * internals.c (struct pthread_start_args): New struct for passing
1416 args to cloning function.
1417 (struct _pthread): Rename to _pthread_descr_struct and adapt for
1420 * Examples/Makefile (clean): Pass -f option to rm.
1422 * sysdeps/i386/pt-machine.h: Add check for compare-exchange instruction
1423 and define TEST_FOR_COMPARE_AND_SWAP.
1424 * sysdeps/i386/i486/pt-machine.h: Removed.
1426 * sysdeps/unix/sysv/linux/local_lim.h (PTHREAD_THREADS_MAX): Increase
1429 1997-04-04 16:38 Ulrich Drepper <drepper@cygnus.com>
1431 * restart.h (suspend): Clear p_signal before suspending.
1432 (suspend_with_cancellation): Likewise.
1433 Patch by Xavier Leroy <Xavier.Leroy@inria.fr>.
1435 * weaks.c: Make __pthread_key_create return 1.
1436 * sysdeps/pthread/libc-lock.h: Define __libc_key_create,
1437 __libc_getspecific, __libc_setspecific, and __libc_key_t.
1438 * sysdeps/pthread/stdio-lock.h: Don't care for implementation not
1441 1997-03-19 15:13 Miguel de Icaza <miguel@nuclecu.unam.mx>
1443 * sysdeps/sparc/pt-machine (RELEASE): Fix.
1445 1997-03-01 07:55 Geoff Keating <geoffk@ozemail.com.au>
1447 * sysdeps/powerpc/Implies: Added.
1448 * sysdeps/powerpc/pt-machine.h: Added.
1449 * sysdeps/powerpc/semaphorebits.h: Added.
1451 1997-01-22 01:22 Ulrich Drepper <drepper@cygnus.com>
1453 * linuxtheads/pthread.c (__pthread_initial_thread): Correct
1455 (__pthread_manager_thread): Likewise.
1456 Reported by Andreas Jaeger.
1458 1997-01-18 22:15 Richard Henderson <rth@tamu.edu>
1460 Since sigset_t no longer fits in a register, we can't pass in the
1461 thread's initial mask so easily. Take this opportunity to simplify
1462 the clone implementation by only accepting a single void* argument.
1464 * linuxthreads/manager.c (__pthread_manager): Put thread vitals
1465 in the thread struct instead of as arguments through clone.
1466 (pthread_start_thread): Look for them there.
1467 * linuxthreads/internals.h (struct _pthread): Add p_initial_fn,
1468 p_initial_fn_arg, p_initial_mask. Fix __pthread_manager proto.
1469 * linuxthreads/pthread.c (pthread_initialize_manager): Revise