]> sourceware.org Git - glibc.git/blame - linuxthreads/ChangeLog
Update.
[glibc.git] / linuxthreads / ChangeLog
CommitLineData
a956d045
UD
12000-07-25 Ulrich Drepper <drepper@redhat.com>
2
a99db924 3 * internals.h (struct __pthread_descr_struct): Add p_sem_avail.
9ec9e34e
UD
4 * semaphore.c: Handle spurious wakeups.
5
6 * sysdeps/pthread/pthread.h: Add back PTHREAD_MUTX_FAST_NP as an alias
7 for PTHREAD_MUTEX_ADAPTIVE_NP for source code compatibility.
8
9 * pthread.c (__pthread_set_own_extricate): Use THREAD_GETMEM.
10 (__pthread_wait_for_restart): Likewise.
11
12 * condvar.c (pthread_cond_wait): Also check whether thread is
13 cancelable before aborting loop.
14 (pthread_cond_timedwait): Likewise.
15
a956d045
UD
16 * signals.c (pthread_sighandler): Remove special code to restrore
17 %gs on x86.
18 (pthread_sighandler_t): Likewise.
19
70e392a3
UD
202000-07-25 Mark Kettenis <kettenis@gnu.org>
21
22 * internals.h (__RES_PTHREAD_INTERNAL): Remove define.
23 * pthread.c: Include <resolv.h>.
24 (_res): Undefine. Add extern declaration.
25
5122880a
UD
262000-07-24 Ulrich Drepper <drepper@redhat.com>
27
f3d5834e
UD
28 * pthread.c (__pthread_initial_thread): Update initializer.
29 (__pthread_manager_thread): Likewise.
30 (pthread_initialize): Move setrlimit call to...
31 (__pthread_initialize_manager): ...here.
32 (__pthread_reset_main_thread): Reset also soft limit on stack size.
33
5122880a 34 * condvar.c: Handle spurious wakeups. [PR libc/1749].
ad0c66a0 35 * internals.h (struct _pthread_descr_struct): Add p_condvar_avail.
5122880a 36
0c0c8bde
UD
372000-07-21 Ulrich Drepper <drepper@redhat.com>
38
5122880a 39 * spinlock.h: If IMPLEMENT_TAS_WITH_CAS is defined use
0c0c8bde
UD
40 __compare_and_swap to define testandset.
41 * linuxthreads/sysdeps/powerpc/pt-machine.h: Add volatile to asms.
42 Define IMPLEMENT_TAS_WITH_CAS.
43
0fb7851f
UD
442000-07-20 Ulrich Drepper <drepper@redhat.com>
45
46 * Makefile: Pass -z nodelete to linker for libpthread.so
47 generation if it understand this option.
48
4e8286ac
UD
492000-07-18 Mark Kettenis <kettenis@gnu.org>
50
51 * manager.c (pthread_handle_create): Remove initialization of
52 new_thread->p_res._sock.
53
80ec4993
UD
542000-07-19 Kaz Kylheku <kaz@ashi.footprints.net>
55
56 Bugfixes to the variant of the code for machines with no compare
57 and swap.
58
59 * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Wait
60 node was not being properly enqueued, due to failing to update
61 the lock->__status field.
62
63 * spinlock.c (__pthread_alt_timedlock): The oldstatus variable was
64 being set inappropriately, causing the suspend function to be called
65 with a null self pointer and crash.
66
70c5b33d
UD
672000-07-18 Ulrich Drepper <drepper@redhat.com>
68
056f707c
UD
69 * spinlock.h (__pthread_alt_trylock): Fix code used if no
70 compare&swap is available.
71
a48297fd
UD
72 * spinlock.h (__pthread_trylock): Use __compare_and_swap, not
73 compare_and_swap.
74
89bc5366 75 * pthread.c (pthread_initialize): Don't use sysconf to determine
247c8869
UD
76 whether the machine has more than one processor.
77
70c5b33d
UD
78 * spinlock.c (__pthread_alt_timedlock): Add back one of the
79 removed thread_self calls.
80
83142e8f
UD
812000-07-18 Kaz Kylheku <kaz@ashi.footprints.net>
82
83 * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Changed
84 __compare_and_swap to compare_and_swap in code which assumes
85 compare swap is available.
86
89bc5366 872000-07-18 Kaz Kylheku <kaz@ashi.footprints.net>
e6574c9c
UD
88
89 * spinlock.c (__pthread_alt_lock, __pthread_alt_timedlock): Fixed
90 bug whereby thr field of waitnode structure would not be correctly
91 set unless a null self pointer is passed to the functions.
92 Eliminated redundant calls to thread_self().
93
c6df09ad
UD
942000-07-18 Jakub Jelinek <jakub@redhat.com>
95
96 * pthread.c (__pthread_initialize_manager): Lock
97 __pthread_manager_thread.p_lock before calling clone.
98
9aae19cd
UD
992000-05-05 H.J. Lu <hjl@gnu.org>
100
101 * sysdeps/ia64/pt-machine.h (__compare_and_swap): Change it to
102 have acquire semantics.
103 (__compare_and_swap_with_release_semantics): New inline
104 function.
105 (HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS): New macro.
106
1072000-01-28 Hans Boehm <hboehm@exch.hpl.hp.com>
108
109 * manager.c: Fix the problem with signals at startup.
110 Change the way that thread stacks are allocated on IA64.
111 Clean up some of the guard page allocation stuff.
112
1131999-12-19 H.J. Lu <hjl@gnu.org>
114
115 * internals.h (page_roundup): New.
116 * attr.c (__pthread_attr_setguardsize); Use page_roundup
117 instead of roundup.
118 * manager.c (pthread_allocate_stack): Make sure guardaddr is
119 page aligned with page_roundup if NEED_SEPARATE_REGISTER_STACK
120 is define.
121
1221999-12-17 Hans Boehm <hboehm@exch.hpl.hp.com>
123
124 * manager.c (pthread_allocate_stack): Unmap the stack top
125 if failed to map the stack bottom.
126 Fix the guard page.
127 (pthread_free): Fix the guard page.
128
129 * pthread.c (pthread_initialize): Set rlimit correctly for
130 NEED_SEPARATE_REGISTER_STACK.
131
1321999-12-16 H.J. Lu <hjl@gnu.org>
133
134 * pthread.c (__pthread_initialize_manager): Pass
135 __pthread_manager_thread_bos instead of
136 __pthread_manager_thread_tos to __clone2.
137
1381999-12-16 H.J. Lu <hjl@gnu.org>
139
140 * manager.c (pthread_allocate_stack): Correct the calculation
141 of "new_thread_bottom". Remove MAP_GROWSDOWN from mmap for
142 stack bottom.
143
1441999-12-13 H.J. Lu <hjl@gnu.org>
145
146 * sysdeps/ia64/pt-machine.h (__compare_and_swap): Added a stop
147 bit after setting ar.ccv.
148
1491999-12-12 H.J. Lu <hjl@gnu.org>
150
151 * manager.c (pthread_allocate_stack): Make the starting
152 address of the stack bottom page aligned. FIXME: it may
153 need changes in other places.
154 (pthread_handle_create): Likewise.
155
1561999-12-11 Hans Boehm <hboehm@exch.hpl.hp.com>
157
158 * manager.c (pthread_allocate_stack): Handle
159 NEED_SEPARATE_REGISTER_STACK.
160 (pthread_handle_create): Likewise.
161 * pthread.c (__pthread_initialize_manager): Likewise.
162
163 * sysdeps/ia64/pt-machine.h: Use r13 for thread pointer.
164
1651999-12-02 H.J. Lu <hjl@gnu.org>
166
167 * sysdeps/ia64/pt-machine.h: New.
168
f218b5f5
UD
1692000-07-13 Ulrich Drepper <drepper@redhat.com>
170
171 * wrapsyscall.c: Mark non-__ protected names as weak.
172 PR libc/1466.
173
0d655550
UD
1742000-07-12 Bruno Haible <haible@clisp.cons.org>
175
176 * Examples/ex8.c: Include <sys/wait.h>, not <wait.h>.
177
9f835f5f
UD
1782000-07-12 Ulrich Drepper <drepper@redhat.com>
179
180 * spinlock.c: Fix code for TEST_FOR_COMPARE_AND_SWAP being defined.
181 Add tests also to new alternative spinlock implementation.
182 * spinlock.h: Likewise.
183 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
184
a85d5c80
UD
1852000-07-06 Ulrich Drepper <drepper@redhat.com>
186
c0f53cdd
UD
187 * Version: Export __sigaction.
188 * signals.c: Define __sigaction alias. Use __libc_sigaction instead
189 of __sigaction.
190 * pthread.c: Use __libc_sigaction instead of __sigaction.
191
a85d5c80
UD
192 * condvar.c: Implement pthread_condattr_getpshared and
193 pthread_condattr_setpshared.
194 * mutex.c: Implement pthread_mutexattr_getpshared and
195 pthread_mutexattr_setpshared.
196 * Versions: Export new functions.
197 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
198
199 * rwlock.c (pthread_rwlockattr_init): Use PTHREAD_PROCESS_PRIVATE.
200 (pthread_rwlockattr_setpshared): Fail if PTHREAD_PROCESS_PRIVATE
201 is not selected.
202
66c5b9aa
GM
2032000-07-04 Greg McGary <greg@mcgary.org>
204
205 * sysdeps/pthread/bits/libc-lock.h: Remove BP_SYM from
206 pragmas. Include bp-sym.h only if _LIBC.
207
83b1b6d8
UD
2082000-07-04 Ulrich Drepper <drepper@redhat.com>
209
210 * spinlock.c (__pthread_unlock): Properly place write barrier.
211 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
212
a88b96f4
UD
2132000-07-03 Ulrich Drepper <drepper@redhat.com>
214
215 * spinlock.c: Replace fast spinlocks by adaptive spinlocks which are
216 faster on SMP systems. No more emulation of compare&swap for adaptive
217 spinlocks.
218 * spinlock.h: Likewise.
219 * sysdeps/pthread/pthread.h: Shuffle PTHREAD_MUTEX_* values around.
220 Replace fast with adaptive mutex.
221 * mutex.c: Rewrite for replacement of fast by adaptive mutex.
222 * condvar.c: Likewise.
223 * pthread.c: Define and initialize __pthread_smp_kernel variable.
224 * internals.h: Declare __pthread_smp_kernel.
225 * sysdeps/pthread/bits/pthreadtypes.h: Update comment of
226 _pthread_fastlock structure.
227 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
228
229 * pthread.c: Remove initialization to zero from global variables.
230
1a6d7967
UD
2312000-06-29 Jakub Jelinek <jakub@redhat.com>
232
233 * shlib-versions: Make sparc64 GLIBC_2.2+ only.
234
1efd15e3
GM
2352000-06-28 Greg McGary <greg@mcgary.org>
236
237 * weaks.c: Wrap BP_SYM () around weak extern declarations of
238 pthread functions that have pointers in their return+arg signatures.
239
3210bef0
GM
2402000-06-27 Greg McGary <greg@mcgary.org>
241
1efd15e3
GM
242 * sysdeps/pthread/bits/libc-lock.h: Wrap BP_SYM () around weak
243 extern declarations of pthread functions that have pointers in
244 their return+arg signatures.
3210bef0 245
c49ebf76
UD
2462000-06-26 Ulrich Drepper <drepper@redhat.com>
247
248 * Makefile (tests): Add ex11. Add rules to build it.
249 * Examples/ex11.c: New file.
250 * rwlock.c: Fix complete braindamaged previous try to implement
251 timedout functions.
252
253 * spinlock.c: Pretty print.
254
d82e4c7b
UD
2552000-06-25 Ulrich Drepper <drepper@redhat.com>
256
257 * Makefile (tests): Add ex10. Add rules to build it.
258 * Versions [GLIBC_2.2] (libpthread): Add pthread_mutex_timedlock,
259 pthread_rwlock_timedrdlock, and pthread_rwlock_timedwrlock.
260 * condvar.c (pthread_cond_wait): Allow mutex of kind
261 PTHREAD_MUTEX_TIMED_NP.
262 (pthread_cond_timedwait_relative): Likewise.
263 * mutex.c (__pthread_mutex_init): Default is PTHREAD_MUTEX_TIMED_NP.
264 (__pthread_mutex_trylock): Use __pthread_alt_trylock for
265 PTHREAD_MUTEX_ERRORCHECK_NP. Handle PTHREAD_MUTEX_TIMED_NP.
266 (__pthread_mutex_lock): Use __pthread_alt_lock for
267 PTHREAD_MUTEX_ERRORCHECK_NP. Handle PTHREAD_MUTEX_TIMED_NP.
268 (__pthread_mutex_timedlock): New function.
269 (__pthread_mutex_unlock): Use __pthread_alt_unlock for
270 PTHREAD_MUTEX_ERRORCHECK_NP. Handle PTHREAD_MUTEX_TIMED_NP.
271 (__pthread_mutexattr_init): Use PTHREAD_MUTEX_TIMED_NP.
272 (__pthread_mutexattr_settype): Allow PTHREAD_MUTEX_TIMED_NP.
273 * spinlock.c: Implement alternate fastlocks.
274 * spinlock.h: Add prototypes.
275 * Examples/ex10.c: New file.
276 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
277 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
278
279 * rwlock.c (__pthread_rwlock_rdlock): Optimize loop a bit.
280 (__pthread_rwlock_timedrdlock): New function.
281 (__pthread_rwlock_timedwrlock): New function.
282 Use laternate fastlock function everywhere.
283
3d8e9510
AJ
2842000-06-21 Andreas Jaeger <aj@suse.de>
285
efa24b51 286 * sysdeps/pthread/timer_routines.c: Include <string.h> for memset
3d8e9510
AJ
287 prototype.
288
289 * join.c: Include <stdlib.h> for exit prototype.
290
697568d1
UD
2912000-06-20 Ulrich Drepper <drepper@redhat.com>
292
bdf09fab
UD
293 * sysdeps/i386/useldt.h: Include <stdlib.h>.
294
697568d1
UD
295 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define _POSIX_BARRIERS.
296 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
297
298 * Makefile (libpthread-routines): Add barrier.
299 (tests): Add ex9. Add rule to build ex9.
300 * Versions: Export barrier functions.
301 * barrier.c: New file.
302 * Examples/ex9.c: New file.
303 * sysdeps/pthread/pthread.h: Add barrier data types and declarations.
304 * sysdeps/pthread/bits/pthreadtypes.h: Likewise.
bdf09fab 305 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
697568d1 306
ba80a015
UD
3072000-06-19 H.J. Lu <hjl@gnu.org>
308
309 * spinlock.h (HAS_COMPARE_AND_SWAP): Defined if
310 HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS is defined.
311 (compare_and_swap_with_release_semantics): New. Default to
312 compare_and_swap if HAS_COMPARE_AND_SWAP_WITH_RELEASE_SEMANTICS
313 is not defined.
314
315 * spinlock.c (__pthread_unlock): Call
316 compare_and_swap_with_release_semantics () instead of
317 compare_and_swap ().
318
d2dfc5de
UD
3192000-06-19 Ulrich Drepper <drepper@redhat.com>
320
321 * sysdeps/pthread/timer_create.c: Use _set_errno instead of assigning
322 to errno directly.
323 * sysdeps/pthread/timer_delete.c: Likewise.
324 * sysdeps/pthread/timer_getoverr.c: Likewise.
325 * sysdeps/pthread/timer_gettime.c: Likewise.
326 * sysdeps/pthread/timer_settime.c: Likewise.
327
3282000-06-13 Kaz Kylheku <kaz@ashi.footprints.net>
329
330 Timer nodes are now reference counted, and can be marked
331 as deleted. This allows for the safe release of the global mutex
332 in the middle without losing the timer being operated on.
333
334 * sysdeps/pthread/posix-timer.h (struct timer_node): The inuse
335 member is now an enum with three values, so that an intermediate
336 state can be represented (deleted but not free for reuse yet).
337 New refcount member added.
338 * sysdeps/pthread/timer_routines.c: Likewise.
339
340 * sysdeps/pthread/posix-timer.h (timer_addref, timer_delref,
341 timer_valid): New inline functions added.
342
343 * sysdeps/pthread/timer_gettime.c (timer_gettime): Function
344 restructured, recursive deadlock bug fixed.
345
346 * sysdeps/pthread/timer_gettime.c (timer_gettime): Uses new
347 timer_addref to ensure that timer won't be deleted while mutex is not
348 held. Also uses timer_invalid to perform validation of timer handle.
349 * sysdeps/pthread/timer_settime.c (timer_settime): Likewise.
350 * sysdeps/pthread/timer_getoverr.c (timer_getoverrun): Likewise.
351
e26dd47f
UD
3522000-06-14 Ulrich Drepper <drepper@redhat.com>
353
354 * shlib-versions: Add entry for SH.
355 Patch by Kaz Kojima <kkojima@rr.iij4u.or.jp>.
356
38161ac7
UD
3572000-06-13 Kaz Kylheku <kaz@ashi.footprints.net>
358
359 A few optimizations. Got rid of unnecessary wakeups of timer threads,
360 tightened up some critical regions and micro-optimized some list
361 manipulation code.
362
363 * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
364 Returns int value now to indicate whether timer was queued at head.
365 * sysdeps/pthread/posix-timer.h: Likewise.
366 * sysdeps/pthread/timer_settime.c (timer_settime): Takes advantage of
367 new return value from __timer_thread_queue_timer to avoid waking
368 up timer thread unnecessarily.
369
370 * sysdeps/pthread/posix-timer.h (timer_id2ptr): No longer checks
371 inuse flag, because this requires mutex to be held. Callers updated
372 to do the check when they have the mutex.
373 * sysdeps/pthread/timer_getoverr.c: Add check for inuse here.
374
375 * sysdeps/pthread/timer_settime.c (timer_settime): Tighter critical
376 regions: avoids making system calls while holding timer mutex, and
377 a few computations were moved outside of the mutex as well.
378 * sysdeps/pthread/timer_gettime.c (timer_gettime): Likewise.
379
380 * sysdeps/pthread/posix-timer.h (list_unlink_ip): Function name changed
381 to list_unlink_ip, meaning idempotent. Pointer manipulation
382 changed to get better better code out of gcc.
383 * sysdeps/pthread/timer_routines.c (list_unlink): Non-idempotent
384 version of list_unlink added here.
385 * sysdeps/pthread/timer_delete.c: Use appropriate list unlink
386 function in all places: idempotent one for timers, non-idempotent
387 one for thread nodes.
388 * sysdeps/pthread/timer_settime: Likewise.
389 * sysdeps/pthread/timer_routines.c: Likewise.
390
7ae1fe4d
UD
3912000-06-13 Ulrich Drepper <drepper@redhat.com>
392
490dc9aa
UD
393 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_TIMERS): Define.
394 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
395
7ae1fe4d
UD
396 * sysdeps/pthread/Makefile: Remove tests definition.
397
3846ef75
UD
3982000-06-12 Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
399 Yutaka Niibe <gniibe@chroot.org>
400
401 * sysdeps/sh/pspinlock.c: New file.
402 * sysdeps/sh/pt-machine.h: New file.
403
a5b97402
UD
4042000-06-12 Ulrich Drepper <drepper@redhat.com>
405
55985355
UD
406 * Makefile (tests): Add joinrace.
407
a5b97402
UD
408 * Examples/ex6.c: Test return value of pthread_join.
409
2b72ebac
GK
4102000-06-11 Geoff Keating <geoffk@cygnus.com>
411
412 * sysdeps/powerpc/pspinlock.c (__pthread_spin_lock): Implement.
413 (__pthread_spin_trylock): Implement.
414 (__pthread_spin_unlock): Implement.
415 (__pthread_spin_init): Implement.
416 (__pthread_spin_destroy): Implement.
417
425638fb
UD
4182000-06-10 Ulrich Drepper <drepper@redhat.com>
419
420 * sysdeps/pthread/timer_routines.c (list_append): Little fix to
2b72ebac 421 really append the entry.
425638fb 422
6948d763
AJ
4232000-06-10 Andreas Jaeger <aj@suse.de>
424
425 * lockfile.c (__fresetlockfiles): Remove unused variable fp.
426
45dc1187
UD
4272000-06-10 Kaz Kylheku <kaz@ashi.footprints.net>
428
429 * sysdeps/pthread/timer_create.c: Thread matching now done on
430 clock type as well as thread attributes.
431 There are individual global signal-delivering threads for
432 different clock types.
433 * sysdeps/pthread/posix-timer.h: Likewise.
434 * sysdeps/pthread/timer_routines.c: Likewise.
435
436 * sysdeps/pthread/timer_routines.c: Thread allocation and
437 deallocation function now remembers to put thread on active
425638fb 438 list and remove from active list.
45dc1187
UD
439 Thus now the feature of binding multiple timers
440 to a single thread actually works.
441
ee5d4855
UD
4422000-06-10 Ulrich Drepper <drepper@redhat.com>
443
444 * pthread.c (__pthread_create_2_1): Optimize a bit.
445
446 * internals.h (invalid_handle): Also test for p_terminated != 0.
447 (nonexisting_handle): New function. Same as old invalid_handle.
448 * join.c (pthread_join): Use nonexisting_handle instead of
449 invalid_handle to test for acceptable thread handle.
41b37cb5 450 * manager.c (pthread_handle_free): Likewise.
15109bd4 451 * joinrace.c: New file.
ee5d4855
UD
452 Reported by Permaine Cheung <pcheung@cygnus.com>.
453
2715f28a
UD
4542000-06-08 Ulrich Drepper <drepper@redhat.com>
455
8aa8fc7f
UD
456 * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
457 Correct handling of matching variable.
458
480a06df
UD
459 * sysdeps/pthread/tst-timer.c (main): Rewrite initializers to
460 avoid warnings.
461
18e4e446
UD
462 * sysdeps/pthread/timer_routines.c (__timer_thread_queue_timer):
463 Be prepared for empty timer list.
464
165ab1d7
UD
465 * sysdeps/pthread/timer_create.c (timer_create): Correct names of
466 CPUTIME clock ID. Add support for thread clocks.
467
f2a5974b
UD
468 * sysdeps/pthread/posix-timer.h (timer_ptr2id): Operands in
469 subtraction were switched.
470
c0f79a04
UD
471 * sysdeps/pthread/timer_routines.c (init_module): Use
472 THREAD_MAXNODES threads.
473
55938273
UD
474 * sysdeps/pthread/posix-timer.h (struct timer_node): Add creator_pid.
475 * sysdeps/pthread/timer_create.c: Fill in creator_pid.
476 * sysdeps/pthread/timer_routines.c (thread_expire_timer): Send signal
477 with sigqueueinfo is this system call is available.
478
479 * sysdeps/pthread/timer_create.c (timer_create): Allow
480 CLOCK_CPUTIME if _POSIX_CPUTIME is defined.
481
2715f28a
UD
482 * sysdeps/pthread/Makefile: New file. Add rules to build timer
483 functionality.
484 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add TIMER_MAX.
485
4862000-06-04 Kaz Kylheku <kaz@ashi.footprints.net>
487
488 * sysdeps/pthread/posix-timer.h: New file.
489 * sysdeps/pthread/timer_create.c: New file.
490 * sysdeps/pthread/timer_delete.c: New file.
491 * sysdeps/pthread/timer_getoverr.c: New file.
492 * sysdeps/pthread/timer_gettime.c: New file.
493 * sysdeps/pthread/timer_routines.c: New file.
494 * sysdeps/pthread/timer_settime.c: New file.
495 * sysdeps/pthread/tst-timer.c: New file.
496
1b579f91
UD
4972000-06-08 Ulrich Drepper <drepper@redhat.com>
498
499 * sysdeps/unix/sysv/linux/bits/local_lim.h: Remove OPEN_MAX and
500 LINK_MAX definitions if necessary.
501
dc3b5786
UD
5022000-06-04 Kaz Kylheku <kaz@ashi.footprints.net>
503
504 Added missing fork time handling of global libio lock.
505
506 * lockfile.c (__fresetlockfiles): Now also resets the list lock,
507 not just the individual stream locks. Rewritten to use new
508 iterator interface provided by libio rather than accessing
509 global variable.
510
511 * lockfile.c (__flockfilelist, _funlockfilelist): New functions
512 which lock and unlock the stream list using the new interface
513 provied by libio.
514 * internals.h: Likewise.
515
516 * ptfork.c (__fork): Now calls __flockfilelist before fork,
517 and __funlockfilelist in the parent after the fork.
518 Child still calls __fresetlockfiles as before.
519
520 * linuxthreads.texi: Now explains what happens to streams at
521 fork time. Also whole new section on forking and thread added.
522 Definition of pthread_atfork moved out of Miscellaneous Functions
523 to this new section.
524
1dd54850
UD
5252000-06-04 Jakub Jelinek <jakub@redhat.com>
526
527 * sysdeps/sparc/sparc32/sparcv9/pspinlock.c (__pthread_spin_lock):
528 Add missing register.
529 * sysdeps/sparc/sparc64/pspinlock.c (__pthread_spin_lock): Likewise.
530
554eca5c
AJ
5312000-06-02 Jakub Jelinek <jakub@redhat.com>
532
533 * sysdeps/sparc/sparc32/pspinlock.c: Implement spinlocks.
534 * sysdeps/sparc/sparc32/sparcv9/pspinlock.c: New.
535 * sysdeps/sparc/sparc64/pspinlock.c: Implement spinlocks.
536
a3a99e01
AJ
5372000-05-31 Andreas Jaeger <aj@suse.de>
538
539 * sysdeps/mips/pspinlock.c: Implement spinlocks.
540
c0f3519d
UD
5412000-05-28 Ulrich Drepper <drepper@redhat.com>
542
84838b8f
UD
543 * spinlock.c (__pthread_lock): Remove ASSERT.
544
c0f3519d
UD
545 * Makefile (tests): Add ex8.
546 * Examples/ex8.c: New file.
547
5482000-05-12 Kaz Kylheku <kaz@ashi.footprints.net>
549
550 Bugfix: The pthread_atfork mechanism now takes care of its
551 own internal mutex at fork time.
552
553 * ptfork.c (__fork): Revised so that the mutex is held across
554 the fork operation and while the handlers are called, and so that
555 the child resets the mutex.
c0f3519d
UD
556
557 * linuxthreads.texi: Updated pthread_atfork documentation to make
558 it clear that fork and pthread_atfork can't be reentered from
559 atfork handlers, that pthread_atfork and fork are mutually atomic,
560 and that the handlers are inherited by the child process.
561
378fbeb4
UD
5622000-05-24 Ulrich Drepper <drepper@redhat.com>
563
564 * Makefile (libpthread-routines): Add pspinlock.
565 * cancel.c: Rename __pthread_spin_unlock back to __pthread_unlock.
566 Use struct _pthread_fastlock instead of pthread_spinlock_t.
567 * condvar.c: Likewise.
568 * internals.h: Likewise.
569 * join.c: Likewise.
570 * manager.c: Likewise.
571 * mutex.c: Likewise.
572 * pthread.c: Likewise.
573 * rwlock.c: Likewise.
574 * semaphore.c: Likewise.
575 * signals.c: Likewise.
576 * spinlock.h: Likewise.
577 * spinlock.c: Likewise. Remove pthread_spin_lock functions.
578 * sysdeps/alpha/pspinlock.c: New file.
579 * sysdeps/arm/pspinlock.c: New file.
580 * sysdeps/i386/pspinlock.c: New file.
581 * sysdeps/m68k/pspinlock.c: New file.
582 * sysdeps/mips/pspinlock.c: New file.
583 * sysdeps/powerpc/pspinlock.c: New file.
584 * sysdeps/sparc/sparc32/pspinlock.c: New file.
585 * sysdeps/sparc/sparc64/pspinlock.c: New file.
586 * sysdeps/pthread/bits/pthreadtypes.h: Remove pthread_spinlock_t
587 back to _pthread_fastlock. Define new pthread_spinlock_t.
588
fff82885
AJ
5892000-05-24 Andreas Jaeger <aj@suse.de>
590
591 * sysdeps/i386/i686/pt-machine.h: Only use LDT on newer kernels.
592
5d1fba6d
AJ
5932000-05-21 Jakub Jelinek <jakub@redhat.com>
594
595 * manager.c (pthread_handle_create): Initialize p_res._sock to -1.
596
f14273c5
AJ
5972000-05-13 Jakub Jelinek <jakub@redhat.com>
598
599 * internals.h (__RES_PTHREAD_INTERNAL): Define.
600
93414bb9
UD
6012000-05-06 Kaz Kylheku <kaz@ashi.footprints.net>
602
603 * mutex.c (pthread_once): IN_PROGRESS state of pthread_once_t
604 object state is represented with additional bits which distinguish
605 whether that state was set up in the current process, or
606 in an ancestor process. If that state was set in an ancestor,
607 it means that a fork happened while thread was executing the init
608 function. In that case, the state is reset to NEVER.
609 * mutex.c (__pthread_once_fork_prepare): New function.
610 (__pthread_once_fork_child): Likewise
611 (__pthread_once_fork_parent): Likewise
612 (__pthread_reset_pthread_once): Removed.
613 * ptfork.c (__fork): Call new handlers in mutex.c.
614 * internals.h: Declarations of new mutex.c functions added.
615 Declaration of removed function deleted.
616 * linuxthreads.texi: Updated documentation about pthread_once
617 to clarify what happens under cancellation and forking.
618
fc08075d
UD
6192000-05-06 Kaz Kylheku <kaz@ashi.footprints.net>
620
621 * internals.h: New thread manager request type, REQ_KICK.
622 * join.c (pthread_exit): main thread now calls exit() instead
623 of _exit() in order to proper process cleanup.
624 * manager.c (__pthread_manager): Do not terminate manager
625 after unblocking main thread; wait for main thread's
626 REQ_PROCESS_EXIT request instead.
627 Also, added REQ_KICK case to handle new request; this just does
628 nothing.
629 * manager.c (pthread_exited): Do not terminate manager after
630 unblocking main thread.
631 * manager.c (__pthread_manager_sighandler): If the main thread
632 is waiting for all other threads to die, send a REQ_KICK into
633 the thread manager request pipe to get it to clean out the threads
634 and unblock the main thread as soon as possible. This fixes
635 the 2000 millisecond hang on shutdown bug.
636 * Examples/ex7.c: New file, tests shutdown behavior when all threads
637 including the main one call pthread_exit(), or implicitly do so.
638 * Makefile (tests): Add ex7.
639
b19b7383
AJ
6402000-05-05 Andreas Jaeger <aj@suse.de>
641
642 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
643 (pthread_getcpuclockid): Correct test for ourselves.
644
c77ec56d
UD
6452000-05-05 Ulrich Drepper <drepper@redhat.com>
646
647 * internals.h (struct _pthread_descr_struct): Reorganization.
648 Allocate room for 16 pointers at head of the structure for future
649 thread-local data handling. Move p_self member in this area.
650 * manager.c (pthread_handle_create): Adjust use of p_self.
651 * sysdeps/i386/useldt.h (THREAD_SELF): Likewise.
652 * pthread.c (__pthread_initial_thread): Adjust initialization.
653 (__pthread_manager_thread): Likewise.
654
6552000-04-29 Bruno Haible <haible@clisp.cons.org>
160016c9
UD
656
657 * join.c (pthread_exit): Use THREAD_GETMEM_NC instead of THREAD_GETMEM
658 for eventmask larger than 1 word.
659
3300816c
UD
6602000-04-27 Ulrich Drepper <drepper@redhat.com>
661
662 * Versions [libpthread] (GLIBC_2.2): Add __pthread_initialize_minimal.
663 * pthread.c (__pthread_initialize_minimal): New function. Perform
664 minimal initialization.
665 (pthread_initialize): Remove this code here.
666 * sysdeps/i386/i686/pt-machine.h: Include "../useldt.h" again. We
667 are working around the problem in glibc.
668
d472655c
UD
6692000-04-25 Ulrich Drepper <drepper@redhat.com>
670
671 * sysdeps/i386/i686/pt-machine.h: Do not use "../useldt.h" for
672 now. First gcc must be fixed (more concrete: libgcc).
673
9bf4d640
UD
6742000-04-24 Ulrich Drepper <drepper@redhat.com>
675
e19ae111 676 * pthread.c: Remove special treatement for interrupt handlers on x86.
9bf4d640
UD
677 * manager.c (pthread_free): Use FREE_THREAD not FREE_THREAD_SELF.
678 * sysdeps/i386/useldt.h: Use "q" constraint instead of "r" where
679 necessary.
680 * sysdeps/i386/i686/pt-machine.h: Include "../useldt.h".
681
9682a871
UD
6822000-04-24 Mark Kettenis <kettenis@gnu.org>
683
684 * join.c (pthread_exit): Set p_terminated after reporting the
685 termination event instead of before.
686
d879eb85
UD
6872000-04-20 Jakub Jelinek <jakub@redhat.com>
688
689 * sysdeps/pthread/bits/libc-lock.h: Only declare __pthread_rwlock_*
690 if __USE_UNIX98.
691
6922000-04-18 Andreas Jaeger <aj@suse.de>
693
694 * Versions: Use ld instead of ld.so.
695
318c80d4
UD
6962000-04-18 Jakub Jelinek <jakub@redhat.com>
697
698 * sysdeps/unix/sysv/linux/sparc/bits/sigcontext.h (struct sigcontext):
699 Remove the typedef keyword.
700
cd43f797
UD
7012000-04-18 Jakub Jelinek <jakub@redhat.com>
702
703 * sysdeps/sparc/sparc64/pt-machine.h (MEMORY_BARRIER): Use membar,
704 not stbar.
705 (READ_MEMORY_BARRIER): Define.
706 * spinlock.c (__pthread_spin_unlock): Use READ_MEMORY_BARRIER, not
707 MEMORY_BARRIER.
708 * internals.h (READ_MEMORY_BARRIER): Define if not defined in sysdep
709 headers.
710
dbacafe5
UD
7112000-04-17 Ulrich Drepper <drepper@redhat.com>
712
713 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
714 (pthread_getcpuclockid): Don't compare thread_id with thread_self,
715 use thread_handle().
716
e2947c42
UD
7172000-04-16 Ulrich Drepper <drepper@redhat.com>
718
e3265f5b
UD
719 * condvar.c (pthread_cond_timedwait_relative): Don't test for owner
720 if fast mutex is used. Don't initialize `already_canceled' twice.
721 Correctly test for return value of timedsuspend.
722
e2947c42
UD
723 * pthread.c: Correct long-time braino. We never set SA_SIGINFO and
724 therefore don't need the _rt versions of the signal handlers.
725
150f740a
UD
7262000-04-15 Ulrich Drepper <drepper@redhat.com>
727
c269fdb4
UD
728 * pthread.c (pthread_yield): New function.
729 * sysdeps/pthread/pthread.h (pthread_yield): Add prototype.
730 * Versions [libpthread] (GLIBC_2.2): Add pthread_yield.
e2947c42 731 * internals.h: Declare __pthread_yield.
c269fdb4 732
145b8413
UD
733 * pthread.c (pthread_initialize): Avoid a bit more code if
734 realtime signals are known to exist.
735
150f740a
UD
736 * pthread.c: Is __ASSUME_REALTIME_SIGNALS then avoid generating code
737 to dynamically detect RT signals and avoid generating compatibility
738 functions with old kernel.
739 * restart.h (restart) [__ASSUME_REALTIME_SIGNALS]: Use
740 __pthread_restart_new directly.
741 (suspend) [__ASSUME_REALTIME_SIGNALS]: Use
742 __pthread_wait_for_restart_signal directly.
743 (timedsuspend) [__ASSUME_REALTIME_SIGNALS]: Use
744 __pthread_timedsuspend_new directly.
745
b2d4446f
UD
7462000-04-15 Ulrich Drepper <drepper@redhat.com>
747
ef187474
UD
748 * condvar.c: Remove all the special code to handle cond_timedwait.
749 Use timedsuspend instead.
750 * internals.h: Declare __pthread_timedsuspend_old,
751 __pthread_timedsuspend_new, and __pthread_timedsuspend.
752 Remove declaration of __pthread_init_condvar.
753 * pthread.c: Define __pthread_timedsuspend variable.
754 (__pthread_timedsuspend_old): New function. Timed suspension
755 implementation for old Linux kernels.
756 (__pthread_timedsuspend_new): New function. Timed suspension
757 implementation for new Linux kernels.
758 * restart.h (timedsuspend): New function. Call appropriate
759 suspension function through __pthread_timedsuspend.
760 * semaphore.c (sem_timedwait): Use timedsuspend, don't duplicate
761 the code.
762 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
763
a5a6f926
UD
764 * internals.h (WRITE_MEMORY_BARRIER): Define as MEMORY_BARRIER if
765 undefined.
766 * spinlock.c: Use WRITE_MEMORY_BARRIER instead of MEMORY_BARRIER
767 where possible.
768 * sysdeps/alpha/pt-machine.h: Define WRITE_MEMORY_BARRIER.
769 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
770
b2d4446f
UD
771 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _POSIX_SPAWN.
772 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
773
b82f6af2
AJ
7742000-04-14 Andreas Jaeger <aj@suse.de>
775
776 * weaks.c: Fix typo.
777
43c36f63
AJ
778 * shlib-versions (mips.*-.*-linux.*): Support only GLIBC 2.0 and
779 2.2 for linuxthreads.
780
547ff462
UD
7812000-04-13 Ulrich Drepper <drepper@redhat.com>
782
783 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c
784 (pthread_getcpuclockid): Fix typo.
785
b3ae0650
UD
7862000-04-12 Ulrich Drepper <drepper@redhat.com>
787
3737ff12
UD
788 * Makefile (libpthread-routines): Add getcpuclockid.
789 * Versions [libpthread] (GLIBC_2.2): Add pthread_getcpuclockid.
790 * sysdeps/pthread/getcpuclockid.c: New file.
791 * sysdeps/unix/sysv/linux/i386/getcpuclockid.c: New file.
792 * sysdeps/pthread/pthread.h: Add prototype for pthread_getcpuclockid.
793
07d641eb
UD
794 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_SPIN_LOCKS):
795 Defined.
796 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
797
d8d914df
UD
798 * sysdeps/pthread/pthread.h: Add prototypes for pthread_spin_init,
799 pthread_spin_destroy, pthread_spin_lock, pthread_spin_trylock,
800 and pthread_spin_unlock.
801 * sysdeps/pthread/bits/pthreadtypes.h: Change struct _pthread_fastlock
802 into pthread_spinlock_t. Change all uses.
803 * spinlock.c: Implement pthread_spin_lock.
804 Rename __pthread_unlock to __pthread_spin_unlock and define weak
805 alias for real name.
806 Define pthread_spin_trylock, pthread_spin_init, and
807 pthread_spin_destroy.
808 Change all uses of _pthread_fastlock to pthread_spinlock_t.
809 * spinlock.h: Rename __pthread_unlock to __pthread_spin_unlock.
810 Change all uses of _pthread_fastlock to pthread_spinlock_t.
811 * Versions [libpthread] (GLIBC_2.2): Add pthread_spin_init,
812 pthread_spin_destroy, pthread_spin_lock, pthread_spin_trylock,
813 and pthread_spin_unlock.
814 * cancel.c: Use __pthread_spin_unlock instead of __pthread_unlock.
815 Change all uses of _pthread_fastlock to pthread_spinlock_t.
816 * condvar.c: Likewise.
817 * internals.h: Likewise.
818 * join.c: Likewise.
819 * manager.c: Likewise.
820 * mutex.c: Likewise.
821 * pthread.c: Likewise.
822 * rwlock.c: Likewise.
823 * semaphore.c: Likewise.
824 * signals.c: Likewise.
825
b3ae0650
UD
826 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add various new POSIX
827 macros.
828 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: New file.
829
8a31d742
UD
8302000-04-11 Ulrich Drepper <drepper@redhat.com>
831
832 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add
833 _POSIX_SHARED_MEMORY_OBJECTS.
834
2a086df9
AJ
8352000-04-11 Andreas Jaeger <aj@suse.de>
836
837 * sysdeps/mips/pt-machine.h (MEMORY_BARRIER): Define.
838 (__compare_and_swap): Mark as modifying memory.
839
4a1a3c21
GK
8402000-04-11 Geoff Keating <geoffk@cygnus.com>
841
842 * sysdeps/powerpc/pt-machine.h (MEMORY_BARRIER): Don't be
843 __volatile__.
844 (__compare_and_swap): Replace other 'sync' with MEMORY_BARRIER.
845 Don't have the 'asm' __volatile__.
846
de262537
UD
8472000-04-11 Ulrich Drepper <drepper@redhat.com>
848
849 * internals.h: Define MEMORY_BARRIER as empty if not defined already.
850 * spinlock.c (__pthread_lock): Add memory barriers.
851 (__pthread_unlock): Likewise.
852 * sysdeps/alpha/pt-machine.h (MEMORY_BARRIER): Define using mb
853 instruction.
854 (RELEASE): Not needed anymore.
855 (__compare_and_swap): Mark asm as modifying memory.
856 * sysdeps/powerpc/pt-machine.h (sync): Remove. Replace with definition
857 of MEMORY_BARRIER.
858 (__compare_and_swap): Use MEMORY_BARRIER instead of sync.
859 * sysdeps/sparc/sparc32/pt-machine.h (RELEASE): Not needed anymore.
860 (MEMORY_BARRIER): Define using stbar.
861 * sysdeps/sparc/sparc64/pt-machine.h (MEMORY_BARRIER): Define using
862 stbar.
863 (__compare_and_swap): Use MEMORY_BARRIER to ensure ordering.
864 Patch by Xavier Leroy <Xavier.Leroy@inria.fr> based on comments by
865 Mike Burrows <m3b@pa.dec.com>.
866
4186c9f4
UD
8672000-04-09 Ulrich Drepper <drepper@redhat.com>
868
869 * signals.c (sigaction): Fix return value for the case SIG is one
870 of the signals the implementation uses.
871 Patch by Xavier.Leroy@inria.fr.
872
bd457114
UD
8732000-04-01 Andreas Jaeger <aj@suse.de>
874
875 * attr.c: Use shlib-compat macros.
876 * oldsemaphore.c: Likewise.
877 * pthread.c: Likewise.
878 * weaks.c: Likewise.
879
1edf26ff
UD
8802000-03-26 Ulrich Drepper <drepper@redhat.com>
881
882 * semaphore.c (sem_timedwait): New function.
883 Patch by Carl Mailloux <carlm@oricom.ca>.
884 * semaphore.h: Declare sem_timedwait.
8e605e78 885 * Versions [libpthread] (GLIBC_2.2): Add sem_timedwait.
1edf26ff 886
54f6cbb3
RM
8872000-03-26 Roland McGrath <roland@baalperazim.frob.com>
888
889 * sysdeps/pthread/Makefile: File removed.
890
c0bc5f7b
UD
8912000-03-23 Ulrich Drepper <drepper@redhat.com>
892
383052e9
UD
893 * mutex.c (__pthread_reset_pthread_once): Reset once_masterlock.
894 * internals.h (__pthread_reset_pthread_once): Add prototype.
895 * ptfork.c (__fork): Call __pthread_reset_pthread_once.
896
c0bc5f7b
UD
897 * manager.c (pthread_handle_create): Store ID of new thread before
898 clone call.
899
0bf98029
UD
9002000-03-21 Ulrich Drepper <drepper@redhat.com>
901
ef7dddd0
UD
902 * attr.c: Use new macros from shlib-compat.h to define versions.
903 * oldsemaphore.c: Likewise.
904 * semaphore.c: Likewise.
905 * weaks.c: Likewise.
906
1ab1ea76
UD
907 * pthread.c: Update for new SHLIB_COMPAT definition.
908
101edd3f
UD
909 * manager.c (__pthread_manager): Unmask debug signal.
910
0bf98029
UD
911 * pthread.c (pthread_initialize): Test for address of __dso_handle
912 being NULL, not value. Use __on_exit, not on_exit.
e063cef8 913 Patch by Andreas Jaeger <aj@suse.de>.
0bf98029 914
75836bc8
UD
915 * pthread.c: Use new macros from shlib-compat.h to define versions.
916
a6a478e9
UD
9172000-03-19 Ulrich Drepper <drepper@redhat.com>
918
919 * pthread.c (pthread_initialize): Instead of on_exit use
920 __cxa_atexit if __dso_label is available to allow unloading the
921 libpthread shared library.
922
13a83604
UD
9232000-03-16 Ulrich Drepper <drepper@redhat.com>
924
925 * condvar.c: Make tests for ownership of mutex less strict.
926
30b416ea
UD
9272000-03-14 Ulrich Drepper <drepper@redhat.com>
928
5d141597
UD
929 * condvar.c (pthread_cond_wait): Check whether mutex is owned by
930 current thread and return error if not.
04366d5f
UD
931 (pthread_cond_timedwait_relative_old): Likewise.
932 (pthread_cond_timedwait_relative_new): Likewise.
5d141597 933
30b416ea
UD
934 * mutex.c (__pthread_once): Handle cancelled init function correctly.
935 (pthread_once_cancelhandler): New function.
936 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
937
56eea8d1
UD
9382000-03-14 Andreas Jaeger <aj@suse.de>
939
940 * pthread.c (pthread_handle_sigcancel_rt): GS has been renamed to
941 REG_GS.
942 (pthread_handle_sigrestart_rt): Likewise.
943 * signals.c (pthread_sighandler_rt): Likewise.
944
3d9ebedb
AJ
9452000-03-02 Andreas Jaeger <aj@suse.de>
946
947 * sysdeps/pthread/bits/libc-lock.h: Fix typo.
948 Reported by Sean Chen <sean.chen@turbolinux.com>.
949
b041ebc2
UD
9502000-02-28 Andreas Jaeger <aj@suse.de>
951
952 * rwlock.c: Fix typo.
953
0ed99ce4
UD
9542000-02-27 Ulrich Drepper <drepper@redhat.com>
955
956 * rwlock.c: Define __* variants of the functions and make old names
957 aliases.
958 * Versions [GLIBC_2.2]: Export the __pthread_rwlock_* functions.
959 * sysdeps/pthread/bits/libc-lock.h: Define __libc_rwlock_* macros.
960
d66732e0
UD
9612000-02-25 Andreas Jaeger <aj@suse.de>
962
963 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
0ed99ce4
UD
964 pwrite64, lseek64, open64, and __open64 with version 2.2.
965
93a19c64
UD
9662000-02-22 Ulrich Drepper <drepper@redhat.com>
967
968 * semaphore.h (SEM_FAILED): Use 0 not NULL.
969
ec91ea7c
UD
9702000-02-14 Ulrich Drepper <drepper@redhat.com>
971
972 * condvar.c (pthread_cond_timedwait_relative_old): Tight loop with
973 nanosleep does not work either. Get absolute time inside the
974 loop.
975 (pthread_cond_timedwait_relative_new): Likewise.
976 Patch by Kaz Kylheku <kaz@ashi.footprints.net>.
977
f5ff12d8
UD
9782000-02-13 Andreas Jaeger <aj@suse.de>
979
980 * condvar.c (pthread_cond_timedwait_relative_new): Fix last patch.
981 (pthread_cond_timedwait_relative_old): Likewise.
982
46661856
UD
9832000-02-13 Ulrich Drepper <drepper@redhat.com>
984
985 * condvar.c (pthread_cond_timedwait_relative_old): Undo last patch
986 but keep the code around. A bug in the kernel prevent us from
987 using the code.
988 (pthread_cond_timedwait_relative_new): Likewise.
989 (PR libc/1597 and libc/1598).
990
b168cff2
UD
9912000-02-01 Kaz Kylheku <kaz@ashi.footprints.net>
992
993 * condvar.c (pthread_cond_timedwait_relative_old): Do tight
994 loop around nanosleep calls instead of around most of the function
995 (pthread_cond_timedwait_relative_new): Likewise.
996 body. Got rid of backwards goto and one local.
997
8a94dfe4
UD
9982000-01-31 Ulrich Drepper <drepper@redhat.com>
999
1000 * condvar.c (pthread_cond_timedwait_relative_old): Recompute time
1001 before every nanosleep call to account for time spent in the rest
1002 of the function.
1003 (pthread_cond_timedwait_relative_new): Likewise.
1004 Patch by khendricks@ivey.uwo.ca (PR libc/1564).
1005
b6aa34eb
UD
10062000-01-29 Ulrich Drepper <drepper@redhat.com>
1007
1008 * condvar.c (pthread_cond_timedwait_relative_old): Get remaining time
1009 from nanosleep call so that in case we restart we only wait for the
1010 remaining time.
1011 (pthread_cond_timedwait_relative_new): Likewise.
1012 Patch by khendricks@ivey.uwo.ca (PR libc/1561).
1013
0af4c646
UD
10142000-01-18 Ulrich Drepper <drepper@cygnus.com>
1015
1016 * manager.c (pthread_allocate_stack): Compute guard page address
1017 correctly. Patch by HJ Lu.
1018
1019 * sysdeps/pthread/pthread.h: Define
1020 PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP.
1021
2449110a
UD
10222000-01-16 Ulrich Drepper <drepper@cygnus.com>
1023
1024 * rwlock.c (pthread_rwlock_unlock): Correct one more problem with
1025 preference handling.
1026 (pthread_rwlockattr_setkind_np): Allow
1027 PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP.
1028 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
1029
03c0d6ef
UD
10302000-01-12 Ulrich Drepper <drepper@cygnus.com>
1031
1032 * internals.h (pthread_readlock_info): New structure.
1033 (_pthread_descr_struct): Add p_readlock_list, p_readlock_free, and
1034 p_untracked_readlock_count.
1035 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
1036 Add initializers for new fields.
1037 * manager.c (pthread_free): Free read/write lock lists.
1038 * queue.h (queue_is_empty): New function.
1039 * rwlock.c: Implement requirements about when readers should get
1040 locks assigned.
1041 * sysdeps/pthread/pthread.h
1042 (PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP): New definition.
1043 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_rwlock_t):
1044 Define this name as well.
1045 Patches by Kaz Kylheku <kaz@ashi.footprints.net>.
1046
d569d333
UD
10472000-01-05 Ulrich Drepper <drepper@cygnus.com>
1048
2ba3c836
UD
1049 * pthread.c (__pthread_initial_thread, pthread_manager_thread):
1050 Adjust initializers for struct _pthread_descr_struct change.
d569d333
UD
1051 * internals.h (struct _pthread_descr_struct): Move new elements to
1052 the end.
1053
1d2fc9b3
UD
10542000-01-03 Kaz Kylheku <kaz@ashi.footprints.net>
1055
1056 Redesigned how cancellation unblocks a thread from internal
1057 cancellation points (sem_wait, pthread_join,
1058 pthread_cond_{wait,timedwait}).
1059 Cancellation won't eat a signal in any of these functions
1060 (*required* by POSIX and Single Unix Spec!).
a3bfd999 1061 * condvar.c: Spontaneous wakeup on pthread_cond_timedwait won't eat a
1d2fc9b3
UD
1062 simultaneous condition variable signal (not required by POSIX
1063 or Single Unix Spec, but nice).
1064 * spinlock.c: __pthread_lock queues back any received restarts
1065 that don't belong to it instead of assuming ownership of lock
1066 upon any restart; fastlock can no longer be acquired by two threads
1067 simultaneously.
a3bfd999 1068 * restart.h: Restarts queue even on kernels that don't have
1d2fc9b3
UD
1069 queued real time signals (2.0, early 2.1), thanks to atomic counter,
1070 avoiding a rare race condition in pthread_cond_timedwait.
1071
1c5d4617
UD
10721999-12-31 Andreas Jaeger <aj@suse.de>
1073
1074 * internals.h: Remove duplicate prototype declarations.
1075
1076 * weaks.c: Remove __THROW from prototypes since the file is not
1077 compiled by a C++ compiler.
1078 * internals.h: Likewise.
1079
10801999-12-30 Andreas Jaeger <aj@suse.de>
1081
1082 * sysdeps/pthread/pthread.h: Move internal functions to...
1083 * sysdeps/pthread/bits/libc-lock.h: ...here.
1084
d876f532
UD
10851999-12-29 Andreas Jaeger <aj@suse.de>
1086
1087 * sysdeps/pthread/pthread.h: Fix typos, reformat comments.
1088
056e0358
UD
10891999-12-28 Ulrich Drepper <drepper@cygnus.com>
1090
1091 * sysdeps/alpha/pt-machine.h: Move stack_pointer definition to the
1092 beginning.
1093
1094 * manager.c (__pthread_start): Add one more cast to prevent
1095 warning on 64bit machines.
1096
46fd4f67
UD
10971999-12-21 Ulrich Drepper <drepper@cygnus.com>
1098
1099 * manager.c (pthread_handle_create): Set p_pid of new thread
1100 before calling the callback function to report a new thread.
1101
c63598bf
UD
11021999-12-20 Andreas Jaeger <aj@suse.de>
1103
1104 * pthread.c (pthread_initialize): Move getrlimit call after
1105 setting of errno.
1106
b85697f6
UD
11071999-12-18 Ulrich Drepper <drepper@cygnus.com>
1108
778c59c8
UD
1109 * Versions: Export pread, __pread64, pread64, pwrite, __pwrite64,
1110 pwrite64, lseek64, open64, and __open64.
1111 * wrapsyscall.c: Define pread, __pread64, pread64, pwrite, __pwrite64,
1112 pwrite64, lseek64, open64, and __open64.
1113
b85697f6
UD
1114 * manager.c (pthread_allocate_stack): Correct computation of
1115 new_thread_bottom. Correct handling of stack size and when the
1116 rlimit method to guard for stack growth is used.
1117 * pthread.c (pthread_initialize): Stack limit must be STACK_SIZE
1118 minus one pagesize (not two).
1119
b43b13ac
UD
11201999-12-03 Andreas Jaeger <aj@suse.de>
1121
1122 * Versions: Add __res_state with version GLIBC_2.2.
1123
1124 * errno.c (__res_state): New function to return thread specific
1125 resolver state.
1126
1127 * pthread.c (pthread_initialize): Initialize p_resp.
1128 (__pthread_reset_main_thread): Also set p_resp.
1129
1130 * manager.c (pthread_handle_create): Initialize p_resp.
1131
1132 * internals.h: Add thread specific resolver state.
1133 Based on patches by Adam D. Bradley <artdodge@cs.bu.edu>.
1134
d7a4856e
UD
11351999-12-01 Ulrich Drepper <drepper@cygnus.com>
1136
1137 * sysdeps/i386/pt-machine.h: Move stack_pointer definition to the
1138 beginning.
1139 * sysdeps/i386/i686/pt-machine.h: Likewise.
1140 Patches by Alan Modra <alan@SPRI.Levels.UniSA.Edu.Au>.
1141
ffd35632
UD
11421999-11-23 Ulrich Drepper <drepper@cygnus.com>
1143
1144 * manager.c (pthread_start_thread_event): Initialize p_pid already
1145 here.
1146
20bdb31b
UD
11471999-11-22 Ulrich Drepper <drepper@cygnus.com>
1148
1149 * internals.h: Add prototype for __pthread_manager_event.
1150 * manager.c (__pthread_manager_event): New function.
1151 (pthread_start_thread_event): Correct computation of self.
1152 Use INIT_THREAD_SELF.
1153 * pthread.c (__pthread_manager_thread): Initialize p_lock.
1154 (__pthread_initialize_manager): Respect event flags also for creation
1155 of the manager thread.
1156
178a145a
UD
11571999-11-08 Ulrich Drepper <drepper@cygnus.com>
1158
1159 * pthread.c (__pthread_initialize_manager): Initialize
1160 __pthread_manager_thread.p_tid.
1161
a9cb398f
UD
11621999-11-02 Ulrich Drepper <drepper@cygnus.com>
1163
ab86fbb1
UD
1164 * internals.h: Declare __pthread_last_event.
1165 * manager.c: Define __pthread_last_event.
1166 (pthread_handle_create): Set __pthread_last_event.
1167 (pthread_exited): Likewise.
1168 * join.c (pthread_exit): Likewise.
1169
a9cb398f
UD
1170 * Makefile (libpthread-routines): Add events.
1171 * events.c: New file.
1172 * internals.h: Protect against multiple inclusion.
1173 Include thread_dbP.h header.
1174 (struct _pthread_descr_struct): Add new fields p_report_events and
1175 p_eventbuf.
1176 Declare event reporting functions.
1177 * join.c (pthread_exit): Signal event if this is wanted.
1178 * manager.c (__pthread_threads_events): New variable.
1179 (pthread_handle_create): Take new parameters with event information.
1180 Signal TD_CREATE event if wanted.
1181 (__pthread_manager): Adjust pthread_handle_create call.
1182 (pthread_start_thread_event): New function. Block until manager is
1183 finished and then call pthread_start_thread.
1184 (pthread_exited): Signal TD_REAP event if wanted.
1185
8dd1e494
UD
11861999-10-26 Ulrich Drepper <drepper@cygnus.com>
1187
1188 * restart.h (suspend_with_cancellation): Rewrite as a macro.
1189
1190 * condvar.c (pthread_cond_timedwait_relative): Don't mark as inline.
1191
86cfe82d
UD
11921999-10-25 Andreas Jaeger <aj@suse.de>
1193
1194 * internals.h: Remove K&R compatibility.
1195 * no-tsd.c: Likewise.
1196 * semaphore.h: Likewise.
1197 * signals.c: Likewise.
1198 * sysdeps/pthread/bits/libc-tsd.h: Likewise.
1199 * sysdeps/unix/sysv/linux/bits/sigthread.h: Likewise.
1200 * weaks.c: Likewise.
1201
15daa639
UD
12021999-10-21 Xavier Leroy <Xavier.Leroy@inria.fr>
1203
1204 * linuxthreads/pthread.c: For i386, wrap pthread_handle_sigrestart
1205 and pthread_handle_sigcancel with functions that restore
1206 %gs from the signal context. For each signal handling function,
1207 two wrappers are required, one for a non-RT signal and one for
1208 a RT signal.
1209 * linuxthreads/signal.c: For i386, add code to restore %gs
1210 from the signal context in pthread_sighandler and
1211 pthread_sighandler_rt.
1212
ef5d6645
UD
12131999-10-17 Ulrich Drepper <drepper@cygnus.com>
1214
1215 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add cast.
1216
f6367df2
UD
12171999-10-14 Ulrich Drepper <drepper@cygnus.com>
1218
4a379216
UD
1219 * pthread.c (__pthread_initial_thread): Pass argument to
1220 PTHREAD_START_ARGS_INITIALIZER.
1221 (__pthread_manager_thread): Likewise.
1222
1223 * internals.h (PTHREAD_START_ARGS_INITIALIZER): Add parameter to
1224 initialize function.
1225
f6367df2
UD
1226 * manager.c (pthread_handle_create): Remove p_startfct initialization.
1227
1228 * internals.h (_pthread_descr_struct): We don't need p_startfct field.
1229
d4c5cf80
UD
12301999-10-12 Ulrich Drepper <drepper@cygnus.com>
1231
1232 * internals.h: Correct return types for __libc_read and __libc_write.
1233
883c331a
UD
12341999-10-09 Andreas Jaeger <aj@suse.de>
1235
1236 * internals.h: Add __new_sem_post to get prototype in
1237 manager.c; include semaphore.h for needed types.
1238
c813f986
UD
12391999-10-08 Ulrich Drepper <drepper@cygnus.com>
1240
1241 * manager.c (__pthread_manager) [REQ_POST]: Use __new_sem_post
1242 directly instead of calling sem_post which should not be necessary
1243 but is faster and might help in some case to work around problems.
c1422e5b 1244 Patch by khendricks@ivey.uwo.ca [libc/1382].
c813f986 1245
0f5219d4
UD
12461999-10-08 Andreas Schwab <schwab@suse.de>
1247
1248 * sysdeps/pthread/Subdirs: New file.
1249 * Implies: Removed.
1250
9640bbe1
UD
12511999-10-07 Ulrich Drepper <drepper@cygnus.com>
1252
1253 * Implies: New file.
1254 * internals.h (struct _pthread_descr_struct): Add p_startfct.
1255 * manager.c (pthread_handle_create): Initialize p_startfct.
1256 * pthread.c: Define __linuxthread_pthread_sizeof_descr variable.
1257
079c00e6
UD
12581999-09-25 Ulrich Drepper <drepper@cygnus.com>
1259
d790bc34
UD
1260 * manager.c (__linuxthreads_pthread_threads_max): New variable.
1261 * specific.c (__linuxthreads_pthread_keys_max): New variable.
6e42b0f1 1262 (__linuxthreads_pthread_key_2ndlevel_size): New variable.
d790bc34 1263
079c00e6
UD
1264 * condvar.c (pthread_cond_timedwait_relative): Never return with
1265 EINTR. Patch by Andreas Schwab.
1266
b5c69d99
UD
12671999-09-19 Ulrich Drepper <drepper@cygnus.com>
1268
1269 * signals.c (sigaction): Correct last patch. Don't select
1270 pthread_sighandler_rt based on the signal number but instead of
1271 the SA_SIGINFO flag.
1272
d790bc34
UD
12731999-09-23 Ulrich Drepper <drepper@cygnus.com>
1274
1275 * specific.c: Move definitions of struct pthread_key_struct and
1276 destr_function to ...
1277 * internals.h: ...here.
1278
9cf44e65
UD
12791999-09-18 Ulrich Drepper <drepper@cygnus.com>
1280
1281 * pthread.c (pthread_handle_sigrestart_rt): New function. Use
1282 this instead of pthread_handle_sigrestart if the signal is an RT
1283 signal.
1284
1285 * signals.c: Handle passing through of sighandler arguments also
1286 for real-time signals.
1287
4fe53b3a
UD
12881999-09-03 Andreas Schwab <schwab@suse.de>
1289
1290 * ptfork.c (__fork): Renamed from fork and use __libc_fork. Add
1291 fork as weak alias.
1292 (__vfork): New function, alias vfork.
1293 * Versions: Export __fork, vfork, and __vfork in libpthread.
1294
1d0b89a4
UD
12951999-08-23 Andreas Schwab <schwab@suse.de>
1296
1297 * signals.c (pthread_sighandler): Add SIGCONTEXT_EXTRA_ARGS to
1298 call to signal handler.
1299
6570e194
UD
13001999-08-20 Ulrich Drepper <drepper@cygnus.com>
1301
1302 * pthread.c (__pthread_reset_main_thread): Undo last change.
1303 (__pthread_kill_other_threads_np): Reset signal handlers for the
1304 signals we used in the thread implementation here.
1305
70aea399
UD
13061999-08-19 Ulrich Drepper <drepper@cygnus.com>
1307
2b638910 1308 * pthread.c (__pthread_reset_main_thread): Reset signal handlers
68ea6c18 1309 for the signals we used in the thread implementation [PR libc/1234].
2b638910 1310
264ec183
UD
1311 * Versions: Export __pthread_kill_other_threads_np from libpthread
1312 for GLIBC_2.1.2.
1313
70aea399
UD
1314 * signals.c: Pass sigcontext through wrapper to the user function.
1315
ff5fad16
UD
13161999-08-01 Ulrich Drepper <drepper@cygnus.com>
1317
1318 * Versions [ld.so] (GLIBC_2.0): Export __libc_internal_tsd_get and
1319 __libc_internal_tsd_set.
1320
6b798621
UD
13211999-07-29 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1322
1323 * manager.c: Remove inclusion of <linux/tasks.h> since it's not
1324 needed anymore.
1325
76a16b8f
UD
13261999-07-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1327
4bf307e3 1328 * internals.h: Align _pthread_descr_struct to 32 bytes.
76a16b8f
UD
1329 Reported by Tim Hockin <thockin@cobaltnet.com>, close PR
1330 libc/1206.
1331
5ef2d37b
UD
13321999-07-09 Ulrich Drepper <drepper@cygnus.com>
1333
1334 * oldsemaphore.c (sem_compare_and_swap): Fix use of compare and
1335 swap function.
1336
c2fa5b5a
UD
13371999-07-09 Cristian Gafton <gafton@redhat.com>
1338
1339 * Makefile (libpthread-routines): Add oldsemaphore routine.
ae3c1571
UD
1340 * Versions: Add sem_destroy, sem_getvalue, sem_init, sem_post,
1341 sem_trywait, and sem_wait to GLIBC_2.1.
c2fa5b5a
UD
1342 * oldsemaphore.c: New file.
1343 * semaphore.c: Add default_symbol_versions for the changed functions.
1344 (__new_sem_init): Rename from sem_init.
1345 (__new_sem_post): Rename from sem_post.
1346 (__new_sem_wait): Rename from sem_wait.
1347 (__new_sem_trywait): Rename from sem_trywait.
1348 (__new_sem_getvalue): Rename from sem_getvalue.
1349 (__new_sem_destroy): Rename from sem_destroy.
1350
6a1db4ff
UD
13511999-06-23 Robey Pointer <robey@netscape.com>
1352
1353 * internals.h: Added p_nextlock entry to separate queueing for a
1354 lock from queueing for a CV (sometimes a thread queues on a lock
1355 to serialize removing itself from a CV queue).
1356 * pthread.c: Added p_nextlock to initializers.
1357 * spinlock.c: Changed to use p_nextlock instead of p_nextwaiting.
1358
019e7a64
UD
13591999-07-09 Ulrich Drepper <drepper@cygnus.com>
1360
1361 * manager.c (pthread_handle_create): Free mmap region after stack
1362 if clone failed. Patch by Kaz Kylheku <kaz@ashi.FootPrints.net>.
1363
33d1a2c5
UD
13641999-05-23 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1365
1366 * man/pthread_cond_init.man: Correct example.
1367 Reported by Tomas Berndtsson <tomas@nocrew.org>.
1368
1369 * linuxthreads.texi (Condition Variables): Likewise.
1370
407d26b7
UD
13711999-05-18 Jakub Jelinek <jj@ultra.linux.cz>
1372
1373 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): Use
1374 casx not cas, also successful casx returns the old value in rd
1375 and not the new value.
1376
431c33c0
UD
13771999-05-16 Xavier Leroy <Xavier.Leroy@inria.fr>
1378
1379 * manager.c: If pthread_create() is given a NULL attribute
1380 and the thread manager runs with a realtime policy, set the
1381 scheduling policy of the newly created thread back to SCHED_OTHER.
1382 * manager.c: If the PTHREAD_INHERIT_SCHED attribute is given,
1383 initialize the schedpolicy field of new_thread->p_start_args
1384 to that of the calling thread.
1385
2c68584c
UD
13861999-04-29 Ulrich Drepper <drepper@cygnus.com>
1387
1388 * sysdeps/sparc/sparc64/pt-machine.h (__compare_and_swap): cas
1389 instruction does not allow memory element to use offset.
1390
390500b1
UD
13911999-04-28 Ulrich Drepper <drepper@cygnus.com>
1392
1393 * manager.c (pthread_allocate_stack): Optimize initialization of new
1394 thread descriptor.
1395
89afc233
UD
1396 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_define_initialized):
1397 Don't use initializer since it is all zeroes.
1398 (__libc_once_define): Likewise.
1399
1e76ce9c
UD
14001999-04-16 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1401
1402 * sysdeps/arm/Implies: Removed since cmpxchg/no-cmpxchg
1403 doesn't exist anymore.
1404 * sysdeps/i386/Implies: Likewise.
1405 * sysdeps/m68k/Implies: Likewise.
1406 * sysdeps/mips/Implies: Likewise.
1407 * sysdeps/powerpc/Implies: Likewise.
1408 * sysdeps/sparc/sparc32/Implies: Likewise.
1409 * sysdeps/sparc/sparc64/Implies: Likewise.
1410
46a4682d
UD
14111999-04-15 Ulrich Drepper <drepper@cygnus.com>
1412
1413 * sysdeps/alpha/bits/semaphore.h: Removed.
1414 * sysdeps/powerpc/bits/semaphore.h: Removed.
1415 * sysdeps/pthread/cmpxchg/bits/semaphore.h: Removed.
1416 * sysdeps/pthread/no-cmpxchg/bits/semaphore.h: Removed.
1417 * Makefile (headers): Remove bits/semaphore.h.
1418
1419 * semaphore.h: Define _pthread_descr if necessary.
1420 Don't include limits.h. Define SEM_VALUE_MAX directly.
1421 Define SEM_FAILED.
1422 (sem_t): Protect element names with leading __.
1423 Add declarations for sem_close, sem_open, and sem_unlink.
1424 * semaphore.c: Adjust all functions for new element names.
1425 Define sem_close, sem_open, and sem_unlink.
1426 * Versions (libthread): Add sem_close, sem_open, and sem_unlink for
1427 GLIBC_2.1.1.
1428 * sysdeps/pthread/bits/pthreadtypes.h: Define _pthread_descr only if
1429 necessary.
1430
ea48e2c4
UD
14311999-03-16 H.J. Lu <hjl@gnu.org>
1432
1433 * specific.c (pthread_key_delete): Check th->p_terminated to see
1434 if the thread is running.
1435
670af0d9
UD
1436 * Versions (__libc_internal_tsd_get, __libc_internal_tsd_set):
1437 Added to GLIBC_2.0 for libc.so.
1438
0543cd26
UD
14391999-02-12 H.J. Lu <hjl@gnu.org>
1440
1441 * Versions (__libc_current_sigrtmin, __libc_current_sigrtmax,
1442 __libc_allocate_rtsig): Added to GLIBC_2.1.
1443
1444 * internals.h (DEFAULT_SIG_RESTART): Removed.
1445 (DEFAULT_SIG_CANCEL): Removed.
1446
1447 * pthread.c (init_rtsigs, __libc_current_sigrtmin,
1448 __libc_current_sigrtmax, __libc_allocate_rtsig): New functions.
1449 (__pthread_sig_restart, __pthread_sig_cancel,
1450 __pthread_sig_debug): Initialized.
1451 (pthread_initialize): Call init_rtsigs () to initialize
1452 real-time signals.
1453
f5492334
UD
14541999-02-03 H.J. Lu <hjl@gnu.org>
1455
1456 * manager.c (__pthread_manager): Do block __pthread_sig_debug.
1457 Don't restart the thread which sent REQ_DEBUG.
1458 (pthread_start_thread): Check if __pthread_sig_debug > 0
1459 before debugging.
1460
1461 * pthread.c (__pthread_initialize_manager): Suspend ourself
1462 after sending __pthread_sig_debug to gdb instead of
1463 __pthread_sig_cancel.
1464
8f0302ee
UD
14651999-01-24 H.J. Lu <hjl@gnu.org>
1466
1467 * manager.c (__pthread_manager): Delete __pthread_sig_debug
1468 from mask if __pthread_sig_debug > 0.
1469 (pthread_handle_create): Increment __pthread_handles_num.
1470
1471 * manager.c (pthread_handle_create): Don't pass CLONE_PTRACE to clone.
1472 * pthread.c (__pthread_initialize_manager): Likewise.
1473
1474 * pthread.c (pthread_initialize): Use __libc_allocate_rtsig (1)
1475 instead of __libc_allocate_rtsig (2).
1476 (__pthread_initialize_manager): Send __pthread_sig_debug to gdb
1477 instead of __pthread_sig_cancel.
1478 (pthread_handle_sigdebug): Fix comments.
1479
82df2969
UD
14801999-01-21 Ulrich Drepper <drepper@cygnus.com>
1481
1482 * manager.c (pthread_allocate_stack): Set
1483 __pthread_nonstandard_stacks if user-specified stack is used.
1484
482eec0d
UD
14851999-01-16 Ulrich Drepper <drepper@cygnus.com>
1486
1487 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Add _LFS_ASYNCHRONOUS_IO,
1488 _LFS_LARGEFILE, _LFS64_LARGEFILE, and _LFS64_STDIO from Unix98.
1489
b92ad8d6
UD
14901999-01-07 Xavier Leroy <Xavier.Leroy@inria.fr>
1491
1492 * pthread.c: Use a third signal __pthread_sig_debug distinct
1493 from __pthread_sig_cancel to notify gdb when a thread is
1494 created
1495 * manager.c: Likewise.
1496 * internals.h: Likewise.
1497 * signals.c: The implementation of sigwait(s) assumed that
1498 all signals in s have signal handlers already attached.
1499 This is not required by the standard, so make it work
1500 also if some of the signals have no handlers.
1501
34992338
UD
15021999-01-05 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
1503
1504 * linuxthreads.texi: Remove pointers from first @node. Move old
1505 @node spec inside comment.
1506
118bad87
UD
15071998-12-31 Ulrich Drepper <drepper@cygnus.com>
1508
1509 * sysdeps/pthread/bits/stdio-lock.h: Define _IO_lock_lock and
1510 _IO_lock_unlock.
1511
c046e7a5
UD
15121998-12-29 Ulrich Drepper <drepper@cygnus.com>
1513
1514 * semaphore.c (sem_trywait): Don't forget to unlock the semaphore
1515 lock. Patch by Bernd Schmidt <crux@pool.informatik.rwth-aachen.de>.
1516
361d49e6
UD
15171998-12-21 Ulrich Drepper <drepper@cygnus.com>
1518
1519 * manager.c: Threads now send __pthread_sig_cancel on termination.
1520 Change clone call and signal masks.
1521 * thread.c (pthread_handle_sigrestart): Remove special code for
1522 manager.
1523 (pthread_handle_sigcancel): In manager thread call
1524 __pthread_manager_sighandler.
1525 * sysdeps/i386/pt-machine.h (__compare_and_swap): Add memory clobber.
1526 * sysdeps/i386/i686/pt-machine.h: Likewise.
1527 Patches by Xavier Leroy.
1528
4260bc74
UD
15291998-12-14 Ulrich Drepper <drepper@cygnus.com>
1530
361d49e6 1531 * spinlock.c (__pthread_unlock): Don't crash if called for an
fbaf6e72
UD
1532 untaken mutex. Reported by Ruslan V. Brushkoff <rus@Snif.Te.Net.UA>.
1533
4260bc74
UD
1534 * Examples/ex6.c: Unbuffer stdout and reduce sleep time to reduce
1535 overall runtime.
1536
e3743e2f
UD
15371998-12-13 Ulrich Drepper <drepper@cygnus.com>
1538
1539 * Examples/ex3.c: Wait until all threads are started before
1540 searching for the number to avoid race condition on very fast
1541 systems.
1542
8632b240
UD
15431998-12-08 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1544
1545 * sysdeps/pthread/pthread.h: Remove __pthread_setcanceltype
2eda5d9b 1546 declaration since it's not needed.
8632b240
UD
1547
1548 * sysdeps/pthread/pthread.h: Move internal functions to ...
1549 * internals.h: ...here.
1550
a6ff34d7
UD
15511998-12-02 H.J. Lu <hjl@gnu.org>
1552
1553 * pthread.c (__pthread_sig_restart): Initiliaze to 0 if
1554 SIGRTMIN is defined.
1555 (__pthread_sig_cancel): Likewise.
1556
628a0aa1
UD
15571998-12-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1558
1559 * wrapsyscall.c: Include <sys/mman.h> for msync,
1560 <stdlib.h> for system and <termios.h> for tcdrain prototype.
1561 Correct msync declaration.
1562
348ed515
UD
15631998-11-29 Roland McGrath <roland@baalperazim.frob.com>
1564
1565 * sysdeps/pthread/bits/libc-tsd.h (__libc_tsd_define, __libc_tsd_get,
1566 __libc_tsd_set): New macros for new interface.
1567 * no-tsd.c: New file, provide uninitialized defns of
1568 __libc_internal_tsd_get and __libc_internal_tsd_set.
1569 * Makefile (routines): Add no-tsd.
1570
15711998-10-12 Roland McGrath <roland@baalperazim.frob.com>
1572
1573 * internals.h: Include <bits/libc-tsd.h>, not <bits/libc-lock.h>.
1574 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
1575 __libc_internal_tsd_set): Move decls to ...
1576 * sysdeps/pthread/bits/libc-tsd.h: New file for __libc_internal_tsd_*
1577 declarations.
1578
1579 * sysdeps/pthread/bits/libc-lock.h (__libc_internal_tsd_get,
1580 __libc_internal_tsd_set): Make these pointers to functions, not
1581 functions; remove #pragma weak decls for them.
1582 * specific.c (__libc_internal_tsd_get, __libc_internal_tsd_set):
1583 Define static functions and initialized pointers to them.
1584
97dac76c
UD
15851998-11-18 Ulrich Drepper <drepper@cygnus.com>
1586
1587 * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES.
1588 (CFLAGS-specific.c): Likewise.
1589 (CFLAGS-pthread.c): Likewise.
1590 (CFLAGS-ptfork.c): Likewise.
1591 (CFLAGS-cancel.c): Likewise.
1592 * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions
1593 as weak references if __NO_WEAK_PTHREAD_ALIASES is defined.
1594
1595 * mutex.c (pthread_mutex_init): Define as strong symbol.
1596 (pthread_mutex_destroy): Likewise.
1597 (pthread_mutex_trylock): Likewise.
1598 (pthread_mutex_lock): Likewise.
1599 (pthread_mutex_unlock): Likewise.
1600 (pthread_mutexattr_init): Likewise.
1601 (pthread_mutexattr_destroy): Likewise.
1602 (pthread_once): Likewise.
1603 * ptfork.c (pthread_atfork): Likewise.
1604 * specific.c (pthread_key_create): Likewise.
1605 (pthread_setspecific): Likewise.
1606 (pthread_getspecific): Likewise.
1607
8b7fb588
UD
16081998-11-15 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
1609
1610 * linuxthreads.texi: Fix punctuation after xref.
1611
d2537a47
UD
16121998-11-10 H.J. Lu <hjl@gnu.org>
1613
1614 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine NR_OPEN
1615 if it is defined in <linux/limits.h>.
1616
d5cabaa4
UD
16171998-10-29 14:28 Ulrich Drepper <drepper@cygnus.com>
1618
1619 * spinlock.h (__pthread_trylock): Define inline.
1620 (__pthread_lock): Add extra parameter to declaration. Declare
1621 using internal_function.
1622 (__pthread_unlock): Declare using internal_function.
1623 * spinlock.c (__pthread_lock): Add new parameter. Use it instead
1624 of local variable self. Avoid recomputing self. Define using
1625 internal_function.
1626 (__pthread_trylock): Remove.
1627 (__pthread_unlock): Define using internal_function.
1628 * cancel.c: Adjust for __pthread_lock interface change. Use already
1629 computed self value is possible.
1630 * condvar.c: Likewise.
1631 * join.c: Likewise.
1632 * manager.c: Likewise.
1633 * mutex.c: Likewise.
1634 * pthread.c: Likewise.
1635 * rwlock.c: Likewise.
1636 * semaphore.c: Likewise.
1637 * signals.c: Likewise.
1638
c70ca1fa
UD
16391998-10-27 13:46 Ulrich Drepper <drepper@cygnus.com>
1640
1641 * sysdeps/pthread/pthread.h (struct _pthread_cleanup_buffer): Prepend
1642 __ to field names of the struct.
1643 * sysdeps/pthread/bits/pthreadtypes.h (struct _pthread_fastlock):
1644 Likewise.
1645 (pthread_attr_t): Likewise.
1646 (pthread_cond_t): Likewise.
1647 (pthread_condattr_t): Likewise.
1648 (pthread_mutex_t): Likewise.
1649 (pthread_mutexattr_t): Likewise.
1650 (pthread_rwlock_t): Likewise.
1651 (pthread_rwlockattr_t): Likewise.
1652 * attr.c: Adjust for pthread.h and pthreadtypes.h change.
1653 * cancel.c: Likewise.
1654 * condvar.c: Likewise.
1655 * manager.c: Likewise.
1656 * mutex.c: Likewise.
1657 * pthread.c: Likewise.
1658 * ptlongjmp.c: Likewise.
1659 * rwlock.c: Likewise.
1660 * spinlock.c: Likewise.
1661
a5d1d726
UD
16621998-10-09 Ulrich Drepper <drepper@cygnus.com>
1663
7ccc548b
UD
1664 * sysdeps/i386/pt-machine.h (get_eflags, set_eflags): Mark these
1665 also with PT_EI.
1666
a5d1d726
UD
1667 * sysdeps/i386/i686/pt-machine.h: Remove unused inline
1668 definitions.
1669
9a29bc37
UD
1670 * Makefile (libpthread-routines): Add pt-machine.
1671 * pt-machine.c: New file.
1672 * sysdeps/alpha/pt-machine.h: Define PT_EI as extern inline is not
1673 yet defined. Use PT_EI in extern inline definitions.
1674 * sysdeps/arm/pt-machine.h: Likewise.
1675 * sysdeps/i386/pt-machine.h: Likewise.
1676 * sysdeps/i386/i686/pt-machine.h: Likewise.
1677 * sysdeps/m68k/pt-machine.h: Likewise.
1678 * sysdeps/mips/pt-machine.h: Likewise.
1679 * sysdeps/powerpc/pt-machine.h: Likewise.
1680 * sysdeps/sparc/sparc32/pt-machine.h: Likewise.
1681 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
1682
c10bb795
UD
16831998-10-02 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1684
1685 * semaphore.h: Include <sys/types.h> so that _pthread_descr
1686 is declared.
1687
16881998-09-15 David S. Miller <davem@pierdol.cobaltmicro.com>
1689
1690 * sysdeps/sparc/sparc32/pt-machine.h (INIT_THREAD_SELF): Add nr
1691 argument.
1692 * sysdeps/sparc/sparc64/pt-machine.h (INIT_THREAD_SELF): Likewise.
1693
16941998-09-12 14:24 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
1695
1696 * linuxthreads/sysdeps/unix/sysv/linux/bits/sigthread.h: Add
1697 multiple inclusion guard.
1698
5e0889da
UD
16991998-09-02 11:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1700
1701 * signals.c (sigaction): Check that sig is less than NSIG to avoid
1702 array index overflow.
1703
6796bc80
UD
17041998-09-06 10:56 Ulrich Drepper <drepper@cygnus.com>
1705
1706 * sysdeps/pthread/semaphore.h: New file.
1707
be935610
UD
17081998-09-06 09:08 Ulrich Drepper <drepper@cygnus.com>
1709
1710 * sysdeps/pthread/bits/libc-lock.h (enum __libc_tsd_key_t): Add
1711 _LIBC_TSD_KEY_DL_ERROR.
1712
bfce746a
UD
17131998-08-31 Ulrich Drepper <drepper@cygnus.com>
1714
7afab53d 1715 * sysdeps/i386/i686/pt-machine.h (testandset): Add memory clobber.
6a805a0b 1716 * sysdeps/i386/pt-machine.h: Likewise.
bfce746a
UD
1717 Suggested by Roland McGrath.
1718
75311719
UD
17191998-08-28 13:58 Ulrich Drepper <drepper@cygnus.com>
1720
1721 * internals.h: Also define THREAD_GETMEM_NC and THREAD_SETMEM_NC to
1722 access thread data with non-constant offsets.
1723 * specific.c: Use THREAD_GETMEM_NC and THREAD_SETMEM_NC where
1724 necessary.
1725
1726 * sysdeps/i386/useldt.h: Fix typo. Add THREAD_GETMEM_NC and
1727 THREAD_SETMEM_NC definitions.
1728
1729 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM_NC and
1730 THREAD_SETMEM_NC.
1731 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
1732
00a2f9aa
UD
17331998-08-26 15:46 Ulrich Drepper <drepper@cygnus.com>
1734
1735 * internals.h: Define THREAD_GETMEM and THREAD_SETMEM to default if
1736 not already defined.
1737 (struct _pthread_descr_struct): Add p_self and p_nr field.
1738 * manager.c (__pthread_handles): Define second element to point
1739 to manager thread.
1740 (__pthread_handles_num): Initialize to 2.
1741 (__pthread_manager): Use INIT_THREAD_SELF with two arguments.
1742 (pthread_start_thread): Likewise.
1743 (pthread_handle_create): Start search for free slot at entry 2.
1744 Initialize new fields p_self and p_nr.
1745 Call __clone with CLONE_PTRACE if available.
1746 (pthread_free): Call FREE_THREAD_SELF if available.
1747 * pthread.c (__pthread_initial_thread): Initialize new fields.
1748 (__pthread_manager_thread): Likewise.
1749 (__pthread_initialize_manager): Call __clone with CLONE_PTRACE.
1750
1751 * cancel.c: Use THREAD_GETMEM and THREAD_SETMEM to access the
1752 elements of the thread descriptor.
1753 * condvar.c: Likewise.
1754 * errno.c: Likewise.
1755 * join.c: Likewise.
1756 * manager.c: Likewise.
1757 * pthread.c: Likewise.
1758 * ptlongjmp.c: Likewise.
1759 * semaphore.c: Likewise.
1760 * signals.c: Likewise.
1761 * specific.c: Likewise.
1762 * spinlock.c: Likewise.
1763
1764 * sysdeps/alpha/pt-machine.h (INIT_THREAD_SELF): Add extra parameter.
1765
1766 * sysdeps/i386/useldt.h: New file.
1767 * sysdeps/i386/i686/pt-machine.h: Show how to use this file.
1768
1769 * sysdeps/sparc/sparc32/pt-machine.h: Define THREAD_GETMEM and
1770 THREAD_SETMEM using __thread_self.
1771 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
1772
ed1ac6a2
UD
17731998-08-24 Geoff Keating <geoffk@ozemail.com.au>
1774
1775 * spinlock.c (__pthread_lock): Reset p_nextwaiting to NULL if it
1776 turned out that we didn't need to queue after all.
1777
17781998-08-22 Geoff Keating <geoffk@ozemail.com.au>
1779
1780 * sysdeps/powerpc/pt-machine.h: Remove testandset, it's not used
1781 and wastes space; correct types.
1782
cf0fd016
UD
17831998-08-08 11:18 H.J. Lu <hjl@gnu.org>
1784
1785 * signals.c (sigaction): Handle NULL argument.
1786
d358336f
UD
17871998-08-04 Ulrich Drepper <drepper@cygnus.com>
1788
1789 * sysdeps/unix/sysv/linux/bits/sigthread.h: Use __sigset_t instead
1790 of sigset_t.
1791
7cabd57c
UD
17921998-08-02 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1793
1794 * Makefile (linuxthreads-version): Extract correct number from
1795 Banner.
1796
ddbf7fef
UD
17971998-07-29 Xavier Leroy <Xavier.Leroy@inria.fr>
1798
1799 * Banner: Bump version number to 0.8
1800 * FAQ.html: Many updates, in particular w.r.t. debugging.
1801 * manager.c: Support for non-default stacksize for
1802 LinuxThreads-allocated stacks;
1803 don't use guard pages for stacks with default size, rely on
1804 rlimit(RLIMIT_STACK) instead (it's cheaper).
1805 * attr.c: Likewise.
1806 * cancel.c: Use __pthread_sig_cancel and __pthread_sig_restart
1807 everywhere instead of PTHREAD_SIG_CANCEL and PTHREAD_SIG_RESTART.
1808 * condvar.c: Likewise.
1809 * internals.h: Likewise.
1810 * restart.h: Likewise.
1811 * signals.c: Likewise.
1812 * pthread.c: Likewise; set rlimit(RLIMIT_STACK) as we need it.
1813
6c202c68
UD
18141998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1815
1816 * weaks.c: Define pthread_mutexattr_[sg]ettype instead of
1817 __pthread_mutexattr_[sg]ettype. Add more weak aliases.
1818 * Versions: Put __pthread_mutexattr_settype under version
1819 GLIBC_2.0. Don't export __pthread_mutexattr_setkind_np and
1820 __pthread_mutexattr_gettype.
1821
18221998-07-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1823
1824 * sysdeps/pthread/bits/libc-lock.h: Make
1825 __pthread_mutexattr_settype weak. Don't make
1826 __pthread_mutexattr_setkind_np weak.
1827
50304ef0
UD
18281998-07-16 10:52 Ulrich Drepper <drepper@cygnus.com>
1829
1830 * manager.c (pthread_handle_create): Check whether sched_setscheduler
1831 call can succeed here.
1832
1833 * mutex.c: Define __pthread_mutexattr_settype and make
1834 __pthread_mutexattr_setkind_np an alias.
1835 Likewise for __pthread_mutexattr_gettype.
1836
18371998-07-15 11:00 -0400 Zack Weinberg <zack@rabi.phys.columbia.edu>
1838
1839 * attr.c (pthread_attr_setschedpolicy): Don't check whether caller
1840 is root.
1841
c764b9a7
UD
18421998-07-14 19:38 Ulrich Drepper <drepper@cygnus.com>
1843
1844 * sysdeps/pthread/bits/libc-lock.h: Define __libc_cleanup_end.
1845
ceb27555
UD
18461998-07-11 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1847
1848 * Examples/ex6.c: Include <unistd.h> for usleep.
1849
b1209f90
UD
18501998-06-13 11:04 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1851
1852 * Examples/ex4.c (main): Use exit, not pthread_exit.
1853
6077fe6e
UD
18541998-07-09 13:39 Ulrich Drepper <drepper@cygnus.com>
1855
1856 * Versions: Add __pthread_mutexattr_gettype and
1857 __pthread_mutexattr_settype.
1858 * lockfile.c: Use __pthread_mutexattr_settype instead of
1859 __pthread_mutexattr_setkind_np.
1860 * mutex.c: Define __pthread_mutexattr_gettype and
1861 __pthread_mutexattr_settype.
1862 * weak.c: Likewise.
e918a7fe
UD
1863 * sysdeps/pthread/pthread.h: Declare __pthread_mutexattr_gettype and
1864 __pthread_mutexattr_settype.
1865 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_init_recursive):
1866 Use __pthread_mutexattr_settype.
6077fe6e 1867
4bae5567
UD
18681998-07-08 22:26 Ulrich Drepper <drepper@cygnus.com>
1869
1870 * Versions: Add pthread_mutexattr_gettype, pthread_mutexattr_settype.
1871 * mutex.c: Define weak alias pthread_mutexattr_gettype and
1872 pthread_mutexattr_settype.
1873 * sysdeps/pthread/pthread.h: Declare these functions.
1874 Move pthread_sigmask and pthread_kill declaration in separate header.
1875 * sysdeps/unix/sysv/linux/bits/sigthread.h: New file.
1876
0302fece
UD
18771998-07-07 15:20 Ulrich Drepper <drepper@cygnus.com>
1878
1879 * Makefile: Add rules to compile and run tests.
1880 * Examples/ex1.c: Little changes to fix warnings.
1881 * Examples/ex2.c: Likewise.
1882 * Examples/ex3.c: Likewise.
1883 * Examples/ex4.c: Likewise.
1884 * Examples/ex5.c: Likewise.
1885 * Examples/ex6.c: New file.
1886
77ccaba1
UD
18871998-07-05 11:54 Ulrich Drepper <drepper@cygnus.com>
1888
6777b467 1889 * Versions: Add pthread_attr_init to GLIBC_2.1 version in libc.
77ccaba1 1890
ba9234d9
UD
18911998-07-01 Andreas Jaeger <aj@arthur.rhein-neckar.de>
1892
1893 * attr.c: Include <string.h>.
1894
d64fae6a
UD
18951998-06-30 11:47 Ulrich Drepper <drepper@cygnus.com>
1896
1897 * attr.c: Include errno.h. Use memcpy to copy sched_param.
1898 * internals.h: Include limits.h.
1899 * manager.c: Use memcpy to copy sched_param.
1900 * ptfork.c: Include errno.h.
1901 * pthread.c: Likewise.
1902 * semaphore.c: Likewise.
1903 * specific.c: Likewise.
1904 * spinlock.h: Likewise.
1905 * sysdeps/pthread/pthread.h: Include only allowed headers. Move
1906 type definition to ...
1907 * sysdeps/pthread/bits/pthreadtypes.h: ...here. New file.
1908
fdacb17d
UD
19091998-06-29 12:34 Ulrich Drepper <drepper@cygnus.com>
1910
1911 * sysdeps/pthread/pthread.h: Use __PMT not __P for function pointers.
1912
1913 * sysdeps/pthread/pthread.h: Define various PTHREAD_* symbols also
1914 as macros as demanded in POSIX.1, Annex C.
1915
19161998-06-29 12:29 Ulrich Drepper <drepper@cygnus.com>
1917
1918 * internals.h (struct pthread_request): For free use pthread_t
1919 instead of pthread_descr.
1920 * join.c (pthread_join): Pass thread_id, not th to manager.
1921 (pthread_detach): Likewise.
1922 * manager.c (__pthread_manager): Except thread ID in FREE_REQ case.
1923 (pthread_exited): Remove detached queue code.
1924 (pthread_handle_free): Expect thread ID parameter and use it to
1925 validate the thread decsriptor. Don't use detached queue.
1926 Patches by Xavier Leroy.
1927
19281998-06-27 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
1929
1930 * libpthread.map: Export accept, longjmp, sigaction, siglongjmp,
1931 _IO_flockfile, _IO_ftrylockfile, _IO_funlockfile,
1932 __pthread_atfork, __pthread_key_create, __pthread_once.
1933 * internals.h: Doc fix.
1934 * pthread.c (__pthread_initialize): Define again.
1935
e138a800
UD
19361998-06-26 Ulrich Drepper <drepper@cygnus.com>
1937
026d5011
UD
1938 * manager.c (pthread_exited): If thread is not detached put it on
1939 special list.
1940 (pthread_handle_free): If thread is not on list with living threads
1941 search on list with detached threads.
1942
b195f6bc
UD
1943 * sysdeps/pthread/pthread.h (PTHREAD_RWLOCK_INITIALIZER): Correct
1944 for new definition of pthread_rwlock_t.
1945
e138a800
UD
1946 * spinlock.c: Correct test whether to compile
1947 __pthread_compare_and_swap or not.
1948
3387a425
UD
19491998-06-25 19:27 Ulrich Drepper <drepper@cygnus.com>
1950
1951 * attr.c: Finish user stack support. Change locking code to be safe
1952 in situations with different priorities.
1953 * cancel.c: Likewise.
1954 * condvar.c: Likewise.
1955 * internals.h: Likewise.
1956 * join.c: Likewise.
1957 * manager.c: Likewise.
1958 * mutex.c: Likewise.
1959 * pthread.c: Likewise.
1960 * ptlongjmp.c: Likewise.
1961 * queue.h: Likewise.
1962 * rwlock.c: Likewise.
1963 * semaphore.c: Likewise.
1964 * semaphore.h: Likewise.
1965 * signals.c: Likewise.
1966 * spinlock.c: Likewise.
1967 * spinlock.h: Likewise.
75c3a84f 1968 * sysdeps/pthread/pthread.h: Likewise.
df4099e8 1969 Patches by Xavier Leroy.
3387a425 1970
0ca7e46e 1971 * sysdeps/i386/i686/pt-machine.h: New file.
75c3a84f 1972
3387a425
UD
19731998-06-25 Ulrich Drepper <drepper@cygnus.com>
1974
1975 * sysdeps/pthread/pthread.h: Make [sg]et_stacksize and
1976 [sg]et_stackaddr prototypes always available.
1977
1978 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1979 _POSIX_THREAD_ATTR_STACKSIZE and _POSIX_THREAD_ATTR_STACKADDR.
1980
d47aac39
UD
19811998-06-24 Ulrich Drepper <drepper@cygnus.com>
1982
1983 * manager.c (pthread_free): Undo patch from 980430.
1984 Reported by David Wragg <dpw@doc.ic.ac.uk>.
1985
69f234e8
UD
19861998-06-09 15:07 Ulrich Drepper <drepper@cygnus.com>
1987
1988 * manager.c: Define __pthread_manager_adjust_prio and use it to
1989 increase priority when needed.
1990 * internals.h: Add prototype for __pthread_manager_adjust_prio.
1991 * mutex.c: Optimize mutexes to wake up only one thread.
768cbca8 1992 * pthread.c: Move PID of manager for global variable in structure
69f234e8
UD
1993 element.
1994 Patches by Xavier Leroy.
1995
c0fb8a56
UD
19961998-06-07 13:47 Ulrich Drepper <drepper@cygnus.com>
1997
1998 * sysdeps/pthread/bits/libc-lock.h: Optimize cleanup handlers a bit.
1999
c6bd526f
UD
20001998-06-03 Andreas Jaeger <aj@arthur.rhein-neckar.de>
2001
2002 * attr.c: Correct typo.
2003
f9119f49
UD
20041998-05-01 Ulrich Drepper <drepper@cygnus.com>
2005
2006 * manager.c (pthread_free): Unmap guard before the stack.
2007 Patch by Matthias Urlichs.
2008
3dd2c3e2
UD
20091998-04-30 Ulrich Drepper <drepper@cygnus.com>
2010
2011 * manager.c (pthread_free): Detect already free child.
2012 Patch by Xavier Leroy, reported by Matthias Urlichs.
2013
0111b224
UD
20141998-04-23 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2015
2016 * Makefile (linuxthreads-version): Renamed back from
2017 libpthread-version.
2018
f12944ec
UD
20191998-04-21 Ulrich Drepper <drepper@cygnus.com>
2020
26e119f1 2021 * ptlongjmp.c: Add prototypes for __libc_siglongjmp and
f12944ec
UD
2022 __libc_longjmp.
2023
8619129f
UD
20241998-04-20 14:55 Ulrich Drepper <drepper@cygnus.com>
2025
2026 * Makefile (libpthread-routines): Add ptlongjmp and spinlock.
2027 * internals.h: Add definitions for new spinlock implementation.
2028 * ptlongjmp.c: New file.
2029 * spinlock.c: New file.
2030 * spinlock.h (acquire): Don't reschedule using __sched_yield, use
2031 new function __pthread_acquire to prevent deadlocks with thread
2032 with different priorities.
2033 Patches by Xavier Leroy <Xavier.Leroy@inria.fr>.
2034
52cda958
UD
20351998-03-16 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2036
2037 * manager.c (__pthread_manager): Reduce first argument to select
2038 to include just the needed file descriptor.
2039
48fc3dd2
UD
20401998-03-17 00:06 Ulrich Drepper <drepper@cygnus.com>
2041
2042 * manager.c: Fix last patch which caused core dumps.
2043
2044 * pthread.c: Correctly handle missing SIGRTMIN.
2045
f649c201
UD
20461998-03-15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2047
2048 * libpthread.map: Add __libc_internal_tsd_get and
2049 __libc_internal_tsd_set. Add missing cancelable functions. Export
2050 libc internal versions of the cancelable functions.
2051
14c44e2e
UD
20521998-03-13 16:51 Ulrich Drepper <drepper@cygnus.com>
2053
2054 * weaks.c: Define pthread_attr_init as GLIBC_2.0 and GLIBC_2.1.
2055
5d409851
UD
20561998-03-13 00:46 Ulrich Drepper <drepper@cygnus.com>
2057
2058 * attr.c: Implement pthread_attr_[gs]etguardsize,
2059 pthread_attr_[gs]setstackaddr, pthread_attr_[gs]etstacksize.
2060 Change pthread_attr_init to have two interfaces.
2061 * internals.h (struct _pthread_descr_struct): Add new fields for
2062 above functions.
2063 * libpthread.map: Add names in GLIBC_2.1 section.
2064 * manager.c (pthread_handle_create): Implement guardsize and
2065 user stack.
2066 (pthread_free): Likewise.
2067 * pthread.c (pthread_create): Add new interface for changed
2068 pthread_attr_t.
2069 * sysdeps/pthread/pthread.h: Add prototypes for new functions.
2070 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add definition of
2071 PTHREAD_STACK_MIN.
2072
5afdca00
UD
20731998-03-11 00:42 Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>
2074
5d409851
UD
2075 * manager.c: Enable resetting of the thread scheduling policy
2076 to SCHED_OTHER when the parent thread has a different one.
5afdca00
UD
2077
20781998-02-01 13:51 Ulrich Drepper <drepper@cygnus.com>
2079
2080 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
2081 _POSIX_ASYNCHRONOUS_IO.
2082
2083 * sysdeps/pthread/pthread.h: Define bits for Unix98 variants of
2084 mutexes.
2085 * mutex.c: Implement new mutex types.
2086
2087 * internals.h: Include <signal.h>.
2088
2089 * libpthread.map: Add __erno_location and __h_errno_location.
2090
2091 * errno.c: Return pointer to variable actually in use. This might
2092 not be the one in the thread structure.
2093 * internals.h (struct _pthread_descr_struct): Add new fields p_errnop
2094 and p_h_errnop.
2095 * manager.c (__pthread_manager): Set p_errnop and p_h_errnop member
2096 of manager thread structure.
2097 (pthread_handle_create): Set p_errnop and p_h_errnop members for new
2098 thread.
2099 * pthread.c: Adapt initializer for thread structures.
2100 (__pthread_initial_thread): Set p_errnop and p_h_errnop member.
2101 (__pthread_reset_main_thread): Reset p_errnop and p_h_errnop of
2102 current thread to global variables.
2103
21041998-01-31 17:27 Ulrich Drepper <drepper@cygnus.com>
2105
2106 * rwlock.c: New file.
2107 * Makefile (libpthread-routines): Add rwlock.
2108 * sysdeps/pthread/pthread.h: Define data structures and declare
2109 functions.
2110 * libpthread.map: Add new functions.
2111
21121997-12-18 13:50 Philip Blundell <pb@nexus.co.uk>
2113
2114 * sysdeps/arm/pt-machine.h: New file; add ARM support.
2115 * sysdeps/arm/Implies: likewise.
2116 * README: Document it.
2117
21181997-12-13 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2119
2120 * signals.c: Remove unneeded initializer for sigwaited, saving a
2121 warning.
2122
21231997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2124
2125 * semaphore.c (sem_init): Set sem_spinlock only if available.
2126
21271997-12-04 01:48 Ulrich Drepper <drepper@cygnus.com>
2128
2129 * mutex.c: Implement PTHREAD_MUTEX_CHECKERROR.
2130 * sysdeps/pthread/pthread.h: Define PTHREAD_MUTEX_CHECKERROR.
2131
2132 * Makefile: Update from LinuxThreads 0.7.
2133 * internals.h. Likewise.
2134 * manager.c: Likewise.
2135 * mutex.c: Likewise.
2136 * pthread.c: Likewise.
2137 * signals.c: Likewise.
2138 * specific.c: Likewise.
2139 * Examples/ex3.c: Likewise.
2140
21411997-11-20 18:13 Ulrich Drepper <drepper@cygnus.com>
2142
2143 * pthread.c (__pthread_reset_main_thread): Close pipe only if still
2144 open.
2145
21461997-10-29 05:38 Ulrich Drepper <drepper@cygnus.com>
2147
2148 * wrapsyscall.c: Add socket functions which are also cancelation
2149 points.
2150
21511997-10-19 21:40 Wolfram Gloger <wg@wolfram.dent.med.uni-muenchen.de>
2152
2153 * specific.c (__libc_internal_tsd_set, __libc_internal_tsd_get):
2154 New functions for fast thread specific data within libc.
2155
2156 * internals.h: Add new array p_libc_specific to struct
2157 _pthread_descr_struct.
2158
2159 * sysdeps/pthread/bits/libc-lock.h: Declare new functions.
2160
21611997-10-13 05:39 Ulrich Drepper <drepper@cygnus.com>
2162
2163 * semaphore.h: Add __BEGIN_DECLS/__END_DECLS.
2164 Reported by Ralf Corsepius <corsepiu@faw.uni-ulm.de>.
2165
21661997-08-29 03:05 Ulrich Drepper <drepper@cygnus.com>
2167
2168 * internals.h (struct _pthread_descr_struct): Add definitions for
2169 two-level specific key handling.
2170 * manager.c (pthread_handle_create): Initialize specific memory array.
2171 * specific.c: Implement two-level key handling.
2172 * weaks.c: Don't provide dummy key handling.
2173 * sysdeps/pthread/bits/libc-lock.h: Typedef __libc_lock_t (no #define).
2174 Add definition of __libc_key_t.
2175 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define PTHREAD_KEYS_MAX
2176 as 1024.
2177 Add definition of _POSIX_THREAD_DESTRUCTOR_ITERATIONS and
2178 PTHREAD_DESTRUCTOR_ITERATIONS.
2179
2180 * manager.c (pthread_handle_create): Compare mmap result with
2181 MAP_FAILED.
2182
2183 * ptfork.c: Rename to __pthread_atfork and make old name a weak alias.
2184 * sysdeps/pthread/bits/pthread.h: Add prototype for __pthread_atfork.
2185
21861997-08-22 19:04 Richard Henderson <rth@cygnus.com>
2187
2188 sysdeps/sparc -> sysdeps/sparc/sparc32
2189 sysdeps/sparc64 -> sysdeps/sparc/sparc64
2190
2191 * internals.h: Change definition of THREAD_SELF to be an expression,
2192 not a statement that did a return.
2193 * sysdeps/alpha/pt-machine.h (THREAD_SELF): Update accordingly.
2194 * sysdeps/sparc/sparc32/pt-machine.h (THREAD_SELF, INIT_THREAD_SELF):
2195 Follow Solaris and use a "system reserved" register (%g6) to hold
2196 the thread descriptor.
2197 * sysdeps/sparc/sparc64/pt-machine.h: Likewise.
2198
21991997-08-03 00:09 Ulrich Drepper <drepper@cygnus.com>
2200
2201 * mutex.c: Correct pthread_once. Patch by Xavier Leroy.
2202 * sysdeps/pthread/pthread.h: Add prototype for __pthread_once.
2203 * sysdeps/pthread/bits/pthread.h: Add macros for __libc_once.
2204
2205 * semaphore.c: Include spinlock.h only when needed.
2206
2207 * specific.c (__pthread_setsepcific, __pthread_getspecific): Reject
2208 keys for entries not in use.
2209
2210 * weaks.c: Implement key handling functions for real.
2211
22121997-06-29 01:04 Richard Henderson <richard@gnu.ai.mit.edu>
2213
2214 Initial sparc64-linux support:
2215 * linuxthreads/sysdeps/sparc64/Implies: New file.
2216 * linuxthreads/sysdeps/sparc64/pt-machine.h: Likewise.
2217
22181997-06-29 00:48 Ulrich Drepper <drepper@cygnus.com>
2219
2220 * semaphore.c: Include spinlock.h at correct place.
2221 Patch by HJ Lu.
2222
22231997-06-13 10:06 Richard Henderson <rth@tamu.edu>
2224
2225 The Great Bit File Move:
2226 * sysdeps/alpha/semaphorebits.h: -> .../bits/semaphore.h.
2227 * sysdeps/powerpc/semaphorebits.h: Likewise.
2228 * sysdeps/pthread/cmpxchg/semaphorebits.h: Likewise.
2229 * sysdeps/pthread/no-cmpxchg/semaphorebits.h: Likewise.
2230 * sysdeps/pthread/libc-lock.h: -> bits/
2231 * sysdeps/pthread/stdio-lock.h: Likewise.
2232 * sysdeps/unix/sysv/linux/local_lim.h: Likewise.
2233 * sysdeps/unix/sysv/linux/posix_opt.h: Likewise.
2234 * semaphore.h: Likewise.
2235 * sysdeps/pthread/pthread.h: Likewise.
2236
2237 * lockfile.c: <foo.h> -> <bits/foo.h>.
2238 * semaphore.h: Likewise.
2239
2240 * Makefile: (headers): foo.h -> bits/foo.h.
2241 * sysdeps/pthread/Makefile: Likewise.
2242
22431997-04-11 01:18 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
2244
2245 * semaphore.c (sem_init): Set sem_spinlock only if available.
2246
2247 * sysdeps/m68k/pt-machine.h (testandset, __compare_and_swap): Fix
2248 asm constraints.
2249
22501997-04-09 03:00 Ulrich Drepper <drepper@cygnus.com>
2251
2252 Update from LinuxThreads 0.6.
2253
2254 * attr.c (pthread_attr_getdetachstate): Use __sched_get_priority_max
2255 and __sched_get_priority_min instead of names without `__'.
2256
2257 * manager.c: Rewrite large parts to implement opaque pthread_t.
2258
2259 * cancel.c: Adapt for opaque pthread_t type.
2260 * condvar.c: Likewise.
2261 * errno.c: Likewise.
2262 * join.c: Likewise.
2263 * mutex.c: Likewise.
2264 * pthread.c: Likewise.
2265 * signals.c: Likewise.
2266 * specific.c: Likewise.
2267 * restart.h: Likewise.
2268 * queue.h: Likewise.
2269 * Examples/ex3.c: Likewise.
2270 * Examples/ex4.c: Likewise.
2271 * sysdeps/pthread/pthread.h: Likewise.
2272
2273 * pthread.c: Accumulate time for all threads in thread manager.
2274
2275 * semaphore.c: Implement fallback implementation for architectures
2276 sometimes missing compare-exchange operations.
2277
2278 * cancel.c (pthread_cancel): Validate handle argument.
2279 * join.c (pthread_join): Likewise.
2280 (pthread_detach): Likewise.
2281 * signals.c (pthread_kill): Likewise.
2282
2283 * spinlock.h (acquire): Use __sched_yield not sched_yield.
2284
2285 * queue.h (enqueue): Enqueue thread according to priority.
2286
2287 * internals.c (struct pthread_start_args): New struct for passing
2288 args to cloning function.
2289 (struct _pthread): Rename to _pthread_descr_struct and adapt for
2290 opaque pthread_t.
2291
2292 * Examples/Makefile (clean): Pass -f option to rm.
2293
2294 * sysdeps/i386/pt-machine.h: Add check for compare-exchange instruction
2295 and define TEST_FOR_COMPARE_AND_SWAP.
2296 * sysdeps/i386/i486/pt-machine.h: Removed.
2297
2298 * sysdeps/unix/sysv/linux/local_lim.h (PTHREAD_THREADS_MAX): Increase
2299 to 1024.
2300
23011997-04-04 16:38 Ulrich Drepper <drepper@cygnus.com>
2302
2303 * restart.h (suspend): Clear p_signal before suspending.
2304 (suspend_with_cancellation): Likewise.
2305 Patch by Xavier Leroy <Xavier.Leroy@inria.fr>.
2306
2307 * weaks.c: Make __pthread_key_create return 1.
2308 * sysdeps/pthread/libc-lock.h: Define __libc_key_create,
2309 __libc_getspecific, __libc_setspecific, and __libc_key_t.
2310 * sysdeps/pthread/stdio-lock.h: Don't care for implementation not
2311 using libio.
2312
23131997-03-19 15:13 Miguel de Icaza <miguel@nuclecu.unam.mx>
2314
2315 * sysdeps/sparc/pt-machine (RELEASE): Fix.
2316
23171997-03-01 07:55 Geoff Keating <geoffk@ozemail.com.au>
2318
2319 * sysdeps/powerpc/Implies: Added.
2320 * sysdeps/powerpc/pt-machine.h: Added.
2321 * sysdeps/powerpc/semaphorebits.h: Added.
2322
23231997-01-22 01:22 Ulrich Drepper <drepper@cygnus.com>
2324
2325 * linuxtheads/pthread.c (__pthread_initial_thread): Correct
2326 initializer.
2327 (__pthread_manager_thread): Likewise.
2328 Reported by Andreas Jaeger.
2329
23301997-01-18 22:15 Richard Henderson <rth@tamu.edu>
2331
2332 Since sigset_t no longer fits in a register, we can't pass in the
2333 thread's initial mask so easily. Take this opportunity to simplify
2334 the clone implementation by only accepting a single void* argument.
2335
2336 * linuxthreads/manager.c (__pthread_manager): Put thread vitals
2337 in the thread struct instead of as arguments through clone.
2338 (pthread_start_thread): Look for them there.
2339 * linuxthreads/internals.h (struct _pthread): Add p_initial_fn,
2340 p_initial_fn_arg, p_initial_mask. Fix __pthread_manager proto.
2341 * linuxthreads/pthread.c (pthread_initialize_manager): Revise
2342 clone invocation.
This page took 0.346205 seconds and 5 git commands to generate.