1 2000-03-14 Ulrich Drepper <drepper@redhat.com>
3 * mutex.c (__pthread_once): Handle cancelled init function correctly.
4 (pthread_once_cancelhandler): New function.
5 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
7 2000-03-14 Andreas Jaeger <aj@suse.de>
9 * pthread.c (pthread_handle_sigcancel_rt): GS has been renamed to
11 (pthread_handle_sigrestart_rt): Likewise.
12 * signals.c (pthread_sighandler_rt): Likewise.
14 2000-03-02 Andreas Jaeger <aj@suse.de>
16 * sysdeps/pthread/bits/libc-lock.h: Fix typo.
17 Reported by Sean Chen <sean.chen@turbolinux.com>.
19 2000-02-28 Andreas Jaeger <aj@suse.de>
23 2000-02-27 Ulrich Drepper <drepper@redhat.com>
25 * rwlock.c: Define __* variants of the functions and make old names
27 * Versions [GLIBC_2.2]: Export the __pthread_rwlock_* functions.
28 * sysdeps/pthread/bits/libc-lock.h: Define __libc_rwlock_* macros.
30 2000-02-25 Andreas Jaeger <aj@suse.de>
32 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
33 pwrite64, lseek64, open64, and __open64 with version 2.2.
35 2000-02-22 Ulrich Drepper <drepper@redhat.com>
37 * semaphore.h (SEM_FAILED): Use 0 not NULL.
39 2000-02-14 Ulrich Drepper <drepper@redhat.com>
41 * condvar.c (pthread_cond_timedwait_relative_old): Tight loop with
42 nanosleep does not work either. Get absolute time inside the
44 (pthread_cond_timedwait_relative_new): Likewise.
45 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
47 2000-02-13 Andreas Jaeger <aj@suse.de>
49 * condvar.c (pthread_cond_timedwait_relative_new): Fix last patch.
50 (pthread_cond_timedwait_relative_old): Likewise.
52 2000-02-13 Ulrich Drepper <drepper@redhat.com>
54 * condvar.c (pthread_cond_timedwait_relative_old): Undo last patch
55 but keep the code around. A bug in the kernel prevent us from
57 (pthread_cond_timedwait_relative_new): Likewise.
58 (PR libc/1597 and libc/1598).
60 2000-02-01 Kaz Kylheku <kaz@ashi.footprints.net>
62 * condvar.c (pthread_cond_timedwait_relative_old): Do tight
63 loop around nanosleep calls instead of around most of the function
64 (pthread_cond_timedwait_relative_new): Likewise.
65 body. Got rid of backwards goto and one local.
67 2000-01-31 Ulrich Drepper <drepper@redhat.com>
69 * condvar.c (pthread_cond_timedwait_relative_old): Recompute time
70 before every nanosleep call to account for time spent in the rest
72 (pthread_cond_timedwait_relative_new): Likewise.
73 Patch by khendricks@ivey.uwo.ca (PR libc/1564).
75 2000-01-29 Ulrich Drepper <drepper@redhat.com>
77 * condvar.c (pthread_cond_timedwait_relative_old): Get remaining time
78 from nanosleep call so that in case we restart we only wait for the
80 (pthread_cond_timedwait_relative_new): Likewise.
81 Patch by khendricks@ivey.uwo.ca (PR libc/1561).
83 2000-01-18 Ulrich Drepper <drepper@cygnus.com>
85 * manager.c (pthread_allocate_stack): Compute guard page address
86 correctly. Patch by HJ Lu.
88 * sysdeps/pthread/pthread.h: Define
89 PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP.
91 2000-01-16 Ulrich Drepper <drepper@cygnus.com>
93 * rwlock.c (pthread_rwlock_unlock): Correct one more problem with
95 (pthread_rwlockattr_setkind_np): Allow
96 PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP.
97 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
99 2000-01-12 Ulrich Drepper <drepper@cygnus.com>
101 * internals.h (pthread_readlock_info): New structure.
102 (_pthread_descr_struct): Add p_readlock_list, p_readlock_free, and
103 p_untracked_readlock_count.
104 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
105 Add initializers for new fields.
106 * manager.c (pthread_free): Free read/write lock lists.
107 * queue.h (queue_is_empty): New function.
108 * rwlock.c: Implement requirements about when readers should get
110 * sysdeps/pthread/pthread.h
111 (PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP): New definition.
112 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_rwlock_t):
113 Define this name as well.
114 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
116 2000-01-05 Ulrich Drepper <drepper@cygnus.com>
118 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
119 Adjust initializers for struct _pthread_descr_struct change.
120 * internals.h (struct _pthread_descr_struct): Move new elements to
123 2000-01-03 Kaz Kylheku <kaz@ashi.footprints.net>
125 Redesigned how cancellation unblocks a thread from internal
126 cancellation points (sem_wait, pthread_join,
127 pthread_cond_{wait,timedwait}).
128 Cancellation won't eat a signal in any of these functions
129 (*required* by POSIX and Single Unix Spec!).
130 * condvar.c: Spontaneous wakeup on pthread_cond_timedwait won't eat a
131 simultaneous condition variable signal (not required by POSIX
132 or Single Unix Spec, but nice).
133 * spinlock.c: __pthread_lock queues back any received restarts
134 that don't belong to it instead of assuming ownership of lock
135 upon any restart; fastlock can no longer be acquired by two threads
137 * restart.h: Restarts queue even on kernels that don't have
138 queued real time signals (2.0, early 2.1), thanks to atomic counter,
139 avoiding a rare race condition in pthread_cond_timedwait.
141 1999-12-31 Andreas Jaeger <aj@suse.de>
143 * internals.h: Remove duplicate prototype declarations.
145 * weaks.c: Remove __THROW from prototypes since the file is not
146 compiled by a C++ compiler.
147 * internals.h: Likewise.
149 1999-12-30 Andreas Jaeger <aj@suse.de>
151 * sysdeps/pthread/pthread.h: Move internal functions to...
152 * sysdeps/pthread/bits/libc-lock.h: ...here.
154 1999-12-29 Andreas Jaeger <aj@suse.de>
156 * sysdeps/pthread/pthread.h: Fix typos, reformat comments.
158 1999-12-28 Ulrich Drepper <drepper@cygnus.com>
160 * sysdeps/alpha/pt-machine.h: Move stack_pointer definition to the
163 * manager.c (__pthread_start): Add one more cast to prevent
164 warning on 64bit machines.
166 1999-12-21 Ulrich Drepper <drepper@cygnus.com>
168 * manager.c (pthread_handle_create): Set p_pid of new thread
169 before calling the callback function to report a new thread.
171 1999-12-20 Andreas Jaeger <aj@suse.de>
173 * pthread.c (pthread_initialize): Move getrlimit call after
176 1999-12-18 Ulrich Drepper <drepper@cygnus.com>
178 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
179 pwrite64, lseek64, open64, and __open64.
180 * wrapsyscall.c: Define pread, __pread64, pread64, pwrite, __pwrite64,
181 pwrite64, lseek64, open64, and __open64.
183 * manager.c (pthread_allocate_stack): Correct computation of
184 new_thread_bottom. Correct handling of stack size and when the
185 rlimit method to guard for stack growth is used.
186 * pthread.c (pthread_initialize): Stack limit must be STACK_SIZE
187 minus one pagesize (not two).
189 1999-12-03 Andreas Jaeger <aj@suse.de>
191 * Versions: Add __res_state with version GLIBC_2.2.
193 * errno.c (__res_state): New function to return thread specific
196 * pthread.c (pthread_initialize): Initialize p_resp.
197 (__pthread_reset_main_thread): Also set p_resp.
199 * manager.c (pthread_handle_create): Initialize p_resp.
201 * internals.h: Add thread specific resolver state.
202 Based on patches by Adam D. Bradley <artdodge@cs.bu.edu>.
204 1999-12-01 Ulrich Drepper <drepper@cygnus.com>
206 * sysdeps/i386/pt-machine.h: Move stack_pointer definition to the
208 * sysdeps/i386/i686/pt-machine.h: Likewise.
209 Patches by Alan Modra <alan@SPRI.Levels.UniSA.Edu.Au>.
211 1999-11-23 Ulrich Drepper <drepper@cygnus.com>
213 * manager.c (pthread_start_thread_event): Initialize p_pid already
216 1999-11-22 Ulrich Drepper <drepper@cygnus.com>
218 * internals.h: Add prototype for __pthread_manager_event.
219 * manager.c (__pthread_manager_event): New function.
220 (pthread_start_thread_event): Correct computation of self.
221 Use INIT_THREAD_SELF.
222 * pthread.c (__pthread_manager_thread): Initialize p_lock.
223 (__pthread_initialize_manager): Respect event flags also for creation
224 of the manager thread.
226 1999-11-08 Ulrich Drepper <drepper@cygnus.com>
228 * pthread.c (__pthread_initialize_manager): Initialize
229 __pthread_manager_thread.p_tid.
231 1999-11-02 Ulrich Drepper <drepper@cygnus.com>
233 * internals.h: Declare __pthread_last_event.
234 * manager.c: Define __pthread_last_event.
235 (pthread_handle_create): Set __pthread_last_event.
236 (pthread_exited): Likewise.
237 * join.c (pthread_exit): Likewise.
239 * Makefile (libpthread-routines): Add events.
240 * events.c: New file.
241 * internals.h: Protect against multiple inclusion.
242 Include thread_dbP.h header.
243 (struct _pthread_descr_struct): Add new fields p_report_events and
245 Declare event reporting functions.
246 * join.c (pthread_exit): Signal event if this is wanted.
247 * manager.c (__pthread_threads_events): New variable.
248 (pthread_handle_create): Take new parameters with event information.
249 Signal TD_CREATE event if wanted.
250 (__pthread_manager): Adjust pthread_handle_create call.
251 (pthread_start_thread_event): New function. Block until manager is
252 finished and then call pthread_start_thread.
253 (pthread_exited): Signal TD_REAP event if wanted.
255 1999-10-26 Ulrich Drepper <drepper@cygnus.com>
257 * restart.h (suspend_with_cancellation): Rewrite as a macro.
259 * condvar.c (pthread_cond_timedwait_relative): Don't mark as inline.
261 1999-10-25 Andreas Jaeger <aj@suse.de>
263 * internals.h: Remove K&R compatibility.
264 * no-tsd.c: Likewise.
265 * semaphore.h: Likewise.
266 * signals.c: Likewise.
267 * sysdeps/pthread/bits/libc-tsd.h: Likewise.
268 * sysdeps/unix/sysv/linux/bits/sigthread.h: Likewise.
271 1999-10-21 Xavier Leroy <Xavier.Leroy@inria.fr>
273 * linuxthreads/pthread.c: For i386, wrap pthread_handle_sigrestart
274 and pthread_handle_sigcancel with functions that restore
275 %gs from the signal context. For each signal handling function,
276 two wrappers are required, one for a non-RT signal and one for
278 * linuxthreads/signal.c: For i386, add code to restore %gs
279 from the signal context in pthread_sighandler and
280 pthread_sighandler_rt.
282 1999-10-17 Ulrich Drepper <drepper@cygnus.com>
284 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add cast.
286 1999-10-14 Ulrich Drepper <drepper@cygnus.com>
288 * pthread.c (__pthread_initial_thread): Pass argument to
289 PTHREAD_START_ARGS_INITIALIZER.
290 (__pthread_manager_thread): Likewise.
292 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add parameter to
295 * manager.c (pthread_handle_create): Remove p_startfct initialization.
297 * internals.h (_pthread_descr_struct): We don't need p_startfct field.
299 1999-10-12 Ulrich Drepper <drepper@cygnus.com>
301 * internals.h: Correct return types for __libc_read and __libc_write.
303 1999-10-09 Andreas Jaeger <aj@suse.de>
305 * internals.h: Add __new_sem_post to get prototype in
306 manager.c; include semaphore.h for needed types.
308 1999-10-08 Ulrich Drepper <drepper@cygnus.com>
310 * manager.c (__pthread_manager) [REQ_POST]: Use __new_sem_post
311 directly instead of calling sem_post which should not be necessary
312 but is faster and might help in some case to work around problems.
313 Patch by khendricks@ivey.uwo.ca [libc/1382].
315 1999-10-08 Andreas Schwab <schwab@suse.de>
317 * sysdeps/pthread/Subdirs: New file.
320 1999-10-07 Ulrich Drepper <drepper@cygnus.com>
323 * internals.h (struct _pthread_descr_struct): Add p_startfct.
324 * manager.c (pthread_handle_create): Initialize p_startfct.
325 * pthread.c: Define __linuxthread_pthread_sizeof_descr variable.
327 1999-09-25 Ulrich Drepper <drepper@cygnus.com>
329 * manager.c (__linuxthreads_pthread_threads_max): New variable.
330 * specific.c (__linuxthreads_pthread_keys_max): New variable.
331 (__linuxthreads_pthread_key_2ndlevel_size): New variable.
333 * condvar.c (pthread_cond_timedwait_relative): Never return with
334 EINTR. Patch by Andreas Schwab.
336 1999-09-19 Ulrich Drepper <drepper@cygnus.com>
338 * signals.c (sigaction): Correct last patch. Don't select
339 pthread_sighandler_rt based on the signal number but instead of
342 1999-09-23 Ulrich Drepper <drepper@cygnus.com>
344 * specific.c: Move definitions of struct pthread_key_struct and
345 destr_function to ...
346 * internals.h: ...here.
348 1999-09-18 Ulrich Drepper <drepper@cygnus.com>
350 * pthread.c (pthread_handle_sigrestart_rt): New function. Use
351 this instead of pthread_handle_sigrestart if the signal is an RT
354 * signals.c: Handle passing through of sighandler arguments also
355 for real-time signals.
357 1999-09-03 Andreas Schwab <schwab@suse.de>
359 * ptfork.c (__fork): Renamed from fork and use __libc_fork. Add
361 (__vfork): New function, alias vfork.
362 * Versions: Export __fork, vfork, and __vfork in libpthread.
364 1999-08-23 Andreas Schwab <schwab@suse.de>
366 * signals.c (pthread_sighandler): Add SIGCONTEXT_EXTRA_ARGS to
367 call to signal handler.
369 1999-08-20 Ulrich Drepper <drepper@cygnus.com>
371 * pthread.c (__pthread_reset_main_thread): Undo last change.
372 (__pthread_kill_other_threads_np): Reset signal handlers for the
373 signals we used in the thread implementation here.
375 1999-08-19 Ulrich Drepper <drepper@cygnus.com>
377 * pthread.c (__pthread_reset_main_thread): Reset signal handlers
378 for the signals we used in the thread implementation [PR libc/1234].
380 * Versions: Export __pthread_kill_other_threads_np from libpthread
383 * signals.c: Pass sigcontext through wrapper to the user function.
385 1999-08-01 Ulrich Drepper <drepper@cygnus.com>
387 * Versions [ld.so] (GLIBC_2.0): Export __libc_internal_tsd_get and
388 __libc_internal_tsd_set.
390 1999-07-29 Andreas Jaeger <aj@arthur.rhein-neckar.de>
392 * manager.c: Remove inclusion of <linux/tasks.h> since it's not
395 1999-07-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
397 * internals.h: Align _pthread_descr_struct to 32 bytes.
398 Reported by Tim Hockin <thockin@cobaltnet.com>, close PR
401 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
403 * oldsemaphore.c (sem_compare_and_swap): Fix use of compare and
406 1999-07-09 Cristian Gafton <gafton@redhat.com>
408 * Makefile (libpthread-routines): Add oldsemaphore routine.
409 * Versions: Add sem_destroy, sem_getvalue, sem_init, sem_post,
410 sem_trywait, and sem_wait to GLIBC_2.1.
411 * oldsemaphore.c: New file.
412 * semaphore.c: Add default_symbol_versions for the changed functions.
413 (__new_sem_init): Rename from sem_init.
414 (__new_sem_post): Rename from sem_post.
415 (__new_sem_wait): Rename from sem_wait.
416 (__new_sem_trywait): Rename from sem_trywait.
417 (__new_sem_getvalue): Rename from sem_getvalue.
418 (__new_sem_destroy): Rename from sem_destroy.
420 1999-06-23 Robey Pointer <robey@netscape.com>
422 * internals.h: Added p_nextlock entry to separate queueing for a
423 lock from queueing for a CV (sometimes a thread queues on a lock
424 to serialize removing itself from a CV queue).
425 * pthread.c: Added p_nextlock to initializers.
426 * spinlock.c: Changed to use p_nextlock instead of p_nextwaiting.
428 1999-07-09 Ulrich Drepper <drepper@cygnus.com>
430 * manager.c (pthread_handle_create): Free mmap region after stack
431 if clone failed. Patch by Kaz Kylheku <kaz@ashi.FootPrints.net>.
433 1999-05-23 Andreas Jaeger <aj@arthur.rhein-neckar.de>
435 * man/pthread_cond_init.man: Correct example.
436 Reported by Tomas Berndtsson <tomas@nocrew.org>.
438 * linuxthreads.texi (Condition Variables): Likewise.
440 1999-05-18 Jakub Jelinek <jj@ultra.linux.cz>
442 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): Use
443 casx not cas, also successful casx returns the old value in rd
444 and not the new value.
446 1999-05-16 Xavier Leroy <Xavier.Leroy@inria.fr>
448 * manager.c: If pthread_create() is given a NULL attribute
449 and the thread manager runs with a realtime policy, set the
450 scheduling policy of the newly created thread back to SCHED_OTHER.
451 * manager.c: If the PTHREAD_INHERIT_SCHED attribute is given,
452 initialize the schedpolicy field of new_thread->p_start_args
453 to that of the calling thread.
455 1999-04-29 Ulrich Drepper <drepper@cygnus.com>
457 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): cas
458 instruction does not allow memory element to use offset.
460 1999-04-28 Ulrich Drepper <drepper@cygnus.com>
462 * manager.c (pthread_allocate_stack): Optimize initialization of new
465 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_define_initialized):
466 Don't use initializer since it is all zeroes.
467 (__libc_once_define): Likewise.
469 1999-04-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
471 * sysdeps/arm/Implies: Removed since cmpxchg/no-cmpxchg
472 doesn't exist anymore.
473 * sysdeps/i386/Implies: Likewise.
474 * sysdeps/m68k/Implies: Likewise.
475 * sysdeps/mips/Implies: Likewise.
476 * sysdeps/powerpc/Implies: Likewise.
477 * sysdeps/sparc/sparc32/Implies: Likewise.
478 * sysdeps/sparc/sparc64/Implies: Likewise.
480 1999-04-15 Ulrich Drepper <drepper@cygnus.com>
482 * sysdeps/alpha/bits/semaphore.h: Removed.
483 * sysdeps/powerpc/bits/semaphore.h: Removed.
484 * sysdeps/pthread/cmpxchg/bits/semaphore.h: Removed.
485 * sysdeps/pthread/no-cmpxchg/bits/semaphore.h: Removed.
486 * Makefile (headers): Remove bits/semaphore.h.
488 * semaphore.h: Define _pthread_descr if necessary.
489 Don't include limits.h. Define SEM_VALUE_MAX directly.
491 (sem_t): Protect element names with leading __.
492 Add declarations for sem_close, sem_open, and sem_unlink.
493 * semaphore.c: Adjust all functions for new element names.
494 Define sem_close, sem_open, and sem_unlink.
495 * Versions (libthread): Add sem_close, sem_open, and sem_unlink for
497 * sysdeps/pthread/bits/pthreadtypes.h: Define _pthread_descr only if
500 1999-03-16 H.J. Lu <hjl@gnu.org>
502 * specific.c (pthread_key_delete): Check th->p_terminated to see
503 if the thread is running.
505 * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set):
506 Added to GLIBC_2.0 for libc.so.
508 1999-02-12 H.J. Lu <hjl@gnu.org>
510 * Versions (__libc_current_sigrtmin, __libc_current_sigrtmax,
511 __libc_allocate_rtsig): Added to GLIBC_2.1.
513 * internals.h (DEFAULT_SIG_RESTART): Removed.
514 (DEFAULT_SIG_CANCEL): Removed.
516 * pthread.c (init_rtsigs, __libc_current_sigrtmin,
517 __libc_current_sigrtmax, __libc_allocate_rtsig): New functions.
518 (__pthread_sig_restart, __pthread_sig_cancel,
519 __pthread_sig_debug): Initialized.
520 (pthread_initialize): Call init_rtsigs () to initialize
523 1999-02-03 H.J. Lu <hjl@gnu.org>
525 * manager.c (__pthread_manager): Do block __pthread_sig_debug.
526 Don't restart the thread which sent REQ_DEBUG.
527 (pthread_start_thread): Check if __pthread_sig_debug > 0
530 * pthread.c (__pthread_initialize_manager): Suspend ourself
531 after sending __pthread_sig_debug to gdb instead of
532 __pthread_sig_cancel.
534 1999-01-24 H.J. Lu <hjl@gnu.org>
536 * manager.c (__pthread_manager): Delete __pthread_sig_debug
537 from mask if __pthread_sig_debug > 0.
538 (pthread_handle_create): Increment __pthread_handles_num.
540 * manager.c (pthread_handle_create): Don't pass CLONE_PTRACE to clone.
541 * pthread.c (__pthread_initialize_manager): Likewise.
543 * pthread.c (pthread_initialize): Use __libc_allocate_rtsig (1)
544 instead of __libc_allocate_rtsig (2).
545 (__pthread_initialize_manager): Send __pthread_sig_debug to gdb
546 instead of __pthread_sig_cancel.
547 (pthread_handle_sigdebug): Fix comments.
549 1999-01-21 Ulrich Drepper <drepper@cygnus.com>
551 * manager.c (pthread_allocate_stack): Set
552 __pthread_nonstandard_stacks if user-specified stack is used.
554 1999-01-16 Ulrich Drepper <drepper@cygnus.com>
556 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _LFS_ASYNCHRONOUS_IO,
557 _LFS_LARGEFILE, _LFS64_LARGEFILE, and _LFS64_STDIO from Unix98.
559 1999-01-07 Xavier Leroy <Xavier.Leroy@inria.fr>
561 * pthread.c: Use a third signal __pthread_sig_debug distinct
562 from __pthread_sig_cancel to notify gdb when a thread is
564 * manager.c: Likewise.
565 * internals.h: Likewise.
566 * signals.c: The implementation of sigwait(s) assumed that
567 all signals in s have signal handlers already attached.
568 This is not required by the standard, so make it work
569 also if some of the signals have no handlers.
571 1999-01-05 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
573 * linuxthreads.texi: Remove pointers from first @node. Move old
574 @node spec inside comment.
576 1998-12-31 Ulrich Drepper <drepper@cygnus.com>
578 * sysdeps/pthread/bits/stdio-lock.h: Define _IO_lock_lock and
581 1998-12-29 Ulrich Drepper <drepper@cygnus.com>
583 * semaphore.c (sem_trywait): Don't forget to unlock the semaphore
584 lock. Patch by Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>.
586 1998-12-21 Ulrich Drepper <drepper@cygnus.com>
588 * manager.c: Threads now send __pthread_sig_cancel on termination.
589 Change clone call and signal masks.
590 * thread.c (pthread_handle_sigrestart): Remove special code for
592 (pthread_handle_sigcancel): In manager thread call
593 __pthread_manager_sighandler.
594 * sysdeps/i386/pt-machine.h (__compare_and_swap): Add memory clobber.
595 * sysdeps/i386/i686/pt-machine.h: Likewise.
596 Patches by Xavier Leroy.
598 1998-12-14 Ulrich Drepper <drepper@cygnus.com>
600 * spinlock.c (__pthread_unlock): Don't crash if called for an
601 untaken mutex. Reported by Ruslan V. Brushkoff <rus@Snif.Te.Net.UA>.
603 * Examples/ex6.c: Unbuffer stdout and reduce sleep time to reduce
606 1998-12-13 Ulrich Drepper <drepper@cygnus.com>
608 * Examples/ex3.c: Wait until all threads are started before
609 searching for the number to avoid race condition on very fast
612 1998-12-08 Andreas Jaeger <aj@arthur.rhein-neckar.de>
614 * sysdeps/pthread/pthread.h: Remove __pthread_setcanceltype
615 declaration since it's not needed.
617 * sysdeps/pthread/pthread.h: Move internal functions to ...
618 * internals.h: ...here.
620 1998-12-02 H.J. Lu <hjl@gnu.org>
622 * pthread.c (__pthread_sig_restart): Initiliaze to 0 if
624 (__pthread_sig_cancel): Likewise.
626 1998-12-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
628 * wrapsyscall.c: Include <sys/mman.h> for msync,
629 <stdlib.h> for system and <termios.h> for tcdrain prototype.
630 Correct msync declaration.
632 1998-11-29 Roland McGrath <roland@baalperazim.frob.com>
634 * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_define, __libc_tsd_get,
635 __libc_tsd_set): New macros for new interface.
636 * no-tsd.c: New file, provide uninitialized defns of
637 __libc_internal_tsd_get and __libc_internal_tsd_set.
638 * Makefile (routines): Add no-tsd.
640 1998-10-12 Roland McGrath <roland@baalperazim.frob.com>
642 * internals.h: Include <bits/libc-tsd.h>, not <bits/libc-lock.h>.
643 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
644 __libc_internal_tsd_set): Move decls to ...
645 * sysdeps/pthread/bits/libc-tsd.h: New file for __libc_internal_tsd_*
648 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
649 __libc_internal_tsd_set): Make these pointers to functions, not
650 functions; remove #pragma weak decls for them.
651 * specific.c (__libc_internal_tsd_get, __libc_internal_tsd_set):
652 Define static functions and initialized pointers to them.
654 1998-11-18 Ulrich Drepper <drepper@cygnus.com>
656 * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES.
657 (CFLAGS-specific.c): Likewise.
658 (CFLAGS-pthread.c): Likewise.
659 (CFLAGS-ptfork.c): Likewise.
660 (CFLAGS-cancel.c): Likewise.
661 * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions
662 as weak references if __NO_WEAK_PTHREAD_ALIASES is defined.
664 * mutex.c (pthread_mutex_init): Define as strong symbol.
665 (pthread_mutex_destroy): Likewise.
666 (pthread_mutex_trylock): Likewise.
667 (pthread_mutex_lock): Likewise.
668 (pthread_mutex_unlock): Likewise.
669 (pthread_mutexattr_init): Likewise.
670 (pthread_mutexattr_destroy): Likewise.
671 (pthread_once): Likewise.
672 * ptfork.c (pthread_atfork): Likewise.
673 * specific.c (pthread_key_create): Likewise.
674 (pthread_setspecific): Likewise.
675 (pthread_getspecific): Likewise.
677 1998-11-15 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
679 * linuxthreads.texi: Fix punctuation after xref.
681 1998-11-10 H.J. Lu <hjl@gnu.org>
683 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine NR_OPEN
684 if it is defined in <linux/limits.h>.
686 1998-10-29 14:28 Ulrich Drepper <drepper@cygnus.com>
688 * spinlock.h (__pthread_trylock): Define inline.
689 (__pthread_lock): Add extra parameter to declaration. Declare
690 using internal_function.
691 (__pthread_unlock): Declare using internal_function.
692 * spinlock.c (__pthread_lock): Add new parameter. Use it instead
693 of local variable self. Avoid recomputing self. Define using
695 (__pthread_trylock): Remove.
696 (__pthread_unlock): Define using internal_function.
697 * cancel.c: Adjust for __pthread_lock interface change. Use already
698 computed self value is possible.
699 * condvar.c: Likewise.
701 * manager.c: Likewise.
703 * pthread.c: Likewise.
704 * rwlock.c: Likewise.
705 * semaphore.c: Likewise.
706 * signals.c: Likewise.
708 1998-10-27 13:46 Ulrich Drepper <drepper@cygnus.com>
710 * sysdeps/pthread/pthread.h (struct _pthread_cleanup_buffer): Prepend
711 __ to field names of the struct.
712 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_fastlock):
714 (pthread_attr_t): Likewise.
715 (pthread_cond_t): Likewise.
716 (pthread_condattr_t): Likewise.
717 (pthread_mutex_t): Likewise.
718 (pthread_mutexattr_t): Likewise.
719 (pthread_rwlock_t): Likewise.
720 (pthread_rwlockattr_t): Likewise.
721 * attr.c: Adjust for pthread.h and pthreadtypes.h change.
722 * cancel.c: Likewise.
723 * condvar.c: Likewise.
724 * manager.c: Likewise.
726 * pthread.c: Likewise.
727 * ptlongjmp.c: Likewise.
728 * rwlock.c: Likewise.
729 * spinlock.c: Likewise.
731 1998-10-09 Ulrich Drepper <drepper@cygnus.com>
733 * sysdeps/i386/pt-machine.h (get_eflags, set_eflags): Mark these
736 * sysdeps/i386/i686/pt-machine.h: Remove unused inline
739 * Makefile (libpthread-routines): Add pt-machine.
740 * pt-machine.c: New file.
741 * sysdeps/alpha/pt-machine.h: Define PT_EI as extern inline is not
742 yet defined. Use PT_EI in extern inline definitions.
743 * sysdeps/arm/pt-machine.h: Likewise.
744 * sysdeps/i386/pt-machine.h: Likewise.
745 * sysdeps/i386/i686/pt-machine.h: Likewise.
746 * sysdeps/m68k/pt-machine.h: Likewise.
747 * sysdeps/mips/pt-machine.h: Likewise.
748 * sysdeps/powerpc/pt-machine.h: Likewise.
749 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
750 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
752 1998-10-02 Andreas Jaeger <aj@arthur.rhein-neckar.de>
754 * semaphore.h: Include <sys/types.h> so that _pthread_descr
757 1998-09-15 David S. Miller <davem@pierdol.cobaltmicro.com>
759 * sysdeps/sparc/sparc32/pt-machine.h (INIT_THREAD_SELF): Add nr
761 * sysdeps/sparc/sparc64/pt-machine.h (INIT_THREAD_SELF): Likewise.
763 1998-09-12 14:24 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
765 * linuxthreads/sysdeps/unix/sysv/linux/bits/sigthread.h: Add
766 multiple inclusion guard.
768 1998-09-02 11:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
770 * signals.c (sigaction): Check that sig is less than NSIG to avoid
771 array index overflow.
773 1998-09-06 10:56 Ulrich Drepper <drepper@cygnus.com>
775 * sysdeps/pthread/semaphore.h: New file.
777 1998-09-06 09:08 Ulrich Drepper <drepper@cygnus.com>
779 * sysdeps/pthread/bits/libc-lock.h (enum __libc_tsd_key_t): Add
780 _LIBC_TSD_KEY_DL_ERROR.
782 1998-08-31 Ulrich Drepper <drepper@cygnus.com>
784 * sysdeps/i386/i686/pt-machine.h (testandset): Add memory clobber.
785 * sysdeps/i386/pt-machine.h: Likewise.
786 Suggested by Roland McGrath.
788 1998-08-28 13:58 Ulrich Drepper <drepper@cygnus.com>
790 * internals.h: Also define THREAD_GETMEM_NC and THREAD_SETMEM_NC to
791 access thread data with non-constant offsets.
792 * specific.c: Use THREAD_GETMEM_NC and THREAD_SETMEM_NC where
795 * sysdeps/i386/useldt.h: Fix typo. Add THREAD_GETMEM_NC and
796 THREAD_SETMEM_NC definitions.
798 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM_NC and
800 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
802 1998-08-26 15:46 Ulrich Drepper <drepper@cygnus.com>
804 * internals.h: Define THREAD_GETMEM and THREAD_SETMEM to default if
806 (struct _pthread_descr_struct): Add p_self and p_nr field.
807 * manager.c (__pthread_handles): Define second element to point
809 (__pthread_handles_num): Initialize to 2.
810 (__pthread_manager): Use INIT_THREAD_SELF with two arguments.
811 (pthread_start_thread): Likewise.
812 (pthread_handle_create): Start search for free slot at entry 2.
813 Initialize new fields p_self and p_nr.
814 Call __clone with CLONE_PTRACE if available.
815 (pthread_free): Call FREE_THREAD_SELF if available.
816 * pthread.c (__pthread_initial_thread): Initialize new fields.
817 (__pthread_manager_thread): Likewise.
818 (__pthread_initialize_manager): Call __clone with CLONE_PTRACE.
820 * cancel.c: Use THREAD_GETMEM and THREAD_SETMEM to access the
821 elements of the thread descriptor.
822 * condvar.c: Likewise.
825 * manager.c: Likewise.
826 * pthread.c: Likewise.
827 * ptlongjmp.c: Likewise.
828 * semaphore.c: Likewise.
829 * signals.c: Likewise.
830 * specific.c: Likewise.
831 * spinlock.c: Likewise.
833 * sysdeps/alpha/pt-machine.h (INIT_THREAD_SELF): Add extra parameter.
835 * sysdeps/i386/useldt.h: New file.
836 * sysdeps/i386/i686/pt-machine.h: Show how to use this file.
838 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM and
839 THREAD_SETMEM using __thread_self.
840 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
842 1998-08-24 Geoff Keating <geoffk@ozemail.com.au>
844 * spinlock.c (__pthread_lock): Reset p_nextwaiting to NULL if it
845 turned out that we didn't need to queue after all.
847 1998-08-22 Geoff Keating <geoffk@ozemail.com.au>
849 * sysdeps/powerpc/pt-machine.h: Remove testandset, it's not used
850 and wastes space; correct types.
852 1998-08-08 11:18 H.J. Lu <hjl@gnu.org>
854 * signals.c (sigaction): Handle NULL argument.
856 1998-08-04 Ulrich Drepper <drepper@cygnus.com>
858 * sysdeps/unix/sysv/linux/bits/sigthread.h: Use __sigset_t instead
861 1998-08-02 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
863 * Makefile (linuxthreads-version): Extract correct number from
866 1998-07-29 Xavier Leroy <Xavier.Leroy@inria.fr>
868 * Banner: Bump version number to 0.8
869 * FAQ.html: Many updates, in particular w.r.t. debugging.
870 * manager.c: Support for non-default stacksize for
871 LinuxThreads-allocated stacks;
872 don't use guard pages for stacks with default size, rely on
873 rlimit(RLIMIT_STACK) instead (it's cheaper).
875 * cancel.c: Use __pthread_sig_cancel and __pthread_sig_restart
876 everywhere instead of PTHREAD_SIG_CANCEL and PTHREAD_SIG_RESTART.
877 * condvar.c: Likewise.
878 * internals.h: Likewise.
879 * restart.h: Likewise.
880 * signals.c: Likewise.
881 * pthread.c: Likewise; set rlimit(RLIMIT_STACK) as we need it.
883 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
885 * weaks.c: Define pthread_mutexattr_[sg]ettype instead of
886 __pthread_mutexattr_[sg]ettype. Add more weak aliases.
887 * Versions: Put __pthread_mutexattr_settype under version
888 GLIBC_2.0. Don't export __pthread_mutexattr_setkind_np and
889 __pthread_mutexattr_gettype.
891 1998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
893 * sysdeps/pthread/bits/libc-lock.h: Make
894 __pthread_mutexattr_settype weak. Don't make
895 __pthread_mutexattr_setkind_np weak.
897 1998-07-16 10:52 Ulrich Drepper <drepper@cygnus.com>
899 * manager.c (pthread_handle_create): Check whether sched_setscheduler
900 call can succeed here.
902 * mutex.c: Define __pthread_mutexattr_settype and make
903 __pthread_mutexattr_setkind_np an alias.
904 Likewise for __pthread_mutexattr_gettype.
906 1998-07-15 11:00 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
908 * attr.c (pthread_attr_setschedpolicy): Don't check whether caller
911 1998-07-14 19:38 Ulrich Drepper <drepper@cygnus.com>
913 * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_end.
915 1998-07-11 Andreas Jaeger <aj@arthur.rhein-neckar.de>
917 * Examples/ex6.c: Include <unistd.h> for usleep.
919 1998-06-13 11:04 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
921 * Examples/ex4.c (main): Use exit, not pthread_exit.
923 1998-07-09 13:39 Ulrich Drepper <drepper@cygnus.com>
925 * Versions: Add __pthread_mutexattr_gettype and
926 __pthread_mutexattr_settype.
927 * lockfile.c: Use __pthread_mutexattr_settype instead of
928 __pthread_mutexattr_setkind_np.
929 * mutex.c: Define __pthread_mutexattr_gettype and
930 __pthread_mutexattr_settype.
932 * sysdeps/pthread/pthread.h: Declare __pthread_mutexattr_gettype and
933 __pthread_mutexattr_settype.
934 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init_recursive):
935 Use __pthread_mutexattr_settype.
937 1998-07-08 22:26 Ulrich Drepper <drepper@cygnus.com>
939 * Versions: Add pthread_mutexattr_gettype, pthread_mutexattr_settype.
940 * mutex.c: Define weak alias pthread_mutexattr_gettype and
941 pthread_mutexattr_settype.
942 * sysdeps/pthread/pthread.h: Declare these functions.
943 Move pthread_sigmask and pthread_kill declaration in separate header.
944 * sysdeps/unix/sysv/linux/bits/sigthread.h: New file.
946 1998-07-07 15:20 Ulrich Drepper <drepper@cygnus.com>
948 * Makefile: Add rules to compile and run tests.
949 * Examples/ex1.c: Little changes to fix warnings.
950 * Examples/ex2.c: Likewise.
951 * Examples/ex3.c: Likewise.
952 * Examples/ex4.c: Likewise.
953 * Examples/ex5.c: Likewise.
954 * Examples/ex6.c: New file.
956 1998-07-05 11:54 Ulrich Drepper <drepper@cygnus.com>
958 * Versions: Add pthread_attr_init to GLIBC_2.1 version in libc.
960 1998-07-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
962 * attr.c: Include <string.h>.
964 1998-06-30 11:47 Ulrich Drepper <drepper@cygnus.com>
966 * attr.c: Include errno.h. Use memcpy to copy sched_param.
967 * internals.h: Include limits.h.
968 * manager.c: Use memcpy to copy sched_param.
969 * ptfork.c: Include errno.h.
970 * pthread.c: Likewise.
971 * semaphore.c: Likewise.
972 * specific.c: Likewise.
973 * spinlock.h: Likewise.
974 * sysdeps/pthread/pthread.h: Include only allowed headers. Move
975 type definition to ...
976 * sysdeps/pthread/bits/pthreadtypes.h: ...here. New file.
978 1998-06-29 12:34 Ulrich Drepper <drepper@cygnus.com>
980 * sysdeps/pthread/pthread.h: Use __PMT not __P for function pointers.
982 * sysdeps/pthread/pthread.h: Define various PTHREAD_* symbols also
983 as macros as demanded in POSIX.1, Annex C.
985 1998-06-29 12:29 Ulrich Drepper <drepper@cygnus.com>
987 * internals.h (struct pthread_request): For free use pthread_t
988 instead of pthread_descr.
989 * join.c (pthread_join): Pass thread_id, not th to manager.
990 (pthread_detach): Likewise.
991 * manager.c (__pthread_manager): Except thread ID in FREE_REQ case.
992 (pthread_exited): Remove detached queue code.
993 (pthread_handle_free): Expect thread ID parameter and use it to
994 validate the thread decsriptor. Don't use detached queue.
995 Patches by Xavier Leroy.
997 1998-06-27 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
999 * libpthread.map: Export accept, longjmp, sigaction, siglongjmp,
1000 _IO_flockfile, _IO_ftrylockfile, _IO_funlockfile,
1001 __pthread_atfork, __pthread_key_create, __pthread_once.
1002 * internals.h: Doc fix.
1003 * pthread.c (__pthread_initialize): Define again.
1005 1998-06-26 Ulrich Drepper <drepper@cygnus.com>
1007 * manager.c (pthread_exited): If thread is not detached put it on
1009 (pthread_handle_free): If thread is not on list with living threads
1010 search on list with detached threads.
1012 * sysdeps/pthread/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Correct
1013 for new definition of pthread_rwlock_t.
1015 * spinlock.c: Correct test whether to compile
1016 __pthread_compare_and_swap or not.
1018 1998-06-25 19:27 Ulrich Drepper <drepper@cygnus.com>
1020 * attr.c: Finish user stack support. Change locking code to be safe
1021 in situations with different priorities.
1022 * cancel.c: Likewise.
1023 * condvar.c: Likewise.
1024 * internals.h: Likewise.
1026 * manager.c: Likewise.
1027 * mutex.c: Likewise.
1028 * pthread.c: Likewise.
1029 * ptlongjmp.c: Likewise.
1030 * queue.h: Likewise.
1031 * rwlock.c: Likewise.
1032 * semaphore.c: Likewise.
1033 * semaphore.h: Likewise.
1034 * signals.c: Likewise.
1035 * spinlock.c: Likewise.
1036 * spinlock.h: Likewise.
1037 * sysdeps/pthread/pthread.h: Likewise.
1038 Patches by Xavier Leroy.
1040 * sysdeps/i386/i686/pt-machine.h: New file.
1042 1998-06-25 Ulrich Drepper <drepper@cygnus.com>
1044 * sysdeps/pthread/pthread.h: Make [sg]et_stacksize and
1045 [sg]et_stackaddr prototypes always available.
1047 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1048 _POSIX_THREAD_ATTR_STACKSIZE and _POSIX_THREAD_ATTR_STACKADDR.
1050 1998-06-24 Ulrich Drepper <drepper@cygnus.com>
1052 * manager.c (pthread_free): Undo patch from 980430.
1053 Reported by David Wragg <dpw@doc.ic.ac.uk>.
1055 1998-06-09 15:07 Ulrich Drepper <drepper@cygnus.com>
1057 * manager.c: Define __pthread_manager_adjust_prio and use it to
1058 increase priority when needed.
1059 * internals.h: Add prototype for __pthread_manager_adjust_prio.
1060 * mutex.c: Optimize mutexes to wake up only one thread.
1061 * pthread.c: Move PID of manager for global variable in structure
1063 Patches by Xavier Leroy.
1065 1998-06-07 13:47 Ulrich Drepper <drepper@cygnus.com>
1067 * sysdeps/pthread/bits/libc-lock.h: Optimize cleanup handlers a bit.
1069 1998-06-03 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1071 * attr.c: Correct typo.
1073 1998-05-01 Ulrich Drepper <drepper@cygnus.com>
1075 * manager.c (pthread_free): Unmap guard before the stack.
1076 Patch by Matthias Urlichs.
1078 1998-04-30 Ulrich Drepper <drepper@cygnus.com>
1080 * manager.c (pthread_free): Detect already free child.
1081 Patch by Xavier Leroy, reported by Matthias Urlichs.
1083 1998-04-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1085 * Makefile (linuxthreads-version): Renamed back from
1088 1998-04-21 Ulrich Drepper <drepper@cygnus.com>
1090 * ptlongjmp.c: Add prototypes for __libc_siglongjmp and
1093 1998-04-20 14:55 Ulrich Drepper <drepper@cygnus.com>
1095 * Makefile (libpthread-routines): Add ptlongjmp and spinlock.
1096 * internals.h: Add definitions for new spinlock implementation.
1097 * ptlongjmp.c: New file.
1098 * spinlock.c: New file.
1099 * spinlock.h (acquire): Don't reschedule using __sched_yield, use
1100 new function __pthread_acquire to prevent deadlocks with thread
1101 with different priorities.
1102 Patches by Xavier Leroy <Xavier.Leroy@inria.fr>.
1104 1998-03-16 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1106 * manager.c (__pthread_manager): Reduce first argument to select
1107 to include just the needed file descriptor.
1109 1998-03-17 00:06 Ulrich Drepper <drepper@cygnus.com>
1111 * manager.c: Fix last patch which caused core dumps.
1113 * pthread.c: Correctly handle missing SIGRTMIN.
1115 1998-03-15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1117 * libpthread.map: Add __libc_internal_tsd_get and
1118 __libc_internal_tsd_set. Add missing cancelable functions. Export
1119 libc internal versions of the cancelable functions.
1121 1998-03-13 16:51 Ulrich Drepper <drepper@cygnus.com>
1123 * weaks.c: Define pthread_attr_init as GLIBC_2.0 and GLIBC_2.1.
1125 1998-03-13 00:46 Ulrich Drepper <drepper@cygnus.com>
1127 * attr.c: Implement pthread_attr_[gs]etguardsize,
1128 pthread_attr_[gs]setstackaddr, pthread_attr_[gs]etstacksize.
1129 Change pthread_attr_init to have two interfaces.
1130 * internals.h (struct _pthread_descr_struct): Add new fields for
1132 * libpthread.map: Add names in GLIBC_2.1 section.
1133 * manager.c (pthread_handle_create): Implement guardsize and
1135 (pthread_free): Likewise.
1136 * pthread.c (pthread_create): Add new interface for changed
1138 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
1139 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add definition of
1142 1998-03-11 00:42 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
1144 * manager.c: Enable resetting of the thread scheduling policy
1145 to SCHED_OTHER when the parent thread has a different one.
1147 1998-02-01 13:51 Ulrich Drepper <drepper@cygnus.com>
1149 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1150 _POSIX_ASYNCHRONOUS_IO.
1152 * sysdeps/pthread/pthread.h: Define bits for Unix98 variants of
1154 * mutex.c: Implement new mutex types.
1156 * internals.h: Include <signal.h>.
1158 * libpthread.map: Add __erno_location and __h_errno_location.
1160 * errno.c: Return pointer to variable actually in use. This might
1161 not be the one in the thread structure.
1162 * internals.h (struct _pthread_descr_struct): Add new fields p_errnop
1164 * manager.c (__pthread_manager): Set p_errnop and p_h_errnop member
1165 of manager thread structure.
1166 (pthread_handle_create): Set p_errnop and p_h_errnop members for new
1168 * pthread.c: Adapt initializer for thread structures.
1169 (__pthread_initial_thread): Set p_errnop and p_h_errnop member.
1170 (__pthread_reset_main_thread): Reset p_errnop and p_h_errnop of
1171 current thread to global variables.
1173 1998-01-31 17:27 Ulrich Drepper <drepper@cygnus.com>
1175 * rwlock.c: New file.
1176 * Makefile (libpthread-routines): Add rwlock.
1177 * sysdeps/pthread/pthread.h: Define data structures and declare
1179 * libpthread.map: Add new functions.
1181 1997-12-18 13:50 Philip Blundell <pb@nexus.co.uk>
1183 * sysdeps/arm/pt-machine.h: New file; add ARM support.
1184 * sysdeps/arm/Implies: likewise.
1185 * README: Document it.
1187 1997-12-13 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1189 * signals.c: Remove unneeded initializer for sigwaited, saving a
1192 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1194 * semaphore.c (sem_init): Set sem_spinlock only if available.
1196 1997-12-04 01:48 Ulrich Drepper <drepper@cygnus.com>
1198 * mutex.c: Implement PTHREAD_MUTEX_CHECKERROR.
1199 * sysdeps/pthread/pthread.h: Define PTHREAD_MUTEX_CHECKERROR.
1201 * Makefile: Update from LinuxThreads 0.7.
1202 * internals.h. Likewise.
1203 * manager.c: Likewise.
1204 * mutex.c: Likewise.
1205 * pthread.c: Likewise.
1206 * signals.c: Likewise.
1207 * specific.c: Likewise.
1208 * Examples/ex3.c: Likewise.
1210 1997-11-20 18:13 Ulrich Drepper <drepper@cygnus.com>
1212 * pthread.c (__pthread_reset_main_thread): Close pipe only if still
1215 1997-10-29 05:38 Ulrich Drepper <drepper@cygnus.com>
1217 * wrapsyscall.c: Add socket functions which are also cancelation
1220 1997-10-19 21:40 Wolfram Gloger <wg@wolfram.dent.med.uni-muenchen.de>
1222 * specific.c (__libc_internal_tsd_set, __libc_internal_tsd_get):
1223 New functions for fast thread specific data within libc.
1225 * internals.h: Add new array p_libc_specific to struct
1226 _pthread_descr_struct.
1228 * sysdeps/pthread/bits/libc-lock.h: Declare new functions.
1230 1997-10-13 05:39 Ulrich Drepper <drepper@cygnus.com>
1232 * semaphore.h: Add __BEGIN_DECLS/__END_DECLS.
1233 Reported by Ralf Corsepius <corsepiu@faw.uni-ulm.de>.
1235 1997-08-29 03:05 Ulrich Drepper <drepper@cygnus.com>
1237 * internals.h (struct _pthread_descr_struct): Add definitions for
1238 two-level specific key handling.
1239 * manager.c (pthread_handle_create): Initialize specific memory array.
1240 * specific.c: Implement two-level key handling.
1241 * weaks.c: Don't provide dummy key handling.
1242 * sysdeps/pthread/bits/libc-lock.h: Typedef __libc_lock_t (no #define).
1243 Add definition of __libc_key_t.
1244 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define PTHREAD_KEYS_MAX
1246 Add definition of _POSIX_THREAD_DESTRUCTOR_ITERATIONS and
1247 PTHREAD_DESTRUCTOR_ITERATIONS.
1249 * manager.c (pthread_handle_create): Compare mmap result with
1252 * ptfork.c: Rename to __pthread_atfork and make old name a weak alias.
1253 * sysdeps/pthread/bits/pthread.h: Add prototype for __pthread_atfork.
1255 1997-08-22 19:04 Richard Henderson <rth@cygnus.com>
1257 sysdeps/sparc -> sysdeps/sparc/sparc32
1258 sysdeps/sparc64 -> sysdeps/sparc/sparc64
1260 * internals.h: Change definition of THREAD_SELF to be an expression,
1261 not a statement that did a return.
1262 * sysdeps/alpha/pt-machine.h (THREAD_SELF): Update accordingly.
1263 * sysdeps/sparc/sparc32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
1264 Follow Solaris and use a "system reserved" register (%g6) to hold
1265 the thread descriptor.
1266 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
1268 1997-08-03 00:09 Ulrich Drepper <drepper@cygnus.com>
1270 * mutex.c: Correct pthread_once. Patch by Xavier Leroy.
1271 * sysdeps/pthread/pthread.h: Add prototype for __pthread_once.
1272 * sysdeps/pthread/bits/pthread.h: Add macros for __libc_once.
1274 * semaphore.c: Include spinlock.h only when needed.
1276 * specific.c (__pthread_setsepcific, __pthread_getspecific): Reject
1277 keys for entries not in use.
1279 * weaks.c: Implement key handling functions for real.
1281 1997-06-29 01:04 Richard Henderson <richard@gnu.ai.mit.edu>
1283 Initial sparc64-linux support:
1284 * linuxthreads/sysdeps/sparc64/Implies: New file.
1285 * linuxthreads/sysdeps/sparc64/pt-machine.h: Likewise.
1287 1997-06-29 00:48 Ulrich Drepper <drepper@cygnus.com>
1289 * semaphore.c: Include spinlock.h at correct place.
1292 1997-06-13 10:06 Richard Henderson <rth@tamu.edu>
1294 The Great Bit File Move:
1295 * sysdeps/alpha/semaphorebits.h: -> .../bits/semaphore.h.
1296 * sysdeps/powerpc/semaphorebits.h: Likewise.
1297 * sysdeps/pthread/cmpxchg/semaphorebits.h: Likewise.
1298 * sysdeps/pthread/no-cmpxchg/semaphorebits.h: Likewise.
1299 * sysdeps/pthread/libc-lock.h: -> bits/
1300 * sysdeps/pthread/stdio-lock.h: Likewise.
1301 * sysdeps/unix/sysv/linux/local_lim.h: Likewise.
1302 * sysdeps/unix/sysv/linux/posix_opt.h: Likewise.
1303 * semaphore.h: Likewise.
1304 * sysdeps/pthread/pthread.h: Likewise.
1306 * lockfile.c: <foo.h> -> <bits/foo.h>.
1307 * semaphore.h: Likewise.
1309 * Makefile: (headers): foo.h -> bits/foo.h.
1310 * sysdeps/pthread/Makefile: Likewise.
1312 1997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1314 * semaphore.c (sem_init): Set sem_spinlock only if available.
1316 * sysdeps/m68k/pt-machine.h (testandset, __compare_and_swap): Fix
1319 1997-04-09 03:00 Ulrich Drepper <drepper@cygnus.com>
1321 Update from LinuxThreads 0.6.
1323 * attr.c (pthread_attr_getdetachstate): Use __sched_get_priority_max
1324 and __sched_get_priority_min instead of names without `__'.
1326 * manager.c: Rewrite large parts to implement opaque pthread_t.
1328 * cancel.c: Adapt for opaque pthread_t type.
1329 * condvar.c: Likewise.
1330 * errno.c: Likewise.
1332 * mutex.c: Likewise.
1333 * pthread.c: Likewise.
1334 * signals.c: Likewise.
1335 * specific.c: Likewise.
1336 * restart.h: Likewise.
1337 * queue.h: Likewise.
1338 * Examples/ex3.c: Likewise.
1339 * Examples/ex4.c: Likewise.
1340 * sysdeps/pthread/pthread.h: Likewise.
1342 * pthread.c: Accumulate time for all threads in thread manager.
1344 * semaphore.c: Implement fallback implementation for architectures
1345 sometimes missing compare-exchange operations.
1347 * cancel.c (pthread_cancel): Validate handle argument.
1348 * join.c (pthread_join): Likewise.
1349 (pthread_detach): Likewise.
1350 * signals.c (pthread_kill): Likewise.
1352 * spinlock.h (acquire): Use __sched_yield not sched_yield.
1354 * queue.h (enqueue): Enqueue thread according to priority.
1356 * internals.c (struct pthread_start_args): New struct for passing
1357 args to cloning function.
1358 (struct _pthread): Rename to _pthread_descr_struct and adapt for
1361 * Examples/Makefile (clean): Pass -f option to rm.
1363 * sysdeps/i386/pt-machine.h: Add check for compare-exchange instruction
1364 and define TEST_FOR_COMPARE_AND_SWAP.
1365 * sysdeps/i386/i486/pt-machine.h: Removed.
1367 * sysdeps/unix/sysv/linux/local_lim.h (PTHREAD_THREADS_MAX): Increase
1370 1997-04-04 16:38 Ulrich Drepper <drepper@cygnus.com>
1372 * restart.h (suspend): Clear p_signal before suspending.
1373 (suspend_with_cancellation): Likewise.
1374 Patch by Xavier Leroy <Xavier.Leroy@inria.fr>.
1376 * weaks.c: Make __pthread_key_create return 1.
1377 * sysdeps/pthread/libc-lock.h: Define __libc_key_create,
1378 __libc_getspecific, __libc_setspecific, and __libc_key_t.
1379 * sysdeps/pthread/stdio-lock.h: Don't care for implementation not
1382 1997-03-19 15:13 Miguel de Icaza <miguel@nuclecu.unam.mx>
1384 * sysdeps/sparc/pt-machine (RELEASE): Fix.
1386 1997-03-01 07:55 Geoff Keating <geoffk@ozemail.com.au>
1388 * sysdeps/powerpc/Implies: Added.
1389 * sysdeps/powerpc/pt-machine.h: Added.
1390 * sysdeps/powerpc/semaphorebits.h: Added.
1392 1997-01-22 01:22 Ulrich Drepper <drepper@cygnus.com>
1394 * linuxtheads/pthread.c (__pthread_initial_thread): Correct
1396 (__pthread_manager_thread): Likewise.
1397 Reported by Andreas Jaeger.
1399 1997-01-18 22:15 Richard Henderson <rth@tamu.edu>
1401 Since sigset_t no longer fits in a register, we can't pass in the
1402 thread's initial mask so easily. Take this opportunity to simplify
1403 the clone implementation by only accepting a single void* argument.
1405 * linuxthreads/manager.c (__pthread_manager): Put thread vitals
1406 in the thread struct instead of as arguments through clone.
1407 (pthread_start_thread): Look for them there.
1408 * linuxthreads/internals.h (struct _pthread): Add p_initial_fn,
1409 p_initial_fn_arg, p_initial_mask. Fix __pthread_manager proto.
1410 * linuxthreads/pthread.c (pthread_initialize_manager): Revise