.
[kopensolaris-gnu/glibc.git] / nptl / ChangeLog
1 2007-05-29  Ulrich Drepper  <drepper@redhat.com>
2
3         * pthread_getattr_np.c: No need to install a cancellation handler,
4         this is no cancellation point.
5         * pthread_getschedparam.c: Likewise.
6         * pthread_setschedparam.c: Likewise.
7         * pthread_setschedprio.c: Likewise.
8         * sysdeps/unix/sysv/linux/lowlevellock.c: Remove all traces of
9         lll_unlock_wake_cb.
10         * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
11         * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
12         * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
13         * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
14         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
15         * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
16         * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
17         * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
18         * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
19         * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c: Likewise.
20         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
21         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
22
23         * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Checking
24         whether there are more than one thread makes no sense here since
25         we only call the slow path if the locks are taken.
26         * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Likewise.
27
28         * sysdeps/unix/sysv/linux/internaltypes.h: Introduce
29         COND_NWAITERS_SHIFT.
30         * pthread_cond_destroy.c: Use COND_NWAITERS_SHIFT instead of
31         COND_CLOCK_BITS.
32         * pthread_cond_init.c: Likewise.
33         * pthread_cond_timedwait.c: Likewise.
34         * pthread_cond_wait.c: Likewise.
35         * pthread_condattr_getclock.c: Likewise.
36         * pthread_condattr_setclock.c: Likewise.
37         * sysdeps/unix/sysv/linux/lowlevelcond.sym: Likewise.
38         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
39         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
40         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
41         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
42
43 2007-05-28  Jakub Jelinek  <jakub@redhat.com>
44
45         * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstacksize.c: Include
46         unistd.h.
47
48         * sysdeps/i386/tls.h (THREAD_GSCOPE_RESET_FLAG): Use explicit
49         insn suffix.
50         (THREAD_GSCOPE_GET_FLAG): Remove.
51         * sysdeps/x86_64/tls.h (THREAD_GSCOPE_GET_FLAG): Remove.
52         * allocatestack.c (__wait_lookup_done): Revert 2007-05-24
53         changes.
54         * sysdeps/powerpc/tls.h (tcbhead_t): Remove gscope_flag.
55         (THREAD_GSCOPE_GET_FLAG): Remove.
56         (THREAD_GSCOPE_RESET_FLAG): Use THREAD_SELF->header.gscope_flag
57         instead of THREAD_GSCOPE_GET_FLAG.
58         (THREAD_GSCOPE_SET_FLAG): Likewise.  Add atomic_write_barrier after
59         it.
60         * sysdeps/s390/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
61         THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
62         THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
63         THREAD_GSCOPE_WAIT): Define.
64         * sysdeps/sparc/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
65         THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
66         THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
67         THREAD_GSCOPE_WAIT): Define.
68         * sysdeps/sh/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
69         THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
70         THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
71         THREAD_GSCOPE_WAIT): Define.
72         * sysdeps/ia64/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
73         THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
74         THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
75         THREAD_GSCOPE_WAIT): Define.
76
77 2007-05-24  Richard Henderson  <rth@redhat.com>
78
79         * descr.h (struct pthread): Add header.gscope_flag.
80         * sysdeps/alpha/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
81         THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
82         THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
83         THREAD_GSCOPE_WAIT): Define.
84
85 2007-05-27  Ulrich Drepper  <drepper@redhat.com>
86
87         * init.c: Make it compile with older kernel headers.
88
89         * tst-initializers1.c: Show through exit code which test failed.
90
91         * pthread_rwlock_init.c: Also initialize __shared field.
92         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Split __flags
93         element in rwlock structure into four byte elements.  One of them is
94         the new __shared element.
95         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h [__WORDSIZE=32]:
96         Likewise.
97         [__WORDSIZE=64]: Renamed __pad1 element int rwlock structure to
98         __shared, adjust names of other padding elements.
99         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
100         * sysdeps/pthread/pthread.h: Adjust rwlock initializers.
101         * sysdeps/unix/sysv/linux/lowlevelrwlock.sym: Add PSHARED.
102         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define
103         FUTEX_PRIVATE_FLAG.
104         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Change main
105         futex to use private operations if possible.
106         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
107         Likewise.
108         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
109         Likewise.
110         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Likewise.
111         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
112         * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
113         * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
114         Likewise.
115         * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
116         Likewise.
117         * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
118         * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
119
120 2007-05-26  Ulrich Drepper  <drepper@redhat.com>
121
122         * pthreadP.h (PTHREAD_RWLOCK_PREFER_READER_P): Define.
123         * pthread_rwlock_rdlock.c: Use PTHREAD_RWLOCK_PREFER_READER_P.
124         * pthread_rwlock_timedrdlock.c: Likewise.
125         * pthread_rwlock_tryrdlock.c: Likewise.
126
127         * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S (sem_trywait): Tiny
128         optimization.
129
130         * sysdeps/unix/sysv/linux/sem_wait.c: Add missing break.
131         * sysdeps/unix/sysv/linux/sem_timedwait.c: Removed left-over
132         duplication of __sem_wait_cleanup.
133
134         * allocatestack.c: Revert last change.
135         * init.c: Likewise.
136         * sysdeps/i386/tls.h: Likewise.
137         * sysdeps/x86_64/tls.h: Likewise.
138         * descr.h [TLS_DTV_AT_TP] (struct pthread): Add private_futex field to
139         header structure.
140         * sysdeps/powerpc/tcb-offsets.sym: Add PRIVATE_FUTEX_OFFSET.
141
142         * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_barrier):
143         Add private field.
144         * sysdeps/unix/sysv/linux/lowlevelbarrier.sym: Add PRIVATE definition.
145         * pthread_barrier_init.c: Set private flag if pshared and private
146         futexes are supported.
147         * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Use
148         private field in futex command setup.
149         * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise.
150
151 2007-05-25  Ulrich Drepper  <drepper@redhat.com>
152
153         * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Add private futex
154         support.
155         * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
156         * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
157         * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
158         * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
159         * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
160
161         * semaphoreP.h: Declare __old_sem_init and __old_sem_wait.
162         * sem_init.c (__new_sem_init): Rewrite to initialize all three
163         fields in the structure.
164         (__old_sem_init): New function.
165         * sem_open.c: Initialize all fields of the structure.
166         * sem_getvalue.c: Adjust for renamed element.
167         * sysdeps/unix/sysv/linux/Makefile [subdir=nptl]
168         (gen-as-const-headers): Add structsem.sym.
169         * sysdeps/unix/sysv/linux/structsem.sym: New file.
170         * sysdeps/unix/sysv/linux/internaltypes.h: Rename struct sem to
171         struct new_sem.  Add struct old_sem.
172         * sysdeps/unix/sysv/linux/sem_post.c: Wake only when there are waiters.
173         * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
174         * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
175         * sysdeps/unix/sysv/linux/sem_wait.c: Indicate that there are waiters.
176         * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
177         * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
178         * sysdeps/unix/sysv/linux/sem_timedwait.c: Likewise.
179         * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
180         * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
181         * Makefile (tests): Add tst-sem10, tst-sem11, tst-sem12.
182         * tst-sem10.c: New file.
183         * tst-sem11.c: New file.
184         * tst-sem12.c: New file.
185         * tst-typesizes.c: Test struct new_sem and struct old_sem instead
186         of struct sem.
187
188 2007-05-25  Ulrich Drepper  <drepper@redhat.com>
189             Jakub Jelinek  <jakub@redhat.com>
190
191         * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
192         Move __pthread_enable_asynccancel right before futex syscall.
193         * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
194         Likewise.
195
196 2007-05-24  Jakub Jelinek  <jakub@redhat.com>
197
198         * sysdeps/i386/tls.h (THREAD_SET_PRIVATE_FUTEX,
199         THREAD_COPY_PRIVATE_FUTEX): Define.
200         * sysdeps/x86_64/tls.h (THREAD_SET_PRIVATE_FUTEX,
201         THREAD_COPY_PRIVATE_FUTEX): Define.
202         * allocatestack.c (allocate_stack): Use THREAD_COPY_PRIVATE_FUTEX.
203         * init.c (__pthread_initialize_minimal_internal): Use
204         THREAD_SET_PRIVATE_FUTEX.
205
206         * sysdeps/powerpc/tls.h (tcbhead_t): Add gscope_flag.
207         (THREAD_GSCOPE_FLAG_UNUSED, THREAD_GSCOPE_FLAG_USED,
208         THREAD_GSCOPE_FLAG_WAIT): Define.
209         (THREAD_GSCOPE_GET_FLAG, THREAD_GSCOPE_SET_FLAG,
210         THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_WAIT): Define.
211         * sysdeps/i386/tls.h (THREAD_GSCOPE_WAIT): Don't use
212         PTR_DEMANGLE.
213         (THREAD_GSCOPE_GET_FLAG): Define.
214         * sysdeps/x86_64/tls.h (THREAD_GSCOPE_GET_FLAG): Define.
215         * allocatestack.c (__wait_lookup_done): Use THREAD_GSCOPE_GET_FLAG
216         instead of ->header.gscope_flag directly.
217
218 2007-05-23  Ulrich Drepper  <drepper@redhat.com>
219
220         * init.c (__pthread_initialize_minimal_internal): Check whether
221         private futexes are available.
222         * allocatestack.c (allocate_stack): Copy private_futex field from
223         current thread into the new stack.
224         * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Use private
225         futexes if they are available.
226         * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise
227         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Adjust so that change
228         in libc-lowlevellock.S allow using private futexes.
229         * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
230         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Define
231         FUTEX_PRIVATE_FLAG.
232         * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
233         * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Use private futexes
234         if they are available.
235         * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
236         * sysdeps/x86_64/tcb-offsets.sym: Add PRIVATE_FUTEX.
237         * sysdeps/i386/tcb-offsets.sym: Likewise.
238         * sysdeps/x86_64/tls.h (tcbhead_t): Add private_futex field.
239         * sysdeps/i386/tls.h (tcbhead_t): Likewise.
240
241 2007-05-21  Ulrich Drepper  <drepper@redhat.com>
242
243         * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
244         Remove ptr_wait_lookup_done again.
245         * init.c (pthread_functions): Don't add .ptr_wait_lookup_done here.
246         (__pthread_initialize_minimal_internal): Initialize
247         _dl_wait_lookup_done pointer in _rtld_global directly.
248         * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
249         Remove code to code _dl_wait_lookup_done.
250         * sysdeps/x86_64/tls.h (THREAD_GSCOPE_WAIT): The pointer is not
251         encrypted for now.
252
253 2007-05-21  Jakub Jelinek  <jakub@redhat.com>
254
255         * tst-robust9.c (do_test): Don't fail if ENABLE_PI and
256         pthread_mutex_init failed with ENOTSUP.
257
258 2007-05-19  Ulrich Drepper  <drepper@redhat.com>
259
260         * allocatestack.c (__wait_lookup_done): New function.
261         * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
262         Add ptr_wait_lookup_done.
263         * init.c (pthread_functions): Initialize .ptr_wait_lookup_done.
264         * pthreadP.h: Declare __wait_lookup_done.
265         * sysdeps/i386/tls.h (tcbhead_t): Add gscope_flag.
266         Define macros to implement reference handling of global scope.
267         * sysdeps/x86_64/tls.h: Likewise.
268         * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
269         Initialize GL(dl_wait_lookup_done).
270
271 2007-05-17  Ulrich Drepper  <drepper@redhat.com>
272
273         [BZ #4512]
274         * pthread_mutex_lock.c: Preserve FUTEX_WAITERS bit when dead owner
275         is detected.
276         * pthread_mutex_timedlock.c: Likewise.
277         * pthread_mutex_trylock.c: Likewise.
278         Patch in part by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
279
280         * Makefile (tests): Add tst-robust9 and tst-robustpi9.
281         * tst-robust9.c: New file.
282         * tst-robustpi9.c: New file.
283
284         * sysdeps/unix/sysv/linux/sem_wait.c (__new_sem_wait): Remove
285         unnecessary extra cancellation test.
286
287 2007-05-14  Ulrich Drepper  <drepper@redhat.com>
288
289         * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Remove unnecessary
290         extra cancellation test.
291         * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
292
293 2007-05-10  Ulrich Drepper  <drepper@redhat.com>
294
295         * descr.h (struct pthread): Rearrange members to fill hole in
296         64-bit layout.
297
298         * sysdeps/unix/sysv/linux/pthread_setaffinity.c
299         (__pthread_setaffinity_new): If syscall was successful and
300         RESET_VGETCPU_CACHE is defined, use it before returning.
301         * sysdeps/unix/sysv/linux/x86_64/pthread_setaffinity.c: New file.
302
303 2007-05-10  Jakub Jelinek  <jakub@redhat.com>
304
305         [BZ #4455]
306         * tst-align2.c: Include stackinfo.h.
307         * tst-getpid1.c: Likewise.
308
309 2007-05-02  Carlos O'Donell  <carlos@systemhalted.org>
310
311         [BZ #4455]
312         * tst-align2.c (do_test): Add _STACK_GROWS_UP case.
313         * tst-getpid1.c (do_test): Likewise.
314
315         [BZ #4456]
316         * allocatestack.c (change_stack_perm): Add _STACK_GROWS_UP case.
317         (allocate_stack): Likewise.
318
319 2007-05-07  Ulrich Drepper  <drepper@redhat.com>
320
321         * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
322         (__lll_robust_lock_wait): Fix race caused by reloading of futex value.
323         (__lll_robust_timedlock_wait): Likewise.
324         Reported by Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>.
325
326 2007-05-06  Mike Frysinger  <vapier@gentoo.org>
327
328         [BZ #4465]
329         * tst-cancel-wrappers.sh: Set C["fdatasync"] to 1.
330         * tst-cancel4.c (tf_fdatasync): New test.
331
332 2007-04-27  Ulrich Drepper  <drepper@redhat.com>
333
334         [BZ #4392]
335         * pthread_mutex_trylock.c (__pthread_mutex_trylock): Treat error
336         check mutexes like normal mutexes.
337
338         [BZ #4306]
339         * sysdeps/unix/sysv/linux/timer_create.c (timer_create):
340         Initialize the whole sigevent structure to appease valgrind.
341
342 2007-04-25  Ulrich Drepper  <drepper@redhat.com>
343
344         * sysdeps/x86_64/tls.h (tcbhead_t): Add vgetcpu_cache.
345         * sysdeps/x86_64/tcb-offsets.sym: Add VGETCPU_CACHE_OFFSET.
346
347 2007-04-06  Ulrich Drepper  <drepper@redhat.com>
348
349         * tst-locale1.c: Avoid warnings.
350         * tst-locale2.c: Likewise.
351
352 2007-03-19  Steven Munroe  <sjmunroe@us.ibm.com>
353
354         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
355         (__lll_robust_trylock): Add MUTEX_HINT_ACQ to lwarx instruction.
356
357 2007-03-16  Jakub Jelinek  <jakub@redhat.com>
358
359         * sysdeps/pthread/bits/libc-lock.h: Use __extern_inline and
360         __extern_always_inline where appropriate.
361         * sysdeps/pthread/pthread.h: Likewise.
362
363 2007-03-13  Richard Henderson  <rth@redhat.com>
364
365         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (PSEUDO): Use two
366         separate cfi regions for the two subsections.
367
368 2007-02-25  Ulrich Drepper  <drepper@redhat.com>
369
370         * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Reset refcntr in
371         new thread, don't just decrement it.
372         Patch by Suzuki K P <suzuki@in.ibm.com>.
373
374 2007-02-21  Ulrich Drepper  <drepper@redhat.com>
375
376         * sysdeps/pthread/pthread-functions.h: Correct last patch, correct
377         PTHFCT_CALL definition.
378
379 2007-02-18  Ulrich Drepper  <drepper@redhat.com>
380
381         * sysdeps/pthread/pthread-functions.h: If PTR_DEMANGLE is not
382         available, don't use it.
383
384 2007-02-09  Jakub Jelinek  <jakub@redhat.com>
385
386         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
387         (__lll_mutex_timedlock_wait): Use correct pointer when we don't
388         call into the kernel to delay.
389
390 2007-01-18  Ulrich Drepper  <drepper@redhat.com>
391
392         * tst-initializers1.c: We want to test the initializers as seen
393         outside of libc, so undefined _LIBC.
394
395         * pthread_join.c (cleanup): Avoid warning.
396
397 2007-01-17  Ulrich Drepper  <drepper@redhat.com>
398
399         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
400         (__lll_timedwait_tid): Add unwind info.
401
402         * sysdeps/unix/sysv/linux/libc_pthread_init.c: Don't just copy the
403         function table, mangle the pointers.
404         * sysdeps/pthread/pthread-functions.h: Define PTHFCT_CALL.
405         * forward.c: Use PTHFCT_CALL and __libc_pthread_functions_init.
406         * sysdeps/pthread/bits/libc-lock.h: When using __libc_pthread_functions
407         demangle pointers before use.
408         * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Use PTHFCT_CALL to
409         demangle pointer.
410         * sysdeps/unix/sysv/linux/jmp-unwind.c: Likewise.
411         * sysdeps/pthread/setxid.h: Likewise.
412
413 2007-01-12  Ulrich Drepper  <drepper@redhat.com>
414
415         * tst-rwlock7.c: Show some more information in case of correct
416         behavior.
417
418 2007-01-11  Ulrich Drepper  <drepper@redhat.com>
419
420         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
421         (lll_futex_timed_wait): Undo part of last change, don't negate
422         return value.
423
424 2007-01-10  Ulrich Drepper  <drepper@redhat.com>
425
426         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Cleanups.  Define
427         FUTEX_CMP_REQUEUE and lll_futex_requeue.
428
429 2006-12-28  David S. Miller  <davem@davemloft.net>
430
431         * shlib-versions: Fix sparc64 linux target specification.
432
433 2007-01-10  Jakub Jelinek  <jakub@redhat.com>
434
435         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
436         Adjust include path for pthread_barrier_wait.c move.
437
438 2006-12-21  Jakub Jelinek  <jakub@redhat.com>
439
440         * sysdeps/unix/sysv/linux/pthread_kill.c (pthread_kill): Make sure
441         tid isn't reread from pd->tid in between ESRCH test and the syscall.
442
443 2006-12-06  Jakub Jelinek  <jakub@redhat.com>
444
445         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO): Handle
446         6 argument cancellable syscalls.
447         (STM_6, LM_6, LR7_0, LR7_1, LR7_2, LR7_3, LR7_4, LR7_5, LR7_6): Define.
448         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO): Handle
449         6 argument cancellable syscalls.
450         (STM_6, LM_6, LR7_0, LR7_1, LR7_2, LR7_3, LR7_4, LR7_5, LR7_6): Define.
451
452 2006-12-09  Ulrich Drepper  <drepper@redhat.com>
453
454         * sysdeps/unix/sysv/linux/rtld-lowlevel.h
455         (__rtld_mrlock_initialize): Add missing closing parenthesis.
456
457 2006-10-30  Jakub Jelinek  <jakub@redhat.com>
458
459         * sysdeps/ia64/pthread_spin_unlock.c (pthread_spin_unlock): Use
460         __sync_lock_release instead of __sync_lock_release_si.
461
462 2006-10-29  Jakub Jelinek  <jakub@redhat.com>
463
464         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (RTLD_SINGLE_THREAD_P):
465         Define.
466         (SINGLE_THREAD_P): Define to 1 if IS_IN_rtld.
467         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Likewise.
468         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
469         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
470         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
471         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
472         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
473         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
474         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
475         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
476         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
477
478 2006-10-27  Ulrich Drepper  <drepper@redhat.com>
479
480         * sysdeps/pthread/pthread_barrier_wait.c: Move to...
481         * pthread_barrier_wait.c: ...here.
482         * sysdeps/pthread/pthread_cond_broadcast.c: Move to...
483         * pthread_cond_broadcast.c: ...here.
484         * sysdeps/pthread/pthread_cond_signal.c: Move to...
485         * pthread_cond_signal.c: ...here.
486         * sysdeps/pthread/pthread_cond_timedwait.c: Move to...
487         * pthread_cond_timedwait.c: ...here.
488         * sysdeps/pthread/pthread_cond_wait.c: Move to...
489         * pthread_cond_wait.c: ...here.
490         * sysdeps/pthread/pthread_once.c: Move to...
491         * pthread_once.c: ...here.
492         * sysdeps/pthread/pthread_rwlock_rdlock.c: Move to...
493         * pthread_rwlock_rdlock.c: ...here.
494         * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Move to...
495         * pthread_rwlock_timedrdlock.c: ...here.
496         * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Move to...
497         * pthread_rwlock_timedwrlock.c: ...here.
498         * sysdeps/pthread/pthread_rwlock_unlock.c: Move to...
499         * pthread_rwlock_unlock.c: ...here.
500         * sysdeps/pthread/pthread_rwlock_wrlock.c: Move to...
501         * pthread_rwlock_wrlock.c: ...here.
502         * sysdeps/pthread/pthread_spin_destroy.c: Move to...
503         * pthread_spin_destroy.c: ...here.
504         * sysdeps/pthread/pthread_spin_init.c: Move to...
505         * pthread_spin_init.c: ...here.
506         * sysdeps/pthread/pthread_spin_unlock.c: Move to...
507         * pthread_spin_unlock.c: ...here.
508         * sysdeps/pthread/pthread_getcpuclockid.c: Move to...
509         * pthread_getcpuclockid.c: ...here.
510
511         * init.c: USE_TLS support is now always enabled.
512         * tst-tls5.h: Likewise.
513         * sysdeps/alpha/tls.h: Likewise.
514         * sysdeps/i386/tls.h: Likewise.
515         * sysdeps/ia64/tls.h: Likewise.
516         * sysdeps/powerpc/tls.h: Likewise.
517         * sysdeps/s390/tls.h: Likewise.
518         * sysdeps/sh/tls.h: Likewise.
519         * sysdeps/sparc/tls.h: Likewise.
520         * sysdeps/x86_64/tls.h: Likewise.
521
522 2006-10-27  Jakub Jelinek  <jakub@redhat.com>
523
524         * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_mrlock_lock,
525         __rtld_mrlock_change): Update oldval if atomic compare and exchange
526         failed.
527
528         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
529         Define to THREAD_SELF->header.multiple_threads.
530         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SINGLE_THREAD_P):
531         Likewise.
532         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (SINGLE_THREAD_P):
533         Likewise.
534         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
535         (SINGLE_THREAD_P): Likewise.
536         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
537         (SINGLE_THREAD_P): Likewise.
538         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
539         (SINGLE_THREAD_P): Likewise.
540         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
541         (SINGLE_THREAD_P): Likewise.
542         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (SINGLE_THREAD_P):
543         Likewise.
544         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
545         (SINGLE_THREAD_P): Likewise.
546         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
547         (SINGLE_THREAD_P): Likewise.
548         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (SINGLE_THREAD_P):
549         Likewise.
550
551 2006-10-26  Jakub Jelinek  <jakub@redhat.com>
552
553         * pthread_attr_setstacksize.c (NEW_VERNUM): Define to GLIBC_2_3_3
554         by default rather than 2_3_3.
555
556 2006-10-17  Jakub Jelinek  <jakub@redhat.com>
557
558         * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_mrlock_lock,
559         __rtld_mrlock_unlock, __rtld_mrlock_change, __rtld_mrlock_done): Use
560         atomic_* instead of catomic_* macros.
561
562 2006-10-12  Ulrich Drepper  <drepper@redhat.com>
563
564         [BZ #3285]
565         * sysdeps/unix/sysv/linux/bits/local_lim.h: Add SEM_VALUE_MAX.
566         * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: Likewise.
567         * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
568         * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
569         * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
570         * sysdeps/unix/sysv/linux/i386/bits/semaphore.h: Remove SEM_VALUE_MAX.
571         * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: Likewise.
572         * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
573         * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: Likewise.
574         * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h: Likewise.
575         * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: Likewise.
576         * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: Likewise.
577         * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: Likewise.
578
579 2006-10-11  Ulrich Drepper  <drepper@redhat.com>
580
581         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Add support for
582         cancelable syscalls with six parameters.
583
584         * sysdeps/unix/sysv/linux/rtld-lowlevel.h: Use catomic_*
585         operations instead of atomic_*.
586
587 2006-10-09  Ulrich Drepper  <drepper@redhat.com>
588
589         * sysdeps/unix/sysv/linux/rtld-lowlevel.h: New file..
590
591 2006-10-07  Ulrich Drepper  <drepper@redhat.com>
592
593         * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: New file.
594         * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstack.c: New file.
595         * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstacksize.c:
596         New file.
597         * pthread_attr_setstack.c: Allow overwriting the version number of the
598         new symbol.
599         * pthread_attr_setstacksize.c: Likewise.
600         (__old_pthread_attr_setstacksize): If STACKSIZE_ADJUST is defined use
601         it.
602         * sysdeps/unix/sysv/linux/powerpc/Versions (libpthread): Add
603         pthread_attr_setstack and pthread_attr_setstacksize to GLIBC_2.6.
604
605 2006-09-24  Ulrich Drepper  <drepper@redhat.com>
606
607         [BZ #3251]
608         * descr.h (ENQUEUE_MUTEX_BOTH): Add cast to avoid warning.
609         Patch by Petr Baudis.
610
611 2006-09-18  Jakub Jelinek  <jakub@redhat.com>
612
613         * tst-kill4.c (do_test): Explicitly set tf thread's stack size.
614
615         * tst-cancel2.c (tf): Loop as long as something was written.
616
617 2006-09-12  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
618
619         * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: For PI
620         mutexes wake all mutexes.
621         * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Don't increment
622         WAKEUP_SEQ if this would increase the value beyond TOTAL_SEQ.
623         * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
624
625 2006-09-12  Ulrich Drepper  <drepper@redhat.com>
626
627         * tst-cond22.c (tf): Slight changes to the pthread_cond_wait use
628         to guarantee the thread is always canceled.
629
630 2006-09-08  Jakub Jelinek  <jakub@redhat.com>
631
632         * tst-cond22.c: Include pthread.h instead of pthreadP.h.
633         Include stdlib.h.
634         * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Only
635         increase FUTEX if increasing WAKEUP_SEQ.  Fix comment typo.
636         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
637         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
638         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
639
640 2006-09-08  Ulrich Drepper  <drepper@redhat.com>
641
642         [BZ #3123]
643         * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Don't
644         increment WAKEUP_SEQ if this would increase the value beyond TOTAL_SEQ.
645         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
646         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
647         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
648         * Makefile (tests): Add tst-cond22.
649         * tst-cond22.c: New file.
650
651 2006-09-05  Ulrich Drepper  <drepper@redhat.com>
652
653         [BZ #3124]
654         * descr.h (struct pthread): Add parent_cancelhandling.
655         * sysdeps/pthread/createthread.c (create_thread): Pass parent
656         cancelhandling value to child.
657         * pthread_create.c (start_thread): If parent thread was canceled
658         reset the SIGCANCEL mask.
659         * Makefile (tests): Add tst-cancel25.
660         * tst-cancel25.c: New file.
661
662 2006-09-05  Jakub Jelinek  <jakub@redhat.com>
663             Ulrich Drepper  <drepper@redhat.com>
664
665         * sysdeps/pthread/gai_misc.h (GAI_MISC_NOTIFY): Don't decrement
666         counterp if it is already zero.
667         * sysdeps/pthread/aio_misc.h (AIO_MISC_NOTIFY): Likewise..
668
669 2006-03-04  Jakub Jelinek  <jakub@redhat.com>
670             Roland McGrath  <roland@redhat.com>
671
672         * sysdeps/unix/sysv/linux/i386/lowlevellock.h
673         (LLL_STUB_UNWIND_INFO_START, LLL_STUB_UNWIND_INFO_END,
674         LLL_STUB_UNWIND_INFO_3, LLL_STUB_UNWIND_INFO_4): Define.
675         (lll_mutex_lock, lll_robust_mutex_lock, lll_mutex_cond_lock,
676         lll_robust_mutex_cond_lock, lll_mutex_timedlock,
677         lll_robust_mutex_timedlock, lll_mutex_unlock,
678         lll_robust_mutex_unlock, lll_lock, lll_unlock): Use them.
679         Add _L_*_ symbols around the subsection.
680         * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Add unwind info.
681         * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: Likewise.
682
683 2006-03-03  Jakub Jelinek  <jakub@redhat.com>
684             Roland McGrath  <roland@redhat.com>
685
686         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
687         (LLL_STUB_UNWIND_INFO_START, LLL_STUB_UNWIND_INFO_END,
688         LLL_STUB_UNWIND_INFO_5, LLL_STUB_UNWIND_INFO_6): Define.
689         (lll_mutex_lock, lll_robust_mutex_lock, lll_mutex_cond_lock,
690         lll_robust_mutex_cond_lock, lll_mutex_timedlock,
691         lll_robust_mutex_timedlock, lll_mutex_unlock,
692         lll_robust_mutex_unlock, lll_lock, lll_unlock): Use them.
693         Add _L_*_ symbols around the subsection.
694         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Add unwind info.
695         * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Likewise.
696
697 2006-08-31  Ulrich Drepper  <drepper@redhat.com>
698
699         * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Undo last
700         change because it can disturb too much existing code.  If real hard
701         reader preference is needed we'll introduce another type.
702         * sysdeps/pthread/pthread_rwlock_timedwrlock.c
703         (pthread_rwlock_timedwrlock): Likewise.
704         * sysdeps/pthread/pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock):
705         Likewise.
706
707 2006-08-30  Ulrich Drepper  <drepper@redhat.com>
708
709         * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Respect
710         reader preference.
711         * sysdeps/pthread/pthread_rwlock_timedwrlock.c
712         (pthread_rwlock_timedwrlock): Likewise.
713         * sysdeps/pthread/pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock):
714         Likewise.
715
716 2006-08-25  Jakub Jelinek  <jakub@redhat.com>
717
718         * sysdeps/unix/sysv/linux/libc_pthread_init.c (freeres_libpthread):
719         Only define ifdef SHARED.
720
721 2006-08-23  Ulrich Drepper  <drepper@redhat.com>
722
723         * allocatestack.c (queue_stack): Move freeing of surplus stacks to...
724         (free_stacks): ...here.
725         (__free_stack_cache): New function.
726         * pthreadP.h: Declare __free_stack_cache.
727         * sysdeps/pthread/pthread-functions.h (pthread_functions): Add
728         ptr_freeres.
729         * init.c (pthread_functions): Initialize ptr_freeres.
730         * sysdeps/unix/sysv/linux/libc_pthread_init.c (freeres_libptread):
731         New freeres function.
732
733 2006-07-30  Joseph S. Myers  <joseph@codesourcery.com>
734
735         [BZ #3018]
736         * Makefile (extra-objs): Add modules to extra-test-objs instead.
737
738 2006-08-20  Ulrich Drepper  <drepper@redhat.com>
739
740         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
741         _XOPEN_REALTIME_THREADS.
742
743 2006-08-15  Jakub Jelinek  <jakub@redhat.com>
744
745         * sysdeps/unix/sysv/linux/clock_settime.c (INTERNAL_VSYSCALL): Use
746         HAVE_CLOCK_GETRES_VSYSCALL as guard macro rather than
747         HAVE_CLOCK_GETTIME_VSYSCALL.
748         (maybe_syscall_settime_cpu): Use plain INTERNAL_VSYSCALL here.
749
750 2006-08-14  Jakub Jelinek  <jakub@redhat.com>
751
752         * sysdeps/unix/sysv/linux/bits/posix_opt.h
753         (_POSIX_THREAD_PRIO_PROTECT): Define to 200112L.
754         * descr.h (struct priority_protection_data): New type.
755         (struct pthread): Add tpp field.
756         * pthreadP.h (PTHREAD_MUTEX_PP_NORMAL_NP,
757         PTHREAD_MUTEX_PP_RECURSIVE_NP, PTHREAD_MUTEX_PP_ERRORCHECK_NP,
758         PTHREAD_MUTEX_PP_ADAPTIVE_NP): New enum values.
759         * pthread_mutex_init.c (__pthread_mutex_init): Handle non-robust
760         TPP mutexes.
761         * pthread_mutex_lock.c (__pthread_mutex_lock): Handle TPP mutexes.
762         * pthread_mutex_trylock.c (__pthread_mutex_trylock): Likewise.
763         * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Likewise.
764         * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Likewise.
765         * tpp.c: New file.
766         * pthread_setschedparam.c (__pthread_setschedparam): Handle priority
767         boosted by TPP.
768         * pthread_setschedprio.c (pthread_setschedprio): Likewise.
769         * pthread_mutexattr_getprioceiling.c
770         (pthread_mutexattr_getprioceiling): If ceiling is 0, ensure it is
771         in the SCHED_FIFO priority range.
772         * pthread_mutexattr_setprioceiling.c
773         (pthread_mutexattr_setprioceiling): Fix prioceiling validation.
774         * pthread_mutex_getprioceiling.c (pthread_mutex_getprioceiling): Fail
775         if mutex is not TPP.  Ceiling is now in __data.__lock.
776         * pthread_mutex_setprioceiling.c: Include stdbool.h.
777         (pthread_mutex_setprioceiling): Fix prioceiling validation.  Ceiling
778         is now in __data.__lock.  Add locking.
779         * pthread_create.c (__free_tcb): Free pd->tpp structure.
780         * Makefile (libpthread-routines): Add tpp.
781         (xtests): Add tst-mutexpp1, tst-mutexpp6 and tst-mutexpp10.
782         * tst-tpp.h: New file.
783         * tst-mutexpp1.c: New file.
784         * tst-mutexpp6.c: New file.
785         * tst-mutexpp10.c: New file.
786         * tst-mutex1.c (TEST_FUNCTION): Don't redefine if already defined.
787         * tst-mutex6.c (TEST_FUNCTION): Likewise.
788
789 2006-08-12  Ulrich Drepper  <drepper@redhat.com>
790
791         [BZ #2843]
792         * pthread_join.c (pthread_join): Account for self being canceled
793         when checking for deadlocks.
794         * tst-join5.c: Cleanups.  Allow to be used in tst-join6.
795         (tf1): Don't print anything after pthread_join returns, this would be
796         another cancellation point.
797         (tf2): Likewise.
798         * tst-join6.c: New file.
799         * Makefile (tests): Add tst-join6.
800
801 2006-08-03  Ulrich Drepper  <drepper@redhat.com>
802
803         [BZ #2892]
804         * pthread_setspecific.c (__pthread_setspecific): Check
805         out-of-range index before checking for unused key.
806
807         * sysdeps/pthread/gai_misc.h: New file.
808
809 2006-08-01  Ulrich Drepper  <drepper@redhat.com>
810
811         * sysdeps/unix/sysv/linux/i386/smp.h: New file.  Old Linux-specific
812         file.  Don't use sysctl.
813         * sysdeps/unix/sysv/linux/smp.h: Always assume SMP.  Archs can
814         overwrite the file if this is likely not true.
815
816 2006-07-31  Daniel Jacobowitz  <dan@codesourcery.com>
817
818         * allocatestack.c (__reclaim_stacks): Reset the PID on cached stacks.
819         * Makefile (tests): Add tst-getpid3.
820         * tst-getpid3.c: New file.
821
822 2006-07-30  Roland McGrath  <roland@redhat.com>
823
824         * Makefile (libpthread-routines): Add ptw-sigsuspend.
825
826         * sysdeps/unix/sysv/linux/i386/not-cancel.h
827         (pause_not_cancel): New macro.
828         (nanosleep_not_cancel): New macro.
829         (sigsuspend_not_cancel): New macro.
830         * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Use
831         nanosleep_not_cancel macro from <not-cancel.h>.
832         * pthread_mutex_lock.c (__pthread_mutex_lock): Use pause_not_cancel
833         macro from <not-cancel.h>.
834
835 2006-07-28  Ulrich Drepper  <drepper@redhat.com>
836             Jakub Jelinek  <jakub@redhat.com>
837
838         * descr.h: Change ENQUEUE_MUTEX and DEQUEUE_MUTEX for bit 0
839         notification of PI mutex.  Add ENQUEUE_MUTEX_PI.
840         * pthreadP.h: Define PTHREAD_MUTEX_PI_* macros for PI mutex types.
841         * pthread_mutex_setprioceilining.c: Adjust for mutex type name change.
842         * pthread_mutex_init.c: Add support for priority inheritance mutex.
843         * pthread_mutex_lock.c: Likewise.
844         * pthread_mutex_timedlock.c: Likewise.
845         * pthread_mutex_trylock.c: Likewise.
846         * pthread_mutex_unlock.c: Likewise.
847         * sysdeps/pthread/pthread_cond_broadcast.c: For PI mutexes wake
848         all mutexes.
849         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.c: Likewise.
850         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.c: Likewise.
851         * sysdeps/unix/sysv/linux/pthread-pi-defines.sym: New file.
852         * sysdeps/unix/sysv/linux/Makefile (gen-as-const-header): Add
853         pthread-pi-defines.sym.
854         * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define FUTEX_LOCK_PI,
855         FUTEX_UNLOCK_PI, and FUTEX_TRYLOCK_PI.
856         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
857         * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
858         * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
859         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
860         * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
861         * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
862         * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
863         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
864         _POSIX_THREAD_PRIO_INHERIT to 200112L.
865         * tst-mutex1.c: Adjust to allow use in PI mutex test.
866         * tst-mutex2.c: Likewise.
867         * tst-mutex3.c: Likewise.
868         * tst-mutex4.c: Likewise.
869         * tst-mutex5.c: Likewise.
870         * tst-mutex6.c: Likewise.
871         * tst-mutex7.c: Likewise.
872         * tst-mutex7a.c: Likewise.
873         * tst-mutex8.c: Likewise.
874         * tst-mutex9.c: Likewise.
875         * tst-robust1.c: Likewise.
876         * tst-robust7.c: Likewise.
877         * tst-robust8.c: Likewise.
878         * tst-mutexpi1.c: New file.
879         * tst-mutexpi2.c: New file.
880         * tst-mutexpi3.c: New file.
881         * tst-mutexpi4.c: New file.
882         * tst-mutexpi5.c: New file.
883         * tst-mutexpi6.c: New file.
884         * tst-mutexpi7.c: New file.
885         * tst-mutexpi7a.c: New file.
886         * tst-mutexpi8.c: New file.
887         * tst-mutexpi9.c: New file.
888         * tst-robust1.c: New file.
889         * tst-robust2.c: New file.
890         * tst-robust3.c: New file.
891         * tst-robust4.c: New file.
892         * tst-robust5.c: New file.
893         * tst-robust6.c: New file.
894         * tst-robust7.c: New file.
895         * tst-robust8.c: New file.
896         * Makefile (tests): Add the new tests.
897
898         * pthread_create.c (start_thread): Add some casts to avoid warnings.
899         * pthread_mutex_destroy.c: Remove unneeded label.
900
901 2006-07-01  Ulrich Drepper  <drepper@redhat.com>
902
903         * pthread_mutex_init.c (__pthread_mutex_init): Move some
904         computations to compile time.
905
906 2006-06-04  Ulrich Drepper  <drepper@redhat.com>
907
908         * sysdeps/pthread/pthread.h: Add pthread_equal inline version.
909
910 2006-05-15  Ulrich Drepper  <drepper@redhat.com>
911
912         * sysdeps/unix/sysv/linux/fork.h: Mark __fork_handlers as hidden.
913
914 2006-05-11  Ulrich Drepper  <drepper@redhat.com>
915
916         * pthread_key_create.c (__pthread_key_create): Do away with
917         __pthread_keys_lock.
918
919         * sysdeps/unix/sysv/linux/pthread_setaffinity.c
920         (__kernel_cpumask_size): Mark as hidden.
921         * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: Likewise.
922
923         * sem_open.c (__sem_mappings_lock): Mark as hidden.
924         * semaphoreP.h (__sem_mappings_lock): Likewise.
925
926 2006-05-10  Ulrich Drepper  <drepper@redhat.com>
927
928         * pthread_atfork.c: Mark __dso_handle as hidden.
929
930 2006-05-09  Ulrich Drepper  <drepper@redhat.com>
931
932         [BZ #2644]
933         * sysdeps/pthread/unwind-forcedunwind.c: Different solution for
934         the reload problem.  Change the one path in pthread_cancel_init
935         which causes the problem.  Force gcc to reload.  Simplify callers.
936         * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c
937         (_Unwind_GetBSP): Undo last patch.
938
939 2006-05-07  Ulrich Drepper  <drepper@redhat.com>
940
941         * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c: Make sure the
942         function pointer is reloaded after pthread_cancel_init calls.
943
944         [BZ #2644]
945         * sysdeps/pthread/unwind-forcedunwind.c: Make sure functions
946         pointers are reloaded after pthread_cancel_init calls.
947
948 2006-05-01  Ulrich Drepper  <drepper@redhat.com>
949
950         * sysdeps/pthread/allocalim.h (__libc_use_alloca): Mark with
951         __always_inline.
952
953 2006-04-27  Ulrich Drepper  <drepper@redhat.com>
954
955         * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
956         Allocate new object which is passed to timer_sigev_thread so that
957         the timer can be deleted before the new thread is scheduled.
958
959 2006-04-26  Roland McGrath  <roland@redhat.com>
960
961         * sysdeps/x86_64/tls.h: Include <asm/prctl.h> inside [! __ASSEMBLER__].
962
963 2006-04-08  Ulrich Drepper  <drepper@redhat.com>
964
965         * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove branch predicion
966         suffix for conditional jumps.
967         * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
968         * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
969         * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
970         * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
971         * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
972         * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
973
974         * init.c (sigcancel_handler): Compare with correct PID even if the
975         thread is in the middle of a fork call.
976         (sighandler_setxid): Likewise.
977         Reported by Suzuki K P <suzuki@in.ibm.com> .
978
979 2006-04-07  Jakub Jelinek  <jakub@redhat.com>
980
981         * pthreadP.h (FUTEX_TID_MASK): Sync with kernel.
982
983 2006-04-06  Ulrich Drepper  <drepper@redhat.com>
984
985         * pthread_getattr_np.c (pthread_getattr_np): Close fp if getrlimit
986         fails [Coverity CID 105].
987
988 2006-04-05  Ulrich Drepper  <drepper@redhat.com>
989
990         * sysdeps/pthread/pthread.h: Add nonnull attributes.
991
992 2006-04-03  Steven Munroe  <sjmunroe@us.ibm.com>
993
994         [BZ #2505]
995         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h [_ARCH_PWR4]:
996         Define __lll_rel_instr using lwsync.
997
998 2006-03-27  Ulrich Drepper  <drepper@redhat.com>
999
1000         * allocatestack.c (allocate_stack): Always initialize robust_head.
1001         * descr.h: Define struct robust_list_head.
1002         (struct pthread): Use robust_list_head in robust mutex list definition.
1003         Adjust ENQUEUE_MUTEX and DEQUEUE_MUTEX.
1004         * init.c [!__ASSUME_SET_ROBUST_LIST] (__set_robust_list_avail): Define.
1005         (__pthread_initialize_minimal_internal): Register robust_list with
1006         the kernel.
1007         * pthreadP.h: Remove PRIVATE_ from PTHREAD_MUTEX_ROBUST_* names.
1008         Declare __set_robust_list_avail.
1009         * pthread_create.c (start_thread): Register robust_list of new thread.
1010         [!__ASSUME_SET_ROBUST_LIST]: If robust_list is not empty wake up
1011         waiters.
1012         * pthread_mutex_destroy.c: For robust mutexes don't look at the
1013         number of users, it's unreliable.
1014         * pthread_mutex_init.c: Allow use of pshared robust mutexes if
1015         set_robust_list syscall is available.
1016         * pthread_mutex_consistent.c: Adjust for PTHREAD_MUTEX_ROBUST_* rename.
1017         * pthread_mutex_lock.c: Simplify robust mutex code a bit.
1018         Set robust_head.list_op_pending before trying to lock a robust mutex.
1019         * pthread_mutex_timedlock.c: Likewise.
1020         * pthread_mutex_trylock.c: Likewise.
1021         * pthread_mutex_unlock.c: Likewise for unlocking.
1022         * Makefile (tests): Add tst-robust8.
1023         * tst-robust8.c: New file.
1024
1025 2006-03-08  Andreas Schwab  <schwab@suse.de>
1026
1027         * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h
1028         (DL_SYSINFO_IMPLEMENTATION): Add missing newline.
1029
1030 2006-03-05  Roland McGrath  <roland@redhat.com>
1031
1032         * configure (libc_add_on): Disable add-on when $add_ons_automatic = yes
1033         and $config_os doesn't match *linux*.
1034
1035 2006-03-05  David S. Miller  <davem@sunset.davemloft.net>
1036
1037         * sysdeps/unix/sysv/linux/sparc/sparc32/pt-vfork.S:
1038         Use __syscall_error.
1039         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
1040         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: Likewise.
1041         * sysdeps/unix/sysv/linux/sparc/sparc64/pt-vfork.S: Likewise.
1042         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
1043         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: Likewise.
1044         * sysdeps/unix/sysv/linux/sparc/Makefile: New file.
1045
1046 2006-03-02  Ulrich Drepper  <drepper@redhat.com>
1047
1048         * sysdeps/unix/sysv/linux/aio_misc.h: Various cleanups.
1049
1050 2006-03-01  Ulrich Drepper  <drepper@redhat.com>
1051
1052         * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S
1053         (__lll_robust_lock_wait): Also set FUTEX_WAITERS bit if we got the
1054         mutex.
1055         (__lll_robust_timedlock_wait): Likewise.
1056         * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S
1057         (__lll_robust_lock_wait): Likewise.
1058         (__lll_robust_timedlock_wait): Likewise.
1059         * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
1060         (__lll_robust_lock_wait): Likewise.
1061         (__lll_robust_timedlock_wait): Likewise.
1062
1063 2006-03-01  Jakub Jelinek  <jakub@redhat.com>
1064
1065         * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (lll_robust_mutex_dead,
1066         lll_robust_mutex_trylock, lll_robust_mutex_lock,
1067         lll_robust_mutex_cond_lock, lll_robust_mutex_timedlock,
1068         lll_robust_mutex_unlock): Define.
1069         (__lll_robust_lock_wait, __lll_robust_timedlock_wait): New prototypes.
1070
1071 2006-02-28  H.J. Lu  <hongjiu.lu@intel.com>
1072
1073         * sysdeps/unix/sysv/linux/ia64/clone2.S: Include <clone2.S>
1074         instead of <clone.S>.
1075
1076 2006-02-27  Jakub Jelinek  <jakub@redhat.com>
1077
1078         * Makefile (libpthread-routines): Add
1079         pthread_mutexattr_[sg]etprotocol, pthread_mutexattr_[sg]etprioceiling
1080         and pthread_mutex_[sg]etprioceiling.
1081         * Versions (GLIBC_2.4): Export pthread_mutexattr_getprotocol,
1082         pthread_mutexattr_setprotocol, pthread_mutexattr_getprioceiling,
1083         pthread_mutexattr_setprioceiling, pthread_mutex_getprioceiling and
1084         pthread_mutex_setprioceiling.
1085         * sysdeps/pthread/pthread.h (PTHREAD_PRIO_NONE, PTHREAD_PRIO_INHERIT,
1086         PTHREAD_PRIO_PROTECT): New enum values.
1087         (pthread_mutexattr_getprotocol, pthread_mutexattr_setprotocol,
1088         pthread_mutexattr_getprioceiling, pthread_mutexattr_setprioceiling,
1089         pthread_mutex_getprioceiling, pthread_mutex_setprioceiling): New
1090         prototypes.
1091         * pthreadP.h (PTHREAD_MUTEX_PRIO_INHERIT_PRIVATE_NP,
1092         PTHREAD_MUTEX_PRIO_PROTECT_PRIVATE_NP): New enum values.
1093         (PTHREAD_MUTEX_PRIO_CEILING_SHIFT, PTHREAD_MUTEX_PRIO_CEILING_MASK):
1094         Define.
1095         (PTHREAD_MUTEXATTR_PROTOCOL_SHIFT, PTHREAD_MUTEXATTR_PROTOCOL_MASK,
1096         PTHREAD_MUTEXATTR_PRIO_CEILING_SHIFT,
1097         PTHREAD_MUTEXATTR_PRIO_CEILING_MASK): Define.
1098         (PTHREAD_MUTEXATTR_FLAG_BITS): Or in PTHREAD_MUTEXATTR_PROTOCOL_MASK
1099         and PTHREAD_MUTEXATTR_PRIO_CEILING_MASK.
1100         * pthread_mutex_init.c (__pthread_mutex_init): For the time being
1101         return ENOTSUP for PTHREAD_PRIO_INHERIT or PTHREAD_PRIO_PROTECT
1102         protocol mutexes.
1103         * pthread_mutex_getprioceiling.c: New file.
1104         * pthread_mutex_setprioceiling.c: New file.
1105         * pthread_mutexattr_getprioceiling.c: New file.
1106         * pthread_mutexattr_setprioceiling.c: New file.
1107         * pthread_mutexattr_getprotocol.c: New file.
1108         * pthread_mutexattr_setprotocol.c: New file.
1109
1110 2006-02-27  Daniel Jacobowitz  <dan@codesourcery.com>
1111
1112         * sysdeps/unix/sysv/linux/aio_misc.h: Include <limits.h>.
1113
1114 2006-02-27  Roland McGrath  <roland@redhat.com>
1115
1116         * sysdeps/pthread/Subdirs: List nptl here too.
1117         * configure (libc_add_on_canonical): New variable.
1118
1119         * sysdeps/unix/sysv/linux/sh/sh4/lowlevellock.h: Use #include_next.
1120
1121         * sysdeps/unix/sysv/linux/sleep.c: Use #include_next after #include of
1122         self to get main source tree's file.
1123         * sysdeps/unix/sysv/linux/alpha/clone.S: Likewise.
1124         * sysdeps/unix/sysv/linux/i386/clone.S: Likewise.
1125         * sysdeps/unix/sysv/linux/i386/vfork.S: Likewise.
1126         * sysdeps/unix/sysv/linux/ia64/clone2.S: Likewise.
1127         * sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S: Likewise.
1128         * sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S: Likewise.
1129         * sysdeps/unix/sysv/linux/s390/s390-32/clone.S: Likewise.
1130         * sysdeps/unix/sysv/linux/s390/s390-64/clone.S: Likewise.
1131         * sysdeps/unix/sysv/linux/sh/clone.S: Likewise.
1132         * sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: Likewise.
1133         * sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
1134         * sysdeps/unix/sysv/linux/x86_64/clone.S: Likewise.
1135         * sysdeps/unix/sysv/linux/x86_64/vfork.S: Likewise.
1136
1137         * Makefile: Use $(sysdirs) in vpath directive.
1138
1139         * sysdeps/pthread/Makefile (CFLAGS-libc-start.c): Variable removed.
1140         (CPPFLAGS-timer_routines.c): Likewise.
1141
1142         * Makeconfig (includes): Variable removed.
1143
1144 2006-02-26  Roland McGrath  <roland@redhat.com>
1145
1146         * sysdeps/generic/pt-raise.c: Moved to ...
1147         * pt-raise.c: ... here.
1148         * sysdeps/generic/lowlevellock.h: Moved to ...
1149         * lowlevellock.h: ... here.
1150
1151 2006-02-23  Roland McGrath  <roland@redhat.com>
1152
1153         * descr.h (struct pthread): Add final member `end_padding'.
1154         (PTHREAD_STRUCT_END_PADDING): Use it.
1155
1156 2006-02-20  Roland McGrath  <roland@redhat.com>
1157
1158         * sysdeps/mips: Directory removed, saved in ports repository.
1159         * sysdeps/unix/sysv/linux/mips: Likewise.
1160
1161 2006-02-18  Ulrich Drepper  <drepper@redhat.com>
1162
1163         * tst-robust1.c: Add second mutex to check that the mutex list is
1164         handled correctly.
1165
1166 2006-02-17  Jakub Jelinek  <jakub@redhat.com>
1167
1168         * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_robust_mutex_dead,
1169         lll_robust_mutex_trylock, lll_robust_mutex_lock,
1170         lll_robust_mutex_cond_lock, lll_robust_mutex_timedlock,
1171         lll_robust_mutex_unlock): New macros.
1172         (__lll_robust_lock_wait, __lll_robust_timedlock_wait): New prototypes.
1173         * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
1174         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
1175         * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
1176         * sysdeps/unix/sysv/linux/lowlevelrobustlock.c: New file.
1177
1178 2006-02-17  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1179
1180         * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Add lll_robust_mutex_*
1181         definitions.
1182         * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S: New file.
1183
1184 2006-02-17  Ulrich Drepper  <drepper@redhat.com>
1185
1186         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
1187         (lll_robust_mutex_unlock): Avoid unnecessary wakeups.
1188         * sysdeps/unix/sysv/linux/i386/lowlevellock.h
1189         (lll_robust_mutex_unlock): Likewise.
1190
1191 2006-02-13  Jakub Jelinek  <jakub@redhat.com>
1192
1193         * descr.h [!__PTHREAD_MUTEX_HAVE_PREV] (DEQUEUE_MUTEX):
1194         Set robust_list.__next rather than robust_list.
1195         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
1196         (__pthread_list_t): New typedef.
1197         (pthread_mutex_t): Replace __next and __prev fields with __list.
1198         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h
1199         (__pthread_list_t): New typedef.
1200         (pthread_mutex_t): Replace __next and __prev fields with __list.
1201         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
1202         (__pthread_list_t, __pthread_slist_t): New typedefs.
1203         (pthread_mutex_t): Replace __next and __prev fields with __list.
1204         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h
1205         (__pthread_list_t, __pthread_slist_t): New typedefs.
1206         (pthread_mutex_t): Replace __next and __prev fields with __list.
1207         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h
1208         (__pthread_list_t, __pthread_slist_t): New typedefs.
1209         (pthread_mutex_t): Replace __next and __prev fields with __list.
1210         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h
1211         (__pthread_slist_t): New typedef.
1212         (pthread_mutex_t): Replace __next field with __list.
1213
1214 2006-02-15  Ulrich Drepper  <drepper@redhat.com>
1215
1216         * pthreadP.h: Define PTHREAD_MUTEX_INCONSISTENT instead of
1217         PTHREAD_MUTEX_OWNERDEAD.
1218         (PTHREAD_MUTEX_ROBUST_PRIVATE_NP): Define as 16, not 256.
1219         Define FUTEX_WAITERS, FUTEX_OWNER_DIED, FUTEX_TID_MASK.
1220         * Makefile (libpthread-routines): Add lowlevelrobustlock.
1221         * pthread_create.c (start_thread): Very much simplify robust_list loop.
1222         * pthread_mutex_consistent.c: Inconsistent mutex have __owner now set
1223         to PTHREAD_MUTEX_INCONSISTENT.
1224         * pthread_mutex_destroy.c: Allow destroying of inconsistent mutexes.
1225         * pthread_mutex_lock.c: Reimplement robust mutex handling.
1226         * pthread_mutex_trylock.c: Likewise.
1227         * pthread_mutex_timedlock.c: Likewise.
1228         * pthread_mutex_unlock.c: Likewise.
1229         * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
1230         * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
1231         lowlevelrobustlock.sym.
1232         * sysdeps/unix/sysv/linux/lowlevelrobustlock.sym: New file.
1233         * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Add lll_robust_mutex_*
1234         definitions.
1235         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
1236         * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: New file.
1237         * sysdeps/unix/sysv/linux/i386/i586/lowlevelrobustlock.S: New file.
1238         * sysdeps/unix/sysv/linux/i386/i686/lowlevelrobustlock.S: New file.
1239         * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: New file.
1240
1241 2006-02-12  Ulrich Drepper  <drepper@redhat.com>
1242
1243         * allocatestack.c (allocate_stack): Initialize robust_list.
1244         * init.c (__pthread_initialize_minimal_internal): Likewise.
1245         * descr.h (struct xid_command): Pretty printing.
1246         (struct pthread): Use __pthread_list_t or __pthread_slist_t for
1247         robust_list.  Adjust macros.
1248         * pthread_create.c (start_thread): Adjust robust_list handling.
1249         * phtread_mutex_unlock.c: Don't allow unlocking from any thread
1250         but the owner for all robust mutex types.
1251         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Define
1252         __pthread_list_t and __pthread_slist_t.  Use them in pthread_mutex_t.
1253         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
1254         * sysdeps/pthread/pthread.h: Adjust mutex initializers.
1255
1256         * sysdeps/unix/sysv/linux/i386/not-cancel.h: Define openat_not_cancel,
1257         openat_not_cancel_3, openat64_not_cancel, and openat64_not_cancel_3.
1258
1259 2006-02-08  Jakub Jelinek  <jakub@redhat.com>
1260
1261         * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait,
1262         lll_futex_timedwait, lll_wait_tid): Add "memory" clobber.
1263
1264 2006-01-20  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1265
1266         * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_futex_wait):
1267         Return status.
1268         (lll_futex_timed_wait): Define.
1269
1270 2006-01-19  Ulrich Drepper  <drepper@redhat.com>
1271
1272         * tst-cancel4.c: Test ppoll.
1273
1274 2006-01-18  Andreas Jaeger  <aj@suse.de>
1275
1276         [BZ #2167]
1277         * sysdeps/unix/sysv/linux/mips/bits/pthreadtypes.h
1278         (pthread_mutex_t): Follow changes for other archs.  Based on patch
1279         by Jim Gifford <patches@jg555.com>.
1280
1281 2006-01-13  Richard Henderson  <rth@redhat.com>
1282
1283         * sysdeps/alpha/tls.h (tcbhead_t): Rename member to __private.
1284
1285 2006-01-10  Roland McGrath  <roland@redhat.com>
1286
1287         * sysdeps/alpha/jmpbuf-unwind.h: File moved to main source tree.
1288         * sysdeps/i386/jmpbuf-unwind.h: Likewise.
1289         * sysdeps/mips/jmpbuf-unwind.h: Likewise.
1290         * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
1291         * sysdeps/s390/jmpbuf-unwind.h: Likewise.
1292         * sysdeps/sh/jmpbuf-unwind.h: Likewise.
1293         * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
1294         * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Likewise.
1295         * sysdeps/x86_64/jmpbuf-unwind.h: Likewise.
1296         * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
1297
1298 2006-01-09  Roland McGrath  <roland@redhat.com>
1299
1300         * tst-initializers1-c89.c: New file.
1301         * tst-initializers1-c99.c: New file.
1302         * tst-initializers1-gnu89.c: New file.
1303         * tst-initializers1-gnu99.c: New file.
1304         * Makefile (tests): Add them.
1305         (CFLAGS-tst-initializers1-c89.c): New variable.
1306         (CFLAGS-tst-initializers1-c99.c): New variable.
1307         (CFLAGS-tst-initializers1-gnu89.c): New variable.
1308         (CFLAGS-tst-initializers1-gnu99.c): New variable.
1309
1310         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
1311         Use __extension__ on anonymous union definition.
1312         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
1313         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
1314         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
1315         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
1316         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
1317
1318 2006-01-08  Jakub Jelinek  <jakub@redhat.com>
1319
1320         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_mutex_t):
1321         Don't give the union a name because it changes the mangled name.
1322         Instead name the struct for __data.
1323         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_mutex_t):
1324         Likewise.
1325         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_mutex_t):
1326         Likewise.
1327
1328 2006-01-09  Jakub Jelinek  <jakub@redhat.com>
1329
1330         * sysdeps/sparc/sparc64/jmpbuf-unwind.h (_JMPBUF_UNWINDS_ADJ): Add
1331         stack bias to mc_ftp field.
1332
1333 2006-01-07  Ulrich Drepper  <drepper@redhat.com>
1334
1335         * sysdeps/pthread/aio_misc.h (AIO_MISC_WAIT): Work around gcc
1336         being too clever and reloading the futex value where it shouldn't.
1337
1338 2006-01-06  Ulrich Drepper  <drepper@redhat.com>
1339
1340         * descr.h [!__PTHREAD_MUTEX_HAVE_PREV] (DEQUEUE_MUTEX): Use
1341         correct type.
1342
1343 2006-01-06  Jakub Jelinek  <jakub@redhat.com>
1344
1345         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h (PSEUDO):
1346         Add cfi directives.
1347
1348 2006-01-06  Ulrich Drepper  <drepper@redhat.com>
1349
1350         * sysdeps/ia64/tls.h (tcbhead_t): Rename private member to __private.
1351         * sysdeps/ia64/tcb-offsets.sym: Adjust for private->__private
1352         rename in tcbhead_t.
1353
1354         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
1355         Don't give the union a name because it changes the mangled name.
1356         Instead name the struct for __data.
1357         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
1358         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
1359         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
1360         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
1361         * pthread_create.c (start_thread): Adjust robust mutex free loop.
1362         * descr.h (ENQUEUE_MUTEX, DEQUEUE_MUTEX): Adjust.
1363
1364 2006-01-05  Ulrich Drepper  <drepper@redhat.com>
1365
1366         * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait):
1367         Return status.
1368         (lll_futex_timed_wait): Define.
1369         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
1370         * sysdeps/pthread/aio_misc.h: New file.
1371
1372 2006-01-03  Joseph S. Myers  <joseph@codesourcery.com>
1373
1374         * Makefile ($(objpfx)$(multidir)): Use mkdir -p.
1375
1376 2006-01-03  Steven Munroe  <sjmunroe@us.ibm.com>
1377
1378         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
1379         (PSEUDO): Remove redundant cfi_startproc and cfi_endproc directives.
1380         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
1381
1382 2006-01-04  Ulrich Drepper  <drepper@redhat.com>
1383
1384         * tst-cancel24.cc: Use C headers instead of C++ headers.
1385
1386 2006-01-03  Jakub Jelinek  <jakub@redhat.com>
1387
1388         * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Remove #error for
1389         sparc-linux configured glibc.
1390         (lll_futex_wake_unlock): Define to 1 for sparc-linux configured glibc.
1391         (__lll_mutex_trylock, __lll_mutex_cond_trylock, __lll_mutex_lock,
1392         __lll_mutex_cond_lock, __lll_mutex_timedlock): Use
1393         atomic_compare_and_exchange_val_24_acq instead of
1394         atomic_compare_and_exchange_val_acq.
1395         (lll_mutex_unlock, lll_mutex_unlock_force): Use atomic_exchange_24_rel
1396         instead of atomic_exchange_rel.
1397         * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c: New file.
1398         * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_init.c: New
1399         file.
1400         * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_wait.c: New
1401         file.
1402         * sysdeps/unix/sysv/linux/sparc/sparc32/sem_init.c: New file.
1403         * sysdeps/unix/sysv/linux/sparc/sparc32/sem_post.c: New file.
1404         * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c: New file.
1405         * sysdeps/unix/sysv/linux/sparc/sparc32/sem_trywait.c: New file.
1406         * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c: New file.
1407         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_init.c:
1408         New file.
1409         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
1410         New file.
1411         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_init.c: New file.
1412         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_post.c: New file.
1413         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_timedwait.c: New
1414         file.
1415         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_trywait.c: New
1416         file.
1417         * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_wait.c: New file.
1418
1419 2006-01-03  Ulrich Drepper  <drepper@redhat.com>
1420
1421         * sysdeps/pthread/pthread.h [__WORDSIZE==64]: Don't use cast in
1422         mutex initializers.
1423
1424 2006-01-02  Jakub Jelinek  <jakub@redhat.com>
1425
1426         * sysdeps/sparc/tls.h (tcbhead_t): Add pointer_guard field.
1427         (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
1428         THREAD_COPY_POINTER_GUARD): Define.
1429         * sysdeps/sparc/tcb-offsets.sym (POINTER_GUARD): Define.
1430         * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Revert 2005-12-27 changes.
1431
1432 2006-01-01  Ulrich Drepper  <drepper@redhat.com>
1433
1434         * version.c: Update copyright year.
1435
1436 2005-12-29  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1437
1438         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Remove explicit
1439         .eh_frame section, use cfi_* directives.
1440         * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Add cfi instrumentation.
1441
1442 2005-12-30  Ulrich Drepper  <drepper@redhat.com>
1443
1444         * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Undo last change for
1445         now.
1446
1447 2005-12-29  Ulrich Drepper  <drepper@redhat.com>
1448
1449         * sysdeps/pthread/sigaction.c: Removed.
1450         * sigaction.c: New file.
1451         * sysdeps/unix/sysv/linux/Makefile: Define CFLAGS-sigaction.c.
1452
1453 2005-12-28  Ulrich Drepper  <drepper@redhat.com>
1454
1455         * Makefile (tests): Add tst-signal7.
1456         * tst-signal7.c: New file.
1457
1458 2005-12-27  Roland McGrath  <roland@redhat.com>
1459
1460         * sysdeps/x86_64/jmpbuf-unwind.h (_jmpbuf_sp): New inline function.
1461         (_JMPBUF_UNWINDS_ADJ): Use it, to PTR_DEMANGLE before comparison.
1462         * sysdeps/alpha/jmpbuf-unwind.h: Likewise.
1463         * sysdeps/i386/jmpbuf-unwind.h: Likewise.
1464         * sysdeps/mips/jmpbuf-unwind.h: Likewise.
1465         * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
1466         * sysdeps/s390/jmpbuf-unwind.h: Likewise.
1467         * sysdeps/sh/jmpbuf-unwind.h: Likewise.
1468         * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
1469         * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Likewise.
1470         * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
1471
1472 2005-12-27  Jakub Jelinek  <jakub@redhat.com>
1473
1474         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Add __next
1475         and __prev field to pthread_mutex_t.
1476         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
1477         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
1478         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
1479         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
1480         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Add __next field
1481         to pthread_mutex_t.
1482
1483 2005-12-26  Ulrich Drepper  <drepper@redhat.com>
1484
1485         * pthreadP.h: Define PTHREAD_MUTEX_ROBUST_PRIVATE_NP,
1486         PTHREAD_MUTEX_ROBUST_PRIVATE_RECURSIVE_NP,
1487         PTHREAD_MUTEX_ROBUST_PRIVATE_ERRORCHECK_NP,
1488         PTHREAD_MUTEX_ROBUST_PRIVATE_ADAPTIVE_NP,
1489         PTHREAD_MUTEXATTR_FLAG_ROBUST, PTHREAD_MUTEXATTR_FLAG_PSHARED,
1490         and PTHREAD_MUTEXATTR_FLAG_BITS.
1491         * descr.h (struct pthread): Add robust_list field and define
1492         ENQUEUE_MUTEX and DEQUEUE_MUTEX macros.
1493         * pthread_mutexattr_getrobust.c: New file.
1494         * pthread_mutexattr_setrobust.c: New file.
1495         * pthread_mutex_consistent.c: New file.
1496         * sysdeps/pthread/pthread.h: Declare pthread_mutexattr_getrobust,
1497         pthread_mutexattr_setrobust, and pthread_mutex_consistent.
1498         Define PTHREAD_MUTEX_STALLED_NP and PTHREAD_MUTEX_ROBUST_NP.
1499         Adjust pthread_mutex_t initializers.
1500         * nptl/sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Add __next
1501         field to pthread_mutex_t.
1502         * nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Add __next
1503         and __prev field to pthread_mutex_t.
1504         * Versions [GLIBC_2.4]: Export pthread_mutexattr_getrobust_np,
1505         pthread_mutexattr_setrobust_np, and pthread_mutex_consistent_np.
1506         * pthread_mutexattr_getpshared.c: Use PTHREAD_MUTEXATTR_FLAG_PSHARED
1507         and PTHREAD_MUTEXATTR_FLAG_BITS macros instead of magic numbers.
1508         * pthread_mutexattr_gettype.c: Likewise.
1509         * pthread_mutexattr_setpshared.c: Likewise.
1510         * pthread_mutexattr_settype.c: Likewise.
1511         * pthread_mutex_init.c: Reject robust+pshared attribute for now.
1512         Initialize mutex kind according to robust flag.
1513         * pthread_mutex_lock.c: Implement local robust mutex.
1514         * pthread_mutex_timedlock.c: Likewise.
1515         * pthread_mutex_trylock.c: Likewise.
1516         * pthread_mutex_unlock.c: Likewise.
1517         * pthread_create.c (start_thread): Mark robust mutexes which remained
1518         locked as dead.
1519         * tst-robust1.c: New file.
1520         * tst-robust2.c: New file.
1521         * tst-robust3.c: New file.
1522         * tst-robust4.c: New file.
1523         * tst-robust5.c: New file.
1524         * tst-robust6.c: New file.
1525         * tst-robust7.c: New file.
1526         * Makefile (libpthread-routines): Add pthread_mutexattr_getrobust,
1527         pthread_mutexattr_setrobust, and pthread_mutex_consistent.
1528         (tests): Add tst-robust1, tst-robust2, tst-robust3, tst-robust4,
1529         tst-robust5, tst-robust6, and tst-robust7.
1530
1531         * tst-typesizes.c: New file.
1532         * Makefile (tests): Add tst-typesizes.
1533
1534         * tst-once3.c: More debug output.
1535
1536 2005-12-24  Ulrich Drepper  <drepper@redhat.com>
1537
1538         * pthread_mutex_trylock.c (__pthread_mutex_trylock): Add break
1539         missing after last change.
1540
1541         * version.c: Update copyright year.
1542
1543 2005-12-23  Ulrich Drepper  <drepper@redhat.com>
1544
1545         * pthread_mutex_destroy.c: Set mutex type to an invalid value.
1546         * pthread_mutex_lock.c: Return EINVAL for invalid mutex type.
1547         * pthread_mutex_trylock.c: Likewise.
1548         * pthread_mutex_timedlock.c: Likewise.
1549         * pthread_mutex_unlock.c: Likewise.
1550
1551 2005-12-22  Roland McGrath  <roland@redhat.com>
1552
1553         * sysdeps/pthread/sigaction.c: Use "" instead of <> to include self,
1554         so that #include_next's search location is not reset to the -I..
1555         directory where <nptl/...> can be found.
1556
1557 2005-12-22  Ulrich Drepper  <drepper@redhat.com>
1558
1559         [BZ #1913]
1560         * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
1561         Fix unwind info.  Remove useless branch prediction prefix.
1562         * tst-cancel24.cc: New file.
1563         * Makefile: Add rules to build and run tst-cancel24.
1564
1565 2005-12-21  Roland McGrath  <roland@redhat.com>
1566
1567         * libc-cancellation.c: Use <> rather than "" #includes.
1568         * pt-cleanup.c: Likewise.
1569         * pthread_create.c: Likewise.
1570         * pthread_join.c: Likewise.
1571         * pthread_timedjoin.c: Likewise.
1572         * pthread_tryjoin.c: Likewise.
1573         * sysdeps/unix/sysv/linux/libc_pthread_init.c: Likewise.
1574         * sysdeps/unix/sysv/linux/register-atfork.c: Likewise.
1575         * sysdeps/unix/sysv/linux/unregister-atfork.c: Likewise.
1576         * unwind.c: Likewise.
1577
1578 2005-12-19  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1579
1580         * sysdeps/sh/tcb-offsets.sym: Add POINTER_GUARD.
1581         * sysdeps/sh/tls.h (tcbhead_t): Remove private and add pointer_guard.
1582         (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
1583         THREAD_COPY_POINTER_GUARD): Define.
1584
1585 2005-12-19  Jakub Jelinek  <jakub@redhat.com>
1586
1587         * sysdeps/ia64/tls.h (TLS_PRE_TCB_SIZE): Make room for 2 uintptr_t's
1588         rather than one.
1589         (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
1590         THREAD_COPY_POINTER_GUARD): Define.
1591         * sysdeps/powerpc/tcb-offsets.sym (POINTER_GUARD): Add.
1592         * sysdeps/powerpc/tls.h (tcbhead_t): Add pointer_guard field.
1593         (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
1594         THREAD_COPY_POINTER_GUARD): Define.
1595         * sysdeps/s390/tcb-offsets.sym (STACK_GUARD): Add.
1596         * sysdeps/s390/tls.h (THREAD_GET_POINTER_GUARD,
1597         THREAD_SET_POINTER_GUARD, THREAD_COPY_POINTER_GUARD): Define.
1598         * sysdeps/unix/sysv/linux/ia64/__ia64_longjmp.S (__ia64_longjmp):
1599         Use PTR_DEMANGLE for B0 if defined.
1600
1601 2005-12-17  Ulrich Drepper  <drepper@redhat.com>
1602
1603         * pthread_create.c (__pthread_create_2_1): Use
1604         THREAD_COPY_POINTER_GUARD if available.
1605         * sysdeps/i386/tcb-offsets.sym: Add POINTER_GUARD.
1606         * sysdeps/x86_64/tcb-offsets.sym: Likewise.
1607         * sysdeps/i386/tls.h (tcbhead_t): Add pointer_guard.
1608         Define THREAD_SET_POINTER_GUARD and THREAD_COPY_POINTER_GUARD.
1609         * sysdeps/x86_64/tls.h: Likewise.
1610
1611 2005-12-15  Roland McGrath  <roland@redhat.com>
1612
1613         * sysdeps/unix/sysv/linux/mq_notify.c: Don't use sysdeps/generic.
1614
1615 2005-12-13  Ulrich Drepper  <drepper@redhat.com>
1616
1617         * sysdeps/pthread/sigfillset.c: Adjust for files moved out of
1618         sysdeps/generic.
1619         * errno-loc.c: New file.
1620
1621 2005-12-12  Roland McGrath  <roland@redhat.com>
1622
1623         * init.c (__pthread_initialize_minimal_internal): Do __static_tls_size
1624         adjustments before choosing stack size.  Update minimum stack size
1625         calculation to match allocate_stack change.
1626
1627 2005-12-12  Ulrich Drepper  <drepper@redhat.com>
1628
1629         * allocatestack.c (allocate_stack): Don't demand that there is an
1630         additional full page available on the stack beside guard, TLS, the
1631         minimum stack.
1632
1633 2005-11-24  Ulrich Drepper  <drepper@redhat.com>
1634
1635         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h
1636         (__cleanup_fct_attribute): Use __regparm__ not regparm.
1637
1638         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: When
1639         compiling 32-bit code we must define __cleanup_fct_attribute.
1640
1641 005-11-24  Jakub Jelinek  <jakub@redhat.com>
1642
1643         [BZ #1920]
1644         * sysdeps/pthread/pthread.h (__pthread_unwind_next): Use
1645         __attribute__ instead of __attribute.
1646         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h
1647         (__cleanup_fct_attribute): Likewise.
1648
1649 2005-11-17  Jakub Jelinek  <jakub@redhat.com>
1650
1651         * sysdeps/pthread/unwind-forcedunwind.c (pthread_cancel_init): Put
1652         a write barrier before writing libgcc_s_getcfa.
1653
1654 2005-11-06  Ulrich Drepper  <drepper@redhat.com>
1655
1656         * sysdeps/unix/sysv/linux/configure: Removed.
1657
1658 2005-11-05  Ulrich Drepper  <drepper@redhat.com>
1659
1660         * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Remove trace of
1661         optional init_array/fini_array support.
1662
1663 2005-10-24  Roland McGrath  <roland@redhat.com>
1664
1665         * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Remove unnecessary
1666         versioned_symbol use.
1667
1668 2005-10-16  Roland McGrath  <roland@redhat.com>
1669
1670         * init.c (__pthread_initialize_minimal_internal): Even when using a
1671         compile-time default stack size, apply the minimum that allocate_stack
1672         will require, and round up to page size.
1673
1674 2005-10-10  Daniel Jacobowitz  <dan@codesourcery.com>
1675
1676         * Makefile ($(test-modules)): Remove static pattern rule.
1677
1678 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
1679             Ulrich Drepper  <drepper@redhat.com>
1680
1681         * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Fix stack
1682         alignment in callback function.
1683         * Makefile: Add rules to build and run tst-align3.
1684         * tst-align3.c: New file.
1685
1686 2005-10-03  Jakub Jelinek  <jakub@redhat.com>
1687
1688         * allocatestack.c (setxid_signal_thread): Add
1689         INTERNAL_SYSCALL_DECL (err).
1690
1691 2005-10-02  Jakub Jelinek  <jakub@redhat.com>
1692
1693         * allocatestack.c (setxid_signal_thread): Need to use
1694         atomic_compare_and_exchange_bool_acq.
1695
1696 2005-10-01  Ulrich Drepper  <drepper@redhat.com>
1697             Jakub Jelinek  <jakub@redhat.com>
1698
1699         * descr.h: Define SETXID_BIT and SETXID_BITMASK.  Adjust
1700         CANCEL_RESTMASK.
1701         (struct pthread): Move specific_used field to avoid padding.
1702         Add setxid_futex field.
1703         * init.c (sighandler_setxid): Reset setxid flag and release the
1704         setxid futex.
1705         * allocatestack.c (setxid_signal_thread): New function.  Broken
1706         out of the bodies of the two loops in __nptl_setxid.  For undetached
1707         threads check whether they are exiting and if yes, don't send a signal.
1708         (__nptl_setxid): Simplify loops by using setxid_signal_thread.
1709         * pthread_create.c (start_thread): For undetached threads, check
1710         whether setxid bit is set.  If yes, wait until signal has been
1711         processed.
1712
1713         * allocatestack.c (STACK_VARIABLES): Initialize them.
1714         * pthread_create.c (__pthread_create_2_1): Initialize pd.
1715
1716 2004-09-02  Jakub Jelinek  <jakub@redhat.com>
1717
1718         * pthread_cond_destroy.c (__pthread_cond_destroy): If there are
1719         waiters, awake all waiters on the associated mutex.
1720
1721 2005-09-22  Roland McGrath  <roland@redhat.com>
1722
1723         * perf.c [__x86_64__] (HP_TIMING_NOW): New macro (copied from
1724         ../sysdeps/x86_64/hp-timing.h).
1725
1726 2005-08-29  Jakub Jelinek  <jakub@redhat.com>
1727
1728         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_WAKE_OP,
1729         FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
1730         (lll_futex_wake_unlock): Define.
1731         * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_WAKE_OP,
1732         FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
1733         (lll_futex_wake_unlock): Define.
1734         * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_WAKE_OP,
1735         FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
1736         (lll_futex_wake_unlock): Define.
1737         * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_WAKE_OP,
1738         FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
1739         (lll_futex_wake_unlock): Define.
1740         * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_WAKE_OP,
1741         FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
1742         (lll_futex_wake_unlock): Define.
1743         * sysdeps/pthread/pthread_cond_signal.c (__pthread_cond_signal): Use
1744         lll_futex_wake_unlock.
1745         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
1746         (FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
1747         (__pthread_cond_signal): Use FUTEX_WAKE_OP.
1748         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
1749         (FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
1750         (__pthread_cond_signal): Use FUTEX_WAKE_OP.
1751
1752 2005-09-05  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
1753
1754         * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_mutex_lock_wait):
1755         Fix typo in register name.
1756
1757 2005-08-23  Ulrich Drepper  <drepper@redhat.com>
1758
1759         * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
1760         Use __sigfillset.  Document that sigfillset does the right thing wrt
1761         to SIGSETXID.
1762
1763 2005-07-11  Jakub Jelinek  <jakub@redhat.com>
1764
1765         [BZ #1102]
1766         * sysdeps/pthread/pthread.h (PTHREAD_MUTEX_INITIALIZER,
1767         PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP,
1768         PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP,
1769         PTHREAD_MUTEX_ADAPTIVE_NP, PTHREAD_RWLOCK_INITIALIZER,
1770         PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP,
1771         PTHREAD_COND_INITIALIZER): Supply zeros for all fields
1772         in the structure.
1773         * Makefile (tests): Add tst-initializers1.
1774         (CFLAGS-tst-initializers1.c): Set.
1775         * tst-initializers1.c: New test.
1776
1777 2005-07-11  Jakub Jelinek  <jakub@redhat.com>
1778
1779         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_rwlock_t):
1780         Make sure __flags are located at offset 48 from the start of the
1781         structure.
1782
1783 2005-07-02  Roland McGrath  <roland@redhat.com>
1784
1785         * Makeconfig: Comment fix.
1786
1787 2005-07-05  Jakub Jelinek  <jakub@redhat.com>
1788
1789         * descr.h (PTHREAD_STRUCT_END_PADDING): Define.
1790         * sysdeps/ia64/tls.h (TLS_PRE_TCB_SIZE): If PTHREAD_STRUCT_END_PADDING
1791         is smaller than 8 bytes, increase TLS_PRE_TCB_SIZE by 16 bytes.
1792         (THREAD_SYSINFO, THREAD_SELF, DB_THREAD_SELF): Don't assume
1793         TLS_PRE_TCB_SIZE is sizeof (struct pthread).
1794         (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
1795         * sysdeps/ia64/tcb-offsets.sym (PID, TID, MULTIPLE_THREADS_OFFSET):
1796         Use TLS_PRE_TCB_SIZE instead of sizeof (struct pthread).
1797         * sysdeps/unix/sysv/linux/ia64/createthread.c (TLS_VALUE): Don't
1798         assume TLS_PRE_TCB_SIZE is sizeof (struct pthread).
1799
1800 2005-06-25  Jakub Jelinek  <jakub@redhat.com>
1801
1802         * sysdeps/i386/tls.h (tcbhead_t): Add stack_guard field.
1803         (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
1804         * sysdeps/x86_64/tls.h (tcbhead_t): Add sysinfo and stack_guard
1805         fields.
1806         (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
1807         * sysdeps/s390/tls.h (tcbhead_t): Add stack_guard
1808         field.  Put in sysinfo field unconditionally.
1809         (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
1810         * sysdeps/powerpc/tls.h (tcbhead_t): Add stack_guard field.
1811         (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
1812         * sysdeps/sparc/tls.h (tcbhead_t): Add sysinfo and stack_guard
1813         fields.
1814         (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
1815         * pthread_create.c (__pthread_create_2_1): Use
1816         THREAD_COPY_STACK_GUARD macro.
1817         * Makefile: Add rules to build and run tst-stackguard1{,-static}
1818         tests.
1819         * tst-stackguard1.c: New file.
1820         * tst-stackguard1-static.c: New file.
1821
1822 2005-06-14  Alan Modra  <amodra@bigpond.net.au>
1823
1824         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (PSEUDO):
1825         Invoke CGOTSETUP and CGOTRESTORE.
1826         (CGOTSETUP, CGOTRESTORE): Define.
1827
1828 2005-05-29  Richard Henderson  <rth@redhat.com>
1829
1830         * tst-cancel4.c (WRITE_BUFFER_SIZE): New.
1831         (tf_write, tf_writev): Use it.
1832         (do_test): Use socketpair instead of pipe.  Set SO_SNDBUF to
1833         the system minimum.
1834
1835 2005-05-23  Jakub Jelinek  <jakub@redhat.com>
1836
1837         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
1838         [IS_IN_librt] (CENABLE, CDISABLE): Use JUMPTARGET instead of
1839         __librt_*_asynccancel@local.
1840
1841 2005-05-17  Alan Modra  <amodra@bigpond.net.au>
1842
1843         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Delete
1844         all occurrences of JUMPTARGET.  Instead append @local to labels.
1845
1846 2005-05-20  Jakub Jelinek  <jakub@redhat.com>
1847
1848         * sysdeps/i386/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN): Define to
1849         size/alignment of struct pthread rather than tcbhead_t.
1850         * sysdeps/x86_64/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
1851         Likewise.
1852         * sysdeps/s390/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
1853         Likewise.
1854         * sysdeps/sparc/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
1855         Likewise.
1856
1857 2005-05-19  Richard Henderson  <rth@redhat.com>
1858
1859         * sysdeps/ia64/pthread_spin_lock.c (pthread_spin_lock): Use
1860         __sync_val_compare_and_swap, not explicit _si variant.
1861         * sysdeps/ia64/pthread_spin_trylock.c (pthread_spin_trylock): Likewise.
1862
1863 2005-05-03  Ulrich Drepper  <drepper@redhat.com>
1864
1865         [BZ #915]
1866         * sysdeps/pthread/pthread.h: Avoid empty initializers.
1867
1868 2005-05-03  Jakub Jelinek  <jakub@redhat.com>
1869
1870         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Remove explicit
1871         .eh_frame section, use cfi_* directives.
1872
1873 2005-04-27  Jakub Jelinek  <jakub@redhat.com>
1874
1875         * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c: Use <> instead
1876         of "" includes.
1877
1878 2005-04-27  Ulrich Drepper  <drepper@redhat.com>
1879
1880         [BZ #1075]
1881         * tst-cancel17.c (do_test): Add arbitrary factor to make sure
1882         aio_write blocks.
1883
1884 2005-04-27  Roland McGrath  <roland@redhat.com>
1885
1886         * Makefile (tests): Remove tst-clock2.
1887
1888         * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Handle
1889         CLOCK_PROCESS_CPUTIME_ID and CLOCK_PROCESS_THREAD_ID specially,
1890         translating to the kernel clockid_t for our own process/thread clock.
1891
1892         * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c: New file.
1893
1894 2005-04-15  Jakub Jelinek  <jakub@redhat.com>
1895
1896         * old_pthread_cond_init.c: Include <errno.h>.
1897         (__pthread_cond_init_2_0): Fail with EINVAL if COND_ATTR is
1898         process shared or uses clock other than CLOCK_REALTIME.
1899         * pthread_cond_init.c (__pthread_cond_init): Remove bogus comment.
1900
1901 2005-04-13  David S. Miller  <davem@davemloft.net>
1902
1903         * sysdeps/sparc/sparc64/jmpbuf-unwind.h: New file.
1904         * sysdeps/sparc/sparc64/clone.S: New file.
1905
1906 2005-04-05  Jakub Jelinek  <jakub@redhat.com>
1907
1908         [BZ #1102]
1909         * sysdeps/pthread/pthread.h (__pthread_cleanup_routine): Use
1910         __inline instead of inline.
1911         * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_routine): Likewise.
1912
1913 2005-03-31  Jakub Jelinek  <jakub@redhat.com>
1914
1915         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Use
1916         functionally equivalent, but shorter instructions.
1917         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
1918         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
1919         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
1920         Likewise.
1921         * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise.
1922         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
1923         * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
1924         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
1925         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
1926         * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
1927         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
1928         Likewise.
1929         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
1930         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
1931         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
1932         * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
1933         * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
1934
1935 2005-03-28  Daniel Jacobowitz  <dan@codesourcery.com>
1936
1937         * sysdeps/mips/Makefile: New file.
1938         * sysdeps/mips/nptl-sysdep.S: New file.
1939         * sysdeps/mips/tcb-offsets.sym: New file.
1940         * sysdeps/mips/pthread_spin_lock.S: New file.
1941         * sysdeps/mips/pthread_spin_trylock.S: New file.
1942         * sysdeps/mips/pthreaddef.h: New file.
1943         * sysdeps/mips/tls.h: New file.
1944         * sysdeps/mips/jmpbuf-unwind.h: New file.
1945         * sysdeps/unix/sysv/linux/mips/lowlevellock.h: New file.
1946         * sysdeps/unix/sysv/linux/mips/bits/pthreadtypes.h: New file.
1947         * sysdeps/unix/sysv/linux/mips/bits/semaphore.h: New file.
1948         * sysdeps/unix/sysv/linux/mips/pthread_once.c: New file.
1949         * sysdeps/unix/sysv/linux/mips/fork.c: New file.
1950         * sysdeps/unix/sysv/linux/mips/pt-vfork.S: New file.
1951         * sysdeps/unix/sysv/linux/mips/vfork.S: New file.
1952         * sysdeps/unix/sysv/linux/mips/clone.S: New file.
1953         * sysdeps/unix/sysv/linux/mips/createthread.c: New file.
1954         * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h: New file.
1955
1956 2005-03-23  Ulrich Drepper  <drepper@redhat.com>
1957
1958         [BZ #1112]
1959         * pthread_create.c (__pthread_create_2_1): Rename syscall error
1960         variable to scerr.
1961
1962 2005-03-10  Jakub Jelinek  <jakub@redhat.com>
1963
1964         * tst-getpid1.c (do_test): Align stack passed to clone{2,}.
1965
1966 2005-02-25  Roland McGrath  <roland@redhat.com>
1967
1968         * alloca_cutoff.c: Correct license text.
1969         * tst-unload.c: Likewise.
1970         * sysdeps/pthread/allocalim.h: Likewise.
1971         * sysdeps/pthread/pt-initfini.c: Likewise.
1972         * sysdeps/pthread/bits/libc-lock.h: Likewise.
1973         * sysdeps/pthread/bits/sigthread.h: Likewise.
1974         * sysdeps/unix/sysv/linux/bits/local_lim.h: Likewise.
1975         * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
1976
1977 2005-02-16  Roland McGrath  <roland@redhat.com>
1978
1979         * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
1980         Use unsigned int * for ptr_nthreads.
1981
1982 2005-02-14  Alan Modra  <amodra@bigpond.net.au>
1983
1984         [BZ #721]
1985         * sysdeps/powerpc/tcb-offsets.sym (thread_offsetof): Redefine to suit
1986         gcc4.
1987
1988 2005-02-07  Richard Henderson  <rth@redhat.com>
1989
1990         [BZ #787]
1991         * sysdeps/pthread/pthread.h (__sigsetjmp): Use pointer as first
1992         argument.
1993
1994 2004-11-03  Marcus Brinkmann  <marcus@gnu.org>
1995
1996         * sysdeps/generic/lowlevellock.h (__generic_mutex_unlock): Fix
1997         order of arguments in invocation of atomic_add_zero.
1998
1999 2005-01-26  Jakub Jelinek  <jakub@redhat.com>
2000
2001         [BZ #737]
2002         * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S (__new_sem_trywait):
2003         Use direct %gs segment access or, if NO_TLS_DIRECT_SEG_REFS,
2004         at least gotntpoff relocation and addition.
2005         * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
2006         Likewise.
2007         * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__new_sem_post):
2008         Likewise.
2009         * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
2010         Likewise.
2011
2012 2005-01-06  Ulrich Drepper  <drepper@redhat.com>
2013
2014         * allocatestack.c (init_one_static_tls): Adjust initialization of DTV
2015         entry for static tls deallocation fix.
2016         * sysdeps/alpha/tls.h (dtv_t): Change pointer type to be struct which
2017         also contains information whether the memory pointed to is static
2018         TLS or not.
2019         * sysdeps/i386/tls.h: Likewise.
2020         * sysdeps/ia64/tls.h: Likewise.
2021         * sysdeps/powerpc/tls.h: Likewise.
2022         * sysdeps/s390/tls.h: Likewise.
2023         * sysdeps/sh/tls.h: Likewise.
2024         * sysdeps/sparc/tls.h: Likewise.
2025         * sysdeps/x86_64/tls.h: Likewise.
2026
2027 2004-12-27  Ulrich Drepper  <drepper@redhat.com>
2028
2029         * init.c (__pthread_initialize_minimal_internal): Use __sigemptyset.
2030
2031 2004-12-21  Jakub Jelinek  <jakub@redhat.com>
2032
2033         * sysdeps/i386/tls.h (CALL_THREAD_FCT): Maintain 16 byte alignment of
2034         %esp.
2035         * Makefile (tests): Add tst-align2.
2036         * tst-align2.c: New test.
2037         * sysdeps/i386/Makefile (CFLAGS-tst-align{,2}.c): Add
2038         -mpreferred-stack-boundary=4.
2039
2040 2004-12-18  Roland McGrath  <roland@redhat.com>
2041
2042         * sysdeps/unix/sysv/linux/powerpc/powerpc64/bits/local_lim.h:
2043         New file removed withdrawn for the moment.
2044
2045 2004-12-17  Richard Henderson  <rth@redhat.com>
2046
2047         * sysdeps/unix/sysv/linux/alpha/clone.S: New file.
2048         * sysdeps/alpha/tcb-offsets.sym (TID_OFFSET): New.
2049
2050 2004-12-16  Ulrich Drepper  <drepper@redhat.com>
2051
2052         * sysdeps/unix/sysv/linux/powerpc/powerpc64/bits/local_lim.h: New file.
2053         Increased PTHREAD_STACK_MIN.
2054
2055         * tst-context1.c (stacks): Use bigger stack size.
2056
2057 2004-12-16  Jakub Jelinek  <jakub@redhat.com>
2058
2059         * sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: New file.
2060         * sysdeps/sparc/tcb-offsets.sym: Add TID.
2061
2062 2004-12-15  Jakub Jelinek  <jakub@redhat.com>
2063
2064         * sysdeps/unix/sysv/linux/s390/s390-32/clone.S: New file.
2065         * sysdeps/unix/sysv/linux/s390/s390-64/clone.S: New file.
2066         * sysdeps/s390/tcb-offsets.sym (TID): Add.
2067
2068 2004-12-15  Ulrich Drepper  <drepper@redhat.com>
2069
2070         * sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S: New file.
2071
2072 2004-12-14  Ulrich Drepper  <drepper@redhat.com>
2073
2074         * sysdeps/powerpc/tcb-offsets.sym: Add TID.
2075         * sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S: New file.
2076
2077         * tst-getpid1.c: If child crashes, report this first.  Print which
2078         signal.
2079
2080 2004-12-09  Ulrich Drepper  <drepper@redhat.com>
2081
2082         * init.c (__pthread_initialize_minimal_internal): Also unblock
2083         SIGSETXID.
2084
2085 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
2086
2087         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_CPUTIME,
2088         _POSIX_THREAD_CPUTIME): Define to 0.
2089         * sysdeps/pthread/timer_create.c (timer_create): Remove unused code
2090         handling CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID.
2091         * sysdeps/pthread/timer_routines.c (__timer_signal_thread_pclk,
2092         __timer_signal_thread_tclk): Remove.
2093         (init_module): Remove their initialization.
2094         (thread_cleanup): Remove their cleanup assertions.
2095         * sysdeps/pthread/posix-timer.h (__timer_signal_thread_pclk,
2096         __timer_signal_thread_tclk): Remove.
2097         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Removed.
2098         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Removed.
2099         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Removed.
2100
2101 2004-12-07  Jakub Jelinek  <jakub@redhat.com>
2102
2103         * sysdeps/ia64/tcb-offsets.sym (TID): Add.
2104         * sysdeps/unix/sysv/linux/ia64/clone2.S: New file.
2105
2106         * Makefile (tests): Add tst-getpid2.
2107         * tst-getpid1.c (TEST_CLONE_FLAGS): Define.
2108         (do_test): Use it.  Use __clone2 instead of clone on ia64.
2109         * tst-getpid2.c: New test.
2110
2111 2004-12-07  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2112
2113         * sysdeps/unix/sysv/linux/sh/clone.S: New file.
2114
2115 2004-12-04  Ulrich Drepper  <drepper@redhat.com>
2116
2117         * Makefile (tests): Add tst-getpid1.
2118         * tst-getpid1.c: New file.
2119         * sysdeps/unix/sysv/linux/i386/clone.S: New file.
2120         * sysdeps/unix/sysv/linux/x86_64/clone.S: New file.
2121
2122 2004-12-02  Roland McGrath  <roland@redhat.com>
2123
2124         * Makefile (libpthread-nonshared): Variable removed.
2125         ($(objpfx)libpthread_nonshared.a): Target removed.
2126         ($(inst_libdir)/libpthread_nonshared.a): Likewise.
2127         These are now handled by generic magic from
2128         libpthread-static-only-routines being set.
2129
2130 2004-11-27  Ulrich Drepper  <drepper@redhat.com>
2131
2132         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_PRIORITIZED_IO,
2133         _POSIX2_CHAR_TERM, _POSIX_THREAD_PRIO_INHERIT,
2134         _POSIX_THREAD_PRIO_PROTECT): Define.
2135         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
2136         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
2137         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
2138
2139 2004-11-26  Jakub Jelinek  <jakub@redhat.com>
2140
2141         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_ADVISORY_INFO,
2142         _POSIX_SPORADIC_SERVER, _POSIX_THREAD_SPORADIC_SERVER, _POSIX_TRACE,
2143         _POSIX_TRACE_EVENT_FILTER, _POSIX_TRACE_INHERIT, _POSIX_TRACE_LOG,
2144         _POSIX_TYPED_MEMORY_OBJECTS, _POSIX_IPV6, _POSIX_RAW_SOCKETS): Define.
2145         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
2146         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
2147         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
2148
2149 2004-11-24  Ulrich Drepper  <drepper@redhat.com>
2150
2151         * sysdeps/x86_64/Makefile [nptl]: Define CFLAGS-pthread_create.c.
2152
2153         * Makefile (libpthread-routines): Add pthread_setschedprio.
2154         * Versions [libpthread, GLIBC_2.3.4]: Add pthread_setschedprio.
2155         * sysdeps/pthread/pthread.h: Declare pthread_setschedprio.
2156         * pthread_setschedprio.c: New file.
2157
2158 2004-11-20  Jakub Jelinek  <jakub@redhat.com>
2159
2160         * pthread_create.c (pthread_cancel): Add PTHREAD_STATIC_FN_REQUIRE.
2161         * pthread_cancel.c (pthread_create): Likewise.
2162
2163         * Makefile (libpthread-routines): Add vars.
2164         * sysdeps/pthread/createthread.c (__pthread_multiple_threads): Remove.
2165         * init.c (__default_stacksize, __is_smp): Remove.
2166         * vars.c: New file.
2167         * pthreadP.h (__find_thread_by_id): If !SHARED, add weak_function
2168         and define a wrapper macro.
2169         (PTHREAD_STATIC_FN_REQUIRE): Define.
2170         * allocatestack.c (__find_thread_by_id): Undefine.
2171         * pthread_create (__pthread_keys): Remove.
2172         (pthread_mutex_lock, pthread_mutex_unlock, pthread_once,
2173         pthread_key_create, pthread_setspecific, pthread_getspecific): Add
2174         PTHREAD_STATIC_FN_REQUIRE.
2175
2176 2004-11-18  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2177
2178         * sysdeps/sh/tls.h (DB_THREAD_SELF): Set the correct bias
2179         parameter to REGISTER macro.
2180
2181 2004-11-17  Roland McGrath  <roland@redhat.com>
2182
2183         * sysdeps/unix/sysv/linux/timer_routines.c (__start_helper_thread):
2184         Make sure SIGCANCEL is blocked as well.
2185
2186 2004-11-10  Jakub Jelinek  <jakub@redhat.com>
2187
2188         * sysdeps/pthread/setxid.h: New file.
2189         * sysdeps/pthread/pthread-functions.h (HAVE_PTR__NPTL_SETXID): Remove.
2190         (struct xid_command): Add forward decl.
2191         (struct pthread_functions): Change return type of __nptl_setxid hook
2192         to int.
2193         * pthreadP.h (__nptl_setxid): Change return type to int.
2194         * allocatestack.c (__nptl_setxid): Call INTERNAL_SYSCALL_NCS in the
2195         calling thread, return its return value and set errno on failure.
2196         * descr.h (struct xid_command): Change id type to long array.
2197
2198         * Makefile: Add rules to build and test tst-setuid1 and
2199         tst-setuid1-static.
2200         * tst-setuid1.c: New test.
2201         * tst-setuid1-static.c: New test.
2202
2203 2004-11-10  Jakub Jelinek  <jakub@redhat.com>
2204
2205         * Makefile (tests): Add tst-exit3.
2206         * tst-exit3.c: New test.
2207
2208 2004-11-09  Ulrich Drepper  <drepper@redhat.com>
2209
2210         * Makefile (tests): Add tst-exit2.
2211         * tst-exit2.c: New file.
2212
2213 2004-11-09  Roland McGrath  <roland@redhat.com>
2214
2215         [BZ #530]
2216         * sysdeps/pthread/createthread.c (do_clone): Increment __nptl_nthreads
2217         here, before calling clone.
2218         * pthread_create.c (start_thread): Don't do it here.
2219
2220 2004-11-02  Jakub Jelinek  <jakub@redhat.com>
2221
2222         * sysdeps/unix/sysv/linux/smp.h: Include <errno.h>.
2223
2224 2004-10-29  Kaz  Kojima  <kkojima@rr.iij4u.or.jp>
2225
2226         * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait):
2227         Set ETIMEDOUT to errno when time is up.  Tweak to avoid
2228         assembler warning.
2229
2230 2004-10-28  Jakub Jelinek  <jakub@redhat.com>
2231
2232         * pthread_create.c (__pthread_create_2_1): Avoid leaking stacks
2233         if sched_priority is not between minprio and maxprio.
2234
2235 2004-10-25  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2236
2237         * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
2238         (__pthread_cond_timedwait): Use clock_gettime syscall if exists.
2239
2240         * sysdeps/unix/sysv/linux/sh/lowlevellock.S
2241         (__lll_mutex_timedlock_wait): Fix a bad branch condition.
2242
2243 2004-10-24  Ulrich Drepper  <drepper@redhat.com>
2244
2245         * sysdeps/unix/sysv/linux/smp.h (is_smp_system): Use
2246         not-cancelable I/O functions.
2247
2248 2004-10-21  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2249
2250         * sysdeps/unix/sysv/linux/sh/lowlevellock.S
2251         (__lll_mutex_timedlock_wait): If woken but cannot get the lock,
2252         make sure 2 is stored in the futex and we looked at the old value.
2253         Fix a few other problems to return the correct value.
2254
2255 2004-10-14  Richard Henderson  <rth@redhat.com>
2256
2257         * sysdeps/alpha/tcb-offsets.sym (thread_offsetof): Redefine to
2258         make gcc4 happy.
2259
2260 2004-10-06  Jakub Jelinek  <jakub@redhat.com>
2261
2262         * sysdeps/unix/sysv/linux/jmp-unwind.c: Include pthreadP.h instead
2263         of pthread-functions.h and pthreaddef.h.
2264         * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Likewise.
2265
2266         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
2267         Change __data.__nwaiters from int to unsigned int.
2268
2269         * tst-clock2.c (do_test): Don't fail if _POSIX_THREAD_CPUTIME == 0 and
2270         sysconf (_SC_THREAD_CPUTIME) returns negative value.
2271
2272         * allocatestack.c (__find_thread_by_id): Move attribute_hidden
2273         before return type.
2274
2275         * sysdeps/s390/jmpbuf-unwind.h: Include bits/wordsize.h.
2276         (JMPBUF_CFA_UNWINDS_ADJ): Subtract 96 resp. 160 bytes from CFA.
2277
2278 2004-10-06  Ulrich Drepper  <drepper@redhat.com>
2279
2280         * tst-cancel4.c (tf_msgrcv): Check for failure in msgget.  If the
2281         test fails, remove message queue.
2282         (tf_msgsnd): Likewise.
2283
2284 2004-10-05  Jakub Jelinek  <jakub@redhat.com>
2285
2286         * tst-clock1.c: Change #ifdef to #if defined.
2287         * tst-clock2.c: Likewise.
2288         * tst-cond11.c: Likewise.
2289
2290         * sysdeps/pthread/timer_create.c (timer_create): Use
2291         defined _POSIX_CPUTIME && _POSIX_CPUTIME >= 0 instead of
2292         defined CLOCK_PROCESS_CPUTIME_ID #ifs and similarly for
2293         THREAD_CPUTIME.
2294
2295 2004-10-05  Jakub Jelinek  <jakub@redhat.com>
2296
2297         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h (_POSIX_CPUTIME,
2298         _POSIX_THREAD_CPUTIME): Define to 0.
2299
2300 2004-10-04  Ulrich Drepper  <drepper@redhat.com>
2301
2302         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Define _POSIX_CPUTIME
2303         and _POSIX_THREAD_CPUTIME to zero.
2304         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
2305         * tst-barrier2.c: Fix testing for POSIX feature.
2306         * tst-clock1.c: Likewise.
2307         * tst-clock2.c: Likewise.
2308         * tst-cond11.c: Likewise.
2309         * tst-cond4.c: Likewise.
2310         * tst-cond6.c: Likewise.
2311         * tst-flock2.c: Likewise.
2312         * tst-mutex4.c: Likewise.
2313         * tst-mutex9.c: Likewise.
2314         * tst-rwlock12.c: Likewise.
2315         * tst-rwlock4.c: Likewise.
2316         * tst-signal1.c: Likewise.
2317         * tst-spin2.c: Likewise.
2318         * sysdeps/pthread/posix-timer.h: Likewise.
2319         * sysdeps/pthread/timer_create.c: Likewise.
2320         * sysdeps/pthread/timer_routines.c: Likewise.
2321
2322 2004-10-01  Ulrich Drepper  <drepper@redhat.com>
2323
2324         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
2325         (__lll_mutex_timedlock_wait): Address futex correctly.
2326
2327         * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
2328         (__lll_mutex_timedlock_wait): If woken but cannot get the lock,
2329         make sure 2 is stored in the futex and we looked at the old value.
2330         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
2331         (__lll_mutex_timedlock_wait): Likewise.  Fix a few other problems
2332         which might very well made the code not working at all before.
2333         [BZ #417]
2334
2335 2004-09-28  Ulrich Drepper  <drepper@redhat.com>
2336
2337         * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): Don't
2338         allow SIGSETXID to be sent.
2339         * sysdeps/pthread/sigaction.c (__sigaction): Don't allow action
2340         for SIGSETXID to be defined.
2341         * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Make sure
2342         SIGSETXID cannot be blocked.
2343
2344         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
2345         Add __extension__ to long long types.
2346         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
2347         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
2348         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
2349         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
2350         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Likewise.
2351         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
2352         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
2353
2354 2004-09-25  Ulrich Drepper  <drepper@redhat.com>
2355
2356         * descr.h (struct pthread): Add stopped_start field.
2357         * sysdeps/pthread/createthread.c (create_thread): Set
2358         start_stopped flag in descriptor for new thread appropriately.
2359         * pthread_create.c (start_thread): Only take lock to be stopped on
2360         startup if stopped_start flag says so.
2361
2362 2004-09-24  Ulrich Drepper  <drepper@redhat.com>
2363
2364         * pthread_create.c (__pthread_create_2_1): Remember whether thread
2365         is created detached and if yes, do not try to free the stack in case
2366         the thread creation failed.
2367         * sysdeps/pthread/createthread.c (do_clone): Free stack here if clone
2368         call fails.  Don't depend on INTERNAL_SYSCALL_ERRNO return zero in
2369         case there has been no error.  [BZ #405]
2370
2371         * pthread_create.c (start_thread): Don't wait for scheduler data
2372         etc to be set at the beginning of the function.  The cancellation
2373         infrastructure must have been set up.  And enable async
2374         cancellation before potentially going to sleep.  [BZ #401]
2375
2376 2004-09-20  Ulrich Drepper  <drepper@redhat.com>
2377
2378         * Versions: Remove exports for pthread_set*id_np functions.
2379         * sysdeps/pthread/pthread.h: Remove pthread_set*id_np prototypes
2380         for now.
2381         * Makefile: Don't build pthread_set*id code for now.
2382
2383 2004-09-19  Ulrich Drepper  <drepper@redhat.com>
2384
2385         * sysdeps/unix/sysv/linux/allocrtsig.c: Allocate second signal for
2386         internal use.
2387         * allocatestack.c (__nptl_setxid): New function.
2388         * descr.h (struct xid_command): Define type.
2389         * init.c (pthread_functions): Add ptr__nptl_setxid initialization.
2390         (sighandler_setxid): New function.
2391         (__pthread_initialize_minimal): Register sighandler_setxid for
2392         SIGCANCEL.
2393         * pt-allocrtsig.c: Update comment.
2394         * pthreadP.h: Define SIGSETXID.  Declare __xidcmd variable.
2395         Declare __nptl_setxid.
2396         * sysdeps/pthread/pthread-functions.h: Add ptr__nptl_setxid.
2397         * sysdeps/pthread/pthread.h: Declare pthread_setgid_np,
2398         pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
2399         pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
2400         and pthread_setresuid_np.
2401         * pthread_setgid_np.c: New file.
2402         * pthread_setuid_np.c: New file.
2403         * pthread_setegid_np.c: New file.
2404         * pthread_seteuid_np.c: New file.
2405         * pthread_setregid_np.c: New file.
2406         * pthread_setreuid_np.c: New file.
2407         * pthread_setresgid_np.c: New file.
2408         * pthread_setresuid_np.c: New file.
2409         * Versions [libpthread, GLIBC_2.3.4]: Add pthread_setgid_np,
2410         pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
2411         pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
2412         and pthread_setresuid_np.
2413         * Makefile (libpthread-routines): Add pthread_setuid, pthread_seteuid,
2414         pthread_setreuid, pthread_setresuid, pthread_setgid, pthread_setegid,
2415         pthread_setregid, and pthread_setresgid.
2416
2417 2004-09-18  Ulrich Drepper  <drepper@redhat.com>
2418
2419         * allocatestack.c (allocate_stack): Return EAGAIN instead of
2420         ENOMEM when out of memory.
2421
2422 2004-09-10  Roland McGrath  <roland@redhat.com>
2423
2424         [BZ #379]
2425         * allocatestack.c (allocate_stack): Remove [__ASSUME_CLONE_STOPPED]
2426         code, since we don't try to use the broken CLONE_STOPPED any more.
2427         * pthread_create.c (start_thread): Likewise.
2428
2429 2004-09-15  Richard Henderson  <rth@redhat.com>
2430
2431         * sysdeps/unix/sysv/linux/alpha/vfork.S: Use libc_hidden_def.
2432
2433 2004-09-01  David Mosberger  <davidm@hpl.hp.com>
2434
2435         * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h
2436         (__libc_unwind_longjmp): Delete macro and declare as function.
2437         * sysdeps/unix/sysv/linux/ia64/Makefile (sysdep_routines): Mention
2438         __ia64_longjmp, sigstack_longjmp, and __sigstack_longjmp for
2439         nptl directory.
2440         * sysdeps/unix/sysv/linux/ia64/__ia64_longjmp.S: New file.
2441         * sysdeps/unix/sysv/linux/ia64/__sigstack_longjmp.c: New file.
2442         * sysdeps/unix/sysv/linux/ia64/unwind_longjmp.c: New file.
2443
2444 2004-09-12  Ulrich Drepper  <drepper@redhat.com>
2445
2446         * sysdeps/pthread/pthread.h: Make rwlock prototypes available also
2447         for __USE_XOPEN2K.
2448         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Define rwlock
2449         types also for __USE_XOPEN2K.
2450         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
2451         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
2452         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
2453         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
2454         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
2455         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
2456         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
2457         [BZ #320]
2458
2459 2004-09-08  Ulrich Drepper  <drepper@redhat.com>
2460
2461         * sysdeps/pthread/pthread.h
2462         (PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP): Make safe for C++.
2463         (PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP): Likewise.
2464         (PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP): Likewise.
2465         (PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP): Likewise.
2466         [BZ #375]
2467
2468 2004-09-07  Ulrich Drepper  <drepper@redhat.com>
2469
2470         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Allow
2471         PSEUDO to be used with . prefix.
2472
2473         * sysdeps/unix/sysv/linux/alpha/pthread_once.c (__pthread_once):
2474         Use atomic_increment instead of atomic_exchange_and_add.
2475         * sysdeps/unix/sysv/linux/sparc/pthread_once.c (__pthread_once):
2476         Likewise.
2477         * sysdeps/unix/sysv/linux/ia64/pthread_once.c (__pthread_once):
2478         Likewise.
2479         * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (__pthread_once):
2480         Likewise.
2481
2482         * allocatestack.c (allocate_stack): Use atomic_increment_val
2483         instead of atomic_exchange_and_add.
2484         * sysdeps/unix/sysv/linux/sem_post.c (__new_sem_post): Likewise.
2485         * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__new_sem_post):
2486         Likewise.
2487         * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
2488         Likewise.
2489
2490         * sysdeps/pthread/pthread.h (pthread_once): Remove __THROW since
2491         the initialization function might throw.
2492
2493 2005-09-05  Richard Henderson  <rth@redhat.com>
2494
2495         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
2496         Move definition inside libpthread, libc, librt check.  Provide
2497         definition for rtld.
2498
2499 2004-09-02  Ulrich Drepper  <drepper@redhat.com>
2500
2501         * sysdeps/alpha/jmpbuf-unwind.h: Define __libc_unwind_longjmp.
2502         * sysdeps/i386/jmpbuf-unwind.h: Likewise
2503         * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
2504         * sysdeps/s390/jmpbuf-unwind.h: Likewise.
2505         * sysdeps/sh/jmpbuf-unwind.h: Likewise.
2506         * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
2507         * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
2508         * sysdeps/x86_64/jmpbuf-unwind.h: Likewise.
2509         * unwind.c: Use it.
2510
2511         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
2512         Rename __data.__clock to __data.__nwaiters, make it unsigned int.
2513         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
2514         Likewise.
2515         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
2516         Decrement __nwaiters.  If pthread_cond_destroy has been called and
2517         this is the last waiter, signal pthread_cond_destroy caller and
2518         avoid using the pthread_cond_t structure after unlock.
2519         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
2520         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
2521         Read clock type from the least significant bits of __nwaiters instead
2522         of __clock.
2523         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
2524         * sysdeps/unix/sysv/linux/internaltypes.h: Define COND_CLOCK_BITS.
2525
2526 2004-08-31  Jakub Jelinek  <jakub@redhat.com>
2527
2528         [BZ #342]
2529         * Makefile (tests): Add tst-cond20 and tst-cond21.
2530         * tst-cond20.c: New test.
2531         * tst-cond21.c: New test.
2532         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
2533         (pthread_cond_t): Rename __data.__clock to __data.__nwaiters, make
2534         it unsigned int.
2535         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
2536         Likewise.
2537         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
2538         (pthread_cond_t): Likewise.
2539         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_cond_t):
2540         Likewise.
2541         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
2542         Likewise.
2543         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_cond_t):
2544         Likewise.
2545         * sysdeps/unix/sysv/linux/lowlevelcond.sym (cond_clock): Remove.
2546         (cond_nwaiters): New.
2547         (clock_bits): New.
2548         * pthread_cond_destroy.c (__pthread_cond_destroy): Return EBUSY
2549         if there are waiters not signalled yet.
2550         Wait until all already signalled waiters wake up.
2551         * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Decrement
2552         __nwaiters.  If pthread_cond_destroy has been called and this is the
2553         last waiter, signal pthread_cond_destroy caller and avoid using
2554         the pthread_cond_t structure after unlock.
2555         (__pthread_cond_wait): Increment __nwaiters in the beginning,
2556         decrement it when leaving.  If pthread_cond_destroy has been called
2557         and this is the last waiter, signal pthread_cond_destroy caller.
2558         * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
2559         Likewise.  Read clock type from the least significant bits of
2560         __nwaiters instead of __clock.
2561         * pthread_condattr_setclock.c (pthread_condattr_setclock): Check
2562         whether clock ID can be encoded in COND_CLOCK_BITS bits.
2563         * pthread_condattr_getclock.c (pthread_condattr_getclock): Decode
2564         clock type just from the last COND_CLOCK_BITS bits of value.
2565         * pthread_cond_init.c (__pthread_cond_init): Initialize __nwaiters
2566         instead of __clock, just from second bit of condattr's value.
2567
2568 2004-08-30  Jakub Jelinek  <jakub@redhat.com>
2569
2570         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Include
2571         bits/wordsize.h.  Make the header match i386 header when __WORDSIZE
2572         != 64.
2573         * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
2574
2575 2004-08-15  Roland McGrath  <roland@frob.com>
2576
2577         * pthread_atfork.c: Update copyright terms including special exception
2578         for these trivial files, which are statically linked into executables
2579         that use dynamic linking for the significant library code.
2580
2581 2004-08-09  Jakub Jelinek  <jakub@redhat.com>
2582
2583         * DESIGN-rwlock.txt: Add decreasing of nr_readers_queued to
2584         pthread_rwlock_rdlock.
2585         * sysdeps/pthread/pthread_rwlock_rdlock (__pthread_rwlock_rdlock):
2586         Decrease __nr_readers_queued after reacquiring lock.
2587         * sysdeps/pthread/pthread_rwlock_timedrdlock
2588         (pthread_rwlock_timedrdlock): Likewise.
2589         Reported by Bob Cook <bobcook47@hotmail.com>.
2590
2591 2004-08-11  Jakub Jelinek  <jakub@redhat.com>
2592
2593         * tst-rwlock14.c (tf): Read main thread handle from *ARG
2594         before pthread_barrier_wait.
2595
2596 2004-08-07  Ulrich Drepper  <drepper@redhat.com>
2597
2598         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
2599         Remove unnecessary exception handling data.
2600
2601 2004-07-23  Jakub Jelinek  <jakub@redhat.com>
2602
2603         [BZ #284]
2604         * sysdeps/pthread/pthread.h (pthread_getcpuclockid): Use __clockid_t
2605         instead of clockid_t.
2606
2607 2004-07-21  Roland McGrath  <roland@redhat.com>
2608
2609         * Makefile ($(objpfx)multidir.mk): Use $(make-target-directory).
2610
2611 2004-07-19  Roland McGrath  <roland@redhat.com>
2612
2613         * tst-cancel4.c (tf_waitid): Use WEXITED flag bit if available.
2614
2615 2004-07-02  Roland McGrath  <roland@redhat.com>
2616
2617         * configure: Don't exit.
2618
2619 2004-07-14  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2620
2621         * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
2622         (__pthread_cond_timedwait): Check for invalid nanosecond in
2623         timeout value.
2624
2625 2004-07-07  Ulrich Drepper  <drepper@redhat.com>
2626
2627         * Makefile: Add rules to build and run tst-fini1.
2628         * tst-fini1.c: New file.
2629         * tst-fini1mod.c: New file.
2630
2631 2004-07-05  Ulrich Drepper  <drepper@redhat.com>
2632
2633         * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define NO_CANCELLATION
2634         if no cancellation support is needed.
2635         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
2636         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
2637         * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
2638         * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
2639         * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
2640         * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
2641         * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
2642         * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
2643         * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
2644
2645         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define __NR_futex
2646         only if not already defined.
2647
2648 2004-07-05  Jakub Jelinek  <jakub@redhat.com>
2649
2650         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_unlock): Use
2651         constraint "m" instead of "0" for futex.
2652
2653         * shlib-versions: Add powerpc64-.*-linux.*.
2654
2655 2004-07-04  Jakub Jelinek  <jakub@redhat.com>
2656
2657         * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
2658         (pthread_rwlock_timedrdlock): Use cmpq instead of cmpl to check
2659         for valid tv_nsec.
2660         * tst-rwlock14.c (do_test): Test for invalid tv_nsec equal to
2661         1 billion and 64-bit tv_nsec which is valid when truncated to 32
2662         bits.
2663
2664 2004-06-29  Roland McGrath  <roland@redhat.com>
2665
2666         * Banner: NPTL no longer has its own version number.
2667         * Makefile (nptl-version): Variable removed.
2668         * sysdeps/pthread/Makefile (CFLAGS-confstr.c): Set LIBPTHREAD_VERSION
2669         using $(version), the glibc version number.
2670
2671 2004-06-29  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2672
2673         * sysdeps/unix/sysv/linux/sh/pthread_once.S (__pthread_once):
2674         Fix branch offset for a PLT entry.
2675         * sysdeps/unix/sysv/linux/sh/sem_post.S (__new_sem_post):
2676         Likewise.
2677         * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait):
2678         Likewise.
2679         * sysdeps/unix/sysv/linux/sh/sem_trywait.S (__new_sem_trywait):
2680         Likewise.
2681         * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait):
2682         Likewise.
2683
2684 2004-06-28  Jakub Jelinek  <jakub@redhat.com>
2685
2686         * sysdeps/alpha/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Define
2687         unconditionally.
2688
2689 2004-06-28  Jakub Jelinek  <jakub@redhat.com>
2690
2691         * sysdeps/pthread/pthread_rwlock_timedwrlock.c
2692         (pthread_rwlock_timedwrlock): Return EINVAL if tv_nsec is negative,
2693         instead of tv_sec.
2694         * sysdeps/pthread/pthread_rwlock_timedrdlock.c
2695         (pthread_rwlock_timedrdlock): Likewise.
2696
2697 2004-06-22  Jakub Jelinek  <jakub@redhat.com>
2698
2699         * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue):
2700         Set __r7 to val, not mutex.
2701
2702 2004-06-27  Ulrich Drepper  <drepper@redhat.com>
2703
2704         * Makefile: Add rules to build tst-rwlock14.
2705         * tst-rwlock14.c: New file.
2706
2707 2004-06-24  Boris Hu  <boris.hu@intel.com>
2708
2709         * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Add timeout validation
2710         check.
2711         * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
2712
2713 2004-06-19  Andreas Jaeger  <aj@suse.de>
2714
2715         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Fix
2716         assembler in last patch.
2717
2718 2004-06-17  Ulrich Drepper  <drepper@redhat.com>
2719
2720         * sysdeps/pthread/pthread_cond_timedwait.c
2721         (__pthread_cond_timedwait): Also check for negativ nanoseconds.
2722         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
2723         (__pthread_cond_timedwait): Check for invalid nanosecond in
2724         timeout value.
2725         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
2726         * tst-cond19.c: New file.
2727         * Makefile: Add rules to build and run tst-cond19.
2728
2729 2004-06-15  Steven Munroe  <sjmunroe@us.ibm.com>
2730
2731         * tst-context1.c (GUARD_PATTERN): Defined.
2732         (tst_context_t): Define struct containing ucontext_t & guard words.
2733         (ctx): Declare as an array of tst_context_t.
2734         (fct): Verify uc_link & guard words are still valid.
2735         (tf): Initialize guard words in ctx.  Adjust ctx refs for new struct.
2736
2737 2004-06-13  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2738
2739         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
2740         Add __data.__futex field, reshuffle __data.__clock.
2741         * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S
2742         (__pthread_cond_signal): Increment __futex at the same time as
2743         __wakeup_seq or __total_seq.  Pass address of __futex instead of
2744         address of low 32-bits of __wakeup_seq to futex syscall.
2745         * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S
2746         (__pthread_cond_wait): Likewise.  Pass __futex value from before
2747         releasing internal lock to FUTEX_WAIT.
2748         * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
2749         (__pthread_cond_timedwait): Likewise.
2750         * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
2751         (FUTEX_CMP_REQUEUE): Define.
2752         (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
2753         Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
2754         Pass __futex value from before the unlock and __futex address instead
2755         of address of low 32-bits of __wakeup_seq to futex syscall.
2756         Fallback to FUTEX_WAKE all on any errors.
2757
2758 2004-06-08  Jakub Jelinek  <jakub@redhat.com>
2759
2760         * pthread_mutexattr_getpshared.c (pthread_mutex_getpshared): Fix
2761         comment typo.
2762         * pthread_mutexattr_gettype.c (pthread_mutexattr_gettype): Likewise.
2763         * pthread_mutexattr_init.c (__pthread_mutexattr_init): Likewise.
2764         * pthread_mutexattr_settype.c (__pthread_mutexattr_settype): Likewise.
2765         * pthread_mutexattr_setpshared.c (pthread_mutexattr_setpshared):
2766         Likewise.  Reported by Bob Cook <bobcook47@hotmail.com>.
2767
2768 2004-06-11  Martin Schwidefsky  <schwidefsky@de.ibm.com>
2769
2770         * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_compare_and_swap):
2771         Add memory clobber to inline assembly.
2772         (__lll_mutex_trylock): Likewise.
2773         (__lll_mutex_cond_trylock): Likewise.
2774
2775 2004-06-07  Martin Schwidefsky  <schwidefsky@de.ibm.com>
2776
2777         * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue):
2778         Pass val argument as 6th system call argument in %r7.
2779
2780 2004-05-21  Jakub Jelinek  <jakub@redhat.com>
2781
2782         * Makefile (tests): Add tst-cond16.
2783         * sysdeps/unix/sysv/linux/lowlevelcond.sym (cond_futex): Add.
2784         * pthread_cond_init.c (__pthread_cond_init): Clear __data.__futex.
2785         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
2786         Add __data.__futex field, reshuffle __data.__clock.
2787         * sysdeps/unix/sysv/linux/i386/pthread_cond_signal.S
2788         (__pthread_cond_signal): Increment __futex at the same time as
2789         __wakeup_seq or __total_seq.  Pass address of __futex instead of
2790         address of low 32-bits of __wakeup_seq to futex syscall.
2791         * sysdeps/unix/sysv/linux/i386/pthread_cond_wait.S
2792         (__pthread_cond_wait): Likewise.  Pass __futex value from before
2793         releasing internal lock to FUTEX_WAIT.
2794         * sysdeps/unix/sysv/linux/i386/pthread_cond_timedwait.S
2795         (__pthread_cond_timedwait): Likewise.
2796         * sysdeps/unix/sysv/linux/i386/pthread_cond_broadcast.S
2797         (FUTEX_CMP_REQUEUE): Define.
2798         (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
2799         Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
2800         Pass __futex value from before the unlock and __futex address instead
2801         of address of low 32-bits of __wakeup_seq to futex syscall.
2802         Fallback to FUTEX_WAKE all on any errors.
2803         * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_CMP_REQUEUE):
2804         Define.
2805         (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
2806         internally.  Return non-zero if error, zero if success.
2807         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_cond_t):
2808         Add __data.__futex field, reshuffle __data.__clock.
2809         * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_CMP_REQUEUE):
2810         Define.
2811         (lll_futex_requeue): Add val argument, return 1 unconditionally
2812         for the time being.
2813         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
2814         Add __data.__futex field, reshuffle __data.__clock.
2815         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_CMP_REQUEUE):
2816         Define.
2817         (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
2818         internally.  Return non-zero if error, zero if success.
2819         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
2820         (pthread_cond_t): Add __data.__futex field, reshuffle __data.__clock.
2821         * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_CMP_REQUEUE):
2822         Define.
2823         (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
2824         internally.  Return non-zero if error, zero if success.
2825         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_cond_t):
2826         Add __data.__futex field, reshuffle __data.__clock.
2827         * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_CMP_REQUEUE):
2828         Define.
2829         (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
2830         internally.  Return non-zero if error, zero if success.
2831         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_cond_t):
2832         Add __data.__futex field, reshuffle __data.__clock.
2833         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
2834         Add __data.__futex field, reshuffle __data.__clock.
2835         * sysdeps/pthread/pthread_cond_signal.c (__pthread_cond_signal):
2836         Increment __futex at the same time as __wakeup_seq or __total_seq.
2837         Pass address of __futex instead of address of low 32-bits of
2838         __wakeup_seq to futex syscall.
2839         * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
2840         Pass __futex value from before releasing internal lock
2841         to FUTEX_WAIT.
2842         * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
2843         Likewise.  Avoid unnecessary shadowing of variables.
2844         * sysdeps/pthread/pthread_cond_broadcast.c (__pthread_cond_broadcast):
2845         Set __futex to 2 * __total_seq.  Pass __futex value from before the
2846         unlock and __futex address instead of address of low 32-bits of
2847         __wakeup_seq to futex_requeue macro, adjust for new return value
2848         meaning.
2849         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
2850         (__pthread_cond_signal): Increment __futex at the same time as
2851         __wakeup_seq or __total_seq.  Pass address of __futex instead of
2852         address of low 32-bits of __wakeup_seq to futex syscall.
2853         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
2854         (__pthread_cond_wait): Likewise.  Pass __futex value from before
2855         releasing internal lock to FUTEX_WAIT.
2856         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
2857         (__pthread_cond_timedwait): Likewise.
2858         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
2859         (FUTEX_CMP_REQUEUE): Define.
2860         (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
2861         Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
2862         Pass __futex value from before the unlock and __futex address instead
2863         of address of low 32-bits of __wakeup_seq to futex syscall.
2864         Fallback to FUTEX_WAKE all on any errors.
2865
2866 2004-06-03  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2867
2868         * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_mutex_lock):
2869         Add nop to align the end of critical section.
2870         (lll_mutex_cond_lock, lll_mutex_timedlock): Likewise.
2871
2872 2004-06-01  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2873
2874         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
2875         Add __broadcast_seq field.
2876         * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Mark
2877         all waiters as woken with woken_seq and bump broadcast counter.
2878         * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Use new
2879         __broadcast_seq.  Increment __woken_seq correctly when cleanuped.
2880         * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
2881         Comment typo fixes.  Avoid returning -ETIMEDOUT.
2882
2883 2004-06-01  Ulrich Drepper  <drepper@redhat.com>
2884
2885         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
2886         (__condvar_tw_cleanup): Fix access to saved broadcast_seq value.
2887         Reported by Kaz Kojima.
2888
2889 2004-05-25  Jakub Jelinek  <jakub@redhat.com>
2890
2891         * sysdeps/unix/sysv/linux/aio_misc.h: New file.
2892
2893 2004-05-21  Jakub Jelinek  <jakub@redhat.com>
2894
2895         * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Compare
2896         __broadcast_seq with bc_seq after acquiring internal lock instead of
2897         before it.
2898
2899 2004-05-18  Jakub Jelinek  <jakub@redhat.com>
2900
2901         * Makefile (.NOTPARALLEL): Only serialize make check/xcheck, not
2902         compilation.
2903         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
2904         (__pthread_cond_timedwait): Avoid returning -ETIMEDOUT.
2905         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
2906         (pthread_cond_t): Add __data.__broadcast_seq field.
2907         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
2908         (FRAME_SIZE): Define.
2909         (__pthread_cond_timedwait): Use it.  Store/check broadcast_seq.
2910         Comment typo fixes.
2911         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S (FRAME_SIZE):
2912         Define.
2913         (__pthread_cond_wait): Use it.  Store/check broadcast_seq.  Comment
2914         typo fixes.
2915         * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
2916         (__pthread_cond_broadcast): Increment broadcast_seq.  Comment typo
2917         fixes.
2918
2919 2004-05-18  Ulrich Drepper  <drepper@redhat.com>
2920
2921         * sysdeps/unix/sysv/linux/lowlevelcond.sym: Add broadcast_seq entry.
2922         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_cond_t):
2923         Add __broadcast_seq field.
2924         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
2925         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
2926         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
2927         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
2928         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
2929         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Mark
2930         all waiters as woken with woken_seq and bump broadcast counter.
2931         * sysdeps/pthread/pthread_cond_broadcast.c: Likewise.
2932         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Use new
2933         __broadcast_seq field.
2934         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
2935         * sysdeps/pthread/pthread_cond_wait.c: Likewise.
2936         * sysdeps/pthread/pthread_cond_timedwait.c: Likewise.
2937         * pthread_cond_init.c: Initialize __broadcast_seq field.
2938         * Makefile (tests): Add tst-cond17 and tst-cond18.
2939         Add .NOTPARALLEL goal.
2940         * tst-cond16.c: New file.  From Jakub.
2941         * tst-cond17.c: New file.  From Jakub.
2942         * tst-cond18.c: New file.  From Jakub.
2943
2944 2004-05-16  Ulrich Drepper  <drepper@redhat.com>
2945
2946         * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Correct some
2947         unwind info.
2948
2949         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
2950         Parametrize frame size.  Correct some unwind info.
2951         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
2952
2953 2004-05-04  Jakub Jelinek  <jakub@redhat.com>
2954
2955         * tst-stack3.c: Note testing functionality beyond POSIX.
2956
2957 2004-05-04  Jakub Jelinek  <jakub@redhat.com>
2958
2959         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (USE___THREAD):
2960         Change conditional from ifdef to if.
2961
2962 2004-04-23  Jakub Jelinek  <jakub@redhat.com>
2963
2964         * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SYSDEP_CANCEL_ERRNO,
2965         SYSDEP_CANCEL_ERROR): Define.
2966         (PSEUDO): Use it.
2967
2968 2004-05-01  Jakub Jelinek  <jakub@redhat.com>
2969
2970         * Versions (libpthread): Remove __pthread_cleanup_upto@@GLIBC_PRIVATE.
2971
2972 2004-04-20  Jakub Jelinek  <jakub@redhat.com>
2973
2974         * sem_unlink.c (sem_unlink): Change EPERM into EACCES.
2975
2976 2004-04-19  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
2977
2978         * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Add frame info.
2979         Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
2980         * sysdeps/unix/sysv/linux/sh/sem_wait.S: Remove unneeded frame
2981         info.  Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
2982
2983 2004-04-19  Ulrich Drepper  <drepper@redhat.com>
2984
2985         * sysdeps/unix/sysv/linux/timer_routines.c: Make sure helper
2986         thread has all signals blocked.
2987
2988 2004-04-18  Andreas Jaeger  <aj@suse.de>
2989
2990         * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h
2991         (SEM_VALUE_MAX): Add missing brace.
2992
2993 2004-04-17  Jakub Jelinek  <jakub@redhat.com>
2994
2995         * sysdeps/pthread/Makefile (tests): Add tst-mqueue8x
2996         in rt subdir.
2997         (CFLAGS-tst-mqueue8x.c): Add -fexceptions.
2998         * sysdeps/pthread/tst-mqueue8x.c: New test.
2999         * tst-cancel4.c: Update comment about message queues.
3000
3001         * sysdeps/pthread/timer_gettime.c (timer_gettime): For expired timer
3002         return it_value { 0, 0 }.
3003         * sysdeps/pthread/timer_create.c (timer_create): Handle SIGEV_NONE
3004         like SIGEV_SIGNAL.
3005         * sysdeps/pthread/timer_routines.c (thread_expire_timer): Remove
3006         assertion for SIGEV_NONE.
3007         (thread_attr_compare): Compare all attributes, not just a partial
3008         subset.
3009
3010 2004-04-17  Jakub Jelinek  <jakub@redhat.com>
3011
3012         * sysdeps/unix/sysv/linux/mq_notify.c: Include stdlib.h.
3013
3014 2004-04-17  Ulrich Drepper  <drepper@redhat.com>
3015
3016         * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h (SEM_VALUE_MAX):
3017         Just use a plain number.
3018         * sysdeps/unix/sysv/linux/i386/bits/semaphore.h: Likewise.
3019         * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: Likewise.
3020         * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: Likewise.
3021         * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: Likewise.
3022         * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: Likewise.
3023         * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: Likewise.
3024         * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
3025
3026 2004-04-16  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
3027
3028         * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Remove unneeded
3029         frame info.
3030         * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
3031
3032 2004-04-15  Jakub Jelinek  <jakub@redhat.com>
3033
3034         * sysdeps/unix/sysv/linux/timer_routines.c: Include errno.h.
3035         (timer_helper_thread): Use inline rt_sigtimedwait syscall instead
3036         of calling sigwaitinfo.
3037
3038 2004-04-16  Ulrich Drepper  <drepper@redhat.com>
3039
3040         * allocatestack.c (allocate_stack): Set reported_guardsize
3041         unconditionally.
3042         * pthread_getattr_np.c (pthread_getattr_np): Use
3043         reported_guardsize instead of guardsize.
3044         * descr.h (struct pthread): Add reported_guardsize field.
3045
3046 2004-04-13  Jakub Jelinek  <jakub@redhat.com>
3047
3048         * sysdeps/unix/sysv/linux/mq_notify.c: Shut up GCC warning.
3049
3050 2004-04-12  Ulrich Drepper  <drepper@redhat.com>
3051
3052         * sysdeps/unix/sysv/linux/mq-notify.c: New file.
3053
3054 2004-04-08  Jakub Jelinek  <jakub@redhat.com>
3055
3056         * sysdeps/unix/sysv/linux/bits/local_lim.h (MQ_PRIO_MAX): Define.
3057         * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h (MQ_PRIO_MAX): Define.
3058         * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h (MQ_PRIO_MAX): Define.
3059         * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h (MQ_PRIO_MAX): Define.
3060         * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_MESSAGE_PASSING):
3061         Define.
3062         * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h
3063         (_POSIX_MESSAGE_PASSING): Define.
3064         * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h
3065         (_POSIX_MESSAGE_PASSING): Define.
3066         * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h
3067         (_POSIX_MESSAGE_PASSING): Define.
3068
3069 2004-04-04  Ulrich Drepper  <drepper@redhat.com>
3070
3071         * tst-context1.c (fct): Check whether correct stack is used.
3072
3073 2004-04-03  Ulrich Drepper  <drepper@redhat.com>
3074
3075         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Never use
3076         matching constraints for asm mem parameters.
3077
3078         * tst-clock2.c (tf): Don't define unless needed.
3079
3080 2004-03-30  H.J. Lu  <hongjiu.lu@intel.com>
3081
3082         * Makefile (link-libc-static): Use $(static-gnulib) instead of
3083         $(gnulib).
3084
3085 2004-03-30  Ulrich Drepper  <drepper@redhat.com>
3086
3087         * sysdeps/pthread/pthread-functions.h: Add ptr__nptl_deallocate_tsd.
3088         * init.c (pthread_functions): Add ptr__nptl_deallocate_tsd.
3089         * pthreadP.h: Declare __nptl_deallocate_tsd.
3090         * pthread_create.c (deallocate_tsd): Remove to __nptl_deallocate_tsd.
3091         Adjust caller.
3092
3093         * Makefile (tests): Add tst-tsd5.
3094         * tst-tsd5.c: New file.
3095
3096 2004-03-29  Ulrich Drepper  <drepper@redhat.com>
3097
3098         * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
3099         (__pthread_attr_setaffinity_old): Prepend GLIBC_ to version names
3100         is SHLIB_COMPAT check.
3101         * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c
3102         (__pthread_attr_getaffinity_old): Likewise.
3103         * sysdeps/unix/sysv/linux/pthread_getaffinity.c
3104         (__pthread_getaffinity_old): Likewise.
3105         * sysdeps/unix/sysv/linux/pthread_setaffinity.c
3106         (__pthread_setaffinity_old): Likewise.
3107
3108 2004-03-26  Ulrich Drepper  <drepper@redhat.com>
3109
3110         * allocatestack.c (_make_stacks_executable): Call
3111         _dl_make_stack_executable first.
3112
3113 2004-03-24  Roland McGrath  <roland@redhat.com>
3114
3115         * sysdeps/i386/pthread_spin_lock.c (pthread_spin_lock): Use "m"
3116         constraint instead of "0".
3117
3118 2004-03-24  Ulrich Drepper  <drepper@redhat.com>
3119
3120         * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
3121         (lll_mutex_cond_trylock): Define as wrapper around __lll_cond_trylock.
3122
3123         * sysdeps/unix/sysv/linux/getpid.c (really_getpid): Reorganize
3124         code to avoid warning.
3125
3126 2004-03-24  Andreas Jaeger  <aj@suse.de>
3127
3128         * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
3129         (__pthread_attr_setaffinity_old): Remove const.
3130
3131 2004-03-23  Ulrich Drepper  <drepper@redhat.com>
3132
3133         * sysdeps/unix/sysv/linux/smp.h: New file.
3134         * sysdeps/unix/sysv/linux/sh/smp.h: New file.
3135         * init.c: Define __is_smp.
3136         (__pthread_initialize_minimal_internal): Call is_smp_system to
3137         initialize __is_smp.
3138         * pthreadP.h: Declare __is_smp.
3139         Define MAX_ADAPTIVE_COUNT is necessary.
3140         * pthread_mutex_init.c: Add comment regarding __spins field.
3141         * pthread_mutex_lock.c: Implement adaptive mutex type.
3142         * pthread_mutex_timedlock.c: Likewise.
3143         * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
3144         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_mutex_t):
3145         Add __spins field.
3146         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
3147         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
3148         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
3149         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
3150         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
3151         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
3152         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
3153         * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Define
3154         lll_mutex_cond_trylock.
3155         * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
3156         * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
3157         * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
3158         * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
3159         * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
3160         Define BUSY_WAIT_NOP.
3161         * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
3162         * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
3163
3164         * tst-mutex5.c: Add support for testing adaptive mutexes.
3165         * tst-mutex7.c: Likewise.
3166         * tst-mutex5a.c: New file.
3167         * tst-mutex7a.c: New file.
3168         * Makefile (tests): Add tst-mutex5a and tst-mutex7a.
3169
3170         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
3171         (__lll_mutex_timedlock_wait): Preserve r8 and r9 since the
3172         vgettimeofday call might destroy the content.
3173
3174         * sysdeps/ia64/pthread_spin_lock.c (pthread_spin_lock): Use hint
3175         @pause in the loop.
3176
3177         * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_mutex_trylock):
3178         No need to restrict type of ret.  Make it int.  Add comment.
3179
3180         * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_mutex_trylock):
3181         Remove unnecessary setne instruction.
3182
3183 2004-03-22  Jakub Jelinek  <jakub@redhat.com>
3184
3185         * sysdeps/unix/sysv/linux/pthread_getaffinity.c
3186         (__pthread_getaffinity_new): Use INT_MAX instead of UINT_MAX.
3187         * pthread_getattr_np.c (pthread_getattr_np): Double size every cycle.
3188         If realloc fails, break out of the loop.
3189
3190 2004-03-20  Andreas Jaeger  <aj@suse.de>
3191
3192         * sysdeps/unix/sysv/linux/pthread_setaffinity.c
3193         (__pthread_setaffinity_old): Fix interface.
3194         * sysdeps/unix/sysv/linux/pthread_getaffinity.c
3195         (__pthread_getaffinity_old): Likewise.
3196
3197         * sysdeps/unix/sysv/linux/pthread_setaffinity.c
3198         (__pthread_setaffinity_new): Remove duplicate declaration.
3199
3200 2004-03-20  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
3201
3202         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (CENABLE): Save
3203         the return value to a safe register.
3204         (CDISABLE): Set the function argument correctly.
3205
3206 2004-03-17  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
3207
3208         * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h (XCHG): Define.
3209         * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_mutex_lock_wait):
3210         Rewrite so that only one locked memory operation per round is needed.
3211         * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S
3212         (pthread_barrier_wait): After wakeup, release lock only when the
3213         last thread stopped using the barrier object.
3214         * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S
3215         (__pthread_cond_wait): Don't store mutex address if the current
3216         value is ~0l.  Add correct cleanup support and unwind info.
3217         * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
3218         * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
3219         (__pthread_cond_broadcast): Don't use requeue for pshared condvars.
3220         * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Update comment.
3221         * sysdeps/unix/sysv/linux/sh/pthread_once.S (__pthread_once):
3222         Add correct cleanup support and unwind info.
3223         * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait): Likewise.
3224         * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Add unwind
3225         information for syscall wrappers.
3226
3227 2004-03-18  Ulrich Drepper  <drepper@redhat.com>
3228
3229         * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_attr): Add
3230         cpusetsize field, remove next.
3231         * sysdeps/pthread/pthread.h (pthread_getaffinity_np): Add new second
3232         parameter for size of the CPU set.
3233         (pthread_setaffinity_np): Likewise.
3234         (pthread_attr_getaffinity_np): Likewise.
3235         (pthread_attr_setaffinity_np): Likewise.
3236         * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c: Implement
3237         interface change, keep compatibility code.
3238         * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: Likewise.
3239         * sysdeps/unix/sysv/linux/pthread_getaffinity.c: Likewise.
3240         * sysdeps/unix/sysv/linux/pthread_setaffinity.c: Likewise.
3241         * pthreadP.h: Remove hidden_proto for pthread_getaffinity_np.  Declare
3242         __pthread_getaffinity_np.
3243         * Versions: Add version for changed interfaces.
3244         * tst-attr3.c: Adjust test for interface change.
3245         * pthread_getattr_np.c: Query the kernel about the affinity mask with
3246         increasing buffer sizes.
3247         * pthread_attr_destroy.c: Remove unused list handling.
3248         * pthread_attr_init.c: Likewise.
3249
3250 2004-03-17  Roland McGrath  <roland@redhat.com>
3251
3252         * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Pass missing
3253         first argument to clock_getres so we ever enable kernel timers.
3254
3255 2004-03-15  Ulrich Weigand  <uweigand@de.ibm.com>
3256
3257         * init.c (nptl_version): Add __attribute_used__ to nptl_version.
3258
3259 2004-03-12  Richard Henderson  <rth@redhat.com>
3260
3261         * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Propagate
3262         oldvalue from CENABLE to CDISABLE.
3263
3264 2004-03-12  Ulrich Drepper  <drepper@redhat.com>
3265
3266         * sysdeps/unix/sysv/linux/bits/local_lim.h: Define HOST_NAME_MAX.
3267         * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
3268         * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
3269         * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
3270
3271 2004-03-11  Richard Henderson  <rth@redhat.com>
3272
3273         * sysdeps/alpha/tcb-offsets.sym (PID_OFFSET): New.
3274         * sysdeps/unix/sysv/linux/alpha/pt-vfork.S: Save/restore PID.
3275         * sysdeps/unix/sysv/linux/alpha/vfork.S: New file.
3276
3277 2004-03-11  Jakub Jelinek  <jakub@redhat.com>
3278
3279         * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Use jgnl
3280         instead of jnl instruction to jump to SYSCALL_ERROR_LABEL.
3281         * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S (__vfork): Likewise.
3282
3283 2004-03-11  Jakub Jelinek  <jakub@redhat.com>
3284
3285         * forward.c (__pthread_cond_broadcast_2_0,
3286         __pthread_cond_destroy_2_0, __pthread_cond_init_2_0,
3287         __pthread_cond_signal_2_0, __pthread_cond_wait_2_0,
3288         __pthread_cond_timedwait_2_0): Use return 0 as defaction instead of 0.
3289
3290 2004-03-11  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
3291
3292         * sysdeps/sh/tcb-offsets.sym: Add PID.
3293         * sysdeps/unix/sysv/linux/sh/pt-vfork.S: Properly handle PID cache.
3294         * sysdeps/unix/sysv/linux/sh/vfork.S: New file.
3295
3296 2004-03-10  Ulrich Drepper  <drepper@redhat.com>
3297
3298         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: No need to
3299         include <sysdep-cancel.h>, vfork is no cancellation point.
3300         * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: Likewise.
3301         * sysdeps/unix/sysv/linux/powerpc/powerpc64/pt-vfork.S: Likewise.
3302         * sysdeps/unix/sysv/linux/powerpc/powerpc32/pt-vfork.S: Likewise.
3303
3304 2004-03-10  Jakub Jelinek  <jakub@redhat.com>
3305
3306         * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S (__vfork): Add
3307         libc_hidden_def.
3308         * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Likewise.
3309         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
3310         Likewise.
3311         * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S (__vfork):
3312         Likewise.
3313         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Likewise.
3314         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
3315         * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Include tcb-offsets.h.
3316         * sysdeps/unix/sysv/linux/ia64/vfork.S (__vfork): Use DO_CALL instead
3317         of DO_CALL_VIA_BREAK.  Work around a gas problem.
3318
3319         * sysdeps/unix/sysv/linux/powerpc/pt-vfork.S: Remove.
3320         * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: New file.
3321         * sysdeps/unix/sysv/linux/powerpc/powerpc32/pt-vfork.S: New file.
3322         * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: New file.
3323         * sysdeps/unix/sysv/linux/powerpc/powerpc64/pt-vfork.S: New file.
3324         * sysdeps/powerpc/tcb-offsets.sym: Add PID.
3325
3326         * sysdeps/unix/sysv/linux/ia64/pt-vfork.S (__vfork): Don't use
3327         a local register for saving old PID.  Negate PID in parent upon exit.
3328
3329         * sysdeps/unix/sysv/linux/s390/s390-32/pt-vfork.S: Include
3330         tcb-offsets.h.
3331         (__vfork): Negate PID if non-zero and set to INT_MIN if zero
3332         before syscall, set to the old value in the parent afterwards.
3333         * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S: New file.
3334         * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S: Include
3335         tcb-offsets.h.
3336         (__vfork): Negate PID if non-zero and set to INT_MIN if zero
3337         before syscall, set to the old value in the parent afterwards.
3338         * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S: New file.
3339         * sysdeps/s390/tcb-offsets.sym: Add PID.
3340
3341         * sysdeps/unix/sysv/linux/sparc/pt-vfork.S: Remove.
3342         * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: New file.
3343         * sysdeps/unix/sysv/linux/sparc/sparc32/pt-vfork.S: New file.
3344         * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: New file.
3345         * sysdeps/unix/sysv/linux/sparc/sparc64/pt-vfork.S: New file.
3346         * sysdeps/sparc/tcb-offsets.sym: Add PID.
3347
3348 2004-03-10  Andreas Schwab  <schwab@suse.de>
3349
3350         * sysdeps/ia64/tcb-offsets.sym: Add PID.
3351         * sysdeps/unix/sysv/linux/ia64/vfork.S: New file.
3352         * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Properly handle PID cache.
3353
3354 2004-03-09  Jakub Jelinek  <jakub@redhat.com>
3355
3356         * tst-cancel20.c (do_one_test): Clear in_sh_body first.
3357         * tst-cancel21.c (do_one_test): Likewise.
3358         Reported by Gordon Jin <gordon.jin@intel.com>.
3359
3360 2004-02-09  Jakub Jelinek  <jakub@redhat.com>
3361
3362         * sysdeps/unix/sysv/linux/i386/vfork.S (SAVE_PID): Negate PID
3363         if non-zero and set to INT_MIN if zero.
3364         * sysdeps/unix/sysv/linux/x86_64/vfork.S (SAVE_PID): Likewise.
3365         * sysdeps/unix/sysv/linux/i386/pt-vfork.S: Include tcb-offsets.h.
3366         (SAVE_PID, RESTORE_PID): Define.
3367         (__vfork): Use it.
3368         * sysdeps/unix/sysv/linux/x86_64/pt-vfork.S: Include tcb-offsets.h.
3369         Use relative path to avoid including NPTL i386/vfork.S.
3370         (SAVE_PID, RESTORE_PID): Define.
3371         * sysdeps/unix/sysv/linux/raise.c: Include limits.h.
3372         (raise): Handle THREAD_SELF->pid INT_MIN the same as 0.
3373         * Makefile (tests): Add tst-vfork1, tst-vfork2, tst-vfork1x and
3374         tst-vfork2x.
3375         (tests-reverse): Add tst-vfork1x and tst-vfork2x.
3376         * tst-vfork1.c: New test.
3377         * tst-vfork2.c: New test.
3378         * tst-vfork1x.c: New test.
3379         * tst-vfork2x.c: New test.
3380
3381 2004-03-08  Ulrich Drepper  <drepper@redhat.com>
3382
3383         * sysdeps/i386/tcb-offsets.sym: Add PID.
3384         * sysdeps/x86_64/tcb-offsets.sym: Likewise.
3385         * sysdeps/unix/sysv/linux/i386/vfork.S: New file.
3386         * sysdeps/unix/sysv/linux/x86_64/vfork.S: New file.
3387
3388 2004-03-08  Steven Munroe  <sjmunroe@us.ibm.com>
3389
3390         * sysdeps/unix/sysv/linux/powerpc/Versions: Remove leading tabs.
3391
3392 2004-03-08  H.J. Lu  <hongjiu.lu@intel.com>
3393
3394         * sysdeps/s390/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
3395         _rtld_global_ro.
3396
3397 2004-03-07  Ulrich Drepper  <drepper@redhat.com>
3398
3399         * sysdeps/ia64/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
3400         _rtld_global_ro.
3401
3402         * tst-once4.c: Remove unnecessary macro definition.
3403
3404         * tst-mutex7.c (do_test): Limit thread stack size.
3405         * tst-once2.c (do_test): Likewise.
3406         * tst-tls3.c (do_test): Likewise.
3407         * tst-tls1.c (do_test): Likewise.
3408         * tst-signal3.c (do_test): Likewise.
3409         * tst-kill6.c (do_test): Likewise.
3410         * tst-key4.c (do_test): Likewise.
3411         * tst-join4.c (do_test): Likewise.
3412         * tst-fork1.c (do_test): Likewise.
3413         * tst-context1.c (do_test): Likewise.
3414         * tst-cond2.c (do_test): Likewise.
3415         * tst-cond10.c (do_test): Likewise.
3416         * tst-clock2.c (do_test): Likewise.
3417         * tst-cancel10.c (do_test): Likewise.
3418         * tst-basic2.c (do_test): Likewise.
3419         * tst-barrier4.c (do_test): Likewise.
3420
3421 2004-03-05  Ulrich Drepper  <drepper@redhat.com>
3422
3423         * sysdeps/i386/tls.h: Use GLRO instead of GL where appropriate.
3424
3425 2004-03-01  Ulrich Drepper  <drepper@redhat.com>
3426
3427         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
3428         (__pthread_cond_timedwait): Optimize wakeup test.
3429         * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
3430         (__pthread_cond_wait): Likewise.
3431         * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
3432         * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
3433         Likewise.
3434
3435 2004-02-29  Ulrich Drepper  <drepper@redhat.com>
3436
3437         * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
3438         (__lll_mutex_lock_wait): Optimize a bit more.  Just one copy of
3439         the atomic instruction needed.
3440         * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
3441         (__lll_mutex_lock_wait): Likewise.
3442
3443 2004-02-28  Ulrich Drepper  <drepper@redhat.com>
3444
3445         * Makefile (tests): Add tst-cond14 and tst-cond15.
3446         * tst-cond14.c: New file.
3447         * tst-cond15.c: New file.
3448
3449 2004-02-27  Ulrich Drepper  <drepper@redhat.com>
3450
3451         * sysdeps/pthread/createthread.c (create_thread): Remove use of
3452         CLONE_STOPPED.  We cannot use SIGCONT which means CLONE_STOPPED
3453         needs to be implemented differently to be useful.
3454
3455 2004-02-26  Ulrich Drepper  <drepper@redhat.com>
3456
3457         * pthread_attr_setschedparam.c: Don't test priority against limits
3458         here.  Set ATTR_FLAG_SCHED_SET flag.
3459         * pthread_attr_setschedpolicy.c: Set ATTR_FLAG_POLICY_SET flag.
3460         * pthread_create.c (__pthread_create_2_1): Copy scheduling attributes
3461         from parent thread to child.  If attribute is used and scheduling
3462         parameters are not inherited, copy parameters from attribute or
3463         compute them.  Check priority value.
3464         * pthread_getschedparam.c: If the parameters aren't known yet get
3465         them from the kernel.
3466         * pthread_setschedparam.c: Set ATTR_FLAG_SCHED_SET and
3467         ATTR_FLAG_POLICY_SET flag for thread.
3468         * sysdeps/unix/sysv/linux/internaltypes.h: Define ATTR_FLAG_SCHED_SET
3469         and ATTR_FLAG_POLICY_SET.
3470
3471         * sysdeps/pthread/createthread.c: Use tgkill if possible.
3472
3473         * pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr): Don't