1 2012-04-20 Paul Pluzhnikov <ppluzhnikov@google.com>
3 * sysdeps/x86_64/tls.h (TLS_GET_FS, TLS_SET_FS): Delete.
5 2012-03-27 David S. Miller <davem@davemloft.net>
7 * tst-cond16.c (do_test): Use a thread stack size which is either
8 PTHREAD_STACK_MIN or the page size, whichever is larger.
9 * tst-cond18.c (do_test): Likewise.
11 2012-03-19 H.J. Lu <hongjiu.lu@intel.com>
13 * sysdeps/x86_64/pthreaddef.h (CURRENT_STACK_FRAME): Use
14 register char * __asm__("rsp") to get stack frame.
16 2012-03-19 H.J. Lu <hongjiu.lu@intel.com>
18 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (SYS_futex): Use
21 2012-03-19 H.J. Lu <hongjiu.lu@intel.com>
23 * unwind.c (unwind_stop): Cast _Unwind_GetCFA return to
26 2012-03-16 David S. Miller <davem@davemloft.net>
29 * sysdeps/unix/sysv/linux/libc-lowlevellock.c: Include using <..>
31 * sysdeps/unix/sysv/linux/sparc/sparc32/libc-lowlevellock.c:
34 2012-03-15 David S. Miller <davem@davemloft.net>
37 * sysdeps/unix/sysv/linux/sparc/sparc32/libc-lowlevellock.c: New file.
39 2012-03-09 Paul Eggert <eggert@cs.ucla.edu>
42 * pt-crti.S: Replace FSF snail mail address with URL.
44 2012-03-09 Joseph Myers <joseph@codesourcery.com>
46 * sysdeps/pthread/pthread.h (__need_clockid_t, __need_timespec):
47 Do not define before including <time.h>.
49 2012-03-08 David S. Miller <davem@davemloft.net>
51 * sysdeps/unix/sysv/linux/sparc/sem_post.c: Update copyright year.
53 2012-03-08 Thomas Schwinge <thomas@codesourcery.com>
55 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_timedlock_wait):
56 Check for timestamp before the Epoch.
58 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait): Fix
61 * tst-sem13.c (do_test): Add another test case.
62 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
63 Fix updating nwaiters.
65 2012-03-07 Joseph Myers <joseph@codesourcery.com>
68 * sysdeps/pthread/configure.in (libc_cv_forced_unwind): Change
69 link test to a compile test.
70 (libc_cv_c_cleanup): Likewise. Declare puts rather than including
72 * sysdeps/pthread/configure: Regenerated.
74 2012-03-07 Ulrich Drepper <drepper@gmail.com>
76 * Makefile (distribute): Remove variable.
78 2012-01-23 Thomas Schwinge <thomas@codesourcery.com>
80 * sysdeps/unix/sysv/linux/sem_timedwait.c (sem_timedwait): Get rid of
81 superfluous assignment.
82 * sysdeps/unix/sysv/linux/sparc/sem_timedwait.c (sem_timedwait):
84 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c
85 (sem_timedwait): Likewise.
87 2012-03-06 Ulrich Drepper <drepper@gmail.com>
89 * sysdeps/pthread/bits/libc-lock.h: Move information not needed in
90 installed headers to...
91 * sysdeps/pthread/bits/libc-lockP.h: ...here. New file.
93 2012-03-06 David S. Miller <davem@davemloft.net>
95 * sysdeps/unix/sysv/linux/sparc/sem_post.c (__new_sem_post): Use
96 atomic_increment and remove unused local variable.
97 (__old_sem_post): Likewise.
99 2012-02-27 David S. Miller <davem@davemloft.net>
101 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Don't refer to
102 non-existing __pthread_attr.
103 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
104 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
105 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
106 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
107 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
109 2012-02-26 Ulrich Drepper <drepper@gmail.com>
111 * sysdeps/pthread/pthread.h: Define __need_clockid_t for __USE_XOPEN2K.
113 * sysdeps/pthread/pthread.h: Define __need_timespec before including
115 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Name pthread_attr_t
117 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
118 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
119 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
120 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
121 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
123 2012-02-21 Joseph Myers <joseph@codesourcery.com>
126 * Makefile (generated): Remove crti.S, crtn.S, defs.h and
128 [crti.S not in sysdirs] (omit-deps): Do not append.
129 [crti.S not in sysdirs] (CFLAGS-pt-initfini.s): Remove variable.
130 [crti.S not in sysdirs] (pt-initfini.c): Remove vpath directive.
131 [crti.S not in sysdirs] ($(objpfx)crti.S): Remove rule.
132 [crti.S not in sysdirs] ($(objpfx)crtn.S): Likewise.
133 [crti.S not in sysdirs] ($(objpfx)defs.h): Likewise.
134 [crti.S not in sysdirs] ($(objpfx)crti.o): Likewise.
135 [crti.S not in sysdirs] ($(objpfx)crtn.o): Likewise.
136 [crti.S in sysdirs] (extra-objs): Append unconditionally.
137 [crti.S in sysdirs] ($(objpfx)crti.o): Define rule
139 * sysdeps/pthread/pt-initfini.c: Remove file.
141 2012-02-16 Richard Henderson <rth@twiddle.net>
143 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c: Remove file.
144 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: Remove file.
146 2012-02-15 Kaz Kojima <kkojima@rr.iij4u.or.jp>
148 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: Remove file.
150 2012-02-16 David S. Miller <davem@davemloft.net>
152 * sysdeps/sparc/Makefile: Add -fPIC when building pt-crti.S and crtn.S
154 2012-02-15 Marek Polacek <polacek@redhat.com>
156 * sysdeps/unix/sysv/linux/x86_64/Makefile: Remove file.
158 2012-02-09 Paul Eggert <eggert@cs.ucla.edu>
160 Replace FSF snail mail address with URLs, as per GNU coding standards.
162 2012-02-08 Andreas Schwab <schwab@linux-m68k.org>
164 * Makefile (extra-objs) [crti.S in sysdirs]: Add pt-crti.o.
166 2012-02-08 Joseph Myers <joseph@codesourcery.com>
168 Support crti.S and crtn.S provided directly by architectures.
169 * Makefile [crti.S in sysdirs] (omit-deps): Do not append.
170 [crti.S in sysdirs] (CFLAGS-pt-initfini.s): Do not define variable.
171 [crti.S in sysdirs] ($(objpfx)pt-initfini.s): Disable rule.
172 [crti.S in sysdirs] ($(objpfx)crti.S): Likewise.
173 [crti.S in sysdirs] ($(objpfx)crtn.S): Likewise.
174 [crti.S in sysdirs] ($(objpfx)defs.h): Likewise.
175 [crti.S in sysdirs] ($(objpfx)crti.o): Likewise.
176 [crti.S in sysdirs] ($(objpfx)crtn.o): Likewise.
177 [crti.S in sysdirs] (pt-initfini.c): Remove vpath directive.
178 [crti.S in sysdirs] ($(objpfx)crti.o): New rule.
179 * pt-crti.S: New file.
180 * sysdeps/unix/sysv/linux/i386/Makefile: Remove file.
182 2012-02-03 Joseph Myers <joseph@codesourcery.com>
184 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Use
185 macros for PIC register setup.
186 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
187 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
188 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
189 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
190 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
192 2012-01-11 Marek Polacek <polacek@redhat.com>
194 * forward.c (FORWARD_NORETURN): Define macro.
195 (__pthread_unwind): Use FORWARD_NORETURN macro to avoid warning.
196 (__pthread_exit): Likewise.
198 2012-01-10 Ulrich Drepper <drepper@gmail.com>
200 * sysdeps/pthread/pthread.h: Add const attribute to pthread_equal.
202 * pthreadP.h: Add noreturn to __pthread_exit.
203 * sysdeps/pthread/pthread-functions.h: Likewise for ptr___pthread_exit.
205 2011-12-30 Adhemerval Zanella <azanella@linux.vnet.ibm.com>
207 * sysdeps/unix/sysv/linux/aio_misc.h (__aio_create_helper_thread):
208 Call pthread_attr_setstacksize() with result of
209 __pthread_get_minstack() to account for application TLS usage.
211 2012-01-08 Marek Polacek <polacek@redhat.com>
213 * sysdeps/unix/sysv/linux/mq_notify.c: Include <nptl/pthreadP.h>.
215 2012-01-07 Ulrich Drepper <drepper@gmail.com>
218 * pthreadP.h: Use const instead of __const.
219 * semaphore.h: Likewise.
220 * sysdeps/pthread/bits/libc-lock.h: Likewise.
221 * sysdeps/pthread/bits/sigthread.h: Likewise.
222 * sysdeps/pthread/pthread.h: Likewise.
224 * Makefile: Remove elf=yes test, only ELF is supported.
226 * shlib-versions: Remove entries for ports architectures.
228 In case anyone cares, the IA-64 architecture could move to ports.
229 * sysdeps/ia64/*: Removed.
230 * sysdeps/unix/sysv/linux/ia64/*: Removed.
232 2011-12-22 Ulrich Drepper <drepper@gmail.com>
234 * sysdeps/pthread/gai_misc.h (__gai_create_helper_thread): Use
235 __pthread_get_minstack.
236 * sysdeps/unix/sysv/linux/mq_notify.c (init_mq_netlink): Likewise.
239 * sysdeps/unix/sysv/linux/timer_routines.c: Get minimum stack size
240 through __pthread_get_minstack.
241 * nptl-init.c (__pthread_initialize_minimal_internal): Get page size
242 directly from _rtld_global_ro.
243 (__pthread_get_minstack): New function.
244 * pthreadP.h: Declare __pthread_get_minstack.
245 * Versions (libpthread) [GLIBC_PRIVATE]: Add __pthread_get_minstack.
247 2011-12-21 Ulrich Drepper <drepper@gmail.com>
250 * sysdeps/unix/sysv/linux/pthread_getname.c (pthread_getname_np):
251 Correct reading name from file.
253 2011-12-14 Carlos O'Donell <carlos@systemhalted.org>
255 * allocatestack.c (allocate_stack): Return errno on failure.
257 2011-12-14 Jeff Law <law@redhat.com>
260 * pthread_create.c (__pthread_create_2_1): Translate ENOMEM to EAGAIN.
262 2011-11-28 Andreas Schwab <schwab@redhat.com>
264 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Handle
265 EAGAIN from FUTEX_WAIT_REQUEUE_PI.
266 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
268 2011-11-15 Ulrich Drepper <drepper@gmail.com>
270 * pthread_getattr_np.c (pthread_getattr_np): Set FD_CLOEXEC for
273 2011-10-29 Ulrich Drepper <drepper@gmail.com>
276 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
277 (__pthread_cond_timedwait): Initialize %r15 correctly also for code
278 path for kernels with FUTEX_CLOCK_REALTIME.
279 Debugged by H.J. Lu <hjl.tools@gmail.com>.
281 2011-10-27 Andreas Schwab <schwab@redhat.com>
284 * sysdeps/pthread/pthread.h: Use __THREADNL instead of __THREAD
285 for memory synchronization functions.
286 * semaphore.h: Likewise.
288 2011-10-24 Ulrich Drepper <drepper@gmail.com>
290 * tst-cancel7.c: Avoid warning.
291 * tst-mutex6.c: Likewise.
292 * tst-mutex9.c: Likewise.
293 * tst-mutexpi6.c: Likewise.
295 2011-10-23 Ulrich Drepper <drepper@gmail.com>
297 * sysdeps/i386/tls.h: Remove #include <list.h>.
299 2011-10-15 Ulrich Drepper <drepper@gmail.com>
301 * pthread_create.c (start_thread): Call __ctype_init.
303 2011-09-15 Andreas Schwab <schwab@redhat.com>
305 * sysdeps/pthread/list.h: Define only list_t if __need_list_t is
307 (list_add): Add atomic_write_barrier.
308 * descr.h: Define __need_list_t before including <list.h>.
309 * nptl-init.c: Include <list.h>
310 * allocatestack.c: Likewise.
312 2011-09-11 Ulrich Drepper <drepper@gmail.com>
314 * sysdeps/i386/tls.h: Remove HAVE_TLS_SUPPORT test.
315 * sysdeps/ia64/tls.h: Likewise.
316 * sysdeps/powerpc/tls.h: Likewise.
317 * sysdeps/s390/tls.h: Likewise.
318 * sysdeps/sh/tls.h: Likewise.
319 * sysdeps/sparc/tls.h: Likewise.
320 * sysdeps/x86_64/tls.h: Likewise.
322 2011-09-10 Ulrich Drepper <drepper@gmail.com>
324 * sysdeps/pthread/malloc-machine.h: Define MUTEX_INITIALIZER.
326 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Don't handle
328 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
329 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
330 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
331 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
332 * sysdeps/unix/sysv/linux/sh/sem_post.S: Likewise.
333 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
334 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Likewise.
335 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Likewise.
336 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
337 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
338 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
339 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
341 * tst-tls1.c: Support for __thread is now mandatory.
342 * tst-tls2.c: Likewise.
343 * tst-tls3.c: Likewise.
344 * tst-tls3mod.c: Likewise.
345 * tst-tls4.c: Likewise.
346 * tst-tls4moda.c: Likewise.
347 * tst-tls4modb.c: Likewise.
348 * tst-tls5.h: Likewise.
350 2011-09-08 Ulrich Drepper <drepper@gmail.com>
353 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
354 (pthread_rwlock_timedwrlock): Use correct macro in test.
355 Patch by H.J. Lu <hongjiu.lu@intel.com>.
357 2011-09-06 Ulrich Drepper <drepper@gmail.com>
359 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait): Don't
360 use gettimeofday vsyscall, just call gettimeofday.
361 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
362 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Likewise.
363 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
365 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
367 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
368 Simplify __vdso_clock_gettime use.
370 2011-09-05 David S. Miller <davem@davemloft.net>
372 * sysdeps/unix/sysv/linux/sem_timedwait.c (do_futex_timed_wait):
374 (sem_timedwait): Call it to force an exception region around
375 the async cancel enable and the futex operation.
376 * sysdeps/unix/sysv/linux/sparc/sem_timedwait.c: Likewise.
377 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c: Likewise.
378 * sysdeps/unix/sysv/linux/sem_wait.c (do_futex_wait): New function.
379 (__new_sem_wait): Call it to force an exception region around
380 the async cancel enable and the futex operation.
381 * sysdeps/unix/sysv/linux/sparc/sem_wait.c: Likewise.
382 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c: Likewise.
384 2011-08-31 Andreas Schwab <schwab@redhat.com>
386 * allocatestack.c (setxid_mark_thread): Ensure that the exiting
389 2011-08-20 David S. Miller <davem@davemloft.net>
391 * Makefile (tst-cleanup0.out): Fix typo in output redirection.
393 2011-08-14 Roland McGrath <roland@hack.frob.com>
395 * sysdeps/i386/pthreaddef.h (TCB_ALIGNMENT): Set to 64, optimal on Atom.
396 * sysdeps/x86_64/pthreaddef.h (TCB_ALIGNMENT): Likewise.
398 2011-08-08 Andreas Schwab <schwab@redhat.com>
400 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: Maintain aligned
402 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
403 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
405 2011-07-22 Ulrich Drepper <drepper@gmail.com>
407 * sysdeps/pthread/unwind-forcedunwind.c (_Unwind_Resume): Add read
409 (__gcc_personality_v0): Likewise.
410 (_Unwind_ForcedUnwind): Likewise.
411 (_Unwind_GetCFA): Likewise.
413 2011-07-14 Roland McGrath <roland@hack.frob.com>
415 * allocatestack.c (__reclaim_stacks): Use uintptr_t cast rather than
418 2011-06-30 Ulrich Drepper <drepper@gmail.com>
420 * nptl-init.c (__nptl_set_robust): New function.
421 (pthread_functions): Add reference.
422 * npthreadP.h: Declare __nptl_set_robust.
423 * sysdeps/pthread/pthread-functions.h (pthread_functions): Add
424 ptr_set_robust member.
425 * sysdeps/unix/sysv/linux/fork.c: Call set_robust_list syscall in
426 child if threads are used.
428 2011-06-14 Andreas Jaeger <aj@suse.de>
430 * pthread_rwlock_init.c: Include <string.h> for memset declaration.
432 2011-05-11 Ulrich Drepper <drepper@gmail.com>
435 * allocatestack.c (allocate_stack): Convert ENOMEM error to EAGAIN.
437 2011-04-10 Ulrich Drepper <drepper@gmail.com>
440 * allocatestack.c (get_cached_stack): Deallocate DTV entries before
442 Patch partly by Robert Rex <robert.rex@exasol.com>.
444 2011-01-19 Roland McGrath <roland@redhat.com>
446 * pthread_cond_wait.c (__pthread_cond_wait): Fix comment typo.
447 * pthread_cond_timedwait.c (__pthread_cond_timedwait): Likewise.
448 * pthread_rwlock_rdlock.c (__pthread_rwlock_rdlock): Likewise.
449 * pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock): Likewise.
450 * pthread_rwlock_timedrdlock.c (pthread_rwlock_timedrdlock): Likewise.
451 * pthread_rwlock_timedwrlock.c (pthread_rwlock_timedwrlock): Likewise.
453 2011-01-16 Andreas Schwab <schwab@linux-m68k.org>
455 * Makefile (test-extras): Add tst-cleanup4aux.
457 2011-01-14 Ulrich Drepper <drepper@gmail.com>
460 * sysdeps/pthread/setxid.h (__SETXID_1): Add cast to assignment.
461 (__SETXID_2): Likewise.
462 (__SETXID_3): Likewise.
464 2011-01-13 Ulrich Drepper <drepper@gmail.com>
467 * Versions [libc] (GLIBC_PRIVATE): Export __libc_alloca_cutoff.
468 * alloca_cutoff.c: Add libc_hidden_def.
470 2010-10-13 H.J. Lu <hongjiu.lu@intel.com>
473 * sysdeps/x86_64/pthreaddef.h (TCB_ALIGNMENT): Changed to 32.
474 * sysdeps/x86_64/tls.h (TLS_TCB_ALIGN): Defined with alignment
477 2010-09-21 Andreas Schwab <schwab@redhat.com>
479 * sysdeps/pthread/pthread.h (pthread_cleanup_push)
480 [!__EXCEPTIONS]: Mangle local variable not_first_call.
481 (pthread_cleanup_push_defer_np): Likewise.
483 2010-09-03 Ulrich Drepper <drepper@redhat.com>
485 * sysdeps/pthread/allocalim.h (__libc_use_alloca): Expect blocks are
488 2010-08-10 Dinakar Guniguntala <dino@in.ibm.com>
489 Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
491 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: If
492 FUTEX_WAKE_OP fails make sure to call FUTEX_WAKE instead.
494 2010-08-12 H.J. Lu <hongjiu.lu@intel.com>
496 * sysdeps/unix/sysv/linux/i386/Makefile: New file.
498 2010-05-01 Alan Modra <amodra@gmail.com>
500 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
501 (PSEUDO): Use correct cr save. Don't use wrong parm save area
502 to save temps. Correct cfi for possible later frame manipulation.
503 (DOCARGS_1, UNDOCARGS_1): Use the correct parm save area.
504 (DOCARGS_2, UNDOCARGS_2, DOCARGS_3, UNDOCARGS_3): Likewise.
505 (DOCARGS_4, UNDOCARGS_4, DOCARGS_5, UNDOCARGS_5): Likewise.
506 (DOCARGS_6, UNDOCARGS_6): Likewise.
507 (CENABLE, CDISABLE): Add nops for non-shared calls.
509 2010-07-06 Andreas Schwab <schwab@redhat.com>
511 * sysdeps/unix/sysv/linux/pthread_getname.c (pthread_getname_np):
514 2010-07-03 Ulrich Drepper <drepper@redhat.com>
516 * tst-abstime.c (do_test): Some more cleanups
518 2010-07-02 Ulrich Drepper <drepper@redhat.com>
520 * tst-abstime.c: Correct testing and add test for sem_timedwait.
522 2010-07-01 Andreas Schwab <schwab@redhat.com>
523 Ulrich Drepper <drepper@redhat.com>
525 * Makefile (tests): Add tst-abstime.
526 * tst-abstime.c: New file.
527 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
528 (__lll_timedlock_wait): Check for timestamp before the Epoch.
529 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
530 (__lll_timedlock_wait): Likewise.
531 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S
532 (__lll_robust_timedlock_wait): Likewise.
533 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
534 (__pthread_cond_timedwait): Likewise.
535 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
536 (pthread_rwlock_timedrdlock): Likewise.
537 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
538 (pthread_rwlock_timedwrlock): Likewise.
539 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
542 2010-07-01 Ulrich Drepper <drepper@redhat.com>
544 * Makefile (tst-_res1): Add tst-_res1mod1 to dependency list.
546 2010-06-01 Takashi Yoshii <takashi.yoshii.zj@renesas.com>
548 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Fix incorrect
549 location of ifndef __ASSUME_FUTEX_CLOCK_REALTIME.
551 2010-04-09 Ulrich Drepper <drepper@redhat.com>
554 * sysdeps/unix/sysv/linux/pthread_getname.c: New file.
555 * sysdeps/unix/sysv/linux/pthread_setname.c: New file.
556 * nptl/sysdeps/pthread/pthread.h: Declare pthread_getname and
558 * Makefile (libpthread-routines): Add pthread_getname and
560 * Versions: Export pthread_getname and pthread_setname for GLIBC_2.12.
562 2010-04-05 Thomas Schwinge <thomas@schwinge.name>
564 * sysdeps/pthread/unwind-resume.c: Moved to main tree sysdeps/gnu/.
565 * sysdeps/pthread/rt-unwind-resume.c: Likewise.
566 * sysdeps/pthread/Makefile: Remove csu section and rt section's
567 unwind-resume bits, now in main tree sysdeps/gnu/Makefile instead.
569 2010-03-23 Luis Machado <luisgpm@br.ibm.com>
571 * pthread_cond_timedwait.c: Add check for
572 HAVE_CLOCK_GETTIME_VSYSCALL to use VDSO whenever possible.
573 (pthread_cond_timedwait): Use INTERNAL_VSYSCALL instead of
576 2010-03-09 Ulrich Drepper <drepper@redhat.com>
578 * pthread_create.c (__pthread_create_2_1): If priorities are incorrect
579 and the call fails wake eventually waiting setxid threads. Don't free
580 stack here if we try starting a thread.
581 * sysdeps/pthread/createthread.c (do_clone): Only wake setxid waiter
582 if the clone call failed.
584 2010-03-08 Andreas Schwab <schwab@redhat.com>
586 * pthread_create.c (__pthread_create_2_1): Don't set setxid_futex.
587 * allocatestack.c (get_cached_stack): Set setxid_futex.
588 (allocate_stack): Likewise.
590 2010-03-05 Andreas Schwab <schwab@redhat.com>
591 Ulrich Drepper <drepper@redhat.com>
593 * allocatestack.c (setxid_mark_thread): Delay handling of thread if
594 it is creating a thread or it is just being created.
595 * pthread_create.c (start_thread): Wake setxid thread if it is
597 (__pthread_create_2_1): Initialize setxid_futex.
598 * sysdeps/pthread/createthread.c (do_clone): Wake setxid thread if it
601 2010-01-15 Ulrich Drepper <drepper@redhat.com>
603 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
605 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
607 2010-01-15 Michal Schmidt <mschmidt@redhat.com>
609 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
610 Fix pthread_cond_timedwait with requeue-PI.
611 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
612 Fix pthread_cond_wait with requeue-PI.
614 2010-01-14 Ulrich Drepper <drepper@redhat.com>
616 * Versions: Add pthread_mutex_consistent, pthread_mutexattr_getrobust,
617 and pthread_mutexattr_setrobust for GLIBC_2.12.
618 * pthread_mutex_consistent.c: Define alias pthread_mutex_consistent.
619 * pthread_mutexattr_getrobust.c: Define alias
620 pthread_mutexattr_getrobust.
621 * pthread_mutexattr_setrobust.c: Define alias
622 pthread_mutexattr_setrobust.
624 2010-01-12 Ulrich Drepper <drepper@redhat.com>
626 * sysdeps/pthread/pthread.h: Cleanup. Fix up for XPG7.
628 2010-01-08 Ulrich Drepper <drepper@redhat.com>
630 * sysdeps/pthread/pthread.h: Fix pthread_mutex_consistent declaration.
632 2009-12-18 Thomas Schwinge <thomas@codesourcery.com>
634 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c (_init): Don't
636 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c (_init): Likewise.
638 2009-12-17 Ulrich Drepper <drepper@redhat.com>
640 * pthread_rwlock_init.c (__pthread_rwlock_init): Simplify code by
643 2009-12-01 Dinakar Guniguntala <dino@in.ibm.com>
645 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.h: Define
646 FUTEX_WAIT_REQUEUE_PI and FUTEX_CMP_REQUEUE_PI.
647 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: If mutex
648 is a non robust PI mutex, then use FUTEX_CMP_REQUEUE_PI.
649 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
650 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: If mutex
651 is a non robust PI mutex, then use FUTEX_WAIT_REQUEUE_PI.
652 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
654 2009-12-12 Ulrich Drepper <drepper@redhat.com>
656 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
657 Don't update nwaiters after invalid timeout is recognized.
659 2009-11-27 Thomas Schwinge <thomas@codesourcery.com>
661 * sysdeps/unix/sysv/linux/sh/pt-initfini.c (_init): Don't call
664 2009-11-27 Andreas Schwab <schwab@redhat.com>
666 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: Reload
667 THREAD_SELF->cancelhandling after returning from futex call.
669 2009-11-24 Ulrich Drepper <drepper@redhat.com>
671 * tst-sem13.c: New file.
672 * Makefile (tests): Add tst-sem13.
674 2009-11-22 Roland McGrath <roland@redhat.com>
676 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: # include "i686/dl-sysdep.h"
677 instead of recapitulating its contents.
679 2009-11-18 Ulrich Drepper <drepper@redhat.com>
681 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Minor
682 optimizations and cleanups.
684 2009-11-18 Dinakar Guniguntala <dino@in.ibm.com>
686 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S:
687 Remove redundant code. Fix cfi offsets.
688 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S:
691 2009-11-17 Ulrich Drepper <drepper@redhat.com>
693 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Minimally
694 reduce size of unwind info.
696 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Convert to use
698 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
699 Based on a patch by Dinakar Guniguntala <dino@in.ibm.com>.
701 2009-11-03 Andreas Schwab <schwab@linux-m68k.org>
704 * sysdeps/pthread/unwind-resume.c: Include <libgcc_s.h> and use
706 * sysdeps/pthread/unwind-forcedunwind.c: Likewise.
708 2009-10-30 Ulrich Drepper <drepper@redhat.com>
710 * tst-sem11.c (main): Rewrite to avoid aliasing problems.
713 * allocatestack.c (__nptl_setxid): Perform the operation in multiple
714 steps to avoid races with creation and terminations.
715 * nptl-init.c (sighandler_setxid): Adjust.
716 Patch by Daniel Jacobowitz.
718 2009-09-07 Andreas Schwab <schwab@redhat.com>
720 * sysdeps/pthread/bits/libc-lock.h (BP_SYM): Remove space before paren.
722 2009-09-02 Suzuki K P <suzuki@in.ibm.com>
723 Joseph Myers <joseph@codesourcery.com>
726 * sysdeps/unix/sysv/linux/timer_create.c (timer_create):
727 Initialize the sigev_notify field for newly created timer to make sure
728 the timer gets deleted from the active timer's list upon timer_delete.
730 2009-08-27 Andrew Stubbs <ams@codesourcery.com>
732 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_timedlock_wait):
733 Correct a logic error.
735 2009-08-25 Ulrich Drepper <drepper@redhat.com>
737 * sysdeps/x86_64/tls.h (RTLD_ENABLE_FOREIGN_CALL): Store old value
738 of the field in local variables.
739 (RTLD_FINALIZE_FOREIGN_CALL): Restore rtld_must_xmm_save from local
740 variable and don't unconditionally clear it.
742 2009-08-24 Ulrich Drepper <drepper@redhat.com>
744 * pthread_create.c (start_thread): Hint to the kernel that memory for
745 the stack can be reused. We do not mark all the memory. The part
746 still in use and some reserve are kept.
748 2009-08-23 Ulrich Drepper <drepper@redhat.com>
750 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Clean up namespace.
752 2009-08-11 Ulrich Drepper <drepper@redhat.com>
754 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Add CFI
757 2009-08-10 Ulrich Drepper <drepper@redhat.com>
759 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Add CFI
761 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
763 2009-08-10 Andreas Schwab <schwab@redhat.com>
765 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
766 (__pthread_cond_signal): Don't clobber register used for syscall
769 2009-08-08 Ulrich Drepper <drepper@redhat.com>
771 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
772 Optimize code path used when FUTEX_CLOCK_REALTIME is supported.
774 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
775 (__pthread_cond_wait): Optimize by avoiding use of callee-safe
778 2009-08-07 Ulrich Drepper <drepper@redhat.com>
780 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Little optimizations
781 enabled by the special *_asynccancel functions.
782 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
783 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
785 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: Include lowlevellock.h.
787 2009-08-04 Ulrich Drepper <drepper@redhat.com>
789 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: New file.
790 * sysdeps/unix/sysv/linux/x86_64/libc-cancellation.S: New file.
791 * sysdeps/unix/sysv/linux/x86_64/librt-cancellation.S: New file.
792 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (PSEUDO): Optimize
793 since we can assume the special __*_{en,dis}able_asynccancel
795 (PUSHARGS_*, POPARGS_*, SAVESTK_*, RESTSTK_*): Removed.
796 * sysdeps/x86_64/tcb-offsets.sym: Add cancellation-related bits
797 and PTHREAD_CANCELED.
799 2009-07-31 Ulrich Drepper <drepper@redhat.com>
801 * descr.h: Better definition of *_BITMASK macros for cancellation.
803 2009-07-29 Ulrich Drepper <drepper@redhat.com>
805 * sysdeps/x86_64/tls.h (TLS_TCB_ALIGN): Define explicitly to 32.
807 * sysdeps/x86_64/tls.h (tcbhead_t): Add room for SSE registers the
808 dynamic linker might have to save.
809 Define RTLD_CHECK_FOREIGN_CALL, RTLD_ENABLE_FOREIGN_CALL,
810 RTLD_PREPARE_FOREIGN_CALL, and RTLD_FINALIZE_FOREIGN_CALL. Pretty
813 * sysdeps/x86_64/tcb-offsets.sym: Add RTLD_SAVESPACE_SSE.
815 2009-07-28 Ulrich Drepper <drepper@redhat.com>
817 * pthread_mutex_lock.c [NO_INCR] (__pthread_mutex_cond_lock_adjust):
819 * pthreadP.h: Declare __pthread_mutex_cond_lock_adjust.
820 * sysdeps/unix/sysv/linux/pthread-pi-defines.sym: Add ROBUST_BIT.
821 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Don't use
822 requeue_pi for robust mutexes.
823 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
824 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
825 Don't only skip __pthread_mutex_cond_lock. Call instead
826 __pthread_mutex_cond_lock_adjust.
827 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
829 * pthread_mutex_unlock.c (__pthread_mutex_unlock_full): Minor
830 optimization of PI mutex handling.
832 2009-07-27 Ulrich Drepper <drepper@redhat.com>
835 * pthread_mutex_unlock.c (__pthread_mutex_unlock_full): Use _rel
836 instead of of _acq variants of cmpxchg.
838 2009-07-23 Ulrich Drepper <drepper@redhat.com>
840 * sysdeps/x86_64/configure.in: New file.
842 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Fix error
843 path when not using absolute timeout futex.
845 2009-07-20 Ulrich Drepper <drepper@redhat.com>
847 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Minor
848 optimizations of last changes.
849 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
851 2009-07-19 Ulrich Drepper <drepper@redhat.com>
853 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Define
854 FUTEX_WAIT_REQUEUE_PI and FUTEX_CMP_REQUEUE_PI.
855 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: If mutex
856 is a PI mutex, then use FUTEX_CMP_REQUEUE_PI.
857 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
858 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: If mutex
859 is a PI mutex, then use FUTEX_WAIT_REQUEUE_PI.
860 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
862 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
863 (__pthread_cond_timedwait): Make more robust.
865 2009-07-18 Ulrich Drepper <drepper@redhat.com>
867 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S
868 (__lll_robust_timedlock_wait): If possible use FUTEX_WAIT_BITSET to
869 directly use absolute timeout.
871 * tst-sem5.c (do_test): Add test for premature timeout.
872 * Makefile: Linu tst-sem5 with librt.
874 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
875 (pthread_rwlock_timedwrlock): If possible use FUTEX_WAIT_BITSET to
876 directly use absolute timeout.
877 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
878 (pthread_rwlock_timedrdlock): Likewise.
880 * tst-cond11.c (run_test): Add test to check that the timeout is
883 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
884 (__pthread_cond_timedwait): If possible use FUTEX_WAIT_BITSET to
885 directly use absolute timeout.
887 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
888 (__pthread_cond_wait): Convert to using exception handler instead of
889 registered unwind buffer.
890 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
891 (__pthread_cond_timedwait): Likewise.
893 2009-07-17 Ulrich Drepper <drepper@redhat.com>
895 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
896 If possible use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME to directly
897 use absolute timeout.
899 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S (sem_wait): Optimize
900 handling of uncontested semaphore.
902 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
903 (__condvar_cleanup): Rewrite to use cfi directives instead of
904 hand-coded unwind tables.
905 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S (__pthread_once):
907 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S (sem_wait): Likewise.
908 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
911 2009-06-12 Ulrich Drepper <drepper@redhat.com>
913 * Makefile (libpthread-routines): Add pthread_sigqueue.
914 * Versions: Add pthread_sigqueue for GLIBC_2.11.
915 * sysdeps/pthread/bits/sigthread.h: Declare pthread_sigqueue.
916 * sysdeps/unix/sysv/linux/pthread_sigqueue.c: New file.
918 2009-06-11 Ulrich Drepper <drepper@redhat.com>
921 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
922 (LOAD_FUTEX_WAIT_ABS): Fix futex parameter in case private futexes
924 Patch by Bryan Kadzban <bz-glibc@kdzbn.homelinux.net>.
926 2009-05-16 Ulrich Drepper <drepper@redhat.com>
928 * libc-cancellation.c: Move __libc_cleanup_routine to...
929 * libc-cleanup.c: ...here. New file.
930 * Makefile (routines): Add libc-cleanup.
932 * cancellation.c (__pthread_disable_asynccancel): Remove unnecessary
934 * libc-cancellation.c: Use <nptl/cancellation.c: to define the code.
935 * sysdeps/pthread/librt-cancellation.c: Likewise.
938 * nptl-init.c: Renamed from init.c.
939 * Makefile: Change all occurences of init.c to nptl-init.c.
941 2009-05-15 Ulrich Drepper <drepper@redhat.com>
943 * cancellation.c (__pthread_disable_asynccancel): Correct the bits
944 to test when deciding on the delay.
945 * libc-cancellation.c (__libc_disable_asynccancel): Likewise.
946 * pthread_cancel.c: Close race between deciding on sending a signal
947 and setting the CANCELING_BIT bit.
949 * cancellation.c (__pthread_disable_asynccancel): Don't return if
951 * libc-cancellation.c (__libc_disable_asynccancel): Likewise.
953 2009-04-27 Ulrich Drepper <drepper@redhat.com>
955 * cancellation.c (__pthread_disable_asynccancel): Use THREAD_ATOMIC_AND
957 * libc-cancellation.c (__libc_disable_asynccancel): Likewise.
958 * sysdeps/x86_64/tls.h: Define THREAD_ATOMIC_AND.
959 * sysdeps/i386/tls.h: Likewise.
960 (tcbhead_t): Add __private_tm member.
962 2009-04-26 Ulrich Drepper <drepper@redhat.com>
964 * sem_open.c (sem_open): Rewrite initialization of initsem to
967 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
968 Avoid warning by using may_alias attribute on ptrhack.
970 2009-04-22 Ulrich Drepper <drepper@redhat.com>
973 * pthread_attr_setschedparam.c (__pthread_attr_setschedparam):
974 Check policy and priority for validity.
975 Patch mostly by Zhang Xiliang <zhangxiliang@cn.fujitsu.com>.
977 2009-03-15 Ulrich Drepper <drepper@redhat.com>
979 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
980 (__pthread_cond_timedwait): Change to use cfi directives instead of
981 hand-coded unwind sections.
983 2009-03-10 Ulrich Drepper <drepper@redhat.com>
985 * init.c (nptl_freeres): Compile only for SHARED.
987 2009-03-09 Jakub Jelinek <jakub@redhat.com>
989 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Define
990 FUTEX_WAIT_BITSET, FUTEX_WAKE_BITSET, FUTEX_CLOCK_REALTIME and
991 FUTEX_BITSET_MATCH_ANY.
993 2009-02-27 Roland McGrath <roland@redhat.com>
995 * init.c (__nptl_initial_report_events): Mark __attribute_used__.
996 * pthread_create.c (__nptl_threads_events, __nptl_last_event): Likewise.
998 2009-02-26 Ulrich Drepper <drepper@redhat.com>
1000 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
1001 _POSIX_THREAD_ROBUST_PRIO_INHERIT and
1002 _POSIX_THREAD_ROBUST_PRIO_PROTECT. Reset value of macros from
1005 2009-02-25 Ulrich Drepper <drepper@redhat.com>
1007 * sysdeps/pthread/pthread.h: The robust mutex functions are in
1010 2009-02-24 Ulrich Drepper <drepper@redhat.com>
1012 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_BITS_POSIX_OPT_H):
1013 Unify name of include protector macro.
1015 2009-02-14 SUGIOKA Toshinobu <sugioka@itonet.co.jp>
1017 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Define
1018 LOAD_FUTEX_WAIT_ABS even if (FUTEX_WAIT == 0).
1020 2009-01-29 Ulrich Drepper <drepper@redhat.com>
1022 * sysdeps/pthread/unwind-forcedunwind.c: Encrypt all function
1025 * allocatestack.c (__free_stacks): Renamed from free_stacks.
1026 (__free_stack_cache): Removed. Change callers to call __free_stacks.
1027 * init.c (nptl_freeres): New function.
1028 (pthread_functions): Initialize ptr_freeres to nptl_freeres.
1029 * pthreadP.h: Don't declare __free_stack_cache. Declare __free_stacks.
1030 * sysdeps/pthread/unwind-forcedunwind.c (libgcc_s_handle): New
1032 (pthread_cancel_init): Depend in libgcc_s_handle for decision to
1033 load DSO. Assign last.
1034 (__unwind_freeres): New function.
1036 * allocatestack.c (__reclaim_stacks): Reset in_flight_stack later
1037 for better debugging. No need to use stack_list_add here.
1039 2009-01-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1041 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
1042 (__lll_timedlock_wait): Use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME
1043 instead of computing relative timeout.
1044 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Define
1045 FUTEX_CLOCK_REALTIME and FUTEX_BITSET_MATCH_ANY.
1047 2009-01-25 Ulrich Drepper <drepper@redhat.com>
1049 * pthread_mutex_lock.c (__pthread_mutex_lock): Remove unused label out.
1051 2009-01-08 Ulrich Drepper <drepper@redhat.com>
1053 * sysdeps/pthread/list.h (list_add): Initialize new element first.
1054 (list_add_tail): Removed.
1056 2009-01-07 Ulrich Drepper <drepper@redhat.com>
1058 * (in_flight_stack): New variable.
1059 (stack_list_del): New function. Use instead of list_del.
1060 (stack_list_add): New function. Use instead of list_add when adding to
1061 stack_cache and stack_used lists.
1062 (__reclaim_stacks): Complete operations on stack_cache and stack_used lists
1063 when the fork call interrupted another thread.
1065 2009-01-04 Ulrich Drepper <drepper@redhat.com>
1067 * init.c (__pthread_initialize_minimal_internal): Optimize test
1068 FUTEX_CLOCK_REALTIME a bit.
1070 2009-01-03 Ulrich Drepper <drepper@redhat.com>
1072 * init.c (__pthread_initialize_minimal_internal): Cheat a bit by
1073 only passing five parameters to FUTEX_WAIT_BITSET call.
1075 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
1076 (__lll_timedlock_wait): Use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME
1077 instead of computing relative timeout.
1079 2009-01-02 Ulrich Drepper <drepper@redhat.com>
1081 * init.c (__pthread_initialize_minimal_internal): Check for
1082 FUTEX_CLOCK_REALTIME flag.
1083 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S (__lll_timedlock_wait):
1084 Use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME instead of computing
1087 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Define
1088 FUTEX_CLOCK_REALTIME and FUTEX_BITSET_MATCH_ANY.
1089 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
1090 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
1091 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
1092 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
1094 2008-12-09 Ulrich Drepper <drepper@redhat.com>
1096 * sysdeps/pthread/pthread.h (pthread_cleanup_pop): Use { } as empty
1097 loop body instead of ; to avoid gcc warnings.
1098 (pthread_cleanup_pop_restore_np): Likewise.
1099 Patch by Caolán McNamara <caolanm@redhat.com>.
1101 2008-12-09 Jakub Jelinek <jakub@redhat.com>
1103 * pthread_mutex_lock.c (__pthread_mutex_lock): Handle only the
1104 fast path here, for robust/PI/PP mutexes call
1105 __pthread_mutex_lock_full. Don't use switch, instead use a series
1106 of ifs according to their probability.
1107 (__pthread_mutex_lock_full): New function.
1108 * pthread_mutex_unlock.c: Include assert.h.
1109 (__pthread_mutex_unlock_usercnt): Handle only the
1110 fast path here, for robust/PI/PP mutexes call
1111 __pthread_mutex_unlock_full. Don't use switch, instead use a series
1112 of ifs according to their probability.
1113 (__pthread_mutex_unlock_full): New function.
1114 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c
1115 (__pthread_mutex_lock_full): Define.
1117 2008-12-08 Ulrich Drepper <drepper@redhat.com>
1119 * sysdeps/x86_64/tls.h (tcbhead_t): Add fields reserved for TM
1120 implementation. Add necessary padding and.
1121 * descr.h (struct pthread): Increase padding for tcbhead_t to 24
1124 2008-12-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1126 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Define FUTEX_WAIT_BITSET
1127 and FUTEX_WAKE_BITSET.
1129 2008-12-02 Ulrich Drepper <drepper@redhat.com>
1131 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define FUTEX_WAIT_BITSET
1132 and FUTEX_WAKE_BITSET.
1133 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
1134 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
1135 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
1136 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
1138 2008-11-25 Roland McGrath <roland@redhat.com>
1140 * sysdeps/alpha, sysdeps/unix/sysv/linux/alpha:
1141 Subdirectories moved to ports repository as
1142 sysdeps/.../nptl subdirectories.
1144 2008-11-12 Jakub Jelinek <jakub@redhat.com>
1147 * pthread_condattr_setclock.c (pthread_condattr_setclock): Fix masking
1149 * pthread_cond_init.c (__pthread_cond_init): Fix
1150 cond->__data.__nwaiters initialization.
1151 * Makefile (tests): Add tst-cond23.
1152 * tst-cond23.c: New test.
1154 2008-11-07 Jakub Jelinek <jakub@redhat.com>
1156 * sysdeps/pthread/malloc-machine.h (MALLOC): Adjust __libc_tsd_define
1158 (tsd_setspecific, tsd_getspecific): Adjust __libc_tsd_{set,get}
1161 2008-11-01 Ulrich Drepper <drepper@redhat.com>
1164 * pthread_mutex_lock.c: Add support for private PI mutexes.
1165 * pthread_mutex_timedlock.c: Likewise.
1166 * pthread_mutex_trylock.c: Likewise.
1167 * pthread_mutex_unlock.c: Likewise.
1168 Patch mostly by Ben Jackson <ben@ben.com>.
1170 2008-10-31 Ulrich Drepper <drepper@redhat.com>
1173 * sysdeps/pthread/gai_misc.h (__gai_create_helper_thread):
1174 Increase stack size for helper thread.
1176 2008-10-06 Martin Schwidefsky <schwidefsky@de.ibm.com>
1178 * sysdeps/s390/tls.h (THREAD_SET_STACK_GUARD): Add empty inline
1179 assembly with a clobber list for access registers a0 and a1.
1181 2008-09-11 Martin Schwidefsky <schwidefsky@de.ibm.com>
1183 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Add memory barrier
1184 to force runp->refcntr to be read from memory.
1186 2008-09-08 Richard Guenther <rguenther@suse.de>
1188 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_lock,
1189 lll_robust_lock, lll_cond_lock, lll_robust_cond_lock,
1190 lll_timedlock, lll_robust_timedlock, lll_unlock,
1191 lll_robust_unlock): Promote private to int.
1193 2008-08-15 Ulrich Drepper <drepper@redhat.com>
1195 * sysdeps/x86_64/pthreaddef.h: Remove ARCH_MAP_FLAGS and
1196 ARCH_RETRY_MMAP definitions.
1197 * allocatestack.c: Remove definition of ARCH_MAP_FLAGS.
1198 Define MAP_STACK when not defined.
1199 (allocate_stack): Use MAP_STACK instead of ARCH_MAP_FLAGS. Remove
1200 handling of ARCH_RETRY_MMAP.
1202 2008-07-30 Ulrich Drepper <drepper@redhat.com>
1204 * tst-align2.c (f): Print message that f is reached.
1206 2008-04-28 Hiroki Kaminaga <kaminaga@sm.sony.co.jp>
1209 * sysdeps/powerpc/tcb-offsets.sym (PRIVATE_FUTEX_OFFSET): Guard symbol
1210 definition with #ifndef __ASSUME_PRIVATE_FUTEX.
1212 2008-07-25 Ulrich Drepper <drepper@redhat.com>
1214 * sysdeps/unix/sysv/linux/mq_notify.c (init_mq_netlink): Use
1215 SOCK_CLOEXEC if possible.
1217 2008-05-29 Ulrich Drepper <drepper@redhat.com>
1219 * Makefile (tests): Add tst-rwlock2a.
1220 * tst-rwlock2.c: Use TYPE macro to decide what rwlock type to use.
1221 * tst-rwlock2a.c: New file.
1223 2008-06-12 Ulrich Drepper <drepper@redhat.com>
1225 * sysdeps/pthread/pthread.h: Remove inadvertant checkin.
1227 2008-05-17 Samuel Thibault <samuel.thibault@ens-lyon.org>
1229 * sysdeps/pthread/pthread.h: Fix typo in comment.
1231 2008-05-28 Ulrich Drepper <drepper@redhat.com>
1233 * sysdeps/pthread/createthread.c (do_clone): Pass accurate length
1234 of CPU set to the kernel.
1236 2008-05-23 Paul Pluzhnikov <ppluzhnikov@google.com>
1238 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Add
1240 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
1241 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
1242 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
1243 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
1244 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
1245 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
1247 2008-05-22 Paul Pluzhnikov <ppluzhnikov@google.com>
1249 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S: Add
1251 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
1253 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
1255 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
1258 2008-05-26 Ulrich Drepper <drepper@redhat.com>
1260 * tst-typesizes.c: Explicitly check __SIZEOF_PTHREAD_* constants.
1262 2008-05-20 Jakub Jelinek <jakub@redhat.com>
1264 David S. Miller <davem@davemloft.net>
1266 * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: New file.
1268 2008-05-10 Ulrich Drepper <drepper@redhat.com>
1270 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Access
1271 __pshared correctly.
1272 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
1274 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
1276 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
1278 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S:
1280 Reported by Clemens Kolbitsch <clemens.kol@gmx.at>.
1282 2008-04-14 David S. Miller <davem@davemloft.net>
1284 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
1285 (__old_sem_wait): Fix argument to lll_futex_wait().
1287 2007-11-26 Daniel Jacobowitz <dan@codesourcery.com>
1289 * pthread_create.c: Require pthread_mutex_trylock and
1290 pthread_key_delete for libgcc.
1292 2008-04-08 Jakub Jelinek <jakub@redhat.com>
1295 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h
1296 (lll_futex_wake_unlock): Add private argument to the pre-v9 macro.
1297 Patch by Sunil Amitkumar Janki <devel.sjanki@gmail.com>.
1299 2008-03-27 Ulrich Drepper <drepper@redhat.com>
1301 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine ARG_MAX if
1302 <linux/limits.h> has defined it.
1303 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
1304 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
1305 * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: Likewise.
1306 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
1308 2008-03-18 Jakub Jelinek <jakub@redhat.com>
1310 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: Use __ASSEMBLER__ instead
1312 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h: Likewise.
1313 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Likewise.
1315 2008-03-14 Ulrich Drepper <drepper@redhat.com>
1317 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define
1318 HAVE_DL_DISCOVER_OSVERSION.
1319 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h: Likewise.
1320 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: Likewise.
1322 2008-03-07 Ulrich Drepper <drepper@redhat.com>
1325 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Change
1326 _POSIX_CHOWN_RESTRICTED value to zero.
1328 2008-01-31 Roland McGrath <roland@redhat.com>
1330 * Makefile (omit-deps): Variable removed.
1332 2008-01-30 Ulrich Drepper <drepper@redhat.com>
1334 * sysdeps/unix/sysv/linux/x86_64/sem_post.S (sem_post): Avoid
1335 unnecessary addr32 prefix.
1337 2008-01-29 Roland McGrath <roland@redhat.com>
1339 * Makeconfig (ptw-CPPFLAGS, sysd-rules-patterns): New variables.
1341 2008-01-22 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1343 * sysdeps/unix/sysv/linux/sh/sem_post.S: Don't overflow value field.
1345 2008-01-21 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1347 * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h (XADD): Use
1349 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
1350 (__lll_lock_wait_private): Fix typo.
1351 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S
1352 (pthread_barrier_wait): Likewise. Adjust XADD use.
1353 * sysdeps/unix/sysv/linux/sh/sem_post.S (__new_sem_post):
1355 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S
1356 (pthread_rwlock_timedrdlock): Return correct return value.
1357 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S
1358 (pthread_rwlock_timedwrlock): Likewise.
1360 2008-01-15 Ulrich Drepper <drepper@redhat.com>
1362 * tst-eintr2.c (do_test): make sure that if mutex_lock in main
1363 thread returns the program exits with an error code.
1365 2008-01-10 Ulrich Drepper <drepper@redhat.com>
1367 * pthread-errnos.sym: Add EOVERFLOW.
1368 * sysdeps/unix/sysv/linux/structsem.sym: Add SEM_VALUE_MAX.
1369 * sysdeps/unix/sysv/linux/sem_post.c: Don't overflow value field.
1370 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
1371 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
1373 2007-12-14 Ulrich Drepper <drepper@redhat.com>
1375 * sysdeps/x86_64/pthreaddef.h (ARCH_RETRY_MMAP): Take additional
1376 parameter. Passed it as permission to mmap.
1377 * allocatestack.c (allocate_stack): Pass prot as second parameter
1380 2007-12-12 Ulrich Drepper <drepper@redhat.com>
1382 * tst-basic7.c: Allocate memory for the stack.
1385 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S [!SHARED]
1386 (__pthread_cond_timedwait): Don't use VDSO.
1387 Patch by Michal Januszewski.
1389 2007-12-07 Ulrich Drepper <drepper@redhat.com>
1392 * sysdeps/pthread/pthread.h [!__EXCEPTIONS] (pthread_cleanup_pop):
1393 Allow label before pthread_cleanup_pop.
1394 (pthread_cleanup_pop_restore_np): Likewise.
1396 2007-12-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1398 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_timedlock_wait):
1399 Store 2 before returning ETIMEDOUT.
1401 2007-11-23 Ulrich Drepper <drepper@redhat.com>
1403 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S (__lll_timedlock_wait):
1404 Store 2 before returning ETIMEDOUT.
1405 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise
1406 * sysdeps/unix/sysv/linux/lowlevellock.c: Likewise.
1407 (__lll_lock_wait_private): Optimize.
1408 (__lll_lock_wait): Likewise.
1410 2007-11-20 Jakub Jelinek <jakub@redhat.com>
1412 * sysdeps/pthread/pthread.h (pthread_cleanup_push,
1413 pthread_cleanup_push_defer_np): Add extra (void *) cast to shut up
1414 g++ 4.1 and 4.2 -Wstrict-aliasing warnings.
1416 2007-11-08 Ulrich Drepper <drepper@redhat.com>
1419 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait):
1420 If we time out, try one last time to lock the futex to avoid
1421 losing a wakeup signal.
1422 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
1423 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
1426 * sysdeps/pthread/createthread.c (do_clone): Translate clone error
1429 2007-11-07 Ulrich Drepper <drepper@redhat.com>
1432 * allocatestack.c (allocate_stack): Change ENOMEM error in case
1433 mmap failed to EAGAIN.
1434 * Makefile (tests): Add tst-basic7.
1435 * tst-basic7.c: New file.
1437 2007-11-05 Ulrich Drepper <drepper@redhat.com>
1439 * sysdeps/unix/sysv/linux/register-atfork.c (__register_atfork):
1440 Use __linkin_atfork.
1442 2007-11-03 Mike Frysinger <vapier@gentoo.org>
1444 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (LOAD_FUTEX_WAIT): Add
1445 missing line continuations.
1446 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S (LOAD_FUTEX_WAIT,
1447 LOAD_FUTEX_WAKE): Likewise. Also add missing 3rd parameter.
1449 2007-10-28 Ulrich Drepper <drepper@redhat.com>
1452 * sysdeps/unix/sysv/linux/kernel-posix-timers.h: Declare
1453 __active_timer_sigev_thread and __active_timer_sigev_thread_lock.
1454 (struct timer): Add next element.
1455 * sysdeps/unix/sysv/linux/timer_create.c: For SIGEV_THREAD timers,
1456 enqueue timer structure into __active_timer_sigev_thread list.
1457 * sysdeps/unix/sysv/linux/timer_delete.c: For SIGEV_THREAD timers,
1458 remove timer struct from __active_timer_sigev_thread.
1459 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
1460 Before using timer structure make sure it is still on the
1461 __active_timer_sigev_thread list. Keep lock until done.
1462 Define __active_timer_sigev_thread and
1463 __active_timer_sigev_thread_lock.
1465 2007-10-27 Ulrich Drepper <drepper@redhat.com>
1467 * sysdeps/pthread/malloc-machine.h: Define ATFORK_MEM.
1468 Redefine thread_atfork for use of ATFORK_MEM.
1469 * sysdeps/unix/sysv/linux/fork.h: Define __linkin_atfork.
1470 * sysdeps/unix/sysv/linux/register-atfork.c (__linkin_atfork): New
1472 * sysdeps/unix/sysv/linux/unregister-atfork.c (__unregister_atfork):
1473 Use atomic operation when removing first element of list.
1475 2007-10-17 Jakub Jelinek <jakub@redhat.com>
1477 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__old_sem_post): New
1478 routine instead of an alias to __new_sem_post.
1480 2007-10-15 Jakub Jelinek <jakub@redhat.com>
1482 * init.c (__pthread_initialize_minimal): Initialize word to appease
1485 2007-10-10 Jakub Jelinek <jakub@redhat.com>
1487 * sysdeps/pthread/bits/libc-lock.h (__libc_rwlock_init): Inside of
1488 libc.so just clear NAME.
1489 (__libc_rwlock_fini): Nop inside of libc.so.
1490 * tst-initializers1.c (main): Test if PTHREAD_RWLOCK_INITIALIZER is
1493 2007-09-02 Ulrich Drepper <drepper@redhat.com>
1495 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
1496 (__pthread_cond_wait): Fix unlocking of internal lock after mutex
1498 Patch by Luca Barbieri <luca.barbieri@gmail.com>.
1500 2007-08-21 Ulrich Drepper <drepper@redhat.com>
1503 * allocatestack.c (__reclaim_stacks): Clear the TSD in the
1504 reclaimed stack if necessary.
1505 * Makefile (tests): Add tst-tsd6.
1506 * tst-tsd6.c: New file.
1508 2007-08-21 Jakub Jelinek <jakub@redhat.com>
1510 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_robust_dead):
1511 Add private argument.
1513 2007-08-20 Ulrich Drepper <drepper@redhat.com>
1515 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
1516 (__pthread_cond_timedwait): Use clock_gettime from VDSO if possible.
1518 2007-08-16 Jakub Jelinek <jakub@redhat.com>
1520 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h
1521 (__lll_robust_timedlock): Pass private as last argument to
1522 __lll_robust_timedlock_wait.
1523 (__lll_unlock): Fix a pasto.
1525 2007-08-15 Jakub Jelinek <jakub@redhat.com>
1527 * sysdeps/unix/sysv/linux/sparc/internaltypes.h (sparc_new_sem,
1528 sparc_old_sem): New structs.
1529 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
1530 (__sem_wait_cleanup): New function.
1531 (__new_sem_wait): Use sparc_new_sem structure. Bump and afterwards
1532 decrease nwaiters. Register __sem_wait_cleanup as cleanup handler.
1533 Pass isem->private ^ FUTEX_PRIVATE_FLAG as last argument to
1535 (__old_sem_wait): New function.
1536 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_wait.c: Include
1537 nptl/sysdeps/unix/sysv/linux/sparc version.
1538 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_timedwait.c:
1540 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_post.c: Likewise.
1541 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_trywait.c
1542 (__new_sem_trywait): Use sparc_old_sem structure.
1543 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c
1544 (sem_timedwait): Use sparc_new_sem structure. Bump and afterwards
1545 decrease nwaiters. Register __sem_wait_cleanup as cleanup handler.
1546 Pass isem->private ^ FUTEX_PRIVATE_FLAG as last argument to
1547 lll_futex_timed_wait.
1548 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_post.c (__new_sem_post):
1549 Use sparc_new_sem structure. Only wake if nwaiters > 0. Pass
1550 isem->private ^ FUTEX_PRIVATE_FLAG as last argument to
1552 (__old_sem_post): New function.
1553 * sysdeps/unix/sysv/linux/sparc/sem_wait.c: New file.
1554 * sysdeps/unix/sysv/linux/sparc/sem_init.c: New file.
1555 * sysdeps/unix/sysv/linux/sparc/sem_timedwait.c: New file.
1556 * sysdeps/unix/sysv/linux/sparc/sem_post.c: New file.
1557 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_init.c: Remove.
1558 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_init.c: Remove.
1560 2007-08-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1562 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
1563 (__pthread_cond_broadcast): Pass LLL_PRIVATE to lll_* and or
1564 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
1565 Don't use FUTEX_CMP_REQUEUE if dep_mutex is not process private.
1566 * sysdeps/unix/sysv/linux/shpthread_cond_signal.S
1567 (__pthread_cond_signal): Pass LLL_PRIVATE to lll_* and or
1568 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
1570 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Include
1571 kernel-features.h and tcb-offsets.h.
1572 (__pthread_cond_wait, __condvar_w_cleanup): Pass LLL_PRIVATE to
1573 lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
1575 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Include
1577 (__pthread_cond_timedwait, __condvar_tw_cleanup): Pass LLL_PRIVATE
1578 to lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
1580 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Use #ifdef
1581 __ASSUME_PRIVATE_FUTEX instead of #if __ASSUME_PRIVATE_FUTEX.
1582 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
1583 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
1584 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
1585 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
1586 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
1588 2007-08-14 Jakub Jelinek <jakub@redhat.com>
1590 * sysdeps/unix/sysv/linux/lowlevellock.c: Comment fix.
1591 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c
1592 (__lll_timedwait_tid): Pass LLL_SHARED as 4th argument to
1593 lll_futex_timed_wait.
1595 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (__lll_unlock,
1596 __lll_robust_unlock): Rewrite as macros instead of inline functions.
1597 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (__lll_unlock,
1598 __lll_robust_unlock, __lll_wait_tid): Likewise.
1600 2007-08-13 Jakub Jelinek <jakub@redhat.com>
1602 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (__lll_private_flag):
1604 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
1605 (__pthread_cond_broadcast): Pass LLL_PRIVATE to lll_* and or
1606 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
1607 Don't use FUTEX_CMP_REQUEUE if dep_mutex is not process private.
1608 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
1609 (__pthread_cond_signal): Pass LLL_PRIVATE to lll_* and or
1610 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
1611 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Include
1613 (__pthread_cond_wait, __condvar_w_cleanup): Pass LLL_PRIVATE to
1614 lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
1615 process private. Switch DW_CFA_advance_loc1 and some
1616 DW_CFA_advance_loc .eh_frame opcodes to DW_CFA_advance_loc4.
1617 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
1618 (__pthread_cond_timedwait, __condvar_tw_cleanup): Pass LLL_PRIVATE to
1619 lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
1620 process private. Switch DW_CFA_advance_loc{1,2} and some
1621 DW_CFA_advance_loc .eh_frame opcodes to DW_CFA_advance_loc4.
1622 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Use
1623 #ifdef __ASSUME_PRIVATE_FUTEX instead of #if __ASSUME_PRIVATE_FUTEX.
1624 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
1626 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
1627 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
1628 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
1630 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
1631 (__pthread_cond_broadcast): Compare %r8 instead of
1632 dep_mutex-cond_*(%rdi) with $-1.
1633 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
1634 (__pthread_cond_signal): Xor FUTEX_WAKE_OP with FUTEX_WAKE instead
1637 2007-08-13 Ulrich Drepper <drepper@redhat.com>
1639 * sysdeps/unix/sysv/linux/i386/i786/Implies: New file.
1641 2007-08-13 Jakub Jelinek <jakub@redhat.com>
1643 * allocatestack.c: Include kernel-features.h.
1644 * pthread_create.c: Likewise.
1645 * pthread_mutex_init.c: Likewise.
1647 * pthread_cond_timedwait.c: Likewise.
1648 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
1649 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
1650 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
1651 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
1652 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
1653 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
1654 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
1656 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
1658 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
1659 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
1660 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
1661 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
1663 2007-08-12 Jakub Jelinek <jakub@redhat.com>
1665 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h
1666 [__WORDSIZE=32] (pthread_rwlock_t): Split __flags element into four
1667 byte elements. One of them is the new __shared element.
1668 [__WORDSIZE=64] (pthread_rwlock_t): Renamed __pad1 element to __shared,
1669 adjust names of other padding elements.
1670 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h
1671 [__WORDSIZE=32] (pthread_rwlock_t): Split __flags element into four
1672 byte elements. One of them is the new __shared element.
1673 [__WORDSIZE=64] (pthread_rwlock_t): Renamed __pad1 element to __shared,
1674 adjust names of other padding elements.
1675 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_rwlock_t):
1676 Renamed __pad1 element to __shared, adjust names of other padding
1678 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
1679 (pthread_rwlock_t): Likewise.
1680 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_lock): Fix a
1683 2007-08-09 Anton Blanchard <anton@samba.org>
1685 * sysdeps/unix/sysv/linux/powerpc/pthread_spin_unlock.c: New file.
1687 2007-08-12 Ulrich Drepper <drepper@redhat.com>
1689 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Include
1690 <kernel-features.h>.
1691 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
1693 2007-08-11 Ulrich Drepper <drepper@redhat.com>
1695 * pthreadP.h (PTHREAD_ROBUST_MUTEX_PSHARED): Define.
1696 * pthread_mutex_lock.c: Use it instead of PTHREAD_MUTEX_PSHARED when
1697 dealing with robust mutexes.
1698 * pthread_mutex_timedlock.c: Likewise.
1699 * pthread_mutex_trylock.c: Likewise.
1700 * pthread_mutex_unlock.c: Likewise.
1701 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
1703 2007-08-06 Jakub Jelinek <jakub@redhat.com>
1705 * pthreadP.h (PTHREAD_MUTEX_PSHARED_BIT): Define.
1706 (PTHREAD_MUTEX_TYPE): Mask __kind with 127.
1707 (PTHREAD_MUTEX_PSHARED): Define.
1708 * pthread_mutex_init.c (__pthread_mutex_init): Set
1709 PTHREAD_MUTEX_PSHARED_BIT for pshared or robust
1711 * pthread_mutex_lock.c (LLL_MUTEX_LOCK): Take mutex as argument
1712 instead of its __data.__lock field, pass PTHREAD_MUTEX_PSHARED
1713 as second argument to lll_lock.
1714 (LLL_MUTEX_TRYLOCK): Take mutex as argument
1715 instead of its __data.__lock field.
1716 (LLL_ROBUST_MUTEX_LOCK): Take mutex as argument instead of its
1717 __data.__lock field, pass PTHREAD_MUTEX_PSHARED as second argument
1719 (__pthread_mutex_lock): Update LLL_MUTEX_LOCK, LLL_MUTEX_TRYLOCK,
1720 LLL_ROBUST_MUTEX_LOCK users, use PTHREAD_MUTEX_TYPE (mutex)
1721 instead of mutex->__data.__kind directly, pass
1722 PTHREAD_MUTEX_PSHARED (mutex) to lll_unlock and lll_futex_wait.
1723 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Use
1724 PTHREAD_MUTEX_TYPE (mutex) instead of mutex->__data.__kind
1725 directly, pass PTHREAD_MUTEX_PSHARED (mutex) to lll_unlock.
1726 (pthread_mutex_timedlock): Pass PTHREAD_MUTEX_PSHARED (mutex)
1727 to lll_timedlock, lll_robust_timedlock, lll_unlock and
1728 lll_futex_timed_wait. Use PTHREAD_MUTEX_TYPE (mutex) instead
1729 of mutex->__data.__kind directly.
1730 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Pass
1731 PTHREAD_MUTEX_PSHARED (mutex) to lll_timedlock,
1732 lll_robust_timedlock, lll_unlock and lll_futex_timed_wait. Use
1733 PTHREAD_MUTEX_TYPE (mutex) instead of mutex->__data.__kind directly.
1734 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Pass
1735 PTHREAD_MUTEX_PSHARED (mutex) to lll_unlock, lll_robust_unlock
1737 * pthread_mutex_setprioceiling.c (pthread_mutex_setprioceiling): Pass
1738 PTHREAD_MUTEX_PSHARED (mutex) to lll_futex_wait and lll_futex_wake.
1739 Use PTHREAD_MUTEX_TYPE (mutex) instead of mutex->__data.__kind
1741 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c (LLL_MUTEX_LOCK):
1742 Take mutex as argument instead of its __data.__lock field, pass
1743 PTHREAD_MUTEX_PSHARED as second argument to lll_cond_lock.
1744 (LLL_MUTEX_TRYLOCK): Take mutex as argument instead of its
1745 __data.__lock field.
1746 (LLL_ROBUST_MUTEX_LOCK): Take mutex as argument instead of its
1747 __data.__lock field, pass PTHREAD_MUTEX_PSHARED as second argument
1748 to lll_robust_cond_lock.
1749 * pthread_cond_broadcast.c (__pthread_cond_broadcast): Add pshared
1750 variable, pass it to lll_lock, lll_unlock, lll_futex_requeue and
1751 lll_futex_wake. Don't use lll_futex_requeue if dependent mutex
1752 has PTHREAD_MUTEX_PSHARED_BIT bit set in its __data.__kind.
1753 * pthread_cond_destroy.c (__pthread_cond_destroy): Add pshared
1754 variable, pass it to lll_lock, lll_unlock, lll_futex_wake and
1756 * pthread_cond_signal.c (__pthread_cond_signal): Add pshared
1757 variable, pass it to lll_lock, lll_unlock, lll_futex_wake_unlock and
1759 * pthread_cond_timedwait.c (__pthread_cond_wait): Add
1760 pshared variable, pass it to lll_lock, lll_unlock,
1761 lll_futex_timedwait and lll_futex_wake.
1762 * pthread_cond_wait.c (__condvar_cleanup, __pthread_cond_wait): Add
1763 pshared variable, pass it to lll_lock, lll_unlock, lll_futex_wait
1765 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_futex_requeue,
1766 lll_futex_wake_unlock): Add private argument, use __lll_private_flag
1768 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_requeue,
1769 lll_futex_wake_unlock): Likewise.
1770 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (lll_futex_requeue):
1772 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (lll_futex_requeue,
1773 lll_futex_wake_unlock): Likewise.
1774 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_futex_requeue):
1776 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue,
1777 lll_futex_wake_unlock): Likewise.
1778 (lll_futex_wake): Fix a typo.
1779 * sysdeps/unix/sysv/linux/pthread-pi-defines.sym (PS_BIT): Add.
1780 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
1781 (__pthread_cond_broadcast): Pass LLL_PRIVATE to lll_* and or
1782 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
1783 Don't use FUTEX_CMP_REQUEUE if dep_mutex is not process private.
1784 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
1785 (__pthread_cond_signal): Pass LLL_PRIVATE to lll_* and or
1786 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
1787 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
1788 (__pthread_cond_timedwait): Likewise.
1789 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:
1790 (__condvar_cleanup, __pthread_cond_wait): Likewise.
1792 2007-08-05 Jakub Jelinek <jakub@redhat.com>
1794 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (PSEUDO):
1795 Don't use CGOTSETUP and CGOTRESTORE macros.
1796 (CGOTSETUP, CGOTRESTORE): Remove.
1797 <IS_IN_rtld> (CENABLE, CDISABLE): Don't use JUMPTARGET, branch to
1800 2007-08-01 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1802 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Remove
1803 definitions for private futexes.
1804 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Include
1805 kernel-features.h and lowlevellock.h. Use private futexes if
1807 (__lll_lock_wait_private, __lll_unlock_wake_private): New.
1808 (__lll_mutex_lock_wait): Rename to
1809 (__lll_lock_wait): ... this. Don't compile in for libc.so.
1810 (__lll_mutex_timedlock_wait): Rename to ...
1811 (__lll_timedlock_wait): ... this. Use __NR_gettimeofday.
1812 Don't compile in for libc.so.
1813 (__lll_mutex_unlock_wake): Rename to ...
1814 (__lll_unlock_wake): ... this. Don't compile in for libc.so.
1815 (__lll_timedwait_tid): Use __NR_gettimeofday.
1816 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Allow including
1817 the header from assembler. Renamed all lll_mutex_* resp.
1818 lll_robust_mutex_* macros to lll_* resp. lll_robust_*.
1819 Renamed all LLL_MUTEX_LOCK_* macros to LLL_LOCK_*.
1820 (FUTEX_CMP_REQUEUE, FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE):
1822 (__lll_lock_wait_private): Add prototype.
1823 (__lll_lock_wait, __lll_timedlock_wait, __lll_robust_lock_wait,
1824 __lll_robust_timedlock_wait, __lll_unlock_wake_private,
1825 __lll_unlock_wake): Likewise.
1826 (lll_lock): Add private argument. Call __lll_lock_wait_private
1827 if private is constant LLL_PRIVATE.
1828 (lll_robust_lock, lll_cond_lock, lll_robust_cond_lock,
1829 lll_timedlock, lll_robust_timedlock): Add private argument.
1830 (lll_unlock): Add private argument. Call __lll_unlock_wake_private
1831 if private is constant LLL_PRIVATE.
1832 (lll_robust_unlock, lll_robust_dead): Add private argument.
1833 (lll_lock_t): Remove.
1834 (__lll_cond_wait, __lll_cond_timedwait, __lll_cond_wake,
1835 __lll_cond_broadcast, lll_cond_wait, lll_cond_timedwait,
1836 lll_cond_wake, lll_cond_broadcast): Remove.
1837 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S: Include
1838 kernel-features.h and lowlevellock.h.
1839 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Remove.
1840 (LOAD_FUTEX_WAIT): Define.
1841 (__lll_robust_mutex_lock_wait): Rename to ...
1842 (__lll_robust_lock_wait): ... this. Add private argument.
1843 Use LOAD_FUTEX_WAIT macro.
1844 (__lll_robust_mutex_timedlock_wait): Rename to ...
1845 (__lll_robust_timedlock_wait): ... this. Add private argument.
1846 Use __NR_gettimeofday. Use LOAD_FUTEX_WAIT macro.
1847 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Include
1849 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Remove.
1850 (pthread_barrier_wait): Use __lll_{lock,unlock}_* instead of
1851 __lll_mutex_{lock,unlock}_*.
1852 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Include
1853 lowlevellock.h and pthread-errnos.h.
1854 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE,
1855 FUTEX_CMP_REQUEUE, EINVAL): Remove.
1856 (__pthread_cond_broadcast): Use __lll_{lock,unlock}_* instead of
1857 __lll_mutex_{lock,unlock}_*.
1858 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Include
1859 lowlevellock.h and pthread-errnos.h.
1860 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE, EINVAL): Remove.
1861 (__pthread_cond_signal): Use __lll_{lock,unlock}_* instead of
1862 __lll_mutex_{lock,unlock}_*.
1863 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Include
1865 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE): Remove.
1866 (__pthread_cond_timedwait): Use __lll_{lock,unlock}_* instead of
1867 __lll_mutex_{lock,unlock}_*. Use __NR_gettimeofday.
1868 (__condvar_tw_cleanup): Likewise.
1869 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Include
1871 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Remove.
1872 (__pthread_cond_wait): Use __lll_{lock,unlock}_* instead of
1873 __lll_mutex_{lock,unlock}_*.
1874 ( __condvar_w_cleanup): Likewise.
1875 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Include lowlevellock.h.
1876 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
1877 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Include
1879 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
1880 (__pthread_rwlock_rdlock): Use __lll_{lock,unlock}_* instead of
1881 __lll_mutex_{lock,unlock}_*.
1882 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Include
1884 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE,
1885 FUTEX_PRIVATE_FLAG): Remove.
1886 (pthread_rwlock_timedrdlock): Use __lll_{lock,unlock}_* instead of
1887 __lll_mutex_{lock,unlock}_*. Use __NR_gettimeofday.
1888 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Include
1890 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE,
1891 FUTEX_PRIVATE_FLAG): Remove.
1892 (pthread_rwlock_timedwrlock): Use __lll_{lock,unlock}_* instead of
1893 __lll_mutex_{lock,unlock}_*. Use __NR_gettimeofday.
1894 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Include
1896 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
1897 (__pthread_rwlock_unlock): Use __lll_{lock,unlock}_* instead of
1898 __lll_mutex_{lock,unlock}_*.
1899 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Include
1901 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
1902 (__pthread_rwlock_wrlock): Use __lll_{lock,unlock}_* instead of
1903 __lll_mutex_{lock,unlock}_*.
1904 * sysdeps/unix/sysv/linux/sh/sem_post.S: Include lowlevellock.h.
1905 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
1906 (__new_sem_post): Use standard initial exec code sequences.
1907 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Include
1909 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE,
1910 FUTEX_PRIVATE_FLAG): Remove.
1911 (sem_timedwait): Use __NR_gettimeofday. Use standard initial
1912 exec code sequences.
1913 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Include lowlevellock.h.
1914 (__new_sem_trywait): Use standard initial exec code sequences.
1915 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Include lowlevellock.h.
1916 (__new_sem_wait): Use standard initial exec code sequences.
1918 2007-07-31 Anton Blanchard <anton@samba.org>
1920 * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__new_sem_post):
1921 Use __asm __volatile (__lll_acq_instr ::: "memory") instead of
1922 atomic_full_barrier.
1924 2007-07-31 Jakub Jelinek <jakub@redhat.com>
1926 * allocatestack.c (stack_cache_lock): Change type to int.
1927 (get_cached_stack, allocate_stack, __deallocate_stack,
1928 __make_stacks_executable, __find_thread_by_id, __nptl_setxid,
1929 __pthread_init_static_tls, __wait_lookup_done): Add LLL_PRIVATE
1930 as second argument to lll_lock and lll_unlock macros on
1932 * pthread_create.c (__find_in_stack_list): Likewise.
1933 (start_thread): Similarly with pd->lock. Use lll_robust_dead
1934 macro instead of lll_robust_mutex_dead, pass LLL_SHARED to it
1936 * descr.h (struct pthread): Change lock and setxid_futex field
1938 * old_pthread_cond_broadcast.c (__pthread_cond_broadcast_2_0): Use
1939 LLL_LOCK_INITIALIZER instead of LLL_MUTEX_LOCK_INITIALIZER.
1940 * old_pthread_cond_signal.c (__pthread_cond_signal_2_0): Likewise.
1941 * old_pthread_cond_timedwait.c (__pthread_cond_timedwait_2_0):
1943 * old_pthread_cond_wait.c (__pthread_cond_wait_2_0): Likewise.
1944 * pthread_cond_init.c (__pthread_cond_init): Likewise.
1945 * pthreadP.h (__attr_list_lock): Change type to int.
1946 * pthread_attr_init.c (__attr_list_lock): Likewise.
1947 * pthread_barrier_destroy.c (pthread_barrier_destroy): Pass
1948 ibarrier->private ^ FUTEX_PRIVATE_FLAG as second argument to
1950 * pthread_barrier_wait.c (pthread_barrier_wait): Likewise and
1951 also for lll_futex_{wake,wait}.
1952 * pthread_barrier_init.c (pthread_barrier_init): Make iattr
1954 * pthread_cond_broadcast.c (__pthread_cond_broadcast): Pass
1955 LLL_SHARED as second argument to lll_{,un}lock.
1956 * pthread_cond_destroy.c (__pthread_cond_destroy): Likewise.
1957 * pthread_cond_signal.c (__pthread_cond_singal): Likewise.
1958 * pthread_cond_timedwait.c (__pthread_cond_timedwait): Likewise.
1959 * pthread_cond_wait.c (__condvar_cleanup, __pthread_cond_wait):
1961 * pthread_getattr_np.c (pthread_getattr_np): Add LLL_PRIVATE
1962 as second argument to lll_{,un}lock macros on pd->lock.
1963 * pthread_getschedparam.c (__pthread_getschedparam): Likewise.
1964 * pthread_setschedparam.c (__pthread_setschedparam): Likewise.
1965 * pthread_setschedprio.c (pthread_setschedprio): Likewise.
1966 * tpp.c (__pthread_tpp_change_priority, __pthread_current_priority):
1968 * sysdeps/pthread/createthread.c (do_clone, create_thread):
1970 * pthread_once.c (once_lock): Change type to int.
1971 (__pthread_once): Pass LLL_PRIVATE as second argument to
1972 lll_{,un}lock macros on once_lock.
1973 * pthread_rwlock_rdlock.c (__pthread_rwlock_rdlock): Use
1974 lll_{,un}lock macros instead of lll_mutex_{,un}lock, pass
1975 rwlock->__data.__shared as second argument to them and similarly
1977 * pthread_rwlock_timedrdlock.c (pthread_rwlock_timedrdlock):
1979 * pthread_rwlock_timedwrlock.c (pthread_rwlock_timedwrlock):
1981 * pthread_rwlock_tryrdlock.c (__pthread_rwlock_tryrdlock): Likewise.
1982 * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Likewise.
1983 * pthread_rwlock_unlock.c (__pthread_rwlock_unlock): Likewise.
1984 * pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock): Likewise.
1985 * sem_close.c (sem_close): Pass LLL_PRIVATE as second argument
1986 to lll_{,un}lock macros on __sem_mappings_lock.
1987 * sem_open.c (check_add_mapping): Likewise.
1988 (__sem_mappings_lock): Change type to int.
1989 * semaphoreP.h (__sem_mappings_lock): Likewise.
1990 * pthread_mutex_lock.c (LLL_MUTEX_LOCK, LLL_MUTEX_TRYLOCK,
1991 LLL_ROBUST_MUTEX_LOCK): Use lll_{,try,robust_}lock macros
1992 instead of lll_*mutex_*, pass LLL_SHARED as last
1994 (__pthread_mutex_lock): Use lll_unlock instead of lll_mutex_unlock,
1995 pass LLL_SHARED as last argument.
1996 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c (LLL_MUTEX_LOCK,
1997 LLL_MUTEX_TRYLOCK, LLL_ROBUST_MUTEX_LOCK): Use
1998 lll_{cond_,cond_try,robust_cond}lock macros instead of lll_*mutex_*,
1999 pass LLL_SHARED as last argument.
2000 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Use
2001 lll_{timed,try,robust_timed,un}lock instead of lll_*mutex*, pass
2002 LLL_SHARED as last argument.
2003 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Similarly.
2004 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
2006 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_lock,
2007 __libc_lock_lock_recursive, __libc_lock_unlock,
2008 __libc_lock_unlock_recursive): Pass LLL_PRIVATE as second
2009 argument to lll_{,un}lock.
2010 * sysdeps/pthread/bits/stdio-lock.h (_IO_lock_lock,
2011 _IO_lock_unlock): Likewise.
2012 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Don't use
2014 * sysdeps/unix/sysv/linux/unregister-atfork.c (__unregister_atfork):
2015 Pass LLL_PRIVATE as second argument to lll_{,un}lock macros on
2017 * sysdeps/unix/sysv/linux/register-atfork.c (__register_atfork,
2018 free_mem): Likewise.
2019 (__fork_lock): Change type to int.
2020 * sysdeps/unix/sysv/linux/fork.h (__fork_lock): Likewise.
2021 * sysdeps/unix/sysv/linux/sem_post.c (__new_sem_post): Pass
2022 isem->private ^ FUTEX_PRIVATE_FLAG as second argument to
2024 * sysdeps/unix/sysv/linux/sem_timedwait.c (sem_timedwait): Likewise.
2025 * sysdeps/unix/sysv/linux/sem_wait.c (__new_sem_wait): Likewise.
2026 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait_private):
2028 (__lll_lock_wait, __lll_timedlock_wait): Add private argument and
2029 pass it through to lll_futex_*wait, only compile in when
2031 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
2032 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): Add private
2033 argument and pass it through to lll_futex_*wait.
2034 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Renamed all
2035 lll_mutex_* resp. lll_robust_mutex_* macros to lll_* resp.
2036 lll_robust_*. Renamed all __lll_mutex_* resp. __lll_robust_mutex_*
2037 inline functions to __lll_* resp. __lll_robust_*.
2038 (LLL_MUTEX_LOCK_INITIALIZER): Remove.
2039 (lll_mutex_dead): Add private argument.
2040 (__lll_lock_wait_private): New prototype.
2041 (__lll_lock_wait, __lll_robust_lock_wait, __lll_lock_timedwait,
2042 __lll_robust_lock_timedwait): Add private argument to prototypes.
2043 (__lll_lock): Add private argument, if it is constant LLL_PRIVATE,
2044 call __lll_lock_wait_private, otherwise pass private to
2046 (__lll_robust_lock, __lll_cond_lock, __lll_timedlock,
2047 __lll_robust_timedlock): Add private argument, pass it to
2048 __lll_*wait functions.
2049 (__lll_unlock): Add private argument, if it is constant LLL_PRIVATE,
2050 call __lll_unlock_wake_private, otherwise pass private to
2052 (__lll_robust_unlock): Add private argument, pass it to
2053 __lll_robust_unlock_wake.
2054 (lll_lock, lll_robust_lock, lll_cond_lock, lll_timedlock,
2055 lll_robust_timedlock, lll_unlock, lll_robust_unlock): Add private
2056 argument, pass it through to __lll_* inline function.
2057 (__lll_mutex_unlock_force, lll_mutex_unlock_force): Remove.
2058 (lll_lock_t): Remove.
2059 (__lll_cond_wait, __lll_cond_timedwait, __lll_cond_wake,
2060 __lll_cond_broadcast, lll_cond_wait, lll_cond_timedwait,
2061 lll_cond_wake, lll_cond_broadcast): Remove.
2062 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
2063 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
2064 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
2065 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
2066 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Allow including
2067 the header from assembler. Renamed all lll_mutex_* resp.
2068 lll_robust_mutex_* macros to lll_* resp. lll_robust_*.
2069 (LOCK, FUTEX_CMP_REQUEUE, FUTEX_WAKE_OP,
2070 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
2071 (LLL_MUTEX_LOCK_INITIALIZER, LLL_MUTEX_LOCK_INITIALIZER_LOCKED,
2072 LLL_MUTEX_LOCK_INITIALIZER_WAITERS): Remove.
2073 (__lll_mutex_lock_wait, __lll_mutex_timedlock_wait,
2074 __lll_mutex_unlock_wake, __lll_lock_wait, __lll_unlock_wake):
2076 (__lll_trylock_asm, __lll_lock_asm_start, __lll_unlock_asm): Define.
2077 (lll_robust_trylock, lll_cond_trylock): Use LLL_LOCK_INITIALIZER*
2078 rather than LLL_MUTEX_LOCK_INITIALIZER* macros.
2079 (lll_trylock): Likewise, use __lll_trylock_asm, pass
2080 MULTIPLE_THREADS_OFFSET as another asm operand.
2081 (lll_lock): Add private argument, use __lll_lock_asm_start, pass
2082 MULTIPLE_THREADS_OFFSET as last asm operand, call
2083 __lll_lock_wait_private if private is constant LLL_PRIVATE,
2084 otherwise pass private as another argument to __lll_lock_wait.
2085 (lll_robust_lock, lll_cond_lock, lll_robust_cond_lock,
2086 lll_timedlock, lll_robust_timedlock): Add private argument, pass
2087 private as another argument to __lll_*lock_wait call.
2088 (lll_unlock): Add private argument, use __lll_unlock_asm, pass
2089 MULTIPLE_THREADS_OFFSET as another asm operand, call
2090 __lll_unlock_wake_private if private is constant LLL_PRIVATE,
2091 otherwise pass private as another argument to __lll_unlock_wake.
2092 (lll_robust_unlock): Add private argument, pass private as another
2093 argument to __lll_unlock_wake.
2094 (lll_robust_dead): Add private argument, use __lll_private_flag
2096 (lll_islocked): Use LLL_LOCK_INITIALIZER instead of
2097 LLL_MUTEX_LOCK_INITIALIZER.
2098 (lll_lock_t): Remove.
2099 (LLL_LOCK_INITIALIZER_WAITERS): Define.
2100 (__lll_cond_wait, __lll_cond_timedwait, __lll_cond_wake,
2101 __lll_cond_broadcast, lll_cond_wait, lll_cond_timedwait,
2102 lll_cond_wake, lll_cond_broadcast): Remove.
2103 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
2104 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Revert
2105 2007-05-2{3,9} changes.
2106 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Include
2107 kernel-features.h and lowlevellock.h.
2108 (LOAD_PRIVATE_FUTEX_WAIT): Define.
2109 (LOAD_FUTEX_WAIT): Rewritten.
2110 (LOCK, SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't
2112 (__lll_lock_wait_private, __lll_unlock_wake_private): New functions.
2113 (__lll_mutex_lock_wait): Rename to ...
2114 (__lll_lock_wait): ... this. Take futex addr from %edx instead of
2115 %ecx, %ecx is now private argument. Don't compile in for libc.so.
2116 (__lll_mutex_timedlock_wait): Rename to ...
2117 (__lll_timedlock_wait): ... this. Use __NR_gettimeofday. %esi
2118 contains private argument. Don't compile in for libc.so.
2119 (__lll_mutex_unlock_wake): Rename to ...
2120 (__lll_unlock_wake): ... this. %ecx contains private argument.
2121 Don't compile in for libc.so.
2122 (__lll_timedwait_tid): Use __NR_gettimeofday.
2123 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: Include
2124 kernel-features.h and lowlevellock.h.
2125 (LOAD_FUTEX_WAIT): Define.
2126 (LOCK, SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't
2128 (__lll_robust_mutex_lock_wait): Rename to ...
2129 (__lll_robust_lock_wait): ... this. Futex addr is now in %edx
2130 argument, %ecx argument contains private. Use LOAD_FUTEX_WAIT
2132 (__lll_robust_mutex_timedlock_wait): Rename to ...
2133 (__lll_robust_timedlock_wait): ... this. Use __NR_gettimeofday.
2134 %esi argument contains private, use LOAD_FUTEX_WAIT macro.
2135 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Include
2137 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2138 (pthread_barrier_wait): Rename __lll_mutex_* to __lll_*, pass
2139 PRIVATE(%ebx) ^ LLL_SHARED as private argument in %ecx to
2140 __lll_lock_wait and __lll_unlock_wake, pass MUTEX(%ebx) address
2141 to __lll_lock_wait in %edx.
2142 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S:
2143 Include lowlevellock.h and pthread-errnos.h.
2144 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE,
2145 FUTEX_CMP_REQUEUE, EINVAL, LOCK): Don't define.
2146 (__pthread_cond_broadcast): Rename __lll_mutex_* to __lll_*, pass
2147 cond_lock address in %edx rather than %ecx to __lll_lock_wait,
2148 pass LLL_SHARED in %ecx to both __lll_lock_wait and
2150 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S:
2151 Include lowlevellock.h and pthread-errnos.h.
2152 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_WAKE_OP,
2153 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE, EINVAL, LOCK): Don't define.
2154 (__pthread_cond_signal): Rename __lll_mutex_* to __lll_*, pass
2155 cond_lock address in %edx rather than %ecx to __lll_lock_wait,
2156 pass LLL_SHARED in %ecx to both __lll_lock_wait and
2158 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
2159 Include lowlevellock.h.
2160 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE, LOCK):
2162 (__pthread_cond_timedwait): Rename __lll_mutex_* to __lll_*, pass
2163 cond_lock address in %edx rather than %ecx to __lll_lock_wait,
2164 pass LLL_SHARED in %ecx to both __lll_lock_wait and
2165 __lll_unlock_wake. Use __NR_gettimeofday.
2166 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
2167 Include lowlevellock.h.
2168 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2169 (__pthread_cond_wait, __condvar_w_cleanup): Rename __lll_mutex_*
2170 to __lll_*, pass cond_lock address in %edx rather than %ecx to
2171 __lll_lock_wait, pass LLL_SHARED in %ecx to both __lll_lock_wait
2172 and __lll_unlock_wake.
2173 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S:
2174 Include lowlevellock.h.
2175 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2176 (__pthread_rwlock_rdlock): Rename __lll_mutex_* to __lll_*, pass
2177 MUTEX(%ebx) address in %edx rather than %ecx to
2178 __lll_lock_wait, pass PSHARED(%ebx) in %ecx to both __lll_lock_wait
2179 and __lll_unlock_wake. Move return value from %ecx to %edx
2181 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
2182 Include lowlevellock.h.
2183 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE, LOCK):
2185 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*, pass
2186 MUTEX(%ebp) address in %edx rather than %ecx to
2187 __lll_lock_wait, pass PSHARED(%ebp) in %ecx to both __lll_lock_wait
2188 and __lll_unlock_wake. Move return value from %ecx to %edx
2189 register. Use __NR_gettimeofday.
2190 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
2191 Include lowlevellock.h.
2192 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE, LOCK):
2194 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*, pass
2195 MUTEX(%ebp) address in %edx rather than %ecx to
2196 __lll_lock_wait, pass PSHARED(%ebp) in %ecx to both __lll_lock_wait
2197 and __lll_unlock_wake. Move return value from %ecx to %edx
2198 register. Use __NR_gettimeofday.
2199 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
2200 Include lowlevellock.h.
2201 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2202 (__pthread_rwlock_unlock): Rename __lll_mutex_* to __lll_*, pass
2203 MUTEX(%edi) address in %edx rather than %ecx to
2204 __lll_lock_wait, pass PSHARED(%edi) in %ecx to both __lll_lock_wait
2205 and __lll_unlock_wake.
2206 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S:
2207 Include lowlevellock.h.
2208 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2209 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*, pass
2210 MUTEX(%ebx) address in %edx rather than %ecx to
2211 __lll_lock_wait, pass PSHARED(%ebx) in %ecx to both __lll_lock_wait
2212 and __lll_unlock_wake. Move return value from %ecx to %edx
2214 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Include
2216 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Don't
2218 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Include lowlevellock.h.
2219 (LOCK, SYS_futex, FUTEX_WAKE): Don't define.
2220 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Include
2222 (LOCK, SYS_futex, SYS_gettimeofday, FUTEX_WAIT): Don't define.
2223 (sem_timedwait): Use __NR_gettimeofday.
2224 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Include
2226 (LOCK): Don't define.
2227 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Include
2229 (LOCK, SYS_futex, FUTEX_WAIT): Don't define.
2230 * sysdeps/unix/sysv/linux/powerpc/sem_post.c: Wake only when there
2232 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Revert
2233 2007-05-2{3,9} changes.
2234 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Include
2235 kernel-features.h and lowlevellock.h.
2236 (LOAD_PRIVATE_FUTEX_WAIT): Define.
2237 (LOAD_FUTEX_WAIT): Rewritten.
2238 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't define.
2239 (__lll_lock_wait_private, __lll_unlock_wake_private): New functions.
2240 (__lll_mutex_lock_wait): Rename to ...
2241 (__lll_lock_wait): ... this. %esi is now private argument.
2242 Don't compile in for libc.so.
2243 (__lll_mutex_timedlock_wait): Rename to ...
2244 (__lll_timedlock_wait): ... this. %esi contains private argument.
2245 Don't compile in for libc.so.
2246 (__lll_mutex_unlock_wake): Rename to ...
2247 (__lll_unlock_wake): ... this. %esi contains private argument.
2248 Don't compile in for libc.so.
2249 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Include
2250 kernel-features.h and lowlevellock.h.
2251 (LOAD_FUTEX_WAIT): Define.
2252 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't define.
2253 (__lll_robust_mutex_lock_wait): Rename to ...
2254 (__lll_robust_lock_wait): ... this. %esi argument contains private.
2255 Use LOAD_FUTEX_WAIT macro.
2256 (__lll_robust_mutex_timedlock_wait): Rename to ...
2257 (__lll_robust_timedlock_wait): ... this. %esi argument contains
2258 private, use LOAD_FUTEX_WAIT macro.
2259 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Include
2261 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2262 (pthread_barrier_wait): Rename __lll_mutex_* to __lll_*, pass
2263 PRIVATE(%rdi) ^ LLL_SHARED as private argument in %esi to
2264 __lll_lock_wait and __lll_unlock_wake.
2265 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S:
2266 Include lowlevellock.h and pthread-errnos.h.
2267 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE,
2268 FUTEX_CMP_REQUEUE, EINVAL, LOCK): Don't define.
2269 (__pthread_cond_broadcast): Rename __lll_mutex_* to __lll_*,
2270 pass LLL_SHARED in %esi to both __lll_lock_wait and
2272 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S:
2273 Include lowlevellock.h and pthread-errnos.h.
2274 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_WAKE_OP,
2275 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE, EINVAL, LOCK): Don't define.
2276 (__pthread_cond_signal): Rename __lll_mutex_* to __lll_*,
2277 pass LLL_SHARED in %esi to both __lll_lock_wait and
2279 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:
2280 Include lowlevellock.h.
2281 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2282 (__pthread_cond_timedwait): Rename __lll_mutex_* to __lll_*,
2283 pass LLL_SHARED in %esi to both __lll_lock_wait and
2285 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:
2286 Include lowlevellock.h.
2287 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
2288 (__pthread_cond_wait, __condvar_cleanup): Rename __lll_mutex_*
2289 to __lll_*, pass LLL_SHARED in %esi to both __lll_lock_wait
2290 and __lll_unlock_wake.
2291 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S:
2292 Include lowlevellock.h.
2293 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
2295 (__pthread_rwlock_rdlock): Rename __lll_mutex_* to __lll_*,
2296 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
2297 and __lll_unlock_wake.
2298 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
2299 Include lowlevellock.h.
2300 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
2302 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*,
2303 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
2304 and __lll_unlock_wake.
2305 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
2306 Include lowlevellock.h.
2307 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
2309 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*,
2310 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
2311 and __lll_unlock_wake.
2312 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S:
2313 Include lowlevellock.h.
2314 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
2316 (__pthread_rwlock_unlock): Rename __lll_mutex_* to __lll_*,
2317 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
2318 and __lll_unlock_wake.
2319 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S:
2320 Include lowlevellock.h.
2321 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
2323 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*,
2324 pass PSHARED(%rdi) in %ecx to both __lll_lock_wait
2325 and __lll_unlock_wake.
2326 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Include
2328 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Don't
2330 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Include lowlevellock.h.
2331 (LOCK, SYS_futex, FUTEX_WAKE): Don't define.
2332 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Include
2334 (LOCK, SYS_futex, FUTEX_WAIT): Don't define.
2335 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Include
2337 (LOCK): Don't define.
2338 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Include
2340 (LOCK, SYS_futex, FUTEX_WAIT): Don't define.
2341 * sysdeps/unix/sysv/linux/sparc/internaltypes.h: New file.
2342 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_destroy.c: New file.
2343 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_init.c: New file.
2344 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_wait.c: New file.
2345 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c
2346 (__lll_lock_wait_private): New function.
2347 (__lll_lock_wait, __lll_timedlock_wait): Add private argument, pass
2348 it to lll_futex_*wait. Don't compile in for libc.so.
2349 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_init.c:
2351 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_wait.c
2352 (struct sparc_pthread_barrier): Remove.
2353 (pthread_barrier_wait): Use union sparc_pthread_barrier instead of
2354 struct sparc_pthread_barrier. Pass
2355 ibarrier->s.pshared ? LLL_SHARED : LLL_PRIVATE to lll_{,un}lock
2356 and lll_futex_wait macros.
2357 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_init.c:
2359 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
2360 Include sparc pthread_barrier_wait.c instead of generic one.
2362 2007-07-30 Jakub Jelinek <jakub@redhat.com>
2364 * tst-rwlock14.c (do_test): Avoid warnings on 32-bit arches.
2366 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
2367 (pthread_rwlock_timedrdlock): Copy futex retval to %esi rather than
2369 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
2370 (pthread_rwlock_timedwrlock): Likewise.
2371 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
2372 (__pthread_rwlock_unlock): Fix MUTEX != 0 args to __lll_*.
2374 2007-07-31 Jakub Jelinek <jakub@redhat.com>
2376 * sysdeps/sparc/tls.h (tcbhead_t): Add private_futex field.
2378 2007-07-26 Jakub Jelinek <jakub@redhat.com>
2380 * tst-locale2.c (useless): Add return statement.
2382 2007-07-24 Jakub Jelinek <jakub@redhat.com>
2384 * allocatestack.c (__nptl_setxid, __wait_lookup_done): Replace
2385 lll_private_futex_* (*) with lll_futex_* (*, LLL_PRIVATE).
2386 * pthread_create.c (start_thread): Likewise.
2387 * init.c (sighandler_setxid): Likewise.
2388 * sysdeps/alpha/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2389 * sysdeps/ia64/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2390 * sysdeps/i386/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2391 * sysdeps/s390/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2392 * sysdeps/powerpc/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2393 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2394 * sysdeps/sparc/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2395 * sysdeps/sh/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
2396 * sysdeps/pthread/aio_misc.h (AIO_MISC_NOTIFY, AIO_MISC_WAIT):
2398 * sysdeps/pthread/gai_misc.h (GAI_MISC_NOTIFY, GAI_MISC_WAIT):
2400 * sysdeps/unix/sysv/linux/unregister-atfork.c (__unregister_atfork):
2402 * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_waitzero,
2403 __rtld_notify): Likewise.
2404 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Likewise.
2405 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (clear_once_control,
2406 __pthread_once): Likewise.
2407 * sysdeps/unix/sysv/linux/alpha/pthread_once.c (clear_once_control,
2408 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
2409 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_PRIVATE_FLAG,
2410 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
2411 (lll_futex_wait): Add private argument, define as wrapper around
2412 lll_futex_timed_wait.
2413 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
2414 use __lll_private_flag macro.
2415 (lll_robust_mutex_dead, __lll_mutex_unlock, __lll_robust_mutex_unlock,
2416 __lll_mutex_unlock_force): Pass LLL_SHARED as last arg to lll_futex_*.
2417 * sysdeps/unix/sysv/linux/ia64/pthread_once.c (clear_once_control,
2418 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
2419 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_PRIVATE_FLAG,
2420 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
2421 (lll_futex_wait): Add private argument, define as wrapper around
2422 lll_futex_timed_wait.
2423 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
2424 use __lll_private_flag macro.
2425 (__lll_mutex_unlock, __lll_robust_mutex_unlock, lll_wait_tid,
2426 __lll_mutex_unlock_force): Pass LLL_SHARED as last arg to lll_futex_*.
2427 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (__lll_private_flag):
2429 (lll_futex_timed_wait, lll_futex_wake): Use it.
2430 (lll_private_futex_wait, lll_private_futex_timed_wait,
2431 lll_private_futex_wake): Removed.
2432 * sysdeps/unix/sysv/linux/s390/pthread_once.c (clear_once_control,
2433 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
2434 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_PRIVATE_FLAG,
2435 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
2436 (lll_futex_wait): Add private argument, define as wrapper around
2437 lll_futex_timed_wait.
2438 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
2439 use __lll_private_flag macro.
2440 (lll_robust_mutex_dead, __lll_mutex_unlock, __lll_robust_mutex_unlock,
2441 lll_wait_tid, __lll_mutex_unlock_force): Pass LLL_SHARED as last arg
2443 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
2444 (lll_private_futex_wait, lll_private_futex_timed_wait,
2445 lll_private_futex_wake): Removed.
2446 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (__lll_private_flag):
2447 Fix !__ASSUME_PRIVATE_FUTEX non-constant private case.
2448 (lll_private_futex_wait, lll_private_futex_timed_wait,
2449 lll_private_futex_wake): Removed.
2450 * sysdeps/unix/sysv/linux/sparc/pthread_once.c (clear_once_control,
2451 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
2452 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_PRIVATE_FLAG,
2453 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
2454 (lll_futex_wait): Add private argument, define as wrapper around
2455 lll_futex_timed_wait.
2456 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
2457 use __lll_private_flag macro.
2458 (lll_robust_mutex_dead, __lll_mutex_unlock, __lll_robust_mutex_unlock,
2459 lll_wait_tid, __lll_mutex_unlock_force): Pass LLL_SHARED as last arg
2461 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (__lll_private_flag):
2463 (lll_futex_timed_wait, lll_futex_wake): Use it.
2464 (lll_private_futex_wait, lll_private_futex_timed_wait,
2465 lll_private_futex_wake): Removed.
2467 2007-07-27 Jakub Jelinek <jakub@redhat.com>
2469 * sysdeps/sparc/tls.h (tcbhead_t): Move gscope_flag to the end
2470 of the structure for sparc32.
2472 2007-07-26 Aurelien Jarno <aurelien@aurel32.net>
2474 * sysdeps/sparc/tls.h (tcbhead_t): Add gscope_flag.
2476 2007-07-23 Ulrich Drepper <drepper@redhat.com>
2478 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S: Fix
2479 code used when private futexes are assumed.
2480 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
2483 2007-07-23 Jakub Jelinek <jakub@redhat.com>
2485 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
2486 (__lll_private_flag): Define.
2487 (lll_futex_wait): Define as a wrapper around lll_futex_timed_wait.
2488 (lll_futex_timed_wait, lll_futex_wake, lll_futex_wake_unlock): Use
2490 (lll_private_futex_wait, lll_private_futex_timedwait,
2491 lll_private_futex_wake): Define as wrapper around non-_private
2493 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
2494 (__lll_private_flag): Define.
2495 (lll_futex_timed_wait, lll_futex_wake): Use __lll_private_flag.
2496 (lll_private_futex_wait, lll_private_futex_timedwait,
2497 lll_private_futex_wake): Define as wrapper around non-_private
2500 2007-07-10 Steven Munroe <sjmunroe@us.ibm.com>
2502 * pthread_rwlock_rdlock.c (__pthread_rwlock_rdlock): Add LLL_SHARED
2503 parameter to lll_futex_wait call.
2504 * pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock): Likewise.
2506 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (__pthread_once):
2507 Replace lll_futex_wait with lll_private_futex_wait.
2508 * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__new_sem_post):
2509 Add LLL_SHARED parameter to lll_futex_wake().
2511 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define LLL_PRIVATE
2512 LLL_SHARED, lll_private_futex_wait, lll_private_futex_timed_wait and
2513 lll_private_futex_wake.
2514 (lll_futex_wait): Add private parameter. Adjust FUTEX_PRIVATE_FLAG
2515 bit from private parm before syscall.
2516 (lll_futex_timed_wait): Likewise.
2517 (lll_futex_wake): Likewise.
2518 (lll_futex_wake_unlock): Likewise.
2519 (lll_mutex_unlock): Add LLL_SHARED parm to lll_futex_wake call.
2520 (lll_robust_mutex_unlock): Likewise.
2521 (lll_mutex_unlock_force): Likewise.
2522 (lll_wait_tid): Add LLL_SHARED parm to lll_futex_wait call.
2524 2007-07-23 Ulrich Drepper <drepper@redhat.com>
2526 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S: Fix
2527 compilation when unconditionally using private futexes.
2528 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
2529 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
2531 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Likewise.
2532 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
2534 2007-07-17 Jakub Jelinek <jakub@redhat.com>
2536 * sysdeps/pthread/bits/stdio-lock.h (_IO_acquire_lock_clear_flags2):
2539 2007-07-06 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2541 * sysdeps/sh/tls.h: Include stdlib.h, list.h, sysdep.h and
2544 2007-05-16 Roland McGrath <roland@redhat.com>
2546 * init.c (__nptl_initial_report_events): New variable.
2547 (__pthread_initialize_minimal_internal): Initialize pd->report_events
2550 2007-06-22 Jakub Jelinek <jakub@redhat.com>
2552 * pthread_getattr_np.c (pthread_getattr_np): Clear cpuset and
2553 cpusetsize if pthread_getaffinity_np failed with ENOSYS.
2555 2007-06-19 Ulrich Drepper <drepper@redhat.com>
2557 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: Remove mrlock
2560 2007-06-18 Ulrich Drepper <drepper@redhat.com>
2562 * pthreadP.h: Define PTHREAD_MUTEX_TYPE.
2563 * phtread_mutex_lock.c: Use PTHREAD_MUTEX_TYPE.
2564 * pthread_mutex_timedlock.c: Likewise.
2565 * pthread_mutex_trylock.c: Likewise.
2566 * pthread_mutex_unlock.c: Likewise.
2568 2007-06-17 Andreas Schwab <schwab@suse.de>
2570 * sysdeps/pthread/pt-initfini.c: Tell gcc about the nonstandard
2573 2007-06-17 Ulrich Drepper <drepper@redhat.com>
2575 * allocatestack.c (allocate_stack): Make code compile if
2576 __ASSUME_PRIVATE_FUTEX is set.
2578 2007-06-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2580 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S:
2581 (__pthread_rwlock_rdlock): Don't use non SH-3/4 instruction.
2582 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S:
2583 (__pthread_rwlock_wrlock): Likewise.
2584 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S:
2585 (pthread_rwlock_timedrdlock): Likewise.
2586 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S:
2587 (pthread_rwlock_timedwrlock): Likewise.
2588 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S:
2589 (__pthread_rwlock_unlock): Likewise.
2591 2007-06-10 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2593 * sysdeps/sh/tcb-offsets.sym: Add PRIVATE_FUTEX.
2594 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Include endian.h.
2595 Split __flags into __flags, __shared, __pad1 and __pad2.
2596 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Use private
2597 futexes if they are available.
2598 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Adjust so that change
2599 in libc-lowlevellock.S allow using private futexes.
2600 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Define
2601 FUTEX_PRIVATE_FLAG. Add additional parameter to lll_futex_wait,
2602 lll_futex_timed_wait and lll_futex_wake. Change lll_futex_wait
2603 to call lll_futex_timed_wait. Add lll_private_futex_wait,
2604 lll_private_futex_timed_wait and lll_private_futex_wake.
2605 (lll_robust_mutex_unlock): Fix typo.
2606 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Use private
2607 field in futex command setup.
2608 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Use
2609 COND_NWAITERS_SHIFT instead of COND_CLOCK_BITS.
2610 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Likewise.
2611 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Use private futexes
2612 if they are available. Remove clear_once_control.
2613 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Use private
2614 futexes if they are available.
2615 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
2616 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
2617 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
2618 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
2619 * sysdeps/unix/sysv/linux/sh/sem_post.S: Add private futex support.
2620 Wake only when there are waiters.
2621 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Add private futex
2622 support. Indicate that there are waiters. Remove unnecessary
2623 extra cancellation test.
2624 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise. Removed
2625 left-over duplication of __sem_wait_cleanup.
2627 2007-06-07 Ulrich Drepper <drepper@redhat.com>
2629 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Add additional
2630 parameter to lll_futex_wait, lll_futex_timed_wait, and
2631 lll_futex_wake. Change lll_futex_wait to call lll_futex_timed_wait.
2632 Add lll_private_futex_wait, lll_private_futex_timed_wait, and
2633 lll_private_futex_wake.
2634 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
2635 * allocatestack.c: Adjust use of lll_futex_* macros.
2637 * lowlevellock.h: Likewise.
2638 * pthread_barrier_wait.c: Likewise.
2639 * pthread_cond_broadcast.c: Likewise.
2640 * pthread_cond_destroy.c: Likewise.
2641 * pthread_cond_signal.c: Likewise.
2642 * pthread_cond_timedwait.c: Likewise.
2643 * pthread_cond_wait.c: Likewise.
2644 * pthread_create.c: Likewise.
2645 * pthread_mutex_lock.c: Likewise.
2646 * pthread_mutex_setprioceiling.c: Likewise.
2647 * pthread_mutex_timedlock.c: Likewise.
2648 * pthread_mutex_unlock.c: Likewise.
2649 * pthread_rwlock_timedrdlock.c: Likewise.
2650 * pthread_rwlock_timedwrlock.c: Likewise.
2651 * pthread_rwlock_unlock.c: Likewise.
2652 * sysdeps/alpha/tls.h: Likewise.
2653 * sysdeps/i386/tls.h: Likewise.
2654 * sysdeps/ia64/tls.h: Likewise.
2655 * sysdeps/powerpc/tls.h: Likewise.
2656 * sysdeps/pthread/aio_misc.h: Likewise.
2657 * sysdeps/pthread/gai_misc.h: Likewise.
2658 * sysdeps/s390/tls.h: Likewise.
2659 * sysdeps/sh/tls.h: Likewise.
2660 * sysdeps/sparc/tls.h: Likewise.
2661 * sysdeps/unix/sysv/linux/fork.c: Likewise.
2662 * sysdeps/unix/sysv/linux/lowlevellock.c: Likewise.
2663 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c: Likewise.
2664 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: Likewise.
2665 * sysdeps/unix/sysv/linux/sem_post.c: Likewise.
2666 * sysdeps/unix/sysv/linux/sem_timedwait.c: Likewise.
2667 * sysdeps/unix/sysv/linux/sem_wait.c: Likewise.
2668 * sysdeps/unix/sysv/linux/unregister-atfork.c: Likewise.
2669 * sysdeps/unix/sysv/linux/sparc/pthread_once.c: Likewise.
2670 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_wait.c:
2672 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_post.c: Likewise.
2673 * sysdeps/x86_64/tls.h: Likewise.
2675 2007-05-29 Ulrich Drepper <drepper@redhat.com>
2677 * pthread_getattr_np.c: No need to install a cancellation handler,
2678 this is no cancellation point.
2679 * pthread_getschedparam.c: Likewise.
2680 * pthread_setschedparam.c: Likewise.
2681 * pthread_setschedprio.c: Likewise.
2682 * sysdeps/unix/sysv/linux/lowlevellock.c: Remove all traces of
2684 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
2685 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
2686 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
2687 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
2688 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
2689 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
2690 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
2691 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
2692 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
2693 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c: Likewise.
2694 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
2695 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
2697 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Checking
2698 whether there are more than one thread makes no sense here since
2699 we only call the slow path if the locks are taken.
2700 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Likewise.
2702 * sysdeps/unix/sysv/linux/internaltypes.h: Introduce
2703 COND_NWAITERS_SHIFT.
2704 * pthread_cond_destroy.c: Use COND_NWAITERS_SHIFT instead of
2706 * pthread_cond_init.c: Likewise.
2707 * pthread_cond_timedwait.c: Likewise.
2708 * pthread_cond_wait.c: Likewise.
2709 * pthread_condattr_getclock.c: Likewise.
2710 * pthread_condattr_setclock.c: Likewise.
2711 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Likewise.
2712 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
2713 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
2714 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
2715 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
2717 2007-05-28 Jakub Jelinek <jakub@redhat.com>
2719 * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstacksize.c: Include
2722 * sysdeps/i386/tls.h (THREAD_GSCOPE_RESET_FLAG): Use explicit
2724 (THREAD_GSCOPE_GET_FLAG): Remove.
2725 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_GET_FLAG): Remove.
2726 * allocatestack.c (__wait_lookup_done): Revert 2007-05-24
2728 * sysdeps/powerpc/tls.h (tcbhead_t): Remove gscope_flag.
2729 (THREAD_GSCOPE_GET_FLAG): Remove.
2730 (THREAD_GSCOPE_RESET_FLAG): Use THREAD_SELF->header.gscope_flag
2731 instead of THREAD_GSCOPE_GET_FLAG.
2732 (THREAD_GSCOPE_SET_FLAG): Likewise. Add atomic_write_barrier after
2734 * sysdeps/s390/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
2735 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
2736 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
2737 THREAD_GSCOPE_WAIT): Define.
2738 * sysdeps/sparc/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
2739 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
2740 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
2741 THREAD_GSCOPE_WAIT): Define.
2742 * sysdeps/sh/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
2743 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
2744 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
2745 THREAD_GSCOPE_WAIT): Define.
2746 * sysdeps/ia64/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
2747 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
2748 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
2749 THREAD_GSCOPE_WAIT): Define.
2751 2007-05-24 Richard Henderson <rth@redhat.com>
2753 * descr.h (struct pthread): Add header.gscope_flag.
2754 * sysdeps/alpha/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
2755 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
2756 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
2757 THREAD_GSCOPE_WAIT): Define.
2759 2007-05-27 Ulrich Drepper <drepper@redhat.com>
2761 * init.c: Make it compile with older kernel headers.
2763 * tst-initializers1.c: Show through exit code which test failed.
2765 * pthread_rwlock_init.c: Also initialize __shared field.
2766 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Split __flags
2767 element in rwlock structure into four byte elements. One of them is
2768 the new __shared element.
2769 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h [__WORDSIZE=32]:
2771 [__WORDSIZE=64]: Renamed __pad1 element int rwlock structure to
2772 __shared, adjust names of other padding elements.
2773 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
2774 * sysdeps/pthread/pthread.h: Adjust rwlock initializers.
2775 * sysdeps/unix/sysv/linux/lowlevelrwlock.sym: Add PSHARED.
2776 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define
2778 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Change main
2779 futex to use private operations if possible.
2780 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
2782 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
2784 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Likewise.
2785 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
2786 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
2787 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
2789 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
2791 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
2792 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
2794 2007-05-26 Ulrich Drepper <drepper@redhat.com>
2796 * pthreadP.h (PTHREAD_RWLOCK_PREFER_READER_P): Define.
2797 * pthread_rwlock_rdlock.c: Use PTHREAD_RWLOCK_PREFER_READER_P.
2798 * pthread_rwlock_timedrdlock.c: Likewise.
2799 * pthread_rwlock_tryrdlock.c: Likewise.
2801 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S (sem_trywait): Tiny
2804 * sysdeps/unix/sysv/linux/sem_wait.c: Add missing break.
2805 * sysdeps/unix/sysv/linux/sem_timedwait.c: Removed left-over
2806 duplication of __sem_wait_cleanup.
2808 * allocatestack.c: Revert last change.
2810 * sysdeps/i386/tls.h: Likewise.
2811 * sysdeps/x86_64/tls.h: Likewise.
2812 * descr.h [TLS_DTV_AT_TP] (struct pthread): Add private_futex field to
2814 * sysdeps/powerpc/tcb-offsets.sym: Add PRIVATE_FUTEX_OFFSET.
2816 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_barrier):
2818 * sysdeps/unix/sysv/linux/lowlevelbarrier.sym: Add PRIVATE definition.
2819 * pthread_barrier_init.c: Set private flag if pshared and private
2820 futexes are supported.
2821 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Use
2822 private field in futex command setup.
2823 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise.
2825 2007-05-25 Ulrich Drepper <drepper@redhat.com>
2827 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Add private futex
2829 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
2830 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
2831 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
2832 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
2833 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
2835 * semaphoreP.h: Declare __old_sem_init and __old_sem_wait.
2836 * sem_init.c (__new_sem_init): Rewrite to initialize all three
2837 fields in the structure.
2838 (__old_sem_init): New function.
2839 * sem_open.c: Initialize all fields of the structure.
2840 * sem_getvalue.c: Adjust for renamed element.
2841 * sysdeps/unix/sysv/linux/Makefile [subdir=nptl]
2842 (gen-as-const-headers): Add structsem.sym.
2843 * sysdeps/unix/sysv/linux/structsem.sym: New file.
2844 * sysdeps/unix/sysv/linux/internaltypes.h: Rename struct sem to
2845 struct new_sem. Add struct old_sem.
2846 * sysdeps/unix/sysv/linux/sem_post.c: Wake only when there are waiters.
2847 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
2848 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
2849 * sysdeps/unix/sysv/linux/sem_wait.c: Indicate that there are waiters.
2850 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
2851 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
2852 * sysdeps/unix/sysv/linux/sem_timedwait.c: Likewise.
2853 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
2854 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
2855 * Makefile (tests): Add tst-sem10, tst-sem11, tst-sem12.
2856 * tst-sem10.c: New file.
2857 * tst-sem11.c: New file.
2858 * tst-sem12.c: New file.
2859 * tst-typesizes.c: Test struct new_sem and struct old_sem instead
2862 2007-05-25 Ulrich Drepper <drepper@redhat.com>
2863 Jakub Jelinek <jakub@redhat.com>
2865 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
2866 Move __pthread_enable_asynccancel right before futex syscall.
2867 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
2870 2007-05-24 Jakub Jelinek <jakub@redhat.com>
2872 * sysdeps/i386/tls.h (THREAD_SET_PRIVATE_FUTEX,
2873 THREAD_COPY_PRIVATE_FUTEX): Define.
2874 * sysdeps/x86_64/tls.h (THREAD_SET_PRIVATE_FUTEX,
2875 THREAD_COPY_PRIVATE_FUTEX): Define.
2876 * allocatestack.c (allocate_stack): Use THREAD_COPY_PRIVATE_FUTEX.
2877 * init.c (__pthread_initialize_minimal_internal): Use
2878 THREAD_SET_PRIVATE_FUTEX.
2880 * sysdeps/powerpc/tls.h (tcbhead_t): Add gscope_flag.
2881 (THREAD_GSCOPE_FLAG_UNUSED, THREAD_GSCOPE_FLAG_USED,
2882 THREAD_GSCOPE_FLAG_WAIT): Define.
2883 (THREAD_GSCOPE_GET_FLAG, THREAD_GSCOPE_SET_FLAG,
2884 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_WAIT): Define.
2885 * sysdeps/i386/tls.h (THREAD_GSCOPE_WAIT): Don't use
2887 (THREAD_GSCOPE_GET_FLAG): Define.
2888 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_GET_FLAG): Define.
2889 * allocatestack.c (__wait_lookup_done): Use THREAD_GSCOPE_GET_FLAG
2890 instead of ->header.gscope_flag directly.
2892 2007-05-23 Ulrich Drepper <drepper@redhat.com>
2894 * init.c (__pthread_initialize_minimal_internal): Check whether
2895 private futexes are available.
2896 * allocatestack.c (allocate_stack): Copy private_futex field from
2897 current thread into the new stack.
2898 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Use private
2899 futexes if they are available.
2900 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise
2901 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Adjust so that change
2902 in libc-lowlevellock.S allow using private futexes.
2903 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
2904 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Define
2906 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
2907 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Use private futexes
2908 if they are available.
2909 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
2910 * sysdeps/x86_64/tcb-offsets.sym: Add PRIVATE_FUTEX.
2911 * sysdeps/i386/tcb-offsets.sym: Likewise.
2912 * sysdeps/x86_64/tls.h (tcbhead_t): Add private_futex field.
2913 * sysdeps/i386/tls.h (tcbhead_t): Likewise.
2915 2007-05-21 Ulrich Drepper <drepper@redhat.com>
2917 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
2918 Remove ptr_wait_lookup_done again.
2919 * init.c (pthread_functions): Don't add .ptr_wait_lookup_done here.
2920 (__pthread_initialize_minimal_internal): Initialize
2921 _dl_wait_lookup_done pointer in _rtld_global directly.
2922 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
2923 Remove code to code _dl_wait_lookup_done.
2924 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_WAIT): The pointer is not
2927 2007-05-21 Jakub Jelinek <jakub@redhat.com>
2929 * tst-robust9.c (do_test): Don't fail if ENABLE_PI and
2930 pthread_mutex_init failed with ENOTSUP.
2932 2007-05-19 Ulrich Drepper <drepper@redhat.com>
2934 * allocatestack.c (__wait_lookup_done): New function.
2935 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
2936 Add ptr_wait_lookup_done.
2937 * init.c (pthread_functions): Initialize .ptr_wait_lookup_done.
2938 * pthreadP.h: Declare __wait_lookup_done.
2939 * sysdeps/i386/tls.h (tcbhead_t): Add gscope_flag.
2940 Define macros to implement reference handling of global scope.
2941 * sysdeps/x86_64/tls.h: Likewise.
2942 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
2943 Initialize GL(dl_wait_lookup_done).
2945 2007-05-17 Ulrich Drepper <drepper@redhat.com>
2948 * pthread_mutex_lock.c: Preserve FUTEX_WAITERS bit when dead owner
2950 * pthread_mutex_timedlock.c: Likewise.
2951 * pthread_mutex_trylock.c: Likewise.
2952 Patch in part by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
2954 * Makefile (tests): Add tst-robust9 and tst-robustpi9.
2955 * tst-robust9.c: New file.
2956 * tst-robustpi9.c: New file.
2958 * sysdeps/unix/sysv/linux/sem_wait.c (__new_sem_wait): Remove
2959 unnecessary extra cancellation test.
2961 2007-05-14 Ulrich Drepper <drepper@redhat.com>
2963 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Remove unnecessary
2964 extra cancellation test.
2965 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
2967 2007-05-10 Ulrich Drepper <drepper@redhat.com>
2969 * descr.h (struct pthread): Rearrange members to fill hole in
2972 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
2973 (__pthread_setaffinity_new): If syscall was successful and
2974 RESET_VGETCPU_CACHE is defined, use it before returning.
2975 * sysdeps/unix/sysv/linux/x86_64/pthread_setaffinity.c: New file.
2977 2007-05-10 Jakub Jelinek <jakub@redhat.com>
2980 * tst-align2.c: Include stackinfo.h.
2981 * tst-getpid1.c: Likewise.
2983 2007-05-02 Carlos O'Donell <carlos@systemhalted.org>
2986 * tst-align2.c (do_test): Add _STACK_GROWS_UP case.
2987 * tst-getpid1.c (do_test): Likewise.
2990 * allocatestack.c (change_stack_perm): Add _STACK_GROWS_UP case.
2991 (allocate_stack): Likewise.
2993 2007-05-07 Ulrich Drepper <drepper@redhat.com>
2995 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
2996 (__lll_robust_lock_wait): Fix race caused by reloading of futex value.
2997 (__lll_robust_timedlock_wait): Likewise.
2998 Reported by Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>.
3000 2007-05-06 Mike Frysinger <vapier@gentoo.org>
3003 * tst-cancel-wrappers.sh: Set C["fdatasync"] to 1.
3004 * tst-cancel4.c (tf_fdatasync): New test.
3006 2007-04-27 Ulrich Drepper <drepper@redhat.com>
3009 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Treat error
3010 check mutexes like normal mutexes.
3013 * sysdeps/unix/sysv/linux/timer_create.c (timer_create):
3014 Initialize the whole sigevent structure to appease valgrind.
3016 2007-04-25 Ulrich Drepper <drepper@redhat.com>
3018 * sysdeps/x86_64/tls.h (tcbhead_t): Add vgetcpu_cache.
3019 * sysdeps/x86_64/tcb-offsets.sym: Add VGETCPU_CACHE_OFFSET.
3021 2007-04-06 Ulrich Drepper <drepper@redhat.com>
3023 * tst-locale1.c: Avoid warnings.
3024 * tst-locale2.c: Likewise.
3026 2007-03-19 Steven Munroe <sjmunroe@us.ibm.com>
3028 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
3029 (__lll_robust_trylock): Add MUTEX_HINT_ACQ to lwarx instruction.
3031 2007-03-16 Jakub Jelinek <jakub@redhat.com>
3033 * sysdeps/pthread/bits/libc-lock.h: Use __extern_inline and
3034 __extern_always_inline where appropriate.
3035 * sysdeps/pthread/pthread.h: Likewise.
3037 2007-03-13 Richard Henderson <rth@redhat.com>
3039 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (PSEUDO): Use two
3040 separate cfi regions for the two subsections.
3042 2007-02-25 Ulrich Drepper <drepper@redhat.com>
3044 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Reset refcntr in
3045 new thread, don't just decrement it.
3046 Patch by Suzuki K P <suzuki@in.ibm.com>.
3048 2007-02-21 Ulrich Drepper <drepper@redhat.com>
3050 * sysdeps/pthread/pthread-functions.h: Correct last patch, correct
3051 PTHFCT_CALL definition.
3053 2007-02-18 Ulrich Drepper <drepper@redhat.com>
3055 * sysdeps/pthread/pthread-functions.h: If PTR_DEMANGLE is not
3056 available, don't use it.
3058 2007-02-09 Jakub Jelinek <jakub@redhat.com>
3060 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
3061 (__lll_mutex_timedlock_wait): Use correct pointer when we don't
3062 call into the kernel to delay.
3064 2007-01-18 Ulrich Drepper <drepper@redhat.com>
3066 * tst-initializers1.c: We want to test the initializers as seen
3067 outside of libc, so undefined _LIBC.
3069 * pthread_join.c (cleanup): Avoid warning.
3071 2007-01-17 Ulrich Drepper <drepper@redhat.com>
3073 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
3074 (__lll_timedwait_tid): Add unwind info.
3076 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Don't just copy the
3077 function table, mangle the pointers.
3078 * sysdeps/pthread/pthread-functions.h: Define PTHFCT_CALL.
3079 * forward.c: Use PTHFCT_CALL and __libc_pthread_functions_init.
3080 * sysdeps/pthread/bits/libc-lock.h: When using __libc_pthread_functions
3081 demangle pointers before use.
3082 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Use PTHFCT_CALL to
3084 * sysdeps/unix/sysv/linux/jmp-unwind.c: Likewise.
3085 * sysdeps/pthread/setxid.h: Likewise.
3087 2007-01-12 Ulrich Drepper <drepper@redhat.com>
3089 * tst-rwlock7.c: Show some more information in case of correct
3092 2007-01-11 Ulrich Drepper <drepper@redhat.com>
3094 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
3095 (lll_futex_timed_wait): Undo part of last change, don't negate
3098 2007-01-10 Ulrich Drepper <drepper@redhat.com>
3100 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Cleanups. Define
3101 FUTEX_CMP_REQUEUE and lll_futex_requeue.
3103 2006-12-28 David S. Miller <davem@davemloft.net>
3105 * shlib-versions: Fix sparc64 linux target specification.
3107 2007-01-10 Jakub Jelinek <jakub@redhat.com>
3109 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
3110 Adjust include path for pthread_barrier_wait.c move.
3112 2006-12-21 Jakub Jelinek <jakub@redhat.com>
3114 * sysdeps/unix/sysv/linux/pthread_kill.c (pthread_kill): Make sure
3115 tid isn't reread from pd->tid in between ESRCH test and the syscall.
3117 2006-12-06 Jakub Jelinek <jakub@redhat.com>
3119 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO): Handle
3120 6 argument cancellable syscalls.
3121 (STM_6, LM_6, LR7_0, LR7_1, LR7_2, LR7_3, LR7_4, LR7_5, LR7_6): Define.
3122 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO): Handle
3123 6 argument cancellable syscalls.
3124 (STM_6, LM_6, LR7_0, LR7_1, LR7_2, LR7_3, LR7_4, LR7_5, LR7_6): Define.
3126 2006-12-09 Ulrich Drepper <drepper@redhat.com>
3128 * sysdeps/unix/sysv/linux/rtld-lowlevel.h
3129 (__rtld_mrlock_initialize): Add missing closing parenthesis.
3131 2006-10-30 Jakub Jelinek <jakub@redhat.com>
3133 * sysdeps/ia64/pthread_spin_unlock.c (pthread_spin_unlock): Use
3134 __sync_lock_release instead of __sync_lock_release_si.
3136 2006-10-29 Jakub Jelinek <jakub@redhat.com>
3138 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (RTLD_SINGLE_THREAD_P):
3140 (SINGLE_THREAD_P): Define to 1 if IS_IN_rtld.
3141 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Likewise.
3142 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
3143 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
3144 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
3145 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
3146 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
3147 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
3148 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
3149 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
3150 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
3152 2006-10-27 Ulrich Drepper <drepper@redhat.com>
3154 * sysdeps/pthread/pthread_barrier_wait.c: Move to...
3155 * pthread_barrier_wait.c: ...here.
3156 * sysdeps/pthread/pthread_cond_broadcast.c: Move to...
3157 * pthread_cond_broadcast.c: ...here.
3158 * sysdeps/pthread/pthread_cond_signal.c: Move to...
3159 * pthread_cond_signal.c: ...here.
3160 * sysdeps/pthread/pthread_cond_timedwait.c: Move to...
3161 * pthread_cond_timedwait.c: ...here.
3162 * sysdeps/pthread/pthread_cond_wait.c: Move to...
3163 * pthread_cond_wait.c: ...here.
3164 * sysdeps/pthread/pthread_once.c: Move to...
3165 * pthread_once.c: ...here.
3166 * sysdeps/pthread/pthread_rwlock_rdlock.c: Move to...
3167 * pthread_rwlock_rdlock.c: ...here.
3168 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Move to...
3169 * pthread_rwlock_timedrdlock.c: ...here.
3170 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Move to...
3171 * pthread_rwlock_timedwrlock.c: ...here.
3172 * sysdeps/pthread/pthread_rwlock_unlock.c: Move to...
3173 * pthread_rwlock_unlock.c: ...here.
3174 * sysdeps/pthread/pthread_rwlock_wrlock.c: Move to...
3175 * pthread_rwlock_wrlock.c: ...here.
3176 * sysdeps/pthread/pthread_spin_destroy.c: Move to...
3177 * pthread_spin_destroy.c: ...here.
3178 * sysdeps/pthread/pthread_spin_init.c: Move to...
3179 * pthread_spin_init.c: ...here.
3180 * sysdeps/pthread/pthread_spin_unlock.c: Move to...
3181 * pthread_spin_unlock.c: ...here.
3182 * sysdeps/pthread/pthread_getcpuclockid.c: Move to...
3183 * pthread_getcpuclockid.c: ...here.
3185 * init.c: USE_TLS support is now always enabled.
3186 * tst-tls5.h: Likewise.
3187 * sysdeps/alpha/tls.h: Likewise.
3188 * sysdeps/i386/tls.h: Likewise.
3189 * sysdeps/ia64/tls.h: Likewise.
3190 * sysdeps/powerpc/tls.h: Likewise.
3191 * sysdeps/s390/tls.h: Likewise.
3192 * sysdeps/sh/tls.h: Likewise.
3193 * sysdeps/sparc/tls.h: Likewise.
3194 * sysdeps/x86_64/tls.h: Likewise.
3196 2006-10-27 Jakub Jelinek <jakub@redhat.com>
3198 * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_mrlock_lock,
3199 __rtld_mrlock_change): Update oldval if atomic compare and exchange
3202 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
3203 Define to THREAD_SELF->header.multiple_threads.
3204 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SINGLE_THREAD_P):
3206 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (SINGLE_THREAD_P):
3208 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
3209 (SINGLE_THREAD_P): Likewise.
3210 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
3211 (SINGLE_THREAD_P): Likewise.
3212 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
3213 (SINGLE_THREAD_P): Likewise.
3214 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
3215 (SINGLE_THREAD_P): Likewise.
3216 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (SINGLE_THREAD_P):
3218 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
3219 (SINGLE_THREAD_P): Likewise.
3220 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
3221 (SINGLE_THREAD_P): Likewise.
3222 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (SINGLE_THREAD_P):
3225 2006-10-26 Jakub Jelinek <jakub@redhat.com>
3227 * pthread_attr_setstacksize.c (NEW_VERNUM): Define to GLIBC_2_3_3
3228 by default rather than 2_3_3.
3230 2006-10-17 Jakub Jelinek <jakub@redhat.com>
3232 * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_mrlock_lock,
3233 __rtld_mrlock_unlock, __rtld_mrlock_change, __rtld_mrlock_done): Use
3234 atomic_* instead of catomic_* macros.
3236 2006-10-12 Ulrich Drepper <drepper@redhat.com>
3239 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add SEM_VALUE_MAX.
3240 * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: Likewise.
3241 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
3242 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
3243 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
3244 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h: Remove SEM_VALUE_MAX.
3245 * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: Likewise.
3246 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
3247 * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: Likewise.
3248 * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h: Likewise.
3249 * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: Likewise.
3250 * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: Likewise.
3251 * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: Likewise.
3253 2006-10-11 Ulrich Drepper <drepper@redhat.com>
3255 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Add support for
3256 cancelable syscalls with six parameters.
3258 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: Use catomic_*
3259 operations instead of atomic_*.
3261 2006-10-09 Ulrich Drepper <drepper@redhat.com>
3263 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: New file..
3265 2006-10-07 Ulrich Drepper <drepper@redhat.com>
3267 * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: New file.
3268 * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstack.c: New file.
3269 * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstacksize.c:
3271 * pthread_attr_setstack.c: Allow overwriting the version number of the
3273 * pthread_attr_setstacksize.c: Likewise.
3274 (__old_pthread_attr_setstacksize): If STACKSIZE_ADJUST is defined use
3276 * sysdeps/unix/sysv/linux/powerpc/Versions (libpthread): Add
3277 pthread_attr_setstack and pthread_attr_setstacksize to GLIBC_2.6.
3279 2006-09-24 Ulrich Drepper <drepper@redhat.com>
3282 * descr.h (ENQUEUE_MUTEX_BOTH): Add cast to avoid warning.
3283 Patch by Petr Baudis.
3285 2006-09-18 Jakub Jelinek <jakub@redhat.com>
3287 * tst-kill4.c (do_test): Explicitly set tf thread's stack size.
3289 * tst-cancel2.c (tf): Loop as long as something was written.
3291 2006-09-12 Kaz Kojima <kkojima@rr.iij4u.or.jp>
3293 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: For PI
3294 mutexes wake all mutexes.
3295 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Don't increment
3296 WAKEUP_SEQ if this would increase the value beyond TOTAL_SEQ.
3297 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
3299 2006-09-12 Ulrich Drepper <drepper@redhat.com>
3301 * tst-cond22.c (tf): Slight changes to the pthread_cond_wait use
3302 to guarantee the thread is always canceled.
3304 2006-09-08 Jakub Jelinek <jakub@redhat.com>
3306 * tst-cond22.c: Include pthread.h instead of pthreadP.h.
3308 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Only
3309 increase FUTEX if increasing WAKEUP_SEQ. Fix comment typo.
3310 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
3311 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
3312 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
3314 2006-09-08 Ulrich Drepper <drepper@redhat.com>
3317 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Don't
3318 increment WAKEUP_SEQ if this would increase the value beyond TOTAL_SEQ.
3319 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
3320 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
3321 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
3322 * Makefile (tests): Add tst-cond22.
3323 * tst-cond22.c: New file.
3325 2006-09-05 Ulrich Drepper <drepper@redhat.com>
3328 * descr.h (struct pthread): Add parent_cancelhandling.
3329 * sysdeps/pthread/createthread.c (create_thread): Pass parent
3330 cancelhandling value to child.
3331 * pthread_create.c (start_thread): If parent thread was canceled
3332 reset the SIGCANCEL mask.
3333 * Makefile (tests): Add tst-cancel25.
3334 * tst-cancel25.c: New file.
3336 2006-09-05 Jakub Jelinek <jakub@redhat.com>
3337 Ulrich Drepper <drepper@redhat.com>
3339 * sysdeps/pthread/gai_misc.h (GAI_MISC_NOTIFY): Don't decrement
3340 counterp if it is already zero.
3341 * sysdeps/pthread/aio_misc.h (AIO_MISC_NOTIFY): Likewise..
3343 2006-03-04 Jakub Jelinek <jakub@redhat.com>
3344 Roland McGrath <roland@redhat.com>
3346 * sysdeps/unix/sysv/linux/i386/lowlevellock.h
3347 (LLL_STUB_UNWIND_INFO_START, LLL_STUB_UNWIND_INFO_END,
3348 LLL_STUB_UNWIND_INFO_3, LLL_STUB_UNWIND_INFO_4): Define.
3349 (lll_mutex_lock, lll_robust_mutex_lock, lll_mutex_cond_lock,
3350 lll_robust_mutex_cond_lock, lll_mutex_timedlock,
3351 lll_robust_mutex_timedlock, lll_mutex_unlock,
3352 lll_robust_mutex_unlock, lll_lock, lll_unlock): Use them.
3353 Add _L_*_ symbols around the subsection.
3354 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Add unwind info.
3355 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: Likewise.
3357 2006-03-03 Jakub Jelinek <jakub@redhat.com>
3358 Roland McGrath <roland@redhat.com>
3360 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
3361 (LLL_STUB_UNWIND_INFO_START, LLL_STUB_UNWIND_INFO_END,
3362 LLL_STUB_UNWIND_INFO_5, LLL_STUB_UNWIND_INFO_6): Define.
3363 (lll_mutex_lock, lll_robust_mutex_lock, lll_mutex_cond_lock,
3364 lll_robust_mutex_cond_lock, lll_mutex_timedlock,
3365 lll_robust_mutex_timedlock, lll_mutex_unlock,
3366 lll_robust_mutex_unlock, lll_lock, lll_unlock): Use them.
3367 Add _L_*_ symbols around the subsection.
3368 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Add unwind info.
3369 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Likewise.
3371 2006-08-31 Ulrich Drepper <drepper@redhat.com>
3373 * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Undo last
3374 change because it can disturb too much existing code. If real hard
3375 reader preference is needed we'll introduce another type.
3376 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
3377 (pthread_rwlock_timedwrlock): Likewise.
3378 * sysdeps/pthread/pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock):
3381 2006-08-30 Ulrich Drepper <drepper@redhat.com>
3383 * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Respect
3385 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
3386 (pthread_rwlock_timedwrlock): Likewise.
3387 * sysdeps/pthread/pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock):
3390 2006-08-25 Jakub Jelinek <jakub@redhat.com>
3392 * sysdeps/unix/sysv/linux/libc_pthread_init.c (freeres_libpthread):
3393 Only define ifdef SHARED.
3395 2006-08-23 Ulrich Drepper <drepper@redhat.com>
3397 * allocatestack.c (queue_stack): Move freeing of surplus stacks to...
3398 (free_stacks): ...here.
3399 (__free_stack_cache): New function.
3400 * pthreadP.h: Declare __free_stack_cache.
3401 * sysdeps/pthread/pthread-functions.h (pthread_functions): Add
3403 * init.c (pthread_functions): Initialize ptr_freeres.
3404 * sysdeps/unix/sysv/linux/libc_pthread_init.c (freeres_libptread):
3405 New freeres function.
3407 2006-07-30 Joseph S. Myers <joseph@codesourcery.com>
3410 * Makefile (extra-objs): Add modules to extra-test-objs instead.
3412 2006-08-20 Ulrich Drepper <drepper@redhat.com>
3414 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
3415 _XOPEN_REALTIME_THREADS.
3417 2006-08-15 Jakub Jelinek <jakub@redhat.com>
3419 * sysdeps/unix/sysv/linux/clock_settime.c (INTERNAL_VSYSCALL): Use
3420 HAVE_CLOCK_GETRES_VSYSCALL as guard macro rather than
3421 HAVE_CLOCK_GETTIME_VSYSCALL.
3422 (maybe_syscall_settime_cpu): Use plain INTERNAL_VSYSCALL here.
3424 2006-08-14 Jakub Jelinek <jakub@redhat.com>
3426 * sysdeps/unix/sysv/linux/bits/posix_opt.h
3427 (_POSIX_THREAD_PRIO_PROTECT): Define to 200112L.
3428 * descr.h (struct priority_protection_data): New type.
3429 (struct pthread): Add tpp field.
3430 * pthreadP.h (PTHREAD_MUTEX_PP_NORMAL_NP,
3431 PTHREAD_MUTEX_PP_RECURSIVE_NP, PTHREAD_MUTEX_PP_ERRORCHECK_NP,
3432 PTHREAD_MUTEX_PP_ADAPTIVE_NP): New enum values.
3433 * pthread_mutex_init.c (__pthread_mutex_init): Handle non-robust
3435 * pthread_mutex_lock.c (__pthread_mutex_lock): Handle TPP mutexes.
3436 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Likewise.
3437 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Likewise.
3438 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Likewise.
3440 * pthread_setschedparam.c (__pthread_setschedparam): Handle priority
3442 * pthread_setschedprio.c (pthread_setschedprio): Likewise.
3443 * pthread_mutexattr_getprioceiling.c
3444 (pthread_mutexattr_getprioceiling): If ceiling is 0, ensure it is
3445 in the SCHED_FIFO priority range.
3446 * pthread_mutexattr_setprioceiling.c
3447 (pthread_mutexattr_setprioceiling): Fix prioceiling validation.
3448 * pthread_mutex_getprioceiling.c (pthread_mutex_getprioceiling): Fail
3449 if mutex is not TPP. Ceiling is now in __data.__lock.
3450 * pthread_mutex_setprioceiling.c: Include stdbool.h.
3451 (pthread_mutex_setprioceiling): Fix prioceiling validation. Ceiling
3452 is now in __data.__lock. Add locking.
3453 * pthread_create.c (__free_tcb): Free pd->tpp structure.
3454 * Makefile (libpthread-routines): Add tpp.
3455 (xtests): Add tst-mutexpp1, tst-mutexpp6 and tst-mutexpp10.
3456 * tst-tpp.h: New file.
3457 * tst-mutexpp1.c: New file.
3458 * tst-mutexpp6.c: New file.
3459 * tst-mutexpp10.c: New file.
3460 * tst-mutex1.c (TEST_FUNCTION): Don't redefine if already defined.
3461 * tst-mutex6.c (TEST_FUNCTION): Likewise.
3463 2006-08-12 Ulrich Drepper <drepper@redhat.com>
3466 * pthread_join.c (pthread_join): Account for self being canceled
3467 when checking for deadlocks.
3468 * tst-join5.c: Cleanups. Allow to be used in tst-join6.
3469 (tf1): Don't print anything after pthread_join returns, this would be
3470 another cancellation point.
3472 * tst-join6.c: New file.
3473 * Makefile (tests): Add tst-join6.
3475 2006-08-03 Ulrich Drepper <drepper@redhat.com>
3478 * pthread_setspecific.c (__pthread_setspecific): Check
3479 out-of-range index before checking for unused key.
3481 * sysdeps/pthread/gai_misc.h: New file.
3483 2006-08-01 Ulrich Drepper <drepper@redhat.com>
3485 * sysdeps/unix/sysv/linux/i386/smp.h: New file. Old Linux-specific
3486 file. Don't use sysctl.
3487 * sysdeps/unix/sysv/linux/smp.h: Always assume SMP. Archs can
3488 overwrite the file if this is likely not true.
3490 2006-07-31 Daniel Jacobowitz <dan@codesourcery.com>
3492 * allocatestack.c (__reclaim_stacks): Reset the PID on cached stacks.
3493 * Makefile (tests): Add tst-getpid3.
3494 * tst-getpid3.c: New file.
3496 2006-07-30 Roland McGrath <roland@redhat.com>
3498 * Makefile (libpthread-routines): Add ptw-sigsuspend.
3500 * sysdeps/unix/sysv/linux/i386/not-cancel.h
3501 (pause_not_cancel): New macro.
3502 (nanosleep_not_cancel): New macro.
3503 (sigsuspend_not_cancel): New macro.
3504 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Use
3505 nanosleep_not_cancel macro from <not-cancel.h>.
3506 * pthread_mutex_lock.c (__pthread_mutex_lock): Use pause_not_cancel
3507 macro from <not-cancel.h>.
3509 2006-07-28 Ulrich Drepper <drepper@redhat.com>
3510 Jakub Jelinek <jakub@redhat.com>
3512 * descr.h: Change ENQUEUE_MUTEX and DEQUEUE_MUTEX for bit 0
3513 notification of PI mutex. Add ENQUEUE_MUTEX_PI.
3514 * pthreadP.h: Define PTHREAD_MUTEX_PI_* macros for PI mutex types.
3515 * pthread_mutex_setprioceilining.c: Adjust for mutex type name change.
3516 * pthread_mutex_init.c: Add support for priority inheritance mutex.
3517 * pthread_mutex_lock.c: Likewise.
3518 * pthread_mutex_timedlock.c: Likewise.
3519 * pthread_mutex_trylock.c: Likewise.
3520 * pthread_mutex_unlock.c: Likewise.
3521 * sysdeps/pthread/pthread_cond_broadcast.c: For PI mutexes wake
3523 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.c: Likewise.
3524 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.c: Likewise.
3525 * sysdeps/unix/sysv/linux/pthread-pi-defines.sym: New file.
3526 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-header): Add
3527 pthread-pi-defines.sym.
3528 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define FUTEX_LOCK_PI,
3529 FUTEX_UNLOCK_PI, and FUTEX_TRYLOCK_PI.
3530 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
3531 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
3532 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
3533 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
3534 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
3535 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
3536 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
3537 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
3538 _POSIX_THREAD_PRIO_INHERIT to 200112L.
3539 * tst-mutex1.c: Adjust to allow use in PI mutex test.
3540 * tst-mutex2.c: Likewise.
3541 * tst-mutex3.c: Likewise.
3542 * tst-mutex4.c: Likewise.
3543 * tst-mutex5.c: Likewise.
3544 * tst-mutex6.c: Likewise.
3545 * tst-mutex7.c: Likewise.
3546 * tst-mutex7a.c: Likewise.
3547 * tst-mutex8.c: Likewise.
3548 * tst-mutex9.c: Likewise.
3549 * tst-robust1.c: Likewise.
3550 * tst-robust7.c: Likewise.
3551 * tst-robust8.c: Likewise.
3552 * tst-mutexpi1.c: New file.
3553 * tst-mutexpi2.c: New file.
3554 * tst-mutexpi3.c: New file.
3555 * tst-mutexpi4.c: New file.
3556 * tst-mutexpi5.c: New file.
3557 * tst-mutexpi6.c: New file.
3558 * tst-mutexpi7.c: New file.
3559 * tst-mutexpi7a.c: New file.
3560 * tst-mutexpi8.c: New file.
3561 * tst-mutexpi9.c: New file.
3562 * tst-robust1.c: New file.
3563 * tst-robust2.c: New file.
3564 * tst-robust3.c: New file.
3565 * tst-robust4.c: New file.
3566 * tst-robust5.c: New file.
3567 * tst-robust6.c: New file.
3568 * tst-robust7.c: New file.
3569 * tst-robust8.c: New file.
3570 * Makefile (tests): Add the new tests.
3572 * pthread_create.c (start_thread): Add some casts to avoid warnings.
3573 * pthread_mutex_destroy.c: Remove unneeded label.
3575 2006-07-01 Ulrich Drepper <drepper@redhat.com>
3577 * pthread_mutex_init.c (__pthread_mutex_init): Move some
3578 computations to compile time.
3580 2006-06-04 Ulrich Drepper <drepper@redhat.com>
3582 * sysdeps/pthread/pthread.h: Add pthread_equal inline version.
3584 2006-05-15 Ulrich Drepper <drepper@redhat.com>
3586 * sysdeps/unix/sysv/linux/fork.h: Mark __fork_handlers as hidden.
3588 2006-05-11 Ulrich Drepper <drepper@redhat.com>
3590 * pthread_key_create.c (__pthread_key_create): Do away with
3591 __pthread_keys_lock.
3593 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
3594 (__kernel_cpumask_size): Mark as hidden.
3595 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: Likewise.
3597 * sem_open.c (__sem_mappings_lock): Mark as hidden.
3598 * semaphoreP.h (__sem_mappings_lock): Likewise.
3600 2006-05-10 Ulrich Drepper <drepper@redhat.com>
3602 * pthread_atfork.c: Mark __dso_handle as hidden.
3604 2006-05-09 Ulrich Drepper <drepper@redhat.com>
3607 * sysdeps/pthread/unwind-forcedunwind.c: Different solution for
3608 the reload problem. Change the one path in pthread_cancel_init
3609 which causes the problem. Force gcc to reload. Simplify callers.
3610 * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c
3611 (_Unwind_GetBSP): Undo last patch.
3613 2006-05-07 Ulrich Drepper <drepper@redhat.com>
3615 * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c: Make sure the
3616 function pointer is reloaded after pthread_cancel_init calls.
3619 * sysdeps/pthread/unwind-forcedunwind.c: Make sure functions
3620 pointers are reloaded after pthread_cancel_init calls.
3622 2006-05-01 Ulrich Drepper <drepper@redhat.com>
3624 * sysdeps/pthread/allocalim.h (__libc_use_alloca): Mark with
3627 2006-04-27 Ulrich Drepper <drepper@redhat.com>
3629 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
3630 Allocate new object which is passed to timer_sigev_thread so that
3631 the timer can be deleted before the new thread is scheduled.
3633 2006-04-26 Roland McGrath <roland@redhat.com>
3635 * sysdeps/x86_64/tls.h: Include <asm/prctl.h> inside [! __ASSEMBLER__].
3637 2006-04-08 Ulrich Drepper <drepper@redhat.com>
3639 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove branch predicion
3640 suffix for conditional jumps.
3641 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
3642 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
3643 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
3644 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
3645 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
3646 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
3648 * init.c (sigcancel_handler): Compare with correct PID even if the
3649 thread is in the middle of a fork call.
3650 (sighandler_setxid): Likewise.
3651 Reported by Suzuki K P <suzuki@in.ibm.com> .
3653 2006-04-07 Jakub Jelinek <jakub@redhat.com>
3655 * pthreadP.h (FUTEX_TID_MASK): Sync with kernel.
3657 2006-04-06 Ulrich Drepper <drepper@redhat.com>
3659 * pthread_getattr_np.c (pthread_getattr_np): Close fp if getrlimit
3660 fails [Coverity CID 105].
3662 2006-04-05 Ulrich Drepper <drepper@redhat.com>
3664 * sysdeps/pthread/pthread.h: Add nonnull attributes.
3666 2006-04-03 Steven Munroe <sjmunroe@us.ibm.com>
3669 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h [_ARCH_PWR4]:
3670 Define __lll_rel_instr using lwsync.
3672 2006-03-27 Ulrich Drepper <drepper@redhat.com>
3674 * allocatestack.c (allocate_stack): Always initialize robust_head.
3675 * descr.h: Define struct robust_list_head.
3676 (struct pthread): Use robust_list_head in robust mutex list definition.
3677 Adjust ENQUEUE_MUTEX and DEQUEUE_MUTEX.
3678 * init.c [!__ASSUME_SET_ROBUST_LIST] (__set_robust_list_avail): Define.
3679 (__pthread_initialize_minimal_internal): Register robust_list with
3681 * pthreadP.h: Remove PRIVATE_ from PTHREAD_MUTEX_ROBUST_* names.
3682 Declare __set_robust_list_avail.
3683 * pthread_create.c (start_thread): Register robust_list of new thread.
3684 [!__ASSUME_SET_ROBUST_LIST]: If robust_list is not empty wake up
3686 * pthread_mutex_destroy.c: For robust mutexes don't look at the
3687 number of users, it's unreliable.
3688 * pthread_mutex_init.c: Allow use of pshared robust mutexes if
3689 set_robust_list syscall is available.
3690 * pthread_mutex_consistent.c: Adjust for PTHREAD_MUTEX_ROBUST_* rename.
3691 * pthread_mutex_lock.c: Simplify robust mutex code a bit.
3692 Set robust_head.list_op_pending before trying to lock a robust mutex.
3693 * pthread_mutex_timedlock.c: Likewise.
3694 * pthread_mutex_trylock.c: Likewise.
3695 * pthread_mutex_unlock.c: Likewise for unlocking.
3696 * Makefile (tests): Add tst-robust8.
3697 * tst-robust8.c: New file.
3699 2006-03-08 Andreas Schwab <schwab@suse.de>
3701 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h
3702 (DL_SYSINFO_IMPLEMENTATION): Add missing newline.
3704 2006-03-05 Roland McGrath <roland@redhat.com>
3706 * configure (libc_add_on): Disable add-on when $add_ons_automatic = yes
3707 and $config_os doesn't match *linux*.
3709 2006-03-05 David S. Miller <davem@sunset.davemloft.net>
3711 * sysdeps/unix/sysv/linux/sparc/sparc32/pt-vfork.S:
3712 Use __syscall_error.
3713 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
3714 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: Likewise.
3715 * sysdeps/unix/sysv/linux/sparc/sparc64/pt-vfork.S: Likewise.
3716 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
3717 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: Likewise.
3718 * sysdeps/unix/sysv/linux/sparc/Makefile: New file.
3720 2006-03-02 Ulrich Drepper <drepper@redhat.com>
3722 * sysdeps/unix/sysv/linux/aio_misc.h: Various cleanups.
3724 2006-03-01 Ulrich Drepper <drepper@redhat.com>
3726 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S
3727 (__lll_robust_lock_wait): Also set FUTEX_WAITERS bit if we got the
3729 (__lll_robust_timedlock_wait): Likewise.
3730 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S
3731 (__lll_robust_lock_wait): Likewise.
3732 (__lll_robust_timedlock_wait): Likewise.
3733 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
3734 (__lll_robust_lock_wait): Likewise.
3735 (__lll_robust_timedlock_wait): Likewise.
3737 2006-03-01 Jakub Jelinek <jakub@redhat.com>
3739 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (lll_robust_mutex_dead,
3740 lll_robust_mutex_trylock, lll_robust_mutex_lock,
3741 lll_robust_mutex_cond_lock, lll_robust_mutex_timedlock,
3742 lll_robust_mutex_unlock): Define.
3743 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): New prototypes.
3745 2006-02-28 H.J. Lu <hongjiu.lu@intel.com>
3747 * sysdeps/unix/sysv/linux/ia64/clone2.S: Include <clone2.S>
3748 instead of <clone.S>.
3750 2006-02-27 Jakub Jelinek <jakub@redhat.com>
3752 * Makefile (libpthread-routines): Add
3753 pthread_mutexattr_[sg]etprotocol, pthread_mutexattr_[sg]etprioceiling
3754 and pthread_mutex_[sg]etprioceiling.
3755 * Versions (GLIBC_2.4): Export pthread_mutexattr_getprotocol,
3756 pthread_mutexattr_setprotocol, pthread_mutexattr_getprioceiling,
3757 pthread_mutexattr_setprioceiling, pthread_mutex_getprioceiling and
3758 pthread_mutex_setprioceiling.
3759 * sysdeps/pthread/pthread.h (PTHREAD_PRIO_NONE, PTHREAD_PRIO_INHERIT,
3760 PTHREAD_PRIO_PROTECT): New enum values.
3761 (pthread_mutexattr_getprotocol, pthread_mutexattr_setprotocol,
3762 pthread_mutexattr_getprioceiling, pthread_mutexattr_setprioceiling,
3763 pthread_mutex_getprioceiling, pthread_mutex_setprioceiling): New
3765 * pthreadP.h (PTHREAD_MUTEX_PRIO_INHERIT_PRIVATE_NP,
3766 PTHREAD_MUTEX_PRIO_PROTECT_PRIVATE_NP): New enum values.
3767 (PTHREAD_MUTEX_PRIO_CEILING_SHIFT, PTHREAD_MUTEX_PRIO_CEILING_MASK):
3769 (PTHREAD_MUTEXATTR_PROTOCOL_SHIFT, PTHREAD_MUTEXATTR_PROTOCOL_MASK,
3770 PTHREAD_MUTEXATTR_PRIO_CEILING_SHIFT,
3771 PTHREAD_MUTEXATTR_PRIO_CEILING_MASK): Define.
3772 (PTHREAD_MUTEXATTR_FLAG_BITS): Or in PTHREAD_MUTEXATTR_PROTOCOL_MASK
3773 and PTHREAD_MUTEXATTR_PRIO_CEILING_MASK.
3774 * pthread_mutex_init.c (__pthread_mutex_init): For the time being
3775 return ENOTSUP for PTHREAD_PRIO_INHERIT or PTHREAD_PRIO_PROTECT
3777 * pthread_mutex_getprioceiling.c: New file.
3778 * pthread_mutex_setprioceiling.c: New file.
3779 * pthread_mutexattr_getprioceiling.c: New file.
3780 * pthread_mutexattr_setprioceiling.c: New file.
3781 * pthread_mutexattr_getprotocol.c: New file.
3782 * pthread_mutexattr_setprotocol.c: New file.
3784 2006-02-27 Daniel Jacobowitz <dan@codesourcery.com>
3786 * sysdeps/unix/sysv/linux/aio_misc.h: Include <limits.h>.
3788 2006-02-27 Roland McGrath <roland@redhat.com>
3790 * sysdeps/pthread/Subdirs: List nptl here too.
3791 * configure (libc_add_on_canonical): New variable.
3793 * sysdeps/unix/sysv/linux/sh/sh4/lowlevellock.h: Use #include_next.
3795 * sysdeps/unix/sysv/linux/sleep.c: Use #include_next after #include of
3796 self to get main source tree's file.
3797 * sysdeps/unix/sysv/linux/alpha/clone.S: Likewise.
3798 * sysdeps/unix/sysv/linux/i386/clone.S: Likewise.
3799 * sysdeps/unix/sysv/linux/i386/vfork.S: Likewise.
3800 * sysdeps/unix/sysv/linux/ia64/clone2.S: Likewise.
3801 * sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S: Likewise.
3802 * sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S: Likewise.
3803 * sysdeps/unix/sysv/linux/s390/s390-32/clone.S: Likewise.
3804 * sysdeps/unix/sysv/linux/s390/s390-64/clone.S: Likewise.
3805 * sysdeps/unix/sysv/linux/sh/clone.S: Likewise.
3806 * sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: Likewise.
3807 * sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
3808 * sysdeps/unix/sysv/linux/x86_64/clone.S: Likewise.
3809 * sysdeps/unix/sysv/linux/x86_64/vfork.S: Likewise.
3811 * Makefile: Use $(sysdirs) in vpath directive.
3813 * sysdeps/pthread/Makefile (CFLAGS-libc-start.c): Variable removed.
3814 (CPPFLAGS-timer_routines.c): Likewise.
3816 * Makeconfig (includes): Variable removed.
3818 2006-02-26 Roland McGrath <roland@redhat.com>
3820 * sysdeps/generic/pt-raise.c: Moved to ...
3821 * pt-raise.c: ... here.
3822 * sysdeps/generic/lowlevellock.h: Moved to ...
3823 * lowlevellock.h: ... here.
3825 2006-02-23 Roland McGrath <roland@redhat.com>
3827 * descr.h (struct pthread): Add final member `end_padding'.
3828 (PTHREAD_STRUCT_END_PADDING): Use it.
3830 2006-02-20 Roland McGrath <roland@redhat.com>
3832 * sysdeps/mips: Directory removed, saved in ports repository.
3833 * sysdeps/unix/sysv/linux/mips: Likewise.
3835 2006-02-18 Ulrich Drepper <drepper@redhat.com>
3837 * tst-robust1.c: Add second mutex to check that the mutex list is
3840 2006-02-17 Jakub Jelinek <jakub@redhat.com>
3842 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_robust_mutex_dead,
3843 lll_robust_mutex_trylock, lll_robust_mutex_lock,
3844 lll_robust_mutex_cond_lock, lll_robust_mutex_timedlock,
3845 lll_robust_mutex_unlock): New macros.
3846 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): New prototypes.
3847 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
3848 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
3849 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
3850 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c: New file.
3852 2006-02-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
3854 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Add lll_robust_mutex_*
3856 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S: New file.
3858 2006-02-17 Ulrich Drepper <drepper@redhat.com>
3860 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
3861 (lll_robust_mutex_unlock): Avoid unnecessary wakeups.
3862 * sysdeps/unix/sysv/linux/i386/lowlevellock.h
3863 (lll_robust_mutex_unlock): Likewise.
3865 2006-02-13 Jakub Jelinek <jakub@redhat.com>
3867 * descr.h [!__PTHREAD_MUTEX_HAVE_PREV] (DEQUEUE_MUTEX):
3868 Set robust_list.__next rather than robust_list.
3869 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
3870 (__pthread_list_t): New typedef.
3871 (pthread_mutex_t): Replace __next and __prev fields with __list.
3872 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h
3873 (__pthread_list_t): New typedef.
3874 (pthread_mutex_t): Replace __next and __prev fields with __list.
3875 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
3876 (__pthread_list_t, __pthread_slist_t): New typedefs.
3877 (pthread_mutex_t): Replace __next and __prev fields with __list.
3878 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h
3879 (__pthread_list_t, __pthread_slist_t): New typedefs.
3880 (pthread_mutex_t): Replace __next and __prev fields with __list.
3881 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h
3882 (__pthread_list_t, __pthread_slist_t): New typedefs.
3883 (pthread_mutex_t): Replace __next and __prev fields with __list.
3884 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h
3885 (__pthread_slist_t): New typedef.
3886 (pthread_mutex_t): Replace __next field with __list.
3888 2006-02-15 Ulrich Drepper <drepper@redhat.com>
3890 * pthreadP.h: Define PTHREAD_MUTEX_INCONSISTENT instead of
3891 PTHREAD_MUTEX_OWNERDEAD.
3892 (PTHREAD_MUTEX_ROBUST_PRIVATE_NP): Define as 16, not 256.
3893 Define FUTEX_WAITERS, FUTEX_OWNER_DIED, FUTEX_TID_MASK.
3894 * Makefile (libpthread-routines): Add lowlevelrobustlock.
3895 * pthread_create.c (start_thread): Very much simplify robust_list loop.
3896 * pthread_mutex_consistent.c: Inconsistent mutex have __owner now set
3897 to PTHREAD_MUTEX_INCONSISTENT.
3898 * pthread_mutex_destroy.c: Allow destroying of inconsistent mutexes.
3899 * pthread_mutex_lock.c: Reimplement robust mutex handling.
3900 * pthread_mutex_trylock.c: Likewise.
3901 * pthread_mutex_timedlock.c: Likewise.
3902 * pthread_mutex_unlock.c: Likewise.
3903 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
3904 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
3905 lowlevelrobustlock.sym.
3906 * sysdeps/unix/sysv/linux/lowlevelrobustlock.sym: New file.
3907 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Add lll_robust_mutex_*
3909 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
3910 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: New file.
3911 * sysdeps/unix/sysv/linux/i386/i586/lowlevelrobustlock.S: New file.
3912 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrobustlock.S: New file.
3913 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: New file.
3915 2006-02-12 Ulrich Drepper <drepper@redhat.com>
3917 * allocatestack.c (allocate_stack): Initialize robust_list.
3918 * init.c (__pthread_initialize_minimal_internal): Likewise.
3919 * descr.h (struct xid_command): Pretty printing.
3920 (struct pthread): Use __pthread_list_t or __pthread_slist_t for
3921 robust_list. Adjust macros.
3922 * pthread_create.c (start_thread): Adjust robust_list handling.
3923 * phtread_mutex_unlock.c: Don't allow unlocking from any thread
3924 but the owner for all robust mutex types.
3925 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Define
3926 __pthread_list_t and __pthread_slist_t. Use them in pthread_mutex_t.
3927 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
3928 * sysdeps/pthread/pthread.h: Adjust mutex initializers.
3930 * sysdeps/unix/sysv/linux/i386/not-cancel.h: Define openat_not_cancel,
3931 openat_not_cancel_3, openat64_not_cancel, and openat64_not_cancel_3.
3933 2006-02-08 Jakub Jelinek <jakub@redhat.com>
3935 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait,
3936 lll_futex_timedwait, lll_wait_tid): Add "memory" clobber.
3938 2006-01-20 Kaz Kojima <kkojima@rr.iij4u.or.jp>
3940 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_futex_wait):
3942 (lll_futex_timed_wait): Define.
3944 2006-01-19 Ulrich Drepper <drepper@redhat.com>
3946 * tst-cancel4.c: Test ppoll.
3948 2006-01-18 Andreas Jaeger <aj@suse.de>
3951 * sysdeps/unix/sysv/linux/mips/bits/pthreadtypes.h
3952 (pthread_mutex_t): Follow changes for other archs. Based on patch
3953 by Jim Gifford <patches@jg555.com>.
3955 2006-01-13 Richard Henderson <rth@redhat.com>
3957 * sysdeps/alpha/tls.h (tcbhead_t): Rename member to __private.
3959 2006-01-10 Roland McGrath <roland@redhat.com>
3961 * sysdeps/alpha/jmpbuf-unwind.h: File moved to main source tree.
3962 * sysdeps/i386/jmpbuf-unwind.h: Likewise.
3963 * sysdeps/mips/jmpbuf-unwind.h: Likewise.
3964 * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
3965 * sysdeps/s390/jmpbuf-unwind.h: Likewise.
3966 * sysdeps/sh/jmpbuf-unwind.h: Likewise.
3967 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
3968 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Likewise.
3969 * sysdeps/x86_64/jmpbuf-unwind.h: Likewise.
3970 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
3972 2006-01-09 Roland McGrath <roland@redhat.com>
3974 * tst-initializers1-c89.c: New file.
3975 * tst-initializers1-c99.c: New file.
3976 * tst-initializers1-gnu89.c: New file.
3977 * tst-initializers1-gnu99.c: New file.
3978 * Makefile (tests): Add them.
3979 (CFLAGS-tst-initializers1-c89.c): New variable.
3980 (CFLAGS-tst-initializers1-c99.c): New variable.
3981 (CFLAGS-tst-initializers1-gnu89.c): New variable.
3982 (CFLAGS-tst-initializers1-gnu99.c): New variable.
3984 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
3985 Use __extension__ on anonymous union definition.
3986 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
3987 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
3988 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
3989 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
3990 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
3992 2006-01-08 Jakub Jelinek <jakub@redhat.com>
3994 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_mutex_t):
3995 Don't give the union a name because it changes the mangled name.
3996 Instead name the struct for __data.
3997 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_mutex_t):
3999 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_mutex_t):
4002 2006-01-09 Jakub Jelinek <jakub@redhat.com>
4004 * sysdeps/sparc/sparc64/jmpbuf-unwind.h (_JMPBUF_UNWINDS_ADJ): Add
4005 stack bias to mc_ftp field.
4007 2006-01-07 Ulrich Drepper <drepper@redhat.com>
4009 * sysdeps/pthread/aio_misc.h (AIO_MISC_WAIT): Work around gcc
4010 being too clever and reloading the futex value where it shouldn't.
4012 2006-01-06 Ulrich Drepper <drepper@redhat.com>
4014 * descr.h [!__PTHREAD_MUTEX_HAVE_PREV] (DEQUEUE_MUTEX): Use
4017 2006-01-06 Jakub Jelinek <jakub@redhat.com>
4019 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h (PSEUDO):
4022 2006-01-06 Ulrich Drepper <drepper@redhat.com>
4024 * sysdeps/ia64/tls.h (tcbhead_t): Rename private member to __private.
4025 * sysdeps/ia64/tcb-offsets.sym: Adjust for private->__private
4026 rename in tcbhead_t.
4028 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
4029 Don't give the union a name because it changes the mangled name.
4030 Instead name the struct for __data.
4031 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
4032 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
4033 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
4034 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
4035 * pthread_create.c (start_thread): Adjust robust mutex free loop.
4036 * descr.h (ENQUEUE_MUTEX, DEQUEUE_MUTEX): Adjust.
4038 2006-01-05 Ulrich Drepper <drepper@redhat.com>
4040 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait):
4042 (lll_futex_timed_wait): Define.
4043 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
4044 * sysdeps/pthread/aio_misc.h: New file.
4046 2006-01-03 Joseph S. Myers <joseph@codesourcery.com>
4048 * Makefile ($(objpfx)$(multidir)): Use mkdir -p.
4050 2006-01-03 Steven Munroe <sjmunroe@us.ibm.com>
4052 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
4053 (PSEUDO): Remove redundant cfi_startproc and cfi_endproc directives.
4054 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
4056 2006-01-04 Ulrich Drepper <drepper@redhat.com>
4058 * tst-cancel24.cc: Use C headers instead of C++ headers.
4060 2006-01-03 Jakub Jelinek <jakub@redhat.com>
4062 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Remove #error for
4063 sparc-linux configured glibc.
4064 (lll_futex_wake_unlock): Define to 1 for sparc-linux configured glibc.
4065 (__lll_mutex_trylock, __lll_mutex_cond_trylock, __lll_mutex_lock,
4066 __lll_mutex_cond_lock, __lll_mutex_timedlock): Use
4067 atomic_compare_and_exchange_val_24_acq instead of
4068 atomic_compare_and_exchange_val_acq.
4069 (lll_mutex_unlock, lll_mutex_unlock_force): Use atomic_exchange_24_rel
4070 instead of atomic_exchange_rel.
4071 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c: New file.
4072 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_init.c: New
4074 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_wait.c: New
4076 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_init.c: New file.
4077 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_post.c: New file.
4078 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c: New file.
4079 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_trywait.c: New file.
4080 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c: New file.
4081 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_init.c:
4083 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
4085 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_init.c: New file.
4086 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_post.c: New file.
4087 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_timedwait.c: New
4089 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_trywait.c: New
4091 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_wait.c: New file.
4093 2006-01-03 Ulrich Drepper <drepper@redhat.com>
4095 * sysdeps/pthread/pthread.h [__WORDSIZE==64]: Don't use cast in
4098 2006-01-02 Jakub Jelinek <jakub@redhat.com>
4100 * sysdeps/sparc/tls.h (tcbhead_t): Add pointer_guard field.
4101 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
4102 THREAD_COPY_POINTER_GUARD): Define.
4103 * sysdeps/sparc/tcb-offsets.sym (POINTER_GUARD): Define.
4104 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Revert 2005-12-27 changes.
4106 2006-01-01 Ulrich Drepper <drepper@redhat.com>
4108 * version.c: Update copyright year.
4110 2005-12-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4112 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Remove explicit
4113 .eh_frame section, use cfi_* directives.
4114 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Add cfi instrumentation.
4116 2005-12-30 Ulrich Drepper <drepper@redhat.com>
4118 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Undo last change for
4121 2005-12-29 Ulrich Drepper <drepper@redhat.com>
4123 * sysdeps/pthread/sigaction.c: Removed.
4124 * sigaction.c: New file.
4125 * sysdeps/unix/sysv/linux/Makefile: Define CFLAGS-sigaction.c.
4127 2005-12-28 Ulrich Drepper <drepper@redhat.com>
4129 * Makefile (tests): Add tst-signal7.
4130 * tst-signal7.c: New file.
4132 2005-12-27 Roland McGrath <roland@redhat.com>
4134 * sysdeps/x86_64/jmpbuf-unwind.h (_jmpbuf_sp): New inline function.
4135 (_JMPBUF_UNWINDS_ADJ): Use it, to PTR_DEMANGLE before comparison.
4136 * sysdeps/alpha/jmpbuf-unwind.h: Likewise.
4137 * sysdeps/i386/jmpbuf-unwind.h: Likewise.
4138 * sysdeps/mips/jmpbuf-unwind.h: Likewise.
4139 * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
4140 * sysdeps/s390/jmpbuf-unwind.h: Likewise.
4141 * sysdeps/sh/jmpbuf-unwind.h: Likewise.
4142 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
4143 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Likewise.
4144 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
4146 2005-12-27 Jakub Jelinek <jakub@redhat.com>
4148 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Add __next
4149 and __prev field to pthread_mutex_t.
4150 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
4151 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
4152 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
4153 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
4154 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Add __next field
4157 2005-12-26 Ulrich Drepper <drepper@redhat.com>
4159 * pthreadP.h: Define PTHREAD_MUTEX_ROBUST_PRIVATE_NP,
4160 PTHREAD_MUTEX_ROBUST_PRIVATE_RECURSIVE_NP,
4161 PTHREAD_MUTEX_ROBUST_PRIVATE_ERRORCHECK_NP,
4162 PTHREAD_MUTEX_ROBUST_PRIVATE_ADAPTIVE_NP,
4163 PTHREAD_MUTEXATTR_FLAG_ROBUST, PTHREAD_MUTEXATTR_FLAG_PSHARED,
4164 and PTHREAD_MUTEXATTR_FLAG_BITS.
4165 * descr.h (struct pthread): Add robust_list field and define
4166 ENQUEUE_MUTEX and DEQUEUE_MUTEX macros.
4167 * pthread_mutexattr_getrobust.c: New file.
4168 * pthread_mutexattr_setrobust.c: New file.
4169 * pthread_mutex_consistent.c: New file.
4170 * sysdeps/pthread/pthread.h: Declare pthread_mutexattr_getrobust,
4171 pthread_mutexattr_setrobust, and pthread_mutex_consistent.
4172 Define PTHREAD_MUTEX_STALLED_NP and PTHREAD_MUTEX_ROBUST_NP.
4173 Adjust pthread_mutex_t initializers.
4174 * nptl/sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Add __next
4175 field to pthread_mutex_t.
4176 * nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Add __next
4177 and __prev field to pthread_mutex_t.
4178 * Versions [GLIBC_2.4]: Export pthread_mutexattr_getrobust_np,
4179 pthread_mutexattr_setrobust_np, and pthread_mutex_consistent_np.
4180 * pthread_mutexattr_getpshared.c: Use PTHREAD_MUTEXATTR_FLAG_PSHARED
4181 and PTHREAD_MUTEXATTR_FLAG_BITS macros instead of magic numbers.
4182 * pthread_mutexattr_gettype.c: Likewise.
4183 * pthread_mutexattr_setpshared.c: Likewise.
4184 * pthread_mutexattr_settype.c: Likewise.
4185 * pthread_mutex_init.c: Reject robust+pshared attribute for now.
4186 Initialize mutex kind according to robust flag.
4187 * pthread_mutex_lock.c: Implement local robust mutex.
4188 * pthread_mutex_timedlock.c: Likewise.
4189 * pthread_mutex_trylock.c: Likewise.
4190 * pthread_mutex_unlock.c: Likewise.
4191 * pthread_create.c (start_thread): Mark robust mutexes which remained
4193 * tst-robust1.c: New file.
4194 * tst-robust2.c: New file.
4195 * tst-robust3.c: New file.
4196 * tst-robust4.c: New file.
4197 * tst-robust5.c: New file.
4198 * tst-robust6.c: New file.
4199 * tst-robust7.c: New file.
4200 * Makefile (libpthread-routines): Add pthread_mutexattr_getrobust,
4201 pthread_mutexattr_setrobust, and pthread_mutex_consistent.
4202 (tests): Add tst-robust1, tst-robust2, tst-robust3, tst-robust4,
4203 tst-robust5, tst-robust6, and tst-robust7.
4205 * tst-typesizes.c: New file.
4206 * Makefile (tests): Add tst-typesizes.
4208 * tst-once3.c: More debug output.
4210 2005-12-24 Ulrich Drepper <drepper@redhat.com>
4212 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Add break
4213 missing after last change.
4215 * version.c: Update copyright year.
4217 2005-12-23 Ulrich Drepper <drepper@redhat.com>
4219 * pthread_mutex_destroy.c: Set mutex type to an invalid value.
4220 * pthread_mutex_lock.c: Return EINVAL for invalid mutex type.
4221 * pthread_mutex_trylock.c: Likewise.
4222 * pthread_mutex_timedlock.c: Likewise.
4223 * pthread_mutex_unlock.c: Likewise.
4225 2005-12-22 Roland McGrath <roland@redhat.com>
4227 * sysdeps/pthread/sigaction.c: Use "" instead of <> to include self,
4228 so that #include_next's search location is not reset to the -I..
4229 directory where <nptl/...> can be found.
4231 2005-12-22 Ulrich Drepper <drepper@redhat.com>
4234 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
4235 Fix unwind info. Remove useless branch prediction prefix.
4236 * tst-cancel24.cc: New file.
4237 * Makefile: Add rules to build and run tst-cancel24.
4239 2005-12-21 Roland McGrath <roland@redhat.com>
4241 * libc-cancellation.c: Use <> rather than "" #includes.
4242 * pt-cleanup.c: Likewise.
4243 * pthread_create.c: Likewise.
4244 * pthread_join.c: Likewise.
4245 * pthread_timedjoin.c: Likewise.
4246 * pthread_tryjoin.c: Likewise.
4247 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Likewise.
4248 * sysdeps/unix/sysv/linux/register-atfork.c: Likewise.
4249 * sysdeps/unix/sysv/linux/unregister-atfork.c: Likewise.
4250 * unwind.c: Likewise.
4252 2005-12-19 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4254 * sysdeps/sh/tcb-offsets.sym: Add POINTER_GUARD.
4255 * sysdeps/sh/tls.h (tcbhead_t): Remove private and add pointer_guard.
4256 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
4257 THREAD_COPY_POINTER_GUARD): Define.
4259 2005-12-19 Jakub Jelinek <jakub@redhat.com>
4261 * sysdeps/ia64/tls.h (TLS_PRE_TCB_SIZE): Make room for 2 uintptr_t's
4263 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
4264 THREAD_COPY_POINTER_GUARD): Define.
4265 * sysdeps/powerpc/tcb-offsets.sym (POINTER_GUARD): Add.
4266 * sysdeps/powerpc/tls.h (tcbhead_t): Add pointer_guard field.
4267 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
4268 THREAD_COPY_POINTER_GUARD): Define.
4269 * sysdeps/s390/tcb-offsets.sym (STACK_GUARD): Add.
4270 * sysdeps/s390/tls.h (THREAD_GET_POINTER_GUARD,
4271 THREAD_SET_POINTER_GUARD, THREAD_COPY_POINTER_GUARD): Define.
4272 * sysdeps/unix/sysv/linux/ia64/__ia64_longjmp.S (__ia64_longjmp):
4273 Use PTR_DEMANGLE for B0 if defined.
4275 2005-12-17 Ulrich Drepper <drepper@redhat.com>
4277 * pthread_create.c (__pthread_create_2_1): Use
4278 THREAD_COPY_POINTER_GUARD if available.
4279 * sysdeps/i386/tcb-offsets.sym: Add POINTER_GUARD.
4280 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
4281 * sysdeps/i386/tls.h (tcbhead_t): Add pointer_guard.
4282 Define THREAD_SET_POINTER_GUARD and THREAD_COPY_POINTER_GUARD.
4283 * sysdeps/x86_64/tls.h: Likewise.
4285 2005-12-15 Roland McGrath <roland@redhat.com>
4287 * sysdeps/unix/sysv/linux/mq_notify.c: Don't use sysdeps/generic.
4289 2005-12-13 Ulrich Drepper <drepper@redhat.com>
4291 * sysdeps/pthread/sigfillset.c: Adjust for files moved out of
4293 * errno-loc.c: New file.
4295 2005-12-12 Roland McGrath <roland@redhat.com>
4297 * init.c (__pthread_initialize_minimal_internal): Do __static_tls_size
4298 adjustments before choosing stack size. Update minimum stack size
4299 calculation to match allocate_stack change.
4301 2005-12-12 Ulrich Drepper <drepper@redhat.com>
4303 * allocatestack.c (allocate_stack): Don't demand that there is an
4304 additional full page available on the stack beside guard, TLS, the
4307 2005-11-24 Ulrich Drepper <drepper@redhat.com>
4309 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h
4310 (__cleanup_fct_attribute): Use __regparm__ not regparm.
4312 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: When
4313 compiling 32-bit code we must define __cleanup_fct_attribute.
4315 005-11-24 Jakub Jelinek <jakub@redhat.com>
4318 * sysdeps/pthread/pthread.h (__pthread_unwind_next): Use
4319 __attribute__ instead of __attribute.
4320 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h
4321 (__cleanup_fct_attribute): Likewise.
4323 2005-11-17 Jakub Jelinek <jakub@redhat.com>
4325 * sysdeps/pthread/unwind-forcedunwind.c (pthread_cancel_init): Put
4326 a write barrier before writing libgcc_s_getcfa.
4328 2005-11-06 Ulrich Drepper <drepper@redhat.com>
4330 * sysdeps/unix/sysv/linux/configure: Removed.
4332 2005-11-05 Ulrich Drepper <drepper@redhat.com>
4334 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Remove trace of
4335 optional init_array/fini_array support.
4337 2005-10-24 Roland McGrath <roland@redhat.com>
4339 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Remove unnecessary
4340 versioned_symbol use.
4342 2005-10-16 Roland McGrath <roland@redhat.com>
4344 * init.c (__pthread_initialize_minimal_internal): Even when using a
4345 compile-time default stack size, apply the minimum that allocate_stack
4346 will require, and round up to page size.
4348 2005-10-10 Daniel Jacobowitz <dan@codesourcery.com>
4350 * Makefile ($(test-modules)): Remove static pattern rule.
4352 2005-10-14 Jakub Jelinek <jakub@redhat.com>
4353 Ulrich Drepper <drepper@redhat.com>
4355 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Fix stack
4356 alignment in callback function.
4357 * Makefile: Add rules to build and run tst-align3.
4358 * tst-align3.c: New file.
4360 2005-10-03 Jakub Jelinek <jakub@redhat.com>
4362 * allocatestack.c (setxid_signal_thread): Add
4363 INTERNAL_SYSCALL_DECL (err).
4365 2005-10-02 Jakub Jelinek <jakub@redhat.com>
4367 * allocatestack.c (setxid_signal_thread): Need to use
4368 atomic_compare_and_exchange_bool_acq.
4370 2005-10-01 Ulrich Drepper <drepper@redhat.com>
4371 Jakub Jelinek <jakub@redhat.com>
4373 * descr.h: Define SETXID_BIT and SETXID_BITMASK. Adjust
4375 (struct pthread): Move specific_used field to avoid padding.
4376 Add setxid_futex field.
4377 * init.c (sighandler_setxid): Reset setxid flag and release the
4379 * allocatestack.c (setxid_signal_thread): New function. Broken
4380 out of the bodies of the two loops in __nptl_setxid. For undetached
4381 threads check whether they are exiting and if yes, don't send a signal.
4382 (__nptl_setxid): Simplify loops by using setxid_signal_thread.
4383 * pthread_create.c (start_thread): For undetached threads, check
4384 whether setxid bit is set. If yes, wait until signal has been
4387 * allocatestack.c (STACK_VARIABLES): Initialize them.
4388 * pthread_create.c (__pthread_create_2_1): Initialize pd.
4390 2004-09-02 Jakub Jelinek <jakub@redhat.com>
4392 * pthread_cond_destroy.c (__pthread_cond_destroy): If there are
4393 waiters, awake all waiters on the associated mutex.
4395 2005-09-22 Roland McGrath <roland@redhat.com>
4397 * perf.c [__x86_64__] (HP_TIMING_NOW): New macro (copied from
4398 ../sysdeps/x86_64/hp-timing.h).
4400 2005-08-29 Jakub Jelinek <jakub@redhat.com>
4402 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_WAKE_OP,
4403 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
4404 (lll_futex_wake_unlock): Define.
4405 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_WAKE_OP,
4406 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
4407 (lll_futex_wake_unlock): Define.
4408 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_WAKE_OP,
4409 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
4410 (lll_futex_wake_unlock): Define.
4411 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_WAKE_OP,
4412 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
4413 (lll_futex_wake_unlock): Define.
4414 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_WAKE_OP,
4415 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
4416 (lll_futex_wake_unlock): Define.
4417 * sysdeps/pthread/pthread_cond_signal.c (__pthread_cond_signal): Use
4418 lll_futex_wake_unlock.
4419 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
4420 (FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
4421 (__pthread_cond_signal): Use FUTEX_WAKE_OP.
4422 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
4423 (FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
4424 (__pthread_cond_signal): Use FUTEX_WAKE_OP.
4426 2005-09-05 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4428 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_mutex_lock_wait):
4429 Fix typo in register name.
4431 2005-08-23 Ulrich Drepper <drepper@redhat.com>
4433 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
4434 Use __sigfillset. Document that sigfillset does the right thing wrt
4437 2005-07-11 Jakub Jelinek <jakub@redhat.com>
4440 * sysdeps/pthread/pthread.h (PTHREAD_MUTEX_INITIALIZER,
4441 PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP,
4442 PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP,
4443 PTHREAD_MUTEX_ADAPTIVE_NP, PTHREAD_RWLOCK_INITIALIZER,
4444 PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP,
4445 PTHREAD_COND_INITIALIZER): Supply zeros for all fields
4447 * Makefile (tests): Add tst-initializers1.
4448 (CFLAGS-tst-initializers1.c): Set.
4449 * tst-initializers1.c: New test.
4451 2005-07-11 Jakub Jelinek <jakub@redhat.com>
4453 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_rwlock_t):
4454 Make sure __flags are located at offset 48 from the start of the
4457 2005-07-02 Roland McGrath <roland@redhat.com>
4459 * Makeconfig: Comment fix.
4461 2005-07-05 Jakub Jelinek <jakub@redhat.com>
4463 * descr.h (PTHREAD_STRUCT_END_PADDING): Define.
4464 * sysdeps/ia64/tls.h (TLS_PRE_TCB_SIZE): If PTHREAD_STRUCT_END_PADDING
4465 is smaller than 8 bytes, increase TLS_PRE_TCB_SIZE by 16 bytes.
4466 (THREAD_SYSINFO, THREAD_SELF, DB_THREAD_SELF): Don't assume
4467 TLS_PRE_TCB_SIZE is sizeof (struct pthread).
4468 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
4469 * sysdeps/ia64/tcb-offsets.sym (PID, TID, MULTIPLE_THREADS_OFFSET):
4470 Use TLS_PRE_TCB_SIZE instead of sizeof (struct pthread).
4471 * sysdeps/unix/sysv/linux/ia64/createthread.c (TLS_VALUE): Don't
4472 assume TLS_PRE_TCB_SIZE is sizeof (struct pthread).
4474 2005-06-25 Jakub Jelinek <jakub@redhat.com>
4476 * sysdeps/i386/tls.h (tcbhead_t): Add stack_guard field.
4477 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
4478 * sysdeps/x86_64/tls.h (tcbhead_t): Add sysinfo and stack_guard
4480 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
4481 * sysdeps/s390/tls.h (tcbhead_t): Add stack_guard
4482 field. Put in sysinfo field unconditionally.
4483 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
4484 * sysdeps/powerpc/tls.h (tcbhead_t): Add stack_guard field.
4485 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
4486 * sysdeps/sparc/tls.h (tcbhead_t): Add sysinfo and stack_guard
4488 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
4489 * pthread_create.c (__pthread_create_2_1): Use
4490 THREAD_COPY_STACK_GUARD macro.
4491 * Makefile: Add rules to build and run tst-stackguard1{,-static}
4493 * tst-stackguard1.c: New file.
4494 * tst-stackguard1-static.c: New file.
4496 2005-06-14 Alan Modra <amodra@bigpond.net.au>
4498 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (PSEUDO):
4499 Invoke CGOTSETUP and CGOTRESTORE.
4500 (CGOTSETUP, CGOTRESTORE): Define.
4502 2005-05-29 Richard Henderson <rth@redhat.com>
4504 * tst-cancel4.c (WRITE_BUFFER_SIZE): New.
4505 (tf_write, tf_writev): Use it.
4506 (do_test): Use socketpair instead of pipe. Set SO_SNDBUF to
4509 2005-05-23 Jakub Jelinek <jakub@redhat.com>
4511 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
4512 [IS_IN_librt] (CENABLE, CDISABLE): Use JUMPTARGET instead of
4513 __librt_*_asynccancel@local.
4515 2005-05-17 Alan Modra <amodra@bigpond.net.au>
4517 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Delete
4518 all occurrences of JUMPTARGET. Instead append @local to labels.
4520 2005-05-20 Jakub Jelinek <jakub@redhat.com>
4522 * sysdeps/i386/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN): Define to
4523 size/alignment of struct pthread rather than tcbhead_t.
4524 * sysdeps/x86_64/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
4526 * sysdeps/s390/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
4528 * sysdeps/sparc/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
4531 2005-05-19 Richard Henderson <rth@redhat.com>
4533 * sysdeps/ia64/pthread_spin_lock.c (pthread_spin_lock): Use
4534 __sync_val_compare_and_swap, not explicit _si variant.
4535 * sysdeps/ia64/pthread_spin_trylock.c (pthread_spin_trylock): Likewise.
4537 2005-05-03 Ulrich Drepper <drepper@redhat.com>
4540 * sysdeps/pthread/pthread.h: Avoid empty initializers.
4542 2005-05-03 Jakub Jelinek <jakub@redhat.com>
4544 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Remove explicit
4545 .eh_frame section, use cfi_* directives.
4547 2005-04-27 Jakub Jelinek <jakub@redhat.com>
4549 * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c: Use <> instead
4552 2005-04-27 Ulrich Drepper <drepper@redhat.com>
4555 * tst-cancel17.c (do_test): Add arbitrary factor to make sure
4558 2005-04-27 Roland McGrath <roland@redhat.com>
4560 * Makefile (tests): Remove tst-clock2.
4562 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Handle
4563 CLOCK_PROCESS_CPUTIME_ID and CLOCK_PROCESS_THREAD_ID specially,
4564 translating to the kernel clockid_t for our own process/thread clock.
4566 * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c: New file.
4568 2005-04-15 Jakub Jelinek <jakub@redhat.com>
4570 * old_pthread_cond_init.c: Include <errno.h>.
4571 (__pthread_cond_init_2_0): Fail with EINVAL if COND_ATTR is
4572 process shared or uses clock other than CLOCK_REALTIME.
4573 * pthread_cond_init.c (__pthread_cond_init): Remove bogus comment.
4575 2005-04-13 David S. Miller <davem@davemloft.net>
4577 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: New file.
4578 * sysdeps/sparc/sparc64/clone.S: New file.
4580 2005-04-05 Jakub Jelinek <jakub@redhat.com>
4583 * sysdeps/pthread/pthread.h (__pthread_cleanup_routine): Use
4584 __inline instead of inline.
4585 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_routine): Likewise.
4587 2005-03-31 Jakub Jelinek <jakub@redhat.com>
4589 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Use
4590 functionally equivalent, but shorter instructions.
4591 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
4592 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
4593 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
4595 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise.
4596 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
4597 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
4598 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
4599 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
4600 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
4601 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
4603 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
4604 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
4605 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
4606 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
4607 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
4609 2005-03-28 Daniel Jacobowitz <dan@codesourcery.com>
4611 * sysdeps/mips/Makefile: New file.
4612 * sysdeps/mips/nptl-sysdep.S: New file.
4613 * sysdeps/mips/tcb-offsets.sym: New file.
4614 * sysdeps/mips/pthread_spin_lock.S: New file.
4615 * sysdeps/mips/pthread_spin_trylock.S: New file.
4616 * sysdeps/mips/pthreaddef.h: New file.
4617 * sysdeps/mips/tls.h: New file.
4618 * sysdeps/mips/jmpbuf-unwind.h: New file.
4619 * sysdeps/unix/sysv/linux/mips/lowlevellock.h: New file.
4620 * sysdeps/unix/sysv/linux/mips/bits/pthreadtypes.h: New file.
4621 * sysdeps/unix/sysv/linux/mips/bits/semaphore.h: New file.
4622 * sysdeps/unix/sysv/linux/mips/pthread_once.c: New file.
4623 * sysdeps/unix/sysv/linux/mips/fork.c: New file.
4624 * sysdeps/unix/sysv/linux/mips/pt-vfork.S: New file.
4625 * sysdeps/unix/sysv/linux/mips/vfork.S: New file.
4626 * sysdeps/unix/sysv/linux/mips/clone.S: New file.
4627 * sysdeps/unix/sysv/linux/mips/createthread.c: New file.
4628 * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h: New file.
4630 2005-03-23 Ulrich Drepper <drepper@redhat.com>
4633 * pthread_create.c (__pthread_create_2_1): Rename syscall error
4636 2005-03-10 Jakub Jelinek <jakub@redhat.com>
4638 * tst-getpid1.c (do_test): Align stack passed to clone{2,}.
4640 2005-02-25 Roland McGrath <roland@redhat.com>
4642 * alloca_cutoff.c: Correct license text.
4643 * tst-unload.c: Likewise.
4644 * sysdeps/pthread/allocalim.h: Likewise.
4645 * sysdeps/pthread/pt-initfini.c: Likewise.
4646 * sysdeps/pthread/bits/libc-lock.h: Likewise.
4647 * sysdeps/pthread/bits/sigthread.h: Likewise.
4648 * sysdeps/unix/sysv/linux/bits/local_lim.h: Likewise.
4649 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
4651 2005-02-16 Roland McGrath <roland@redhat.com>
4653 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
4654 Use unsigned int * for ptr_nthreads.
4656 2005-02-14 Alan Modra <amodra@bigpond.net.au>
4659 * sysdeps/powerpc/tcb-offsets.sym (thread_offsetof): Redefine to suit
4662 2005-02-07 Richard Henderson <rth@redhat.com>
4665 * sysdeps/pthread/pthread.h (__sigsetjmp): Use pointer as first
4668 2004-11-03 Marcus Brinkmann <marcus@gnu.org>
4670 * sysdeps/generic/lowlevellock.h (__generic_mutex_unlock): Fix
4671 order of arguments in invocation of atomic_add_zero.
4673 2005-01-26 Jakub Jelinek <jakub@redhat.com>
4676 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S (__new_sem_trywait):
4677 Use direct %gs segment access or, if NO_TLS_DIRECT_SEG_REFS,
4678 at least gotntpoff relocation and addition.
4679 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
4681 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__new_sem_post):
4683 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
4686 2005-01-06 Ulrich Drepper <drepper@redhat.com>
4688 * allocatestack.c (init_one_static_tls): Adjust initialization of DTV
4689 entry for static tls deallocation fix.
4690 * sysdeps/alpha/tls.h (dtv_t): Change pointer type to be struct which
4691 also contains information whether the memory pointed to is static
4693 * sysdeps/i386/tls.h: Likewise.
4694 * sysdeps/ia64/tls.h: Likewise.
4695 * sysdeps/powerpc/tls.h: Likewise.
4696 * sysdeps/s390/tls.h: Likewise.
4697 * sysdeps/sh/tls.h: Likewise.
4698 * sysdeps/sparc/tls.h: Likewise.
4699 * sysdeps/x86_64/tls.h: Likewise.
4701 2004-12-27 Ulrich Drepper <drepper@redhat.com>
4703 * init.c (__pthread_initialize_minimal_internal): Use __sigemptyset.
4705 2004-12-21 Jakub Jelinek <jakub@redhat.com>
4707 * sysdeps/i386/tls.h (CALL_THREAD_FCT): Maintain 16 byte alignment of
4709 * Makefile (tests): Add tst-align2.
4710 * tst-align2.c: New test.
4711 * sysdeps/i386/Makefile (CFLAGS-tst-align{,2}.c): Add
4712 -mpreferred-stack-boundary=4.
4714 2004-12-18 Roland McGrath <roland@redhat.com>
4716 * sysdeps/unix/sysv/linux/powerpc/powerpc64/bits/local_lim.h:
4717 New file removed withdrawn for the moment.
4719 2004-12-17 Richard Henderson <rth@redhat.com>
4721 * sysdeps/unix/sysv/linux/alpha/clone.S: New file.
4722 * sysdeps/alpha/tcb-offsets.sym (TID_OFFSET): New.
4724 2004-12-16 Ulrich Drepper <drepper@redhat.com>
4726 * sysdeps/unix/sysv/linux/powerpc/powerpc64/bits/local_lim.h: New file.
4727 Increased PTHREAD_STACK_MIN.
4729 * tst-context1.c (stacks): Use bigger stack size.
4731 2004-12-16 Jakub Jelinek <jakub@redhat.com>
4733 * sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: New file.
4734 * sysdeps/sparc/tcb-offsets.sym: Add TID.
4736 2004-12-15 Jakub Jelinek <jakub@redhat.com>
4738 * sysdeps/unix/sysv/linux/s390/s390-32/clone.S: New file.
4739 * sysdeps/unix/sysv/linux/s390/s390-64/clone.S: New file.
4740 * sysdeps/s390/tcb-offsets.sym (TID): Add.
4742 2004-12-15 Ulrich Drepper <drepper@redhat.com>
4744 * sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S: New file.
4746 2004-12-14 Ulrich Drepper <drepper@redhat.com>
4748 * sysdeps/powerpc/tcb-offsets.sym: Add TID.
4749 * sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S: New file.
4751 * tst-getpid1.c: If child crashes, report this first. Print which
4754 2004-12-09 Ulrich Drepper <drepper@redhat.com>
4756 * init.c (__pthread_initialize_minimal_internal): Also unblock
4759 2004-12-01 Jakub Jelinek <jakub@redhat.com>
4761 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_CPUTIME,
4762 _POSIX_THREAD_CPUTIME): Define to 0.
4763 * sysdeps/pthread/timer_create.c (timer_create): Remove unused code
4764 handling CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID.
4765 * sysdeps/pthread/timer_routines.c (__timer_signal_thread_pclk,
4766 __timer_signal_thread_tclk): Remove.
4767 (init_module): Remove their initialization.
4768 (thread_cleanup): Remove their cleanup assertions.
4769 * sysdeps/pthread/posix-timer.h (__timer_signal_thread_pclk,
4770 __timer_signal_thread_tclk): Remove.
4771 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Removed.
4772 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Removed.
4773 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Removed.
4775 2004-12-07 Jakub Jelinek <jakub@redhat.com>
4777 * sysdeps/ia64/tcb-offsets.sym (TID): Add.
4778 * sysdeps/unix/sysv/linux/ia64/clone2.S: New file.
4780 * Makefile (tests): Add tst-getpid2.
4781 * tst-getpid1.c (TEST_CLONE_FLAGS): Define.
4782 (do_test): Use it. Use __clone2 instead of clone on ia64.
4783 * tst-getpid2.c: New test.
4785 2004-12-07 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4787 * sysdeps/unix/sysv/linux/sh/clone.S: New file.
4789 2004-12-04 Ulrich Drepper <drepper@redhat.com>
4791 * Makefile (tests): Add tst-getpid1.
4792 * tst-getpid1.c: New file.
4793 * sysdeps/unix/sysv/linux/i386/clone.S: New file.
4794 * sysdeps/unix/sysv/linux/x86_64/clone.S: New file.
4796 2004-12-02 Roland McGrath <roland@redhat.com>
4798 * Makefile (libpthread-nonshared): Variable removed.
4799 ($(objpfx)libpthread_nonshared.a): Target removed.
4800 ($(inst_libdir)/libpthread_nonshared.a): Likewise.
4801 These are now handled by generic magic from
4802 libpthread-static-only-routines being set.
4804 2004-11-27 Ulrich Drepper <drepper@redhat.com>
4806 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_PRIORITIZED_IO,
4807 _POSIX2_CHAR_TERM, _POSIX_THREAD_PRIO_INHERIT,
4808 _POSIX_THREAD_PRIO_PROTECT): Define.
4809 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4810 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
4811 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
4813 2004-11-26 Jakub Jelinek <jakub@redhat.com>
4815 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_ADVISORY_INFO,
4816 _POSIX_SPORADIC_SERVER, _POSIX_THREAD_SPORADIC_SERVER, _POSIX_TRACE,
4817 _POSIX_TRACE_EVENT_FILTER, _POSIX_TRACE_INHERIT, _POSIX_TRACE_LOG,
4818 _POSIX_TYPED_MEMORY_OBJECTS, _POSIX_IPV6, _POSIX_RAW_SOCKETS): Define.
4819 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
4820 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
4821 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
4823 2004-11-24 Ulrich Drepper <drepper@redhat.com>
4825 * sysdeps/x86_64/Makefile [nptl]: Define CFLAGS-pthread_create.c.
4827 * Makefile (libpthread-routines): Add pthread_setschedprio.
4828 * Versions [libpthread, GLIBC_2.3.4]: Add pthread_setschedprio.
4829 * sysdeps/pthread/pthread.h: Declare pthread_setschedprio.
4830 * pthread_setschedprio.c: New file.
4832 2004-11-20 Jakub Jelinek <jakub@redhat.com>
4834 * pthread_create.c (pthread_cancel): Add PTHREAD_STATIC_FN_REQUIRE.
4835 * pthread_cancel.c (pthread_create): Likewise.
4837 * Makefile (libpthread-routines): Add vars.
4838 * sysdeps/pthread/createthread.c (__pthread_multiple_threads): Remove.
4839 * init.c (__default_stacksize, __is_smp): Remove.
4841 * pthreadP.h (__find_thread_by_id): If !SHARED, add weak_function
4842 and define a wrapper macro.
4843 (PTHREAD_STATIC_FN_REQUIRE): Define.
4844 * allocatestack.c (__find_thread_by_id): Undefine.
4845 * pthread_create (__pthread_keys): Remove.
4846 (pthread_mutex_lock, pthread_mutex_unlock, pthread_once,
4847 pthread_key_create, pthread_setspecific, pthread_getspecific): Add
4848 PTHREAD_STATIC_FN_REQUIRE.
4850 2004-11-18 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4852 * sysdeps/sh/tls.h (DB_THREAD_SELF): Set the correct bias
4853 parameter to REGISTER macro.
4855 2004-11-17 Roland McGrath <roland@redhat.com>
4857 * sysdeps/unix/sysv/linux/timer_routines.c (__start_helper_thread):
4858 Make sure SIGCANCEL is blocked as well.
4860 2004-11-10 Jakub Jelinek <jakub@redhat.com>
4862 * sysdeps/pthread/setxid.h: New file.
4863 * sysdeps/pthread/pthread-functions.h (HAVE_PTR__NPTL_SETXID): Remove.
4864 (struct xid_command): Add forward decl.
4865 (struct pthread_functions): Change return type of __nptl_setxid hook
4867 * pthreadP.h (__nptl_setxid): Change return type to int.
4868 * allocatestack.c (__nptl_setxid): Call INTERNAL_SYSCALL_NCS in the
4869 calling thread, return its return value and set errno on failure.
4870 * descr.h (struct xid_command): Change id type to long array.
4872 * Makefile: Add rules to build and test tst-setuid1 and
4874 * tst-setuid1.c: New test.
4875 * tst-setuid1-static.c: New test.
4877 2004-11-10 Jakub Jelinek <jakub@redhat.com>
4879 * Makefile (tests): Add tst-exit3.
4880 * tst-exit3.c: New test.
4882 2004-11-09 Ulrich Drepper <drepper@redhat.com>
4884 * Makefile (tests): Add tst-exit2.
4885 * tst-exit2.c: New file.
4887 2004-11-09 Roland McGrath <roland@redhat.com>
4890 * sysdeps/pthread/createthread.c (do_clone): Increment __nptl_nthreads
4891 here, before calling clone.
4892 * pthread_create.c (start_thread): Don't do it here.
4894 2004-11-02 Jakub Jelinek <jakub@redhat.com>
4896 * sysdeps/unix/sysv/linux/smp.h: Include <errno.h>.
4898 2004-10-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4900 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait):
4901 Set ETIMEDOUT to errno when time is up. Tweak to avoid
4904 2004-10-28 Jakub Jelinek <jakub@redhat.com>
4906 * pthread_create.c (__pthread_create_2_1): Avoid leaking stacks
4907 if sched_priority is not between minprio and maxprio.
4909 2004-10-25 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4911 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
4912 (__pthread_cond_timedwait): Use clock_gettime syscall if exists.
4914 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
4915 (__lll_mutex_timedlock_wait): Fix a bad branch condition.
4917 2004-10-24 Ulrich Drepper <drepper@redhat.com>
4919 * sysdeps/unix/sysv/linux/smp.h (is_smp_system): Use
4920 not-cancelable I/O functions.
4922 2004-10-21 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4924 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
4925 (__lll_mutex_timedlock_wait): If woken but cannot get the lock,
4926 make sure 2 is stored in the futex and we looked at the old value.
4927 Fix a few other problems to return the correct value.
4929 2004-10-14 Richard Henderson <rth@redhat.com>
4931 * sysdeps/alpha/tcb-offsets.sym (thread_offsetof): Redefine to
4934 2004-10-06 Jakub Jelinek <jakub@redhat.com>
4936 * sysdeps/unix/sysv/linux/jmp-unwind.c: Include pthreadP.h instead
4937 of pthread-functions.h and pthreaddef.h.
4938 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Likewise.
4940 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
4941 Change __data.__nwaiters from int to unsigned int.
4943 * tst-clock2.c (do_test): Don't fail if _POSIX_THREAD_CPUTIME == 0 and
4944 sysconf (_SC_THREAD_CPUTIME) returns negative value.
4946 * allocatestack.c (__find_thread_by_id): Move attribute_hidden
4949 * sysdeps/s390/jmpbuf-unwind.h: Include bits/wordsize.h.
4950 (JMPBUF_CFA_UNWINDS_ADJ): Subtract 96 resp. 160 bytes from CFA.
4952 2004-10-06 Ulrich Drepper <drepper@redhat.com>
4954 * tst-cancel4.c (tf_msgrcv): Check for failure in msgget. If the
4955 test fails, remove message queue.
4956 (tf_msgsnd): Likewise.
4958 2004-10-05 Jakub Jelinek <jakub@redhat.com>
4960 * tst-clock1.c: Change #ifdef to #if defined.
4961 * tst-clock2.c: Likewise.
4962 * tst-cond11.c: Likewise.
4964 * sysdeps/pthread/timer_create.c (timer_create): Use
4965 defined _POSIX_CPUTIME && _POSIX_CPUTIME >= 0 instead of
4966 defined CLOCK_PROCESS_CPUTIME_ID #ifs and similarly for
4969 2004-10-05 Jakub Jelinek <jakub@redhat.com>
4971 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h (_POSIX_CPUTIME,
4972 _POSIX_THREAD_CPUTIME): Define to 0.
4974 2004-10-04 Ulrich Drepper <drepper@redhat.com>
4976 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Define _POSIX_CPUTIME
4977 and _POSIX_THREAD_CPUTIME to zero.
4978 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
4979 * tst-barrier2.c: Fix testing for POSIX feature.
4980 * tst-clock1.c: Likewise.
4981 * tst-clock2.c: Likewise.
4982 * tst-cond11.c: Likewise.
4983 * tst-cond4.c: Likewise.
4984 * tst-cond6.c: Likewise.
4985 * tst-flock2.c: Likewise.
4986 * tst-mutex4.c: Likewise.
4987 * tst-mutex9.c: Likewise.
4988 * tst-rwlock12.c: Likewise.
4989 * tst-rwlock4.c: Likewise.
4990 * tst-signal1.c: Likewise.
4991 * tst-spin2.c: Likewise.
4992 * sysdeps/pthread/posix-timer.h: Likewise.
4993 * sysdeps/pthread/timer_create.c: Likewise.
4994 * sysdeps/pthread/timer_routines.c: Likewise.
4996 2004-10-01 Ulrich Drepper <drepper@redhat.com>
4998 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
4999 (__lll_mutex_timedlock_wait): Address futex correctly.
5001 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
5002 (__lll_mutex_timedlock_wait): If woken but cannot get the lock,
5003 make sure 2 is stored in the futex and we looked at the old value.
5004 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
5005 (__lll_mutex_timedlock_wait): Likewise. Fix a few other problems
5006 which might very well made the code not working at all before.
5009 2004-09-28 Ulrich Drepper <drepper@redhat.com>
5011 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): Don't
5012 allow SIGSETXID to be sent.
5013 * sysdeps/pthread/sigaction.c (__sigaction): Don't allow action
5014 for SIGSETXID to be defined.
5015 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Make sure
5016 SIGSETXID cannot be blocked.
5018 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
5019 Add __extension__ to long long types.
5020 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
5021 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5022 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
5023 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
5024 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Likewise.
5025 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
5026 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
5028 2004-09-25 Ulrich Drepper <drepper@redhat.com>
5030 * descr.h (struct pthread): Add stopped_start field.
5031 * sysdeps/pthread/createthread.c (create_thread): Set
5032 start_stopped flag in descriptor for new thread appropriately.
5033 * pthread_create.c (start_thread): Only take lock to be stopped on
5034 startup if stopped_start flag says so.
5036 2004-09-24 Ulrich Drepper <drepper@redhat.com>
5038 * pthread_create.c (__pthread_create_2_1): Remember whether thread
5039 is created detached and if yes, do not try to free the stack in case
5040 the thread creation failed.
5041 * sysdeps/pthread/createthread.c (do_clone): Free stack here if clone
5042 call fails. Don't depend on INTERNAL_SYSCALL_ERRNO return zero in
5043 case there has been no error. [BZ #405]
5045 * pthread_create.c (start_thread): Don't wait for scheduler data
5046 etc to be set at the beginning of the function. The cancellation
5047 infrastructure must have been set up. And enable async
5048 cancellation before potentially going to sleep. [BZ #401]
5050 2004-09-20 Ulrich Drepper <drepper@redhat.com>
5052 * Versions: Remove exports for pthread_set*id_np functions.
5053 * sysdeps/pthread/pthread.h: Remove pthread_set*id_np prototypes
5055 * Makefile: Don't build pthread_set*id code for now.
5057 2004-09-19 Ulrich Drepper <drepper@redhat.com>
5059 * sysdeps/unix/sysv/linux/allocrtsig.c: Allocate second signal for
5061 * allocatestack.c (__nptl_setxid): New function.
5062 * descr.h (struct xid_command): Define type.
5063 * init.c (pthread_functions): Add ptr__nptl_setxid initialization.
5064 (sighandler_setxid): New function.
5065 (__pthread_initialize_minimal): Register sighandler_setxid for
5067 * pt-allocrtsig.c: Update comment.
5068 * pthreadP.h: Define SIGSETXID. Declare __xidcmd variable.
5069 Declare __nptl_setxid.
5070 * sysdeps/pthread/pthread-functions.h: Add ptr__nptl_setxid.
5071 * sysdeps/pthread/pthread.h: Declare pthread_setgid_np,
5072 pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
5073 pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
5074 and pthread_setresuid_np.
5075 * pthread_setgid_np.c: New file.
5076 * pthread_setuid_np.c: New file.
5077 * pthread_setegid_np.c: New file.
5078 * pthread_seteuid_np.c: New file.
5079 * pthread_setregid_np.c: New file.
5080 * pthread_setreuid_np.c: New file.
5081 * pthread_setresgid_np.c: New file.
5082 * pthread_setresuid_np.c: New file.
5083 * Versions [libpthread, GLIBC_2.3.4]: Add pthread_setgid_np,
5084 pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
5085 pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
5086 and pthread_setresuid_np.
5087 * Makefile (libpthread-routines): Add pthread_setuid, pthread_seteuid,
5088 pthread_setreuid, pthread_setresuid, pthread_setgid, pthread_setegid,
5089 pthread_setregid, and pthread_setresgid.
5091 2004-09-18 Ulrich Drepper <drepper@redhat.com>
5093 * allocatestack.c (allocate_stack): Return EAGAIN instead of
5094 ENOMEM when out of memory.
5096 2004-09-10 Roland McGrath <roland@redhat.com>
5099 * allocatestack.c (allocate_stack): Remove [__ASSUME_CLONE_STOPPED]
5100 code, since we don't try to use the broken CLONE_STOPPED any more.
5101 * pthread_create.c (start_thread): Likewise.
5103 2004-09-15 Richard Henderson <rth@redhat.com>
5105 * sysdeps/unix/sysv/linux/alpha/vfork.S: Use libc_hidden_def.
5107 2004-09-01 David Mosberger <davidm@hpl.hp.com>
5109 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h
5110 (__libc_unwind_longjmp): Delete macro and declare as function.
5111 * sysdeps/unix/sysv/linux/ia64/Makefile (sysdep_routines): Mention
5112 __ia64_longjmp, sigstack_longjmp, and __sigstack_longjmp for
5114 * sysdeps/unix/sysv/linux/ia64/__ia64_longjmp.S: New file.
5115 * sysdeps/unix/sysv/linux/ia64/__sigstack_longjmp.c: New file.
5116 * sysdeps/unix/sysv/linux/ia64/unwind_longjmp.c: New file.
5118 2004-09-12 Ulrich Drepper <drepper@redhat.com>
5120 * sysdeps/pthread/pthread.h: Make rwlock prototypes available also
5122 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Define rwlock
5123 types also for __USE_XOPEN2K.
5124 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
5125 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
5126 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
5127 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5128 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
5129 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
5130 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
5133 2004-09-08 Ulrich Drepper <drepper@redhat.com>
5135 * sysdeps/pthread/pthread.h
5136 (PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP): Make safe for C++.
5137 (PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP): Likewise.
5138 (PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP): Likewise.
5139 (PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP): Likewise.
5142 2004-09-07 Ulrich Drepper <drepper@redhat.com>
5144 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Allow
5145 PSEUDO to be used with . prefix.
5147 * sysdeps/unix/sysv/linux/alpha/pthread_once.c (__pthread_once):
5148 Use atomic_increment instead of atomic_exchange_and_add.
5149 * sysdeps/unix/sysv/linux/sparc/pthread_once.c (__pthread_once):
5151 * sysdeps/unix/sysv/linux/ia64/pthread_once.c (__pthread_once):
5153 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (__pthread_once):
5156 * allocatestack.c (allocate_stack): Use atomic_increment_val
5157 instead of atomic_exchange_and_add.
5158 * sysdeps/unix/sysv/linux/sem_post.c (__new_sem_post): Likewise.
5159 * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__new_sem_post):
5161 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
5164 * sysdeps/pthread/pthread.h (pthread_once): Remove __THROW since
5165 the initialization function might throw.
5167 2005-09-05 Richard Henderson <rth@redhat.com>
5169 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
5170 Move definition inside libpthread, libc, librt check. Provide
5171 definition for rtld.
5173 2004-09-02 Ulrich Drepper <drepper@redhat.com>
5175 * sysdeps/alpha/jmpbuf-unwind.h: Define __libc_unwind_longjmp.
5176 * sysdeps/i386/jmpbuf-unwind.h: Likewise
5177 * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
5178 * sysdeps/s390/jmpbuf-unwind.h: Likewise.
5179 * sysdeps/sh/jmpbuf-unwind.h: Likewise.
5180 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
5181 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
5182 * sysdeps/x86_64/jmpbuf-unwind.h: Likewise.
5185 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
5186 Rename __data.__clock to __data.__nwaiters, make it unsigned int.
5187 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
5189 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
5190 Decrement __nwaiters. If pthread_cond_destroy has been called and
5191 this is the last waiter, signal pthread_cond_destroy caller and
5192 avoid using the pthread_cond_t structure after unlock.
5193 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
5194 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
5195 Read clock type from the least significant bits of __nwaiters instead
5197 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
5198 * sysdeps/unix/sysv/linux/internaltypes.h: Define COND_CLOCK_BITS.
5200 2004-08-31 Jakub Jelinek <jakub@redhat.com>
5203 * Makefile (tests): Add tst-cond20 and tst-cond21.
5204 * tst-cond20.c: New test.
5205 * tst-cond21.c: New test.
5206 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
5207 (pthread_cond_t): Rename __data.__clock to __data.__nwaiters, make
5209 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
5211 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
5212 (pthread_cond_t): Likewise.
5213 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_cond_t):
5215 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
5217 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_cond_t):
5219 * sysdeps/unix/sysv/linux/lowlevelcond.sym (cond_clock): Remove.
5220 (cond_nwaiters): New.
5222 * pthread_cond_destroy.c (__pthread_cond_destroy): Return EBUSY
5223 if there are waiters not signalled yet.
5224 Wait until all already signalled waiters wake up.
5225 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Decrement
5226 __nwaiters. If pthread_cond_destroy has been called and this is the
5227 last waiter, signal pthread_cond_destroy caller and avoid using
5228 the pthread_cond_t structure after unlock.
5229 (__pthread_cond_wait): Increment __nwaiters in the beginning,
5230 decrement it when leaving. If pthread_cond_destroy has been called
5231 and this is the last waiter, signal pthread_cond_destroy caller.
5232 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
5233 Likewise. Read clock type from the least significant bits of
5234 __nwaiters instead of __clock.
5235 * pthread_condattr_setclock.c (pthread_condattr_setclock): Check
5236 whether clock ID can be encoded in COND_CLOCK_BITS bits.
5237 * pthread_condattr_getclock.c (pthread_condattr_getclock): Decode
5238 clock type just from the last COND_CLOCK_BITS bits of value.
5239 * pthread_cond_init.c (__pthread_cond_init): Initialize __nwaiters
5240 instead of __clock, just from second bit of condattr's value.
5242 2004-08-30 Jakub Jelinek <jakub@redhat.com>
5244 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Include
5245 bits/wordsize.h. Make the header match i386 header when __WORDSIZE
5247 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
5249 2004-08-15 Roland McGrath <roland@frob.com>
5251 * pthread_atfork.c: Update copyright terms including special exception
5252 for these trivial files, which are statically linked into executables
5253 that use dynamic linking for the significant library code.
5255 2004-08-09 Jakub Jelinek <jakub@redhat.com>
5257 * DESIGN-rwlock.txt: Add decreasing of nr_readers_queued to
5258 pthread_rwlock_rdlock.
5259 * sysdeps/pthread/pthread_rwlock_rdlock (__pthread_rwlock_rdlock):
5260 Decrease __nr_readers_queued after reacquiring lock.
5261 * sysdeps/pthread/pthread_rwlock_timedrdlock
5262 (pthread_rwlock_timedrdlock): Likewise.
5263 Reported by Bob Cook <bobcook47@hotmail.com>.
5265 2004-08-11 Jakub Jelinek <jakub@redhat.com>
5267 * tst-rwlock14.c (tf): Read main thread handle from *ARG
5268 before pthread_barrier_wait.
5270 2004-08-07 Ulrich Drepper <drepper@redhat.com>
5272 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
5273 Remove unnecessary exception handling data.
5275 2004-07-23 Jakub Jelinek <jakub@redhat.com>
5278 * sysdeps/pthread/pthread.h (pthread_getcpuclockid): Use __clockid_t
5279 instead of clockid_t.
5281 2004-07-21 Roland McGrath <roland@redhat.com>
5283 * Makefile ($(objpfx)multidir.mk): Use $(make-target-directory).
5285 2004-07-19 Roland McGrath <roland@redhat.com>
5287 * tst-cancel4.c (tf_waitid): Use WEXITED flag bit if available.
5289 2004-07-02 Roland McGrath <roland@redhat.com>
5291 * configure: Don't exit.
5293 2004-07-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5295 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
5296 (__pthread_cond_timedwait): Check for invalid nanosecond in
5299 2004-07-07 Ulrich Drepper <drepper@redhat.com>
5301 * Makefile: Add rules to build and run tst-fini1.
5302 * tst-fini1.c: New file.
5303 * tst-fini1mod.c: New file.
5305 2004-07-05 Ulrich Drepper <drepper@redhat.com>
5307 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define NO_CANCELLATION
5308 if no cancellation support is needed.
5309 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
5310 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
5311 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
5312 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
5313 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
5314 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
5315 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
5316 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
5317 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
5319 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define __NR_futex
5320 only if not already defined.
5322 2004-07-05 Jakub Jelinek <jakub@redhat.com>
5324 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_unlock): Use
5325 constraint "m" instead of "0" for futex.
5327 * shlib-versions: Add powerpc64-.*-linux.*.
5329 2004-07-04 Jakub Jelinek <jakub@redhat.com>
5331 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
5332 (pthread_rwlock_timedrdlock): Use cmpq instead of cmpl to check
5334 * tst-rwlock14.c (do_test): Test for invalid tv_nsec equal to
5335 1 billion and 64-bit tv_nsec which is valid when truncated to 32
5338 2004-06-29 Roland McGrath <roland@redhat.com>
5340 * Banner: NPTL no longer has its own version number.
5341 * Makefile (nptl-version): Variable removed.
5342 * sysdeps/pthread/Makefile (CFLAGS-confstr.c): Set LIBPTHREAD_VERSION
5343 using $(version), the glibc version number.
5345 2004-06-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5347 * sysdeps/unix/sysv/linux/sh/pthread_once.S (__pthread_once):
5348 Fix branch offset for a PLT entry.
5349 * sysdeps/unix/sysv/linux/sh/sem_post.S (__new_sem_post):
5351 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait):
5353 * sysdeps/unix/sysv/linux/sh/sem_trywait.S (__new_sem_trywait):
5355 * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait):
5358 2004-06-28 Jakub Jelinek <jakub@redhat.com>
5360 * sysdeps/alpha/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Define
5363 2004-06-28 Jakub Jelinek <jakub@redhat.com>
5365 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
5366 (pthread_rwlock_timedwrlock): Return EINVAL if tv_nsec is negative,
5368 * sysdeps/pthread/pthread_rwlock_timedrdlock.c
5369 (pthread_rwlock_timedrdlock): Likewise.
5371 2004-06-22 Jakub Jelinek <jakub@redhat.com>
5373 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue):
5374 Set __r7 to val, not mutex.
5376 2004-06-27 Ulrich Drepper <drepper@redhat.com>
5378 * Makefile: Add rules to build tst-rwlock14.
5379 * tst-rwlock14.c: New file.
5381 2004-06-24 Boris Hu <boris.hu@intel.com>
5383 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Add timeout validation
5385 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
5387 2004-06-19 Andreas Jaeger <aj@suse.de>
5389 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Fix
5390 assembler in last patch.
5392 2004-06-17 Ulrich Drepper <drepper@redhat.com>
5394 * sysdeps/pthread/pthread_cond_timedwait.c
5395 (__pthread_cond_timedwait): Also check for negativ nanoseconds.
5396 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
5397 (__pthread_cond_timedwait): Check for invalid nanosecond in
5399 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
5400 * tst-cond19.c: New file.
5401 * Makefile: Add rules to build and run tst-cond19.
5403 2004-06-15 Steven Munroe <sjmunroe@us.ibm.com>
5405 * tst-context1.c (GUARD_PATTERN): Defined.
5406 (tst_context_t): Define struct containing ucontext_t & guard words.
5407 (ctx): Declare as an array of tst_context_t.
5408 (fct): Verify uc_link & guard words are still valid.
5409 (tf): Initialize guard words in ctx. Adjust ctx refs for new struct.
5411 2004-06-13 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5413 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
5414 Add __data.__futex field, reshuffle __data.__clock.
5415 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S
5416 (__pthread_cond_signal): Increment __futex at the same time as
5417 __wakeup_seq or __total_seq. Pass address of __futex instead of
5418 address of low 32-bits of __wakeup_seq to futex syscall.
5419 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S
5420 (__pthread_cond_wait): Likewise. Pass __futex value from before
5421 releasing internal lock to FUTEX_WAIT.
5422 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
5423 (__pthread_cond_timedwait): Likewise.
5424 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
5425 (FUTEX_CMP_REQUEUE): Define.
5426 (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
5427 Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
5428 Pass __futex value from before the unlock and __futex address instead
5429 of address of low 32-bits of __wakeup_seq to futex syscall.
5430 Fallback to FUTEX_WAKE all on any errors.
5432 2004-06-08 Jakub Jelinek <jakub@redhat.com>
5434 * pthread_mutexattr_getpshared.c (pthread_mutex_getpshared): Fix
5436 * pthread_mutexattr_gettype.c (pthread_mutexattr_gettype): Likewise.
5437 * pthread_mutexattr_init.c (__pthread_mutexattr_init): Likewise.
5438 * pthread_mutexattr_settype.c (__pthread_mutexattr_settype): Likewise.
5439 * pthread_mutexattr_setpshared.c (pthread_mutexattr_setpshared):
5440 Likewise. Reported by Bob Cook <bobcook47@hotmail.com>.
5442 2004-06-11 Martin Schwidefsky <schwidefsky@de.ibm.com>
5444 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_compare_and_swap):
5445 Add memory clobber to inline assembly.
5446 (__lll_mutex_trylock): Likewise.
5447 (__lll_mutex_cond_trylock): Likewise.
5449 2004-06-07 Martin Schwidefsky <schwidefsky@de.ibm.com>
5451 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue):
5452 Pass val argument as 6th system call argument in %r7.
5454 2004-05-21 Jakub Jelinek <jakub@redhat.com>
5456 * Makefile (tests): Add tst-cond16.
5457 * sysdeps/unix/sysv/linux/lowlevelcond.sym (cond_futex): Add.
5458 * pthread_cond_init.c (__pthread_cond_init): Clear __data.__futex.
5459 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
5460 Add __data.__futex field, reshuffle __data.__clock.
5461 * sysdeps/unix/sysv/linux/i386/pthread_cond_signal.S
5462 (__pthread_cond_signal): Increment __futex at the same time as
5463 __wakeup_seq or __total_seq. Pass address of __futex instead of
5464 address of low 32-bits of __wakeup_seq to futex syscall.
5465 * sysdeps/unix/sysv/linux/i386/pthread_cond_wait.S
5466 (__pthread_cond_wait): Likewise. Pass __futex value from before
5467 releasing internal lock to FUTEX_WAIT.
5468 * sysdeps/unix/sysv/linux/i386/pthread_cond_timedwait.S
5469 (__pthread_cond_timedwait): Likewise.
5470 * sysdeps/unix/sysv/linux/i386/pthread_cond_broadcast.S
5471 (FUTEX_CMP_REQUEUE): Define.
5472 (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
5473 Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
5474 Pass __futex value from before the unlock and __futex address instead
5475 of address of low 32-bits of __wakeup_seq to futex syscall.
5476 Fallback to FUTEX_WAKE all on any errors.
5477 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_CMP_REQUEUE):
5479 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
5480 internally. Return non-zero if error, zero if success.
5481 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_cond_t):
5482 Add __data.__futex field, reshuffle __data.__clock.
5483 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_CMP_REQUEUE):
5485 (lll_futex_requeue): Add val argument, return 1 unconditionally
5487 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
5488 Add __data.__futex field, reshuffle __data.__clock.
5489 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_CMP_REQUEUE):
5491 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
5492 internally. Return non-zero if error, zero if success.
5493 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
5494 (pthread_cond_t): Add __data.__futex field, reshuffle __data.__clock.
5495 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_CMP_REQUEUE):
5497 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
5498 internally. Return non-zero if error, zero if success.
5499 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_cond_t):
5500 Add __data.__futex field, reshuffle __data.__clock.
5501 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_CMP_REQUEUE):
5503 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
5504 internally. Return non-zero if error, zero if success.
5505 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_cond_t):
5506 Add __data.__futex field, reshuffle __data.__clock.
5507 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
5508 Add __data.__futex field, reshuffle __data.__clock.
5509 * sysdeps/pthread/pthread_cond_signal.c (__pthread_cond_signal):
5510 Increment __futex at the same time as __wakeup_seq or __total_seq.
5511 Pass address of __futex instead of address of low 32-bits of
5512 __wakeup_seq to futex syscall.
5513 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
5514 Pass __futex value from before releasing internal lock
5516 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
5517 Likewise. Avoid unnecessary shadowing of variables.
5518 * sysdeps/pthread/pthread_cond_broadcast.c (__pthread_cond_broadcast):
5519 Set __futex to 2 * __total_seq. Pass __futex value from before the
5520 unlock and __futex address instead of address of low 32-bits of
5521 __wakeup_seq to futex_requeue macro, adjust for new return value
5523 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
5524 (__pthread_cond_signal): Increment __futex at the same time as
5525 __wakeup_seq or __total_seq. Pass address of __futex instead of
5526 address of low 32-bits of __wakeup_seq to futex syscall.
5527 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
5528 (__pthread_cond_wait): Likewise. Pass __futex value from before
5529 releasing internal lock to FUTEX_WAIT.
5530 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
5531 (__pthread_cond_timedwait): Likewise.
5532 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
5533 (FUTEX_CMP_REQUEUE): Define.
5534 (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
5535 Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
5536 Pass __futex value from before the unlock and __futex address instead
5537 of address of low 32-bits of __wakeup_seq to futex syscall.
5538 Fallback to FUTEX_WAKE all on any errors.
5540 2004-06-03 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5542 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_mutex_lock):
5543 Add nop to align the end of critical section.
5544 (lll_mutex_cond_lock, lll_mutex_timedlock): Likewise.
5546 2004-06-01 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5548 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
5549 Add __broadcast_seq field.
5550 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Mark
5551 all waiters as woken with woken_seq and bump broadcast counter.
5552 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Use new
5553 __broadcast_seq. Increment __woken_seq correctly when cleanuped.
5554 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
5555 Comment typo fixes. Avoid returning -ETIMEDOUT.
5557 2004-06-01 Ulrich Drepper <drepper@redhat.com>
5559 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
5560 (__condvar_tw_cleanup): Fix access to saved broadcast_seq value.
5561 Reported by Kaz Kojima.
5563 2004-05-25 Jakub Jelinek <jakub@redhat.com>
5565 * sysdeps/unix/sysv/linux/aio_misc.h: New file.
5567 2004-05-21 Jakub Jelinek <jakub@redhat.com>
5569 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Compare
5570 __broadcast_seq with bc_seq after acquiring internal lock instead of
5573 2004-05-18 Jakub Jelinek <jakub@redhat.com>
5575 * Makefile (.NOTPARALLEL): Only serialize make check/xcheck, not
5577 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
5578 (__pthread_cond_timedwait): Avoid returning -ETIMEDOUT.
5579 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
5580 (pthread_cond_t): Add __data.__broadcast_seq field.
5581 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
5582 (FRAME_SIZE): Define.
5583 (__pthread_cond_timedwait): Use it. Store/check broadcast_seq.
5585 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S (FRAME_SIZE):
5587 (__pthread_cond_wait): Use it. Store/check broadcast_seq. Comment
5589 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
5590 (__pthread_cond_broadcast): Increment broadcast_seq. Comment typo
5593 2004-05-18 Ulrich Drepper <drepper@redhat.com>
5595 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Add broadcast_seq entry.
5596 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_cond_t):
5597 Add __broadcast_seq field.
5598 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5599 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
5600 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
5601 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
5602 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
5603 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Mark
5604 all waiters as woken with woken_seq and bump broadcast counter.
5605 * sysdeps/pthread/pthread_cond_broadcast.c: Likewise.
5606 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Use new
5607 __broadcast_seq field.
5608 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
5609 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
5610 * sysdeps/pthread/pthread_cond_timedwait.c: Likewise.
5611 * pthread_cond_init.c: Initialize __broadcast_seq field.
5612 * Makefile (tests): Add tst-cond17 and tst-cond18.
5613 Add .NOTPARALLEL goal.
5614 * tst-cond16.c: New file. From Jakub.
5615 * tst-cond17.c: New file. From Jakub.
5616 * tst-cond18.c: New file. From Jakub.
5618 2004-05-16 Ulrich Drepper <drepper@redhat.com>
5620 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Correct some
5623 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
5624 Parametrize frame size. Correct some unwind info.
5625 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
5627 2004-05-04 Jakub Jelinek <jakub@redhat.com>
5629 * tst-stack3.c: Note testing functionality beyond POSIX.
5631 2004-05-04 Jakub Jelinek <jakub@redhat.com>
5633 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (USE___THREAD):
5634 Change conditional from ifdef to if.
5636 2004-04-23 Jakub Jelinek <jakub@redhat.com>
5638 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SYSDEP_CANCEL_ERRNO,
5639 SYSDEP_CANCEL_ERROR): Define.
5642 2004-05-01 Jakub Jelinek <jakub@redhat.com>
5644 * Versions (libpthread): Remove __pthread_cleanup_upto@@GLIBC_PRIVATE.
5646 2004-04-20 Jakub Jelinek <jakub@redhat.com>
5648 * sem_unlink.c (sem_unlink): Change EPERM into EACCES.
5650 2004-04-19 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5652 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Add frame info.
5653 Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
5654 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Remove unneeded frame
5655 info. Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
5657 2004-04-19 Ulrich Drepper <drepper@redhat.com>
5659 * sysdeps/unix/sysv/linux/timer_routines.c: Make sure helper
5660 thread has all signals blocked.
5662 2004-04-18 Andreas Jaeger <aj@suse.de>
5664 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h
5665 (SEM_VALUE_MAX): Add missing brace.
5667 2004-04-17 Jakub Jelinek <jakub@redhat.com>
5669 * sysdeps/pthread/Makefile (tests): Add tst-mqueue8x
5671 (CFLAGS-tst-mqueue8x.c): Add -fexceptions.
5672 * sysdeps/pthread/tst-mqueue8x.c: New test.
5673 * tst-cancel4.c: Update comment about message queues.
5675 * sysdeps/pthread/timer_gettime.c (timer_gettime): For expired timer
5676 return it_value { 0, 0 }.
5677 * sysdeps/pthread/timer_create.c (timer_create): Handle SIGEV_NONE
5679 * sysdeps/pthread/timer_routines.c (thread_expire_timer): Remove
5680 assertion for SIGEV_NONE.
5681 (thread_attr_compare): Compare all attributes, not just a partial
5684 2004-04-17 Jakub Jelinek <jakub@redhat.com>
5686 * sysdeps/unix/sysv/linux/mq_notify.c: Include stdlib.h.
5688 2004-04-17 Ulrich Drepper <drepper@redhat.com>
5690 * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h (SEM_VALUE_MAX):
5691 Just use a plain number.
5692 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h: Likewise.
5693 * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: Likewise.
5694 * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: Likewise.
5695 * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: Likewise.
5696 * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: Likewise.
5697 * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: Likewise.
5698 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
5700 2004-04-16 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5702 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Remove unneeded
5704 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
5706 2004-04-15 Jakub Jelinek <jakub@redhat.com>
5708 * sysdeps/unix/sysv/linux/timer_routines.c: Include errno.h.
5709 (timer_helper_thread): Use inline rt_sigtimedwait syscall instead
5710 of calling sigwaitinfo.
5712 2004-04-16 Ulrich Drepper <drepper@redhat.com>
5714 * allocatestack.c (allocate_stack): Set reported_guardsize
5716 * pthread_getattr_np.c (pthread_getattr_np): Use
5717 reported_guardsize instead of guardsize.
5718 * descr.h (struct pthread): Add reported_guardsize field.
5720 2004-04-13 Jakub Jelinek <jakub@redhat.com>
5722 * sysdeps/unix/sysv/linux/mq_notify.c: Shut up GCC warning.
5724 2004-04-12 Ulrich Drepper <drepper@redhat.com>
5726 * sysdeps/unix/sysv/linux/mq-notify.c: New file.
5728 2004-04-08 Jakub Jelinek <jakub@redhat.com>
5730 * sysdeps/unix/sysv/linux/bits/local_lim.h (MQ_PRIO_MAX): Define.
5731 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h (MQ_PRIO_MAX): Define.
5732 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h (MQ_PRIO_MAX): Define.
5733 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h (MQ_PRIO_MAX): Define.
5734 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_MESSAGE_PASSING):
5736 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h
5737 (_POSIX_MESSAGE_PASSING): Define.
5738 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h
5739 (_POSIX_MESSAGE_PASSING): Define.
5740 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h
5741 (_POSIX_MESSAGE_PASSING): Define.
5743 2004-04-04 Ulrich Drepper <drepper@redhat.com>
5745 * tst-context1.c (fct): Check whether correct stack is used.
5747 2004-04-03 Ulrich Drepper <drepper@redhat.com>
5749 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Never use
5750 matching constraints for asm mem parameters.
5752 * tst-clock2.c (tf): Don't define unless needed.
5754 2004-03-30 H.J. Lu <hongjiu.lu@intel.com>
5756 * Makefile (link-libc-static): Use $(static-gnulib) instead of
5759 2004-03-30 Ulrich Drepper <drepper@redhat.com>
5761 * sysdeps/pthread/pthread-functions.h: Add ptr__nptl_deallocate_tsd.
5762 * init.c (pthread_functions): Add ptr__nptl_deallocate_tsd.
5763 * pthreadP.h: Declare __nptl_deallocate_tsd.
5764 * pthread_create.c (deallocate_tsd): Remove to __nptl_deallocate_tsd.
5767 * Makefile (tests): Add tst-tsd5.
5768 * tst-tsd5.c: New file.
5770 2004-03-29 Ulrich Drepper <drepper@redhat.com>
5772 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
5773 (__pthread_attr_setaffinity_old): Prepend GLIBC_ to version names
5774 is SHLIB_COMPAT check.
5775 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c
5776 (__pthread_attr_getaffinity_old): Likewise.
5777 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
5778 (__pthread_getaffinity_old): Likewise.
5779 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
5780 (__pthread_setaffinity_old): Likewise.
5782 2004-03-26 Ulrich Drepper <drepper@redhat.com>
5784 * allocatestack.c (_make_stacks_executable): Call
5785 _dl_make_stack_executable first.
5787 2004-03-24 Roland McGrath <roland@redhat.com>
5789 * sysdeps/i386/pthread_spin_lock.c (pthread_spin_lock): Use "m"
5790 constraint instead of "0".
5792 2004-03-24 Ulrich Drepper <drepper@redhat.com>
5794 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
5795 (lll_mutex_cond_trylock): Define as wrapper around __lll_cond_trylock.
5797 * sysdeps/unix/sysv/linux/getpid.c (really_getpid): Reorganize
5798 code to avoid warning.
5800 2004-03-24 Andreas Jaeger <aj@suse.de>
5802 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
5803 (__pthread_attr_setaffinity_old): Remove const.
5805 2004-03-23 Ulrich Drepper <drepper@redhat.com>
5807 * sysdeps/unix/sysv/linux/smp.h: New file.
5808 * sysdeps/unix/sysv/linux/sh/smp.h: New file.
5809 * init.c: Define __is_smp.
5810 (__pthread_initialize_minimal_internal): Call is_smp_system to
5811 initialize __is_smp.
5812 * pthreadP.h: Declare __is_smp.
5813 Define MAX_ADAPTIVE_COUNT is necessary.
5814 * pthread_mutex_init.c: Add comment regarding __spins field.
5815 * pthread_mutex_lock.c: Implement adaptive mutex type.
5816 * pthread_mutex_timedlock.c: Likewise.
5817 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
5818 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_mutex_t):
5820 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
5821 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
5822 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
5823 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
5824 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5825 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
5826 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
5827 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Define
5828 lll_mutex_cond_trylock.
5829 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
5830 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
5831 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5832 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
5833 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
5834 Define BUSY_WAIT_NOP.
5835 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
5836 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
5838 * tst-mutex5.c: Add support for testing adaptive mutexes.
5839 * tst-mutex7.c: Likewise.
5840 * tst-mutex5a.c: New file.
5841 * tst-mutex7a.c: New file.
5842 * Makefile (tests): Add tst-mutex5a and tst-mutex7a.
5844 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
5845 (__lll_mutex_timedlock_wait): Preserve r8 and r9 since the
5846 vgettimeofday call might destroy the content.
5848 * sysdeps/ia64/pthread_spin_lock.c (pthread_spin_lock): Use hint
5851 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_mutex_trylock):
5852 No need to restrict type of ret. Make it int. Add comment.
5854 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_mutex_trylock):
5855 Remove unnecessary setne instruction.
5857 2004-03-22 Jakub Jelinek <jakub@redhat.com>
5859 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
5860 (__pthread_getaffinity_new): Use INT_MAX instead of UINT_MAX.
5861 * pthread_getattr_np.c (pthread_getattr_np): Double size every cycle.
5862 If realloc fails, break out of the loop.
5864 2004-03-20 Andreas Jaeger <aj@suse.de>
5866 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
5867 (__pthread_setaffinity_old): Fix interface.
5868 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
5869 (__pthread_getaffinity_old): Likewise.
5871 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
5872 (__pthread_setaffinity_new): Remove duplicate declaration.
5874 2004-03-20 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5876 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (CENABLE): Save
5877 the return value to a safe register.
5878 (CDISABLE): Set the function argument correctly.
5880 2004-03-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5882 * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h (XCHG): Define.
5883 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_mutex_lock_wait):
5884 Rewrite so that only one locked memory operation per round is needed.
5885 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S
5886 (pthread_barrier_wait): After wakeup, release lock only when the
5887 last thread stopped using the barrier object.
5888 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S
5889 (__pthread_cond_wait): Don't store mutex address if the current
5890 value is ~0l. Add correct cleanup support and unwind info.
5891 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
5892 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
5893 (__pthread_cond_broadcast): Don't use requeue for pshared condvars.
5894 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Update comment.
5895 * sysdeps/unix/sysv/linux/sh/pthread_once.S (__pthread_once):
5896 Add correct cleanup support and unwind info.
5897 * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait): Likewise.
5898 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Add unwind
5899 information for syscall wrappers.
5901 2004-03-18 Ulrich Drepper <drepper@redhat.com>
5903 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_attr): Add
5904 cpusetsize field, remove next.
5905 * sysdeps/pthread/pthread.h (pthread_getaffinity_np): Add new second
5906 parameter for size of the CPU set.
5907 (pthread_setaffinity_np): Likewise.
5908 (pthread_attr_getaffinity_np): Likewise.
5909 (pthread_attr_setaffinity_np): Likewise.
5910 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c: Implement
5911 interface change, keep compatibility code.
5912 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: Likewise.
5913 * sysdeps/unix/sysv/linux/pthread_getaffinity.c: Likewise.
5914 * sysdeps/unix/sysv/linux/pthread_setaffinity.c: Likewise.
5915 * pthreadP.h: Remove hidden_proto for pthread_getaffinity_np. Declare
5916 __pthread_getaffinity_np.
5917 * Versions: Add version for changed interfaces.
5918 * tst-attr3.c: Adjust test for interface change.
5919 * pthread_getattr_np.c: Query the kernel about the affinity mask with
5920 increasing buffer sizes.
5921 * pthread_attr_destroy.c: Remove unused list handling.
5922 * pthread_attr_init.c: Likewise.
5924 2004-03-17 Roland McGrath <roland@redhat.com>
5926 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Pass missing
5927 first argument to clock_getres so we ever enable kernel timers.
5929 2004-03-15 Ulrich Weigand <uweigand@de.ibm.com>
5931 * init.c (nptl_version): Add __attribute_used__ to nptl_version.
5933 2004-03-12 Richard Henderson <rth@redhat.com>
5935 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Propagate
5936 oldvalue from CENABLE to CDISABLE.
5938 2004-03-12 Ulrich Drepper <drepper@redhat.com>
5940 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define HOST_NAME_MAX.
5941 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
5942 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
5943 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
5945 2004-03-11 Richard Henderson <rth@redhat.com>
5947 * sysdeps/alpha/tcb-offsets.sym (PID_OFFSET): New.
5948 * sysdeps/unix/sysv/linux/alpha/pt-vfork.S: Save/restore PID.
5949 * sysdeps/unix/sysv/linux/alpha/vfork.S: New file.
5951 2004-03-11 Jakub Jelinek <jakub@redhat.com>
5953 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Use jgnl
5954 instead of jnl instruction to jump to SYSCALL_ERROR_LABEL.
5955 * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S (__vfork): Likewise.
5957 2004-03-11 Jakub Jelinek <jakub@redhat.com>
5959 * forward.c (__pthread_cond_broadcast_2_0,
5960 __pthread_cond_destroy_2_0, __pthread_cond_init_2_0,
5961 __pthread_cond_signal_2_0, __pthread_cond_wait_2_0,
5962 __pthread_cond_timedwait_2_0): Use return 0 as defaction instead of 0.
5964 2004-03-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5966 * sysdeps/sh/tcb-offsets.sym: Add PID.
5967 * sysdeps/unix/sysv/linux/sh/pt-vfork.S: Properly handle PID cache.
5968 * sysdeps/unix/sysv/linux/sh/vfork.S: New file.
5970 2004-03-10 Ulrich Drepper <drepper@redhat.com>
5972 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: No need to
5973 include <sysdep-cancel.h>, vfork is no cancellation point.
5974 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: Likewise.
5975 * sysdeps/unix/sysv/linux/powerpc/powerpc64/pt-vfork.S: Likewise.
5976 * sysdeps/unix/sysv/linux/powerpc/powerpc32/pt-vfork.S: Likewise.
5978 2004-03-10 Jakub Jelinek <jakub@redhat.com>
5980 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S (__vfork): Add
5982 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Likewise.
5983 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
5985 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S (__vfork):
5987 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Likewise.
5988 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
5989 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Include tcb-offsets.h.
5990 * sysdeps/unix/sysv/linux/ia64/vfork.S (__vfork): Use DO_CALL instead
5991 of DO_CALL_VIA_BREAK. Work around a gas problem.
5993 * sysdeps/unix/sysv/linux/powerpc/pt-vfork.S: Remove.
5994 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: New file.
5995 * sysdeps/unix/sysv/linux/powerpc/powerpc32/pt-vfork.S: New file.
5996 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: New file.
5997 * sysdeps/unix/sysv/linux/powerpc/powerpc64/pt-vfork.S: New file.
5998 * sysdeps/powerpc/tcb-offsets.sym: Add PID.
6000 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S (__vfork): Don't use
6001 a local register for saving old PID. Negate PID in parent upon exit.
6003 * sysdeps/unix/sysv/linux/s390/s390-32/pt-vfork.S: Include
6005 (__vfork): Negate PID if non-zero and set to INT_MIN if zero
6006 before syscall, set to the old value in the parent afterwards.
6007 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S: New file.
6008 * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S: Include
6010 (__vfork): Negate PID if non-zero and set to INT_MIN if zero
6011 before syscall, set to the old value in the parent afterwards.
6012 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S: New file.
6013 * sysdeps/s390/tcb-offsets.sym: Add PID.
6015 * sysdeps/unix/sysv/linux/sparc/pt-vfork.S: Remove.
6016 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: New file.
6017 * sysdeps/unix/sysv/linux/sparc/sparc32/pt-vfork.S: New file.
6018 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: New file.
6019 * sysdeps/unix/sysv/linux/sparc/sparc64/pt-vfork.S: New file.
6020 * sysdeps/sparc/tcb-offsets.sym: Add PID.
6022 2004-03-10 Andreas Schwab <schwab@suse.de>
6024 * sysdeps/ia64/tcb-offsets.sym: Add PID.
6025 * sysdeps/unix/sysv/linux/ia64/vfork.S: New file.
6026 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Properly handle PID cache.
6028 2004-03-09 Jakub Jelinek <jakub@redhat.com>
6030 * tst-cancel20.c (do_one_test): Clear in_sh_body first.
6031 * tst-cancel21.c (do_one_test): Likewise.
6032 Reported by Gordon Jin <gordon.jin@intel.com>.
6034 2004-02-09 Jakub Jelinek <jakub@redhat.com>
6036 * sysdeps/unix/sysv/linux/i386/vfork.S (SAVE_PID): Negate PID
6037 if non-zero and set to INT_MIN if zero.
6038 * sysdeps/unix/sysv/linux/x86_64/vfork.S (SAVE_PID): Likewise.
6039 * sysdeps/unix/sysv/linux/i386/pt-vfork.S: Include tcb-offsets.h.
6040 (SAVE_PID, RESTORE_PID): Define.
6042 * sysdeps/unix/sysv/linux/x86_64/pt-vfork.S: Include tcb-offsets.h.
6043 Use relative path to avoid including NPTL i386/vfork.S.
6044 (SAVE_PID, RESTORE_PID): Define.
6045 * sysdeps/unix/sysv/linux/raise.c: Include limits.h.
6046 (raise): Handle THREAD_SELF->pid INT_MIN the same as 0.
6047 * Makefile (tests): Add tst-vfork1, tst-vfork2, tst-vfork1x and
6049 (tests-reverse): Add tst-vfork1x and tst-vfork2x.
6050 * tst-vfork1.c: New test.
6051 * tst-vfork2.c: New test.
6052 * tst-vfork1x.c: New test.
6053 * tst-vfork2x.c: New test.
6055 2004-03-08 Ulrich Drepper <drepper@redhat.com>
6057 * sysdeps/i386/tcb-offsets.sym: Add PID.
6058 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
6059 * sysdeps/unix/sysv/linux/i386/vfork.S: New file.
6060 * sysdeps/unix/sysv/linux/x86_64/vfork.S: New file.
6062 2004-03-08 Steven Munroe <sjmunroe@us.ibm.com>
6064 * sysdeps/unix/sysv/linux/powerpc/Versions: Remove leading tabs.
6066 2004-03-08 H.J. Lu <hongjiu.lu@intel.com>
6068 * sysdeps/s390/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
6071 2004-03-07 Ulrich Drepper <drepper@redhat.com>
6073 * sysdeps/ia64/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
6076 * tst-once4.c: Remove unnecessary macro definition.
6078 * tst-mutex7.c (do_test): Limit thread stack size.
6079 * tst-once2.c (do_test): Likewise.
6080 * tst-tls3.c (do_test): Likewise.
6081 * tst-tls1.c (do_test): Likewise.
6082 * tst-signal3.c (do_test): Likewise.
6083 * tst-kill6.c (do_test): Likewise.
6084 * tst-key4.c (do_test): Likewise.
6085 * tst-join4.c (do_test): Likewise.
6086 * tst-fork1.c (do_test): Likewise.
6087 * tst-context1.c (do_test): Likewise.
6088 * tst-cond2.c (do_test): Likewise.
6089 * tst-cond10.c (do_test): Likewise.
6090 * tst-clock2.c (do_test): Likewise.
6091 * tst-cancel10.c (do_test): Likewise.
6092 * tst-basic2.c (do_test): Likewise.
6093 * tst-barrier4.c (do_test): Likewise.
6095 2004-03-05 Ulrich Drepper <drepper@redhat.com>
6097 * sysdeps/i386/tls.h: Use GLRO instead of GL where appropriate.
6099 2004-03-01 Ulrich Drepper <drepper@redhat.com>
6101 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
6102 (__pthread_cond_timedwait): Optimize wakeup test.
6103 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
6104 (__pthread_cond_wait): Likewise.
6105 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
6106 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
6109 2004-02-29 Ulrich Drepper <drepper@redhat.com>
6111 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
6112 (__lll_mutex_lock_wait): Optimize a bit more. Just one copy of
6113 the atomic instruction needed.
6114 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
6115 (__lll_mutex_lock_wait): Likewise.
6117 2004-02-28 Ulrich Drepper <drepper@redhat.com>
6119 * Makefile (tests): Add tst-cond14 and tst-cond15.
6120 * tst-cond14.c: New file.
6121 * tst-cond15.c: New file.
6123 2004-02-27 Ulrich Drepper <drepper@redhat.com>
6125 * sysdeps/pthread/createthread.c (create_thread): Remove use of
6126 CLONE_STOPPED. We cannot use SIGCONT which means CLONE_STOPPED
6127 needs to be implemented differently to be useful.
6129 2004-02-26 Ulrich Drepper <drepper@redhat.com>
6131 * pthread_attr_setschedparam.c: Don't test priority against limits
6132 here. Set ATTR_FLAG_SCHED_SET flag.
6133 * pthread_attr_setschedpolicy.c: Set ATTR_FLAG_POLICY_SET flag.
6134 * pthread_create.c (__pthread_create_2_1): Copy scheduling attributes
6135 from parent thread to child. If attribute is used and scheduling
6136 parameters are not inherited, copy parameters from attribute or
6137 compute them. Check priority value.
6138 * pthread_getschedparam.c: If the parameters aren't known yet get
6139 them from the kernel.
6140 * pthread_setschedparam.c: Set ATTR_FLAG_SCHED_SET and
6141 ATTR_FLAG_POLICY_SET flag for thread.
6142 * sysdeps/unix/sysv/linux/internaltypes.h: Define ATTR_FLAG_SCHED_SET
6143 and ATTR_FLAG_POLICY_SET.
6145 * sysdeps/pthread/createthread.c: Use tgkill if possible.
6147 * pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr): Don't
6148 fail if stack address hasn't been set. Just return 0.
6150 2004-02-25 Ulrich Drepper <drepper@redhat.com>
6152 * Makefile (tests-nolibpthread): Add tst-unload. Don't link with
6153 libpthread for the files in this list.
6154 (CFLAGS-tst-unload): Removed.
6155 * tst-unload.c (do_test): Don't use complete path for
6158 * Makefile: Define sonames for tst-tls5mod, tst-_res1mod1, and
6161 2004-02-22 Ulrich Drepper <drepper@redhat.com>
6163 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
6164 (__lll_mutex_lock_wait): Rewrite so that only one locked memory
6165 operation per round is needed.
6166 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
6167 (__lll_mutex_lock_wait): Likewise.
6169 2004-02-20 Ulrich Drepper <drepper@redhat.com>
6171 * tst-cancel9.c (cleanup): Don't print to stderr.
6173 2004-02-20 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6175 * sysdeps/sh/jmpbuf-unwind.h (_JMPBUF_UNWINDS_ADJ): Fix variable name.
6177 2004-02-20 Jakub Jelinek <jakub@redhat.com>
6179 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
6180 (__syscall_error_handler2): Call CDISABLE.
6181 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
6182 (__syscall_error_handler2): Call CDISABLE.
6184 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
6185 Release lock before the loop, don't reacquire it.
6187 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h (DL_ARGV_NOT_RELRO): Define.
6189 2004-02-19 Andreas Schwab <schwab@suse.de>
6191 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
6194 2004-02-18 Ulrich Drepper <drepper@redhat.com>
6196 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
6197 (pthread_barrier_wait): After wakeup, release lock only when the
6198 last thread stopped using the barrier object.
6199 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S
6200 (pthread_barrier_wait): Likewise.
6201 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
6203 * Makefile (tests): Add tst-barrier4.
6204 * tst-barrier4.c: New file.
6206 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
6207 (__pthread_cond_timedwait): Perform timeout test while holding
6208 internal lock to prevent wakeup race.
6209 Patch by Dinakar Guniguntala <dgunigun@in.ibm.com>.
6210 * sysdeps/pthread/pthread_cond_timedwait.c
6211 (__pthread_cond_timedwait): Likewise.
6212 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
6213 (__pthread_cond_timedwait): Likewise.
6215 2004-02-18 Jakub Jelinek <jakub@redhat.com>
6217 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S
6218 (__pthread_rwlock_unlock): Access WRITER as 32-bit value.
6219 * Makefile (tests): Add tst-rwlock13.
6220 * tst-rwlock13.c: New test.
6222 2004-02-16 Ulrich Drepper <drepper@redhat.com>
6224 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
6225 (__condvar_tw_cleanup): Little optimization.
6226 Patch by Dinakar Guniguntala <dgunigun@in.ibm.com>.
6228 2004-02-16 Steven Munroe <sjmunroe@us.ibm.com>
6230 * sysdeps/unix/sysv/linux/powerpc/pt-longjmp.c: Replace libc with
6231 libpthread as "lib" parameter to SHLIB_COMPAT.
6232 (__novmx_siglongjmp): Fix typo in function name.
6233 (__novmx_longjmp): Fix typo in function name.
6235 2004-02-13 Ulrich Drepper <drepper@redhat.com>
6237 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Add a
6240 * sysdeps/generic/pt-longjmp.c: Moved to...
6241 * sysdeps/pthread/pt-longjmp.c: ...here. New file.
6243 2004-01-29 Steven Munroe <sjmunroe@us.ibm.com>
6245 * Makefile (libpthread-routines): Add pt-cleanup.
6246 * pt-longjmp.c: Removed.
6247 * pt-cleanup.c: Copied __pthread_cleanup_upto to here. New file.
6248 * sysdeps/generic/pt-longjmp.c: Copied longjmp to here. New file.
6249 * sysdeps/unix/sysv/linux/powerpc/Versions: New file.
6250 Version longjmp, siglongjmp for GLIBC_2.3.4.
6251 * sysdeps/unix/sysv/linux/powerpc/pt-longjmp.c: New File.
6253 2004-02-13 Ulrich Drepper <drepper@redhat.com>
6255 * sysdeps/pthread/pthread_cond_timedwait.c
6256 (__pthread_cond_timedwait): Optimize. Drop internal lock earlier.
6257 Reuse code. Add __builtin_expects.
6259 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
6260 (__pthread_cond_timedwait): Get internal lock in case timeout has
6261 passed before the futex syscall.
6262 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
6264 2004-01-20 Ulrich Drepper <drepper@redhat.com>
6266 * allocatestack.c: Pretty printing.
6268 * sysdeps/pthread/createthread.c (create_thread): Don't add
6269 CLONE_DETACHED bit if it is not necessary.
6271 2004-01-16 Ulrich Drepper <drepper@redhat.com>
6273 * pthread_getattr_np.c: Include ldsodefs.h.
6275 2004-01-16 Richard Henderson <rth@redhat.com>
6277 * allocatestack.c: Don't declare __libc_stack_end.
6278 * init.c (__pthread_initialize_minimal_internal): Likewise.
6279 * pthread_getattr_np.c (pthread_getattr_np): Likewise.
6281 2004-01-15 Richard Henderson <rth@redhat.com>
6283 * sysdeps/alpha/tls.h (tcbhead_t): Add private.
6284 (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN, TLS_TCB_SIZE,
6285 TLS_PRE_TCB_SIZE, TLS_TCB_ALIGN, INSTALL_DTV, INSTALL_NEW_DTV,
6286 GET_DTV, THREAD_DTV, THREAD_SELF, DB_THREAD_SELF): Match ia64.
6287 (TLS_TCB_OFFSET, THREAD_ID, NO_TLS_OFFSET): Remove.
6288 (THREAD_GETMEM, THREAD_GETMEM_NC): Simplify.
6289 (THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
6290 * sysdeps/unix/sysv/linux/alpha/createthread.c (TLS_VALUE): Match ia64.
6292 2004-01-14 Ulrich Drepper <drepper@redhat.com>
6294 * init.c (pthread_functions): Make array const.
6296 2004-01-13 Ulrich Drepper <drepper@redhat.com>
6298 * allocatestack.c (__make_stacks_executable): Change interface.
6299 Check parameters. Pass parameter on to libc counterpart.
6300 * pthreadP.h: Change declaration.
6302 2004-01-13 Richard Henderson <rth@redhat.com>
6304 * pthread_attr_setstack.c (__old_pthread_attr_setstack): Use
6306 * pthread_attr_setstacksize.c (__old_pthread_attr_setstacksize):
6309 * sysdeps/alpha/Makefile: New file.
6310 * sysdeps/alpha/tcb-offsets.sym: New file.
6311 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
6312 Use MULTIPLE_THREADS_OFFSET to implement !libpthread !libc version.
6314 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Rewrite based
6317 2004-01-08 Jakub Jelinek <jakub@redhat.com>
6319 * Makefile (tests): Add tst-backtrace1.
6320 * tst-backtrace1.c: New test.
6322 2003-12-11 Ulrich Weigand <uweigand@de.ibm.com>
6324 * sysdeps/alpha/tls.h (DB_THREAD_SELF): Pass bit size of thread
6325 register as second parameter to the REGISTER macro.
6326 * sysdeps/ia64/tls.h (DB_THREAD_SELF): Likewise.
6327 * sysdeps/powerpc/tls.h (DB_THREAD_SELF): Likewise.
6328 * sysdeps/sh/tls.h (DB_THREAD_SELF): Likewise.
6329 * sysdeps/sparc/tls.h (DB_THREAD_SELF): Likewise.
6330 * sysdeps/s390/tls.h (DB_THREAD_SELF): Pass __WORDSIZE as bit size
6331 of thread register as second parameter to REGISTER macro in 64 case.
6333 2004-01-03 Ulrich Drepper <drepper@redhat.com>
6335 * sysdeps/unix/sysv/linux/Makefile (CFLAGS-getpid.c): Removed.
6336 (CFLAGS-getpid.o): Defined.
6337 (CFLAGS-getpid.os): Defined.
6339 2003-12-31 Ulrich Drepper <drepper@redhat.com>
6341 * pthread_getattr_np.c (pthread_getattr_np): Make sure stack info
6342 returned for main thread does not overlap with any other VMA.
6343 Patch by Jakub Jelinek.
6345 2003-12-29 Jakub Jelinek <jakub@redhat.com>
6347 * tst-raise1.c: Include stdio.h.
6349 2003-12-23 Jakub Jelinek <jakub@redhat.com>
6351 * sysdeps/unix/sysv/linux/raise.c (raise): Protect pid = selftid
6352 setting with __ASSUME_TGKILL || defined __NR_tgkill.
6353 If pid is 0, set it to selftid.
6354 * sysdeps/unix/sysv/linux/getpid.c (really_getpid): Make inline.
6355 Don't set self->pid but self->tid. If self->pid == 0 and self->tid
6356 != 0, return self->tid without doing a syscall.
6357 * descr.h (struct pthread): Move pid field after tid.
6359 * Makefile (tests): Add tst-raise1.
6360 * tst-raise1.c: New file.
6362 2003-12-23 Roland McGrath <roland@redhat.com>
6364 * tst-oddstacklimit.c: New file.
6365 * Makefile (tests): Add it.
6366 (tst-oddstacklimit-ENV): New variable.
6368 * init.c (__pthread_initialize_minimal_internal): Round stack rlimit
6369 value up to page size for __default_stacksize.
6371 2003-12-21 Ulrich Drepper <drepper@redhat.com>
6373 * Makefile (tests): Add tst-eintr5.
6374 * tst-eintr5.c: New file.
6376 * eintr.c (eintr_source): Prevent sending signal to self.
6378 * tst-eintr2.c (tf1): Improve error message.
6380 2003-12-20 Ulrich Drepper <drepper@redhat.com>
6382 * sysdeps/unix/sysv/linux/Makefile (CFLAGS-getpid.c): Define.
6383 * sysdeps/unix/sysv/linux/getpid.c: New file.
6384 * pthread_cancel.c: Add comment explaining use of PID field.
6385 * sysdeps/unix/sysv/linux/pthread_kill.c: Likewise.
6386 * pthread_getattr_np.c: Use abs() when comparing PID and TID fields.
6387 * sysdeps/unix/sysv/linux/fork.c: Negate PID field of parent
6388 temporarily to signal the field must not be relied on and updated
6390 * sysdeps/unix/sysv/linux/pt-raise.c: Handle case where PID is
6391 temporarily negative.
6392 * sysdeps/unix/sysv/linux/raise.c: Likewise.
6394 2003-12-19 Ulrich Drepper <drepper@redhat.com>
6396 * eintr.c (setup_eintr): Add new parameter. Pass to thread function.
6397 (eintr_source): If ARG != NULL, use pthread_kill.
6398 * tst-eintr1.c: Adjust for this change.
6399 * tst-eintr2.c: Likewise.
6400 * Makefile (tests): Add tst-eintr3 and tst-eintr4.
6401 * tst-eintr3.c: New file.
6402 * tst-eintr4.c: New file.
6404 2003-12-19 Jakub Jelinek <jakub@redhat.com>
6406 * libc-cancellation.c (__libc_enable_asynccancel): Don't cancel
6407 if CANCELSTATE_BITMASK is set.
6408 * sysdeps/pthread/librt-cancellation.c (__librt_enable_asynccancel):
6411 * Makefile (tests): Add tst-cancel22 and tst-cancel23.
6412 (tests-reverse): Add tst-cancel23.
6413 * tst-cancel22.c: New test.
6414 * tst-cancel23.c: New test.
6416 2003-12-18 Ulrich Drepper <drepper@redhat.com>
6418 * tst-eintr1.c: Better error messages.
6420 * Makefile (tests): Add tst-eintr2.
6421 * tst-eintr2.c: New file.
6423 2003-12-18 Jakub Jelinek <jakub@redhat.com>
6425 * Makefile (tests): Add tst-cancel21 and tst-cancelx21.
6426 (CFLAGS-tst-cancelx21.c): Set.
6427 * tst-cancel21.c: New test.
6428 * tst-cancelx21.c: New test.
6430 * unwind.c (FRAME_LEFT): Add adj argument. Subtract it from each
6432 (unwind_stop): Use _JMPBUF_CFA_UNWINDS_ADJ macro instead of
6433 _JMPBUF_CFA_UNWINDS. Adjust FRAME_LEFT invocations.
6434 * pt-longjmp.c: Include jmpbuf-unwind.h.
6435 (__pthread_cleanup_upto): Use _JMPBUF_UNWINDS_ADJ macro instead of
6436 _JMPBUF_UNWINDS. Adjust compared pointers.
6437 * init.c (__pthread_initialize_minimal_internal): Initialize
6438 pd->stackblock_size.
6439 * sysdeps/pthread/jmpbuf-unwind.h: Removed.
6440 * sysdeps/alpha/jmpbuf-unwind.h: New file.
6441 * sysdeps/i386/jmpbuf-unwind.h: New file.
6442 * sysdeps/powerpc/jmpbuf-unwind.h: New file.
6443 * sysdeps/s390/jmpbuf-unwind.h: New file.
6444 * sysdeps/sh/jmpbuf-unwind.h: New file.
6445 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: New file.
6446 * sysdeps/x86_64/jmpbuf-unwind.h: New file.
6447 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Include stdint.h.
6448 (_JMPBUF_CFA_UNWINDS): Remove.
6449 (_JMPBUF_CFA_UNWINDS_ADJ, _JMPBUF_UNWINDS_ADJ): Define.
6451 2003-12-12 Jakub Jelinek <jakub@redhat.com>
6453 * Makefile (tests): Add tst-cancel20 and tst-cancelx20.
6454 (CFLAGS-tst-cancelx20.c): Set.
6455 * tst-cancel20.c: New test.
6456 * tst-cancelx20.c: New test.
6458 2003-12-17 Ulrich Drepper <drepper@redhat.com>
6460 * init.c (__pthread_initialize_minimal_internal): Don't treat
6461 architectures with separate register stack special here when
6462 computing default stack size.
6464 2003-12-17 Roland McGrath <roland@redhat.com>
6466 * Makefile (tst-cancelx7-ARGS): New variable.
6467 Reportd by Greg Schafer <gschafer@zip.com.au>.
6469 2003-12-17 Jakub Jelinek <jakub@redhat.com>
6471 * Makefile (tests): Add tst-stack3. Depend on $(objpfx)tst-stack3-mem.
6472 (generated): Add tst-stack3.mtrace and tst-stack3-mem.
6473 (tst-stack3-ENV): Set.
6474 ($(objpfx)tst-stack3-mem): New.
6475 * tst-stack3.c: New test.
6477 2003-12-10 David Mosberger <davidm@hpl.hp.com>
6479 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c (_init_EPILOG_BEGINS):
6480 Add unwind directives. Drop unused .regstk directive.
6481 (_fini_EPILOG_BEGINS): Add unwind directives.
6483 2003-12-11 Ulrich Drepper <drepper@redhat.com>
6485 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait):
6486 Assume parameter is a pointer.
6487 (lll_futex_wake): Likewise.
6488 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_futex_wait):
6490 (lll_futex_wake): Likewise.
6491 Reported by Boris Hu.
6492 * sysdeps/unix/sysv/linux/unregister-atfork.c
6493 (__unregister_atfork): Pass pointer to refcntr to lll_futex_wait.
6495 * sysdeps/unix/sysv/linux/sem_wait.c (__new_sem_wait): Simplify a bit.
6497 2003-12-10 Ulrich Drepper <drepper@redhat.com>
6499 * sysdeps/pthread/bits/libc-lock.h (__rtld_lock_initialize): Define.
6500 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Call
6501 __rtld_lock_initialize for ld.so lock.
6502 Patch in part by Adam Li <adam.li@intel.com>.
6504 2003-12-02 David Mosberger <davidm@hpl.hp.com>
6506 * Makefile (link-libc-static): Remove -lgcc_eh---it's already mentioned
6507 in $(gnulib). Also, remove stale comment.
6509 2003-11-12 David Mosberger <davidm@hpl.hp.com>
6511 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO): Take
6512 advantage of new syscall stub and optimize accordingly.
6514 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__NR_futex): Rename
6515 from SYS_futex, to match expectations of
6516 sysdep.h:DO_INLINE_SYSCALL.
6517 (lll_futex_clobbers): Remove.
6518 (lll_futex_timed_wait): Rewrite in terms of DO_INLINE_SYSCALL.
6519 (lll_futex_wake): Likewise.
6520 (lll_futex_requeue): Likewise.
6521 (__lll_mutex_trylock): Rewrite to a macro, so we can include this
6522 file before DO_INLINE_SYSCALL is defined (proposed by Jakub
6524 (__lll_mutex_lock): Likewise.
6525 (__lll_mutex_cond_lock): Likewise.
6526 (__lll_mutex_timed_lock): Likewise.
6527 (__lll_mutex_unlock): Likewise.
6528 (__lll_mutex_unlock_force): Likewise.
6530 * sysdeps/ia64/tls.h: Move declaration of __thread_self up so it
6531 comes before the include of <sysdep.h>.
6532 (THREAD_SELF_SYSINFO): New macro.
6533 (THREAD_SYSINFO): Likewise.
6534 (INIT_SYSINFO): New macro.
6535 (TLS_INIT_TP): Call INIT_SYSINFO.
6537 * sysdeps/ia64/tcb-offsets.sym: Add SYSINFO_OFFSET.
6539 * sysdeps/pthread/createthread.c (create_thread): Use
6540 THREAD_SELF_SYSINFO and THREAD_SYSINFO instead of open code.
6541 * allocatestack.c (allocate_stack): Use THREAD_SYSINFO and
6542 THREAD_SELF_SYSINFO instead of open code.
6543 * sysdeps/i386/tls.h (THREAD_SELF_SYSINFO): New macro.
6544 (THREAD_SYSINFO): Likewise.
6546 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: New file.
6548 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Work around gas problem.
6550 2003-12-06 Ulrich Drepper <drepper@redhat.com>
6552 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Use .init_array
6553 instead of .init. Patch by David Mosberger.
6555 2003-11-30 Thorsten Kukuk <kukuk@suse.de>
6557 * sysdeps/pthread/configure.in: Remove broken declaration in C
6558 cleanup handling check.
6560 2003-11-30 Andreas Jaeger <aj@suse.de>
6562 * Makefile (CFLAGS-pt-initfini.s): Add $(fno_unit_at_a_time).
6563 * sysdeps/unix/sysv/linux/x86_64/Makefile (CFLAGS-pt-initfini.s):
6566 2003-11-27 Jakub Jelinek <jakub@redhat.com>
6568 * sysdeps/unix/sysv/linux/internaltypes.h (ATTR_FLAG_OLDATTR): Define.
6569 * pthread_attr_destroy.c: Include shlib-compat.h.
6570 (__pthread_attr_destroy): Return immediately if ATTR_FLAG_OLDATTR
6571 is set in iattr->flags.
6572 * pthread_attr_init.c (__pthread_attr_init_2_0): Set ATTR_FLAG_OLDATTR.
6574 2003-11-21 Jakub Jelinek <jakub@redhat.com>
6576 * Makefile (distribute): Add tst-cleanup4aux.c.
6578 * tst-cond12.c (prepare): Add prototype. Move after test-skeleton.c
6581 2003-11-21 Ulrich Drepper <drepper@redhat.com>
6583 * tst-cond12.c (do_test): If USE_COND_SIGNAL is defined, use
6584 pthread_cond_signal.
6586 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Don't
6587 store mutex address if the current value is ~0l.
6588 * sysdeps/pthread/pthread_cond_timedwait.c
6589 (__pthread_cond_timedwait): Likewise.
6590 * sysdeps/pthread/pthread_cond_broadcast.c
6591 (__pthread_cond_broadcast): Don't use requeue for pshared
6594 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
6595 (__pthread_cond_wait): Don't store mutex address if the current
6597 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
6598 (__pthread_cond_timedwait): Likewise.
6599 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
6600 (__pthread_cond_broadcast): Don't use requeue for pshared
6603 * pthread_cond_init.c (__pthread_cond_init): Initialize __mutex
6604 element with ~0l for pshared condvars, with NULL otherwise.
6606 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
6607 (__pthread_cond_wait): Don't store mutex address if the current
6609 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
6610 (__pthread_cond_timedwait): Likewise.
6611 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
6612 (__pthread_cond_broadcast): Don't use requeue for pshared
6615 * Makefile: Add rules to build and run tst-cond12 and tst-cond13.
6616 * tst-cond12.c: New file.
6617 * tst-cond13.c: New file.
6619 2003-11-17 Ulrich Drepper <drepper@redhat.com>
6621 * sysdeps/pthread/configure.in: Make missing forced unwind support
6624 2003-11-11 Ulrich Drepper <drepper@redhat.com>
6626 * pthreadP.h: Don't declare __pthread_unwind as weak inside libpthread.
6628 2003-11-06 Ulrich Drepper <drepper@redhat.com>
6630 * Makefile: Add magic to clean up correctly.
6632 2003-11-05 Jakub Jelinek <jakub@redhat.com>
6634 * unwind.c (FRAME_LEFT): Define.
6635 (unwind_stop): Handle old style cleanups here.
6636 (__pthread_unwind): Handle old style cleanups only if
6637 !HAVE_FORCED_UNWIND.
6638 * Makefile (tests): Add tst-cleanup4 and tst-cleanupx4.
6639 (CFLAGS-tst-cleanupx4.c): Add -fexceptions.
6640 ($(objpfx)tst-cleanup4): Depend on $(objpfx)tst-cleanup4aux.o.
6641 ($(objpfx)tst-cleanupx4): Likewise.
6642 * tst-cleanup4.c: New test.
6643 * tst-cleanup4aux.c: New.
6644 * tst-cleanupx4.c: New test.
6646 2003-11-04 Ulrich Drepper <drepper@redhat.com>
6648 * sysdeps/pthread/bits/stdio-lock.h: Use lll_*lock instead of
6649 lll_mutex_*lock macros to skip atomic operations on some archs.
6651 2003-11-03 Ulrich Drepper <drepper@redhat.com>
6653 * sysdeps/pthread/tst-timer.c (main): Initialize
6654 sigev2.sigev_value as well.
6656 2003-10-15 Roland McGrath <roland@redhat.com>
6658 * sysdeps/pthread/configure.in: Barf if visibility attribute support
6660 * sysdeps/pthread/configure: Regenerated.
6662 2003-10-09 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6664 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Completely revamp the
6665 locking macros. No distinction between normal and mutex locking
6667 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Rewrite mutex locking.
6668 Merge bits from lowlevelmutex.S we still need.
6669 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: Remove.
6670 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Likewise.
6671 * sysdeps/unix/sysv/linux/sh/not-cancel.h: New file.
6672 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Adjust for
6673 new mutex implementation.
6674 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Likewise.
6675 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Likewise.
6676 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
6677 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Likewise.
6678 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
6679 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
6680 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
6681 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
6682 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
6683 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (PSEUDO): Also defined
6684 symbol for entry point to avoid cancellation.
6686 2003-10-07 Jakub Jelinek <jakub@redhat.com>
6688 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Backout 2003-10-02
6690 (SAVE_OLDTYPE_0): Fix a typo.
6692 2003-10-03 Ulrich Drepper <drepper@redhat.com>
6694 * sysdeps/unix/sysv/linux/i386/pthread_once.S (__pthread_once):
6695 Check __sigsetjmp return value. Reported by Daniel Jacobowitz.
6697 2003-10-02 Ulrich Drepper <drepper@redhat.com>
6699 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (DOCARGS_1): Use
6702 2003-10-02 Jakub Jelinek <jakub@redhat.com>
6704 * Makefile (tests): Add tst-cancel19.
6705 * tst-cancel19.c: New test.
6707 2003-10-02 Ulrich Drepper <drepper@redhat.com>
6709 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Fix saving and
6710 restoring of the old cancellation type.
6712 2003-09-30 Jakub Jelinek <jakub@redhat.com>
6714 * sysdeps/pthread/malloc-machine.h: Remove misleading comment.
6716 2003-09-27 Wolfram Gloger <wg@malloc.de>
6718 * sysdeps/pthread/malloc-machine.h: New file
6720 2003-09-24 Roland McGrath <roland@redhat.com>
6722 * allocatestack.c (__make_stacks_executable): Don't ignore return
6723 value from _dl_make_stack_executable.
6725 2003-09-24 Ulrich Drepper <drepper@redhat.com>
6727 * allocatestack.c (__make_stacks_executable): Also change
6728 permission of the currently unused stacks.
6730 * allocatestack.c (change_stack_perm): Split out from
6731 __make_stacks_executable.
6732 (allocate_stack): If the required permission changed between the time
6733 we started preparing the stack and queueing it, change the permission.
6734 (__make_stacks_executable): Call change_stack_perm.
6736 * Makefile: Build tst-execstack-mod locally.
6737 * tst-execstack-mod.c: New file.
6739 2003-09-23 Jakub Jelinek <jakub@redhat.com>
6741 * Makefile (tests): Only add tst-execstack if have-z-execstack is yes.
6743 2003-09-23 Roland McGrath <roland@redhat.com>
6745 * tst-execstack.c: New file.
6746 * Makefile (tests): Add it.
6747 ($(objpfx)tst-execstack, $(objpfx)tst-execstack.out): New targets.
6748 (LDFLAGS-tst-execstack): New variable.
6750 * allocatestack.c (allocate_stack): Use GL(dl_stack_flags) to decide
6751 whether to use PROT_EXEC for stack mmap.
6752 (__make_stacks_executable): New function.
6753 * pthreadP.h: Declare it.
6754 * init.c (__pthread_initialize_minimal_internal): Set
6755 GL(dl_make_stack_executable_hook) to that.
6757 2003-09-22 Ulrich Drepper <drepper@redhat.com>
6759 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Adjust for latest
6760 recommendation from AMD re avoidance of lock prefix.
6762 2003-09-22 Jakub Jelinek <jakub@redhat.com>
6764 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait): Use
6765 lll_futex_timed_wait instead of lll_futex_wait.
6766 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Removed.
6767 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c: Removed.
6768 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: Removed.
6769 * sysdeps/unix/sysv/linux/s390/libc-lowlevelmutex.c: Removed.
6770 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Removed.
6771 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Removed.
6772 * sysdeps/unix/sysv/linux/s390/sem_post.c: Removed.
6773 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Removed.
6774 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Include atomic.h.
6775 Completely revamp the locking macros. No distinction between
6776 normal and mutex locking anymore.
6777 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
6778 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_lock_wait,
6779 __lll_lock_timedwait): Fix prototypes.
6780 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (__lll_lock_wait,
6781 __lll_lock_timedwait): Likewise.
6782 (lll_mutex_lock, lll_mutex_cond_lock): Use _val instead of _bool
6783 macros, add __builtin_expect.
6784 (lll_mutex_timedlock): Likewise. Fix return value.
6785 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Removed.
6786 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevelmutex.S: Removed.
6787 * sysdeps/unix/sysv/linux/i386/i586/lowlevelmutex.S: Removed.
6788 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevelmutex.S: Removed.
6789 * sysdeps/unix/sysv/linux/i386/i686/lowlevelmutex.S: Removed.
6790 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevelmutex.S: Removed.
6791 * sysdeps/unix/sysv/linux/lowlevelmutex.c: Removed.
6792 * sysdeps/unix/sysv/linux/libc-lowlevelmutex.c: Removed.
6794 2003-09-22 Ulrich Drepper <drepper@redhat.com>
6796 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
6797 (__lll_mutex_lock_wait): Minor optimization to avoid one atomic
6798 operation if possible.
6800 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Don't play tricks
6801 like jumping over the lock prefix.
6803 2003-09-21 Ulrich Drepper <drepper@redhat.com>
6805 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Completely revamp the
6806 locking macros. No distinction between normal and mutex locking
6808 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
6809 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
6810 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
6811 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Rewrite mutex
6812 locking. Merge bits from lowlevelmutex.S we still need.
6813 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
6814 * sysdeps/unix/sysv/linux/lowlevellock.c: Likewise.
6815 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Removed.
6816 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Removed.
6817 * Makefile (routines): Remove libc-lowlevelmutex.
6818 (libpthread-rountines): Remove lowlevelmutex.
6819 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Adjust
6820 for new mutex implementation.
6821 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
6822 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
6823 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
6824 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
6825 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
6827 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
6829 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
6830 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
6831 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise
6832 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
6833 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
6834 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
6835 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
6836 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
6838 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
6840 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Likewise.
6841 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
6842 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
6844 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
6845 * sysdeps/pthread/pthread_cond_signal.c: Don't use requeue.
6847 2003-09-20 Ulrich Drepper <drepper@redhat.com>
6849 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Don't match memory
6850 in parameters of asm with output parameters.
6852 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Change
6853 type of DECR parameter to int.
6854 * pthreadP.h: Adjust prototype of __pthread_mutex_unlock_usercnt.
6856 2003-09-18 Jakub Jelinek <jakub@redhat.com>
6858 * tst-attr3.c (tf, do_test): Print stack start/end/size and
6859 guardsize for each thread.
6861 2003-09-17 Jakub Jelinek <jakub@redhat.com>
6863 * sysdeps/pthread/pthread.h (pthread_getattr_np): Clarify usage.
6864 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
6865 (pthread_attr_setaffinity_np): Handle cpuset == NULL.
6867 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c
6868 (pthread_attr_getaffinity_np): Don't segfault if iattr->cpuset is
6870 * pthread_getattr_np.c: Set cpuset using pthread_getaffinity_np.
6871 * pthreadP.h (pthread_getaffinity_np): Add hidden_proto.
6872 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
6873 (pthread_getaffinity_np): Add hidden_def.
6875 * Makefile (tests): Add tst-attr3.
6876 * tst-attr3.c: New test.
6878 * sysdeps/i386/Makefile (CFLAGS-tst-align.c): Remove.
6880 2003-09-15 Jakub Jelinek <jakub@redhat.com>
6882 * sysdeps/i386/Makefile (CFLAGS-pthread_create.c,
6883 CFLAGS-tst-align.c): Add -mpreferred-stack-boundary=4.
6885 2003-09-17 Jakub Jelinek <jakub@redhat.com>
6887 * Makefile (CFLAGS-tst-align.c): Add $(stack-align-test-flags).
6888 * tst-align.c: Include tst-stack-align.h.
6889 (tf, do_test): Use TEST_STACK_ALIGN macro.
6891 2003-09-17 Ulrich Drepper <drepper@redhat.com>
6893 * pthread_attr_init.c (__pthread_attr_init_2_0): Remove unused
6896 2003-09-16 Ulrich Drepper <drepper@redhat.com>
6898 * pthread_getattr_np.c (pthread_getattr_np): Correctly fill in the
6899 stack-related values for the initial thread.
6901 2003-09-15 Jakub Jelinek <jakub@redhat.com>
6903 * Makefile (CFLAGS-pthread_once.c): Add $(uses-callbacks).
6905 2003-09-11 Ulrich Drepper <drepper@redhat.com>
6907 * pthread_mutex_lock.c: Minor code rearrangements.
6909 2003-09-05 Roland McGrath <roland@redhat.com>
6911 * pthread_create.c (__pthread_pthread_sizeof_descr): Removed.
6912 Instead, include ../nptl_db/db_info.c to do its magic.
6913 * pthread_key_create.c (__pthread_pthread_keys_max): Removed.
6914 (__pthread_pthread_key_2ndlevel_size): Likewise.
6915 * sysdeps/alpha/tls.h (DB_THREAD_SELF): New macro.
6916 * sysdeps/i386/tls.h (DB_THREAD_SELF): New macro.
6917 * sysdeps/ia64/tls.h (DB_THREAD_SELF): New macro.
6918 * sysdeps/powerpc/tls.h (DB_THREAD_SELF): New macro.
6919 * sysdeps/s390/tls.h (DB_THREAD_SELF): New macro.
6920 * sysdeps/sh/tls.h (DB_THREAD_SELF): New macro.
6921 * sysdeps/sparc/tls.h (DB_THREAD_SELF): New macro.
6922 * sysdeps/x86_64/tls.h (DB_THREAD_SELF): New macro.
6923 * sysdeps/alpha/td_ta_map_lwp2thr.c: File removed.
6924 * sysdeps/generic/td_ta_map_lwp2thr.c: File removed.
6925 * sysdeps/i386/td_ta_map_lwp2thr.c: File removed.
6926 * sysdeps/ia64/td_ta_map_lwp2thr.c: File removed.
6927 * sysdeps/powerpc/td_ta_map_lwp2thr.c: File removed.
6928 * sysdeps/s390/td_ta_map_lwp2thr.c: File removed.
6929 * sysdeps/sh/td_ta_map_lwp2thr.c: File removed.
6930 * sysdeps/sparc/td_ta_map_lwp2thr.c: File removed.
6931 * sysdeps/x86_64/td_ta_map_lwp2thr.c: File removed.
6933 2003-09-08 Ulrich Drepper <drepper@redhat.com>
6935 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Change type
6936 of pthread_t to be compatible with LT.
6937 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
6938 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
6939 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
6940 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
6941 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Likewise.
6942 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
6943 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
6945 2003-09-04 Ulrich Drepper <drepper@redhat.com>
6947 * sysdeps/unix/sysv/linux/i386/not-cancel.h (fcntl_not_cancel): Define.
6949 2003-09-04 Jakub Jelinek <jakub@redhat.com>
6951 * unwind-forcedunwind.c: Move to...
6952 * sysdeps/pthread/unwind-forcedunwind.c: ...here.
6953 (pthread_cancel_init): Use ARCH_CANCEL_INIT if defined.
6954 * sysdeps/pthread/jmpbuf-unwind.h: New file.
6955 * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c: New file.
6956 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: New file.
6957 * unwind.c: Include jmpbuf-unwind.h.
6958 (unwind_stop): Use _JMPBUF_CFA_UNWINDS macro.
6960 2003-09-02 Jakub Jelinek <jakub@redhat.com>
6962 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: New file.
6963 * sysdeps/unix/sysv/linux/ia64/Versions (libpthread): Export
6964 pthread_attr_setstack and pthread_attr_setstacksize @@GLIBC_2.3.3.
6965 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: New file.
6966 * sysdeps/unix/sysv/linux/alpha/Versions: New file.
6967 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: New file.
6968 * sysdeps/unix/sysv/linux/sparc/Versions: New file.
6969 * pthread_attr_setstack.c (__old_pthread_attr_setstack): New function.
6970 (pthread_attr_setstack): If PTHREAD_STACK_MIN != 16384, export
6971 as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.2.
6972 * pthread_attr_setstacksize.c (__old_pthread_attr_setstacksize): New
6974 (pthread_attr_setstacksize): If PTHREAD_STACK_MIN != 16384, export
6975 as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.1.
6976 * Makefile (tests): Add tst-stack2.
6977 * tst-stack2.c: New test.
6978 * tst-stack1.c: Include limits.h and sys/param.h.
6979 (do_test): Set size to MAX (4 * getpagesize (), PTHREAD_STACK_MIN).
6981 * pthread_condattr_setpshared.c: Include errno.h.
6982 (pthread_condattr_setpshared): Return EINVAL if pshared
6983 is neither PTHREAD_PROCESS_PRIVATE nor PTHREAD_PROCESS_SHARED.
6985 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO): Also
6986 defined symbol for entry point to avoid cancellation.
6987 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
6989 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (PSEUDO):
6991 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h (PSEUDO):
6993 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h (PSEUDO):
6995 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h (PSEUDO):
6997 * sysdeps/unix/sysv/linux/i386/not-cancel.h (__open_nocancel,
6998 __close_nocancel, __read_nocancel, __write_nocancel,
6999 __waitpid_nocancel): Add attribute_hidden. If not in libc.so,
7000 libpthread.so or librt.so, define to corresponding function
7001 without _nocancel suffix.
7002 * sysdeps/unix/sysv/linux/s390/not-cancel.h: New file.
7003 * sysdeps/unix/sysv/linux/powerpc/not-cancel.h: New file.
7004 * sysdeps/unix/sysv/linux/sparc/not-cancel.h: New file.
7006 * sysdeps/unix/sysv/linux/x86_64/not-cancel.h: Fix a typo.
7008 2003-09-02 Ulrich Drepper <drepper@redhat.com>
7010 * sysdeps/unix/sysv/linux/i386/not-cancel.h: New file.
7011 * sysdeps/unix/sysv/linux/x86_64/not-cancel.h: New file.
7013 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Make sure the code
7014 in subsections has a symbol associated with it.
7016 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (PSEUDO): Also
7017 defined symbol for entry point to avoid cancellation.
7018 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (PSEUDO): Likewise.
7020 2003-09-01 Jakub Jelinek <jakub@redhat.com>
7022 * Makefile (tests): Add tst-tls5.
7023 (module-names): Add tst-tls5mod{,a,b,c,d,e,f}.
7024 ($(objpfx)tst-tls5mod{,a,b,c,d,e,f}.so-no-z-defs): Set to yes.
7025 ($(objpfx)tst-tls5): New.
7026 ($(objpfx)tst-tls6.out): Likewise.
7027 (tests): Depend on $(objpfx)tst-tls6.out.
7028 * tst-tls3.c: Include stdint.h and pthreaddef.h.
7029 (do_test): Check pthread_self () return value alignment.
7030 * tst-tls3mod.c: Include stdint.h and pthreaddef.h.
7031 (tf): Check pthread_self () return value alignment.
7032 * tst-tls5.c: New test.
7034 * tst-tls5mod.c: New.
7035 * tst-tls5moda.c: New.
7036 * tst-tls5modb.c: New.
7037 * tst-tls5modc.c: New.
7038 * tst-tls5modd.c: New.
7039 * tst-tls5mode.c: New.
7040 * tst-tls5modf.c: New.
7041 * tst-tls6.sh: New test.
7043 * sysdeps/pthread/pthread-functions.h (struct pthread_functions): Add
7044 ptr___pthread_cond_timedwait and ptr___pthread_cond_timedwait_2_0.
7045 * init.c (pthread_functions): Initialize them.
7046 * forward.c (pthread_cond_timedwait@GLIBC_2.0,
7047 pthread_cond_timedwait@@GLIBC_2.3.2): New forwards.
7048 * Versions (libc): Export pthread_cond_timedwait@GLIBC_2.0,
7049 pthread_cond_timedwait@@GLIBC_2.3.2.
7051 2003-09-01 Jakub Jelinek <jakub@redhat.com>
7053 * sysdeps/unix/sysv/linux/alpha/timer_create.c: New file.
7054 * sysdeps/unix/sysv/linux/alpha/timer_delete.c: New file.
7055 * sysdeps/unix/sysv/linux/alpha/timer_getoverr.c: New file.
7056 * sysdeps/unix/sysv/linux/alpha/timer_gettime.c: New file.
7057 * sysdeps/unix/sysv/linux/alpha/timer_settime.c: New file.
7058 * sysdeps/unix/sysv/linux/alpha/Versions: New file.
7060 * sysdeps/unix/sysv/linux/alpha/aio_cancel.c: New file.
7062 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Define
7063 _POSIX_THREAD_PRIORITY_SCHEDULING.
7064 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
7066 2003-08-31 Ulrich Drepper <drepper@redhat.com>
7068 * sysdeps/pthread/bits/stdio-lock.h (_IO_acquire_lock): Avoid
7069 nested function, use static inline function from libio.h.
7070 Code by Richard Henderson.
7072 * sysdeps/pthread/bits/libc-lock.h: Mark pthread_setcancelstate as
7075 2003-08-30 Jakub Jelinek <jakub@redhat.com>
7077 * sysdeps/unix/sysv/linux/sparc/sparc64/Versions: New file.
7078 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_create.c: New file.
7079 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_delete.c: New file.
7080 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_getoverr.c: New file.
7081 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_gettime.c: New file.
7082 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_settime.c: New file.
7083 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: New file.
7084 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: New file.
7085 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: New file.
7086 * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: New file.
7087 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: New file.
7088 * sysdeps/unix/sysv/linux/sparc/pthread_once.c: New file.
7089 * sysdeps/unix/sysv/linux/sparc/pt-vfork.S: New file.
7090 * sysdeps/unix/sysv/linux/sparc/fork.c: New file.
7091 * sysdeps/unix/sysv/linux/sparc/aio_cancel.c: New file.
7092 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_lock.c: New file.
7093 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_trylock.c: New file.
7094 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_unlock.c: New file.
7095 * sysdeps/sparc/sparc32/pthread_spin_lock.c: New file.
7096 * sysdeps/sparc/sparc32/pthread_spin_trylock.c: New file.
7097 * sysdeps/sparc/sparc32/pthreaddef.h: New file.
7098 * sysdeps/sparc/sparc64/pthread_spin_lock.c: New file.
7099 * sysdeps/sparc/sparc64/pthread_spin_trylock.c: New file.
7100 * sysdeps/sparc/sparc64/pthread_spin_unlock.c: New file.
7101 * sysdeps/sparc/sparc64/pthreaddef.h: New file.
7102 * sysdeps/sparc/tls.h: New file.
7103 * sysdeps/sparc/tcb-offsets.sym: New file.
7104 * sysdeps/sparc/Makefile: New file.
7105 * sysdeps/sparc/td_ta_map_lwp2thr.c: New file.
7106 * init.c [__sparc__] (__NR_set_tid_address): Define.
7108 2003-08-29 Jakub Jelinek <jakub@redhat.com>
7110 * sysdeps/pthread/bits/stdio-lock.h (_IO_acquire_lock,
7111 _IO_release_lock): Define.
7113 2003-08-29 Jakub Jelinek <jakuB@redhat.com>
7115 * tst-cancel4.c (tf_sigwait, tf_sigwaitinfo, tf_sigtimedwait): Add
7116 sigemptyset before sigaddset. Reported by jreiser@BitWagon.com.
7118 2003-08-27 Ulrich Drepper <drepper@redhat.com>
7120 * sysdeps/pthread/pthread.h (pthread_exit): Remove __THROW.
7121 (__pthread_cleanup_class): Add missing return types of member
7124 2003-08-26 Steven Munroe <sjmunroe@us.ibm.com>
7126 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
7127 (lll_mutex_unlock_force): Add memory barrier between store and futex
7130 2003-08-25 Ulrich Drepper <drepper@redhat.com>
7132 * tst-cancel4.c (do_test): Also unlink tempfname and remove
7133 tempmsg in first loop.
7135 2003-08-18 Ulrich Drepper <drepper@redhat.com>
7137 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
7138 _POSIX_THREAD_PRIORITY_SCHEDULING.
7139 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
7141 2003-08-07 Jakub Jelinek <jakub@redhat.com>
7143 * sysdeps/pthread/bits/libc-lock.h [_LIBC && SHARED]
7144 (__rtld_lock_default_lock_recursive,
7145 __rtld_lock_default_unlock_recursive): Define.
7146 [_LIBC && SHARED] (__rtld_lock_lock_recursive,
7147 __rtld_lock_unlock_recursive): Define using
7148 GL(_dl_rtld_*lock_recursive).
7149 * init.c (__pthread_initialize_minimal_internal): Initialize
7150 _dl_rtld_lock_recursive and _dl_rtld_unlock_recursive.
7151 Lock GL(_dl_load_lock) the same number of times as
7152 GL(_dl_load_lock) using non-mt implementation was nested.
7154 * pthreadP.h (__pthread_cleanup_upto): Add hidden_proto.
7155 * pt-longjmp.c (__pthread_cleanup_upto): Add hidden_def.
7157 2003-08-06 Jakub Jelinek <jakub@redhat.com>
7159 * tst-cancel17.c (do_test): Make len2 maximum of page size and
7162 2003-08-07 Jakub Jelinek <jakub@redhat.com>
7164 * pthread_create.c (__pthread_create_2_0): Clear new_attr.cpuset.
7166 2003-08-03 Jakub Jelinek <jakub@redhat.com>
7168 * sysdeps/pthread/createthread.c (do_clone): Move error handling
7169 to first syscall error check. Move syscall error check for tkill
7170 into __ASSUME_CLONE_STOPPED #ifdef.
7172 2003-08-02 Ulrich Drepper <drepper@redhat.com>
7174 * sysdeps/pthread/createthread.c (do_clone): If __ASSUME_CLONE_STOPPED
7175 is not defined, do explicit synchronization.
7176 (create_thread): Do not lock pd->lock here. If __ASSUME_CLONE_STOPPED
7177 is not defined also unlock pd->lock for non-debugging case in case
7179 * pthread_create.c (start_thread): Always get and release pd->lock
7180 if __ASSUME_CLONE_STOPPED is not defined.
7181 (start_thread_debug): Removed. Adjust users.
7182 * allocatestack.c (allocate_stack): Always initialize lock if
7183 __ASSUME_CLONE_STOPPED is not defined.
7184 * Makefile (tests): Add tst-sched1.
7185 * tst-sched1.c: New file.
7187 * sysdeps/pthread/createthread.c (do_clone): Only use
7188 sched_setschduler and pass correct parameters.
7190 2003-07-31 Jakub Jelinek <jakub@redhat.com>
7192 * sysdeps/pthread/pthread.h (pthread_attr_setstackaddr,
7193 pthread_attr_setstacksize): Change PTHREAD_STACK_SIZE to
7194 PTHREAD_STACK_MIN in comments.
7196 2003-07-31 Jakub Jelinek <jakub@redhat.com>
7198 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
7199 Shut up warnings if INTERNAL_SYSCALL_ERROR_P does not use its first
7201 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Likewise.
7202 * pthread_condattr_setclock.c (pthread_condattr_setclock): Likewise.
7203 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Include pthreaddef.h.
7204 (__pthread_cleanup_upto): Fix prototype.
7205 (_longjmp_unwind): Adjust caller.
7206 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (__lll_mutex_timedlock):
7207 Change second argument to const struct pointer.
7208 * tst-sem8.c (main): Remove unused s2 and s3 variables.
7209 * tst-sem9.c (main): Likewise.
7210 * unwind.c: Include string.h for strlen prototype.
7212 2003-07-31 Ulrich Drepper <drepper@redhat.com>
7214 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
7215 (__pthread_cond_timedwait): Don't use cmov unless HAVE_CMOV is defined.
7216 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_timedwait.S:
7218 Patch by Nicholas Miell <nmiell@attbi.com>.
7220 2003-07-30 Jakub Jelinek <jakub@redhat.com>
7222 * init.c (__pthread_initialize_minimal_internal): Initialize
7223 GL(dl_init_static_tls).
7224 * pthreadP.h (__pthread_init_static_tls): New prototype.
7225 * allocatestack.c (init_one_static_tls, __pthread_init_static_tls):
7227 * Makefile (tests): Add tst-tls4.
7228 (modules-names): Add tst-tls4moda and tst-tls4modb.
7229 ($(objpfx)tst-tls4): Link against libdl and libpthread.
7230 ($(objpfx)tst-tls4.out): Depend on tst-tls4moda.so and
7232 * tst-tls4.c: New file.
7233 * tst-tls4moda.c: New file.
7234 * tst-tls4modb.c: New file.
7236 2003-06-19 Daniel Jacobowitz <drow@mvista.com>
7238 * sysdeps/pthread/timer_create.c (timer_create): Call timer_delref
7239 before __timer_dealloc.
7240 * sysdeps/pthread/timer_routines.c (__timer_thread_find_matching):
7241 Don't call list_unlink.
7243 2003-07-29 Roland McGrath <roland@redhat.com>
7245 * Makefile [$(build-shared) = yes] (tests): Depend on $(test-modules).
7247 2003-07-25 Jakub Jelinek <jakub@redhat.com>
7249 * tst-cancel17.c (do_test): Check if aio_cancel failed.
7250 Don't reuse struct aiocb A if it failed.
7251 Write fpathconf (fds[1], _PC_PIPE_BUF) + 2 bytes using aio_write,
7252 not just one byte, as that does not block.
7254 2003-07-22 Jakub Jelinek <jakub@redhat.com>
7256 * sysdeps/pthread/unwind-resume.c: New file.
7257 * sysdeps/pthread/Makefile (routines, shared-only-routines): Add
7258 unwind-resume in csu subdir.
7259 (CFLAGS-unwind-resume.c, CFLAGS-rt-unwind-resume.c): Compile with
7261 (librt-sysdep_routines, librt-shared-only-routines): Add
7263 * sysdeps/pthread/rt-unwind-resume.c: New file.
7264 * unwind-forcedunwind.c: New file.
7265 * Makefile (libpthread-routines): Add unwind-forcedunwind.
7266 (libpthread-shared-only-routines): Likewise.
7267 (CFLAGS-unwind-forcedunwind.c): Compile with exceptions.
7268 * pthreadP.h (pthread_cancel_init): New prototype.
7269 * pthread_cancel.c (pthread_cancel): Call pthread_cancel_init.
7271 * sysdeps/pthread/createthread.c (do_thread, create_thread): Make
7272 attr argument const struct pthread_attr *.
7274 * res.c (__res_state): Return __resp.
7275 * descr.h: Include resolv.h.
7276 (struct pthread): Add res field.
7277 * pthread_create.c: Include resolv.h.
7278 (start_thread): Initialize __resp.
7279 * Makefile (tests): Add tst-_res1.
7280 (module-names): Add tst-_res1mod1, tst-_res1mod2.
7281 ($(objpfx)tst-_res1mod2.so): Depend on $(objpfx)tst-_res1mod1.so.
7282 ($(objpfx)tst-_res1): Depend on $(objpfx)tst-_res1mod2.so and
7284 * tst-_res1.c: New file.
7285 * tst-_res1mod1.c: New file.
7286 * tst-_res1mod2.c: New file.
7288 2003-07-21 Ulrich Drepper <drepper@redhat.com>
7290 * sysdeps/pthread/createthread.c: Don't define CLONE_STOPPED.
7292 * Makefile: Define various *-no-z-defs variables for test DSOs
7293 which has undefined symbols.
7295 2003-07-21 Steven Munroe <sjmunroe@us.ibm.com>
7297 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (__pthread_once):
7298 Retry if the stwcx fails to store once_control.
7300 2003-07-20 Ulrich Drepper <drepper@redhat.com>
7302 * Makefile (libpthread-routines): Add pthread_attr_getaffinity and
7303 pthread_attr_setaffinity.
7304 * Versions [libpthread] (GLIBC_2.3.3): Likewise.
7305 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c: New file.
7306 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: New file.
7307 * pthread_attr_destroy.c: Free cpuset element if allocated.
7308 * pthread_create.c: Pass iattr as additional parameter to
7310 * sysdeps/pthread/createthread.c: If attribute is provided and
7311 a new thread is created with affinity set or scheduling parameters,
7312 start thread with CLONE_STOPPED.
7313 * sysdeps/pthread/pthread.h: Declare pthread_attr_getaffinity and
7314 pthread_attr_setaffinity.
7315 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_attr): Add
7318 2003-07-15 Ulrich Drepper <drepper@redhat.com>
7320 * tst-tcancel-wrappers.sh: lseek and llseek are not cancelation points.
7322 2003-07-14 Ulrich Drepper <drepper@redhat.com>
7324 * sysdeps/pthread/configure.in: Require CFI directives also for
7327 2003-07-15 Jakub Jelinek <jakub@redhat.com>
7329 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h (PSEUDO):
7332 2003-07-12 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7334 * sysdeps/sh/tcb-offsets.sym: Add RESULT, TID, CANCELHANDLING and
7336 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Use more
7337 registers as variables. Call __pthread_mutex_unlock_usercnt.
7338 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
7339 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Store TID
7340 not self pointer in __writer. Compare with TID to determine
7342 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
7343 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S:
7345 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S:
7347 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Add cancellation support.
7348 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
7349 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Define all the nice
7350 macros also when compiling librt.
7352 2003-07-11 Jakub Jelinek <jakub@redhat.com>
7354 * Makefile (CFLAGS-pthread_once.c): Add -fexceptions
7355 -fasynchronous-unwind-tables.
7356 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
7357 (PSEUDO): Add cfi directives.
7358 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO):
7360 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
7363 2003-07-08 Jakub Jelinek <jakub@redhat.com>
7365 * pthreadP.h (__pthread_unwind_next, __pthread_register_cancel,
7366 __pthread_unregister_cancel): Add prototypes and hidden_proto.
7367 * unwind.c (__pthread_unwind_next): Add hidden_def.
7368 * cleanup.c (__pthread_register_cancel, __pthread_unregister_cancel):
7370 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
7371 Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
7372 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
7374 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S (sem_wait): Likewise.
7375 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
7377 * sysdeps/unix/sysv/linux/i386/pthread_once.S (__pthread_once): Use
7378 HIDDEN_JUMPTARGET to call __pthread_register_cancel,
7379 __pthread_unregister_cancel and __pthread_unwind_next.
7381 2003-07-04 Jakub Jelinek <jakub@redhat.com>
7383 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO): Use
7384 different symbol for the cancellation syscall wrapper and
7385 non-cancellation syscall wrapper.
7386 (PSEUDO_END): Define.
7388 2003-07-05 Richard Henderson <rth@redhat.com>
7390 * sysdeps/alpha/elf/pt-initfini.c: Avoid .ent/.end.
7391 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_futex_wait,
7392 lll_futex_timed_wait, lll_futex_wake, lll_futex_requeue): On success
7393 return actual return value from the syscall, not 0.
7395 2003-07-07 Ulrich Drepper <drepper@redhat.com>
7397 * descr.h (struct pthread): Add pid field.
7398 * allocatestack.c (allocate_stack): Initialize pid field in descriptor.
7399 (__reclaim_stacks): Likewise.
7400 * init.c (sigcancel_handler): If __ASSUME_CORRECT_SI_PID is defined
7401 also check for PID of the signal source.
7402 (__pthread_initialize_minimal_internal): Also initialize pid field
7403 of initial thread's descriptor.
7404 * pthread_cancel.c: Use tgkill instead of tkill if possible.
7405 * sysdeps/unix/sysv/linux/fork.c: Likewise.
7406 * sysdeps/unix/sysv/linux/pt-raise.c: Likewise.
7407 * sysdeps/unix/sysv/linux/pthread_kill.c: Likewise.
7408 * sysdeps/unix/sysv/linux/raise.c: Likewise.
7410 2003-07-05 Ulrich Drepper <drepper@redhat.com>
7412 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_push): Renamed.
7413 Fix use of parameter.
7414 (__libc_cleanup_pop): Likewise.
7416 2003-07-04 Ulrich Drepper <drepper@redhat.com>
7418 * init.c (sigcancel_handler): Change parameters to match handler
7419 for SA_SIGACTION. Check signal number and code to recognize
7420 invalid invocations.
7422 2003-07-03 Roland McGrath <roland@redhat.com>
7424 * sysdeps/ia64/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr):
7425 Apply sizeof (struct pthread) bias to r13 value.
7427 2003-07-03 Ulrich Drepper <drepper@redhat.com>
7429 * sysdeps/pthread/configure.in: Require CFI directives.
7431 * sysdeps/pthread/librt-cancellation.c (__pthread_unwind): Remove
7433 * pthreadP.h (__pthread_unwind): Add hidden_proto if used in
7434 libpthread compilation.
7435 * unwind.c (__pthread_unwind): Add hidden_def.
7436 * Versions (libpthread) [GLIBC_PRIVATE]: Add __pthread_unwind.
7438 2003-07-01 Ulrich Drepper <drepper@redhat.com>
7440 * libc-cancellation.c (__libc_cleanup_routine): Define.
7441 * sysdeps/pthread/bits/libc-lock.h (__pthread_cleanup_push): Define.
7442 (__pthread_cleanup_pop): Define.
7444 2003-07-01 Richard Henderson <rth@redhat.com>
7446 * sysdeps/alpha/elf/pt-initfini.c: New file.
7447 * sysdeps/alpha/pthread_spin_lock.S: New file.
7448 * sysdeps/alpha/pthread_spin_trylock.S: New file.
7449 * sysdeps/alpha/pthreaddef.h: New file.
7450 * sysdeps/alpha/td_ta_map_lwp2thr.c: New file.
7451 * sysdeps/alpha/tls.h: New file.
7452 * sysdeps/unix/sysv/linux/alpha/Makefile: New file.
7453 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: New file.
7454 * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h: New file.
7455 * sysdeps/unix/sysv/linux/alpha/createthread.c: New file.
7456 * sysdeps/unix/sysv/linux/alpha/fork.c: New file.
7457 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: New file.
7458 * sysdeps/unix/sysv/linux/alpha/pt-vfork.S: New file.
7459 * sysdeps/unix/sysv/linux/alpha/pthread_once.c: New file.
7460 * sysdeps/unix/sysv/linux/alpha/sem_post.c: New file.
7461 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: New file.
7463 2003-07-01 Ulrich Drepper <drepper@redhat.com>
7465 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Add correct
7466 cleanup support and unwind info.
7468 2003-06-30 Ulrich Drepper <drepper@redhat.com>
7470 * sysdeps/unix/sysv/linux/i386/pthread_once.S (__pthread_once):
7471 Use correct cleanup handler registration. Add unwind info.
7472 * sysdeps/unix/sysv/linux/unwindbuf.sym: New file.
7473 * sysdeps/unix/sysv/linux/Makefile: Add rule to build unwindbuf.h.
7474 * tst-once3.c: Add cleanup handler and check it is called.
7475 * tst-once4.c: Likewise.
7476 * tst-oncex3.c: New file.
7477 * tst-oncex4.c: New file.
7478 * Makefile: Add rules to build and run tst-oncex3 and tst-oncex4.
7480 2003-06-29 Ulrich Drepper <drepper@redhat.com>
7482 * sysdeps/pthread/configure.in: Check for C cleanup handling in gcc.
7484 2003-06-27 Ulrich Drepper <drepper@redhat.com>
7486 * tst-cancel4.c (tf_msgrcv): Use IPC_PRIVATE in msgget call.
7487 (tf_msgsnd): Likewise.
7489 * tst-cancel4.c (tf_msgrcv): Strengthen test against valid
7490 premature returns a bit more.
7492 2003-06-26 Ulrich Drepper <drepper@redhat.com>
7494 * sysdeps/pthread/librt-cancellation.c: Move __pthread_unwind
7495 definition to the front.
7497 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Rename
7498 the cleanup functions to make the names unique. Fix dwarf opcode
7500 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Rename cleanup
7501 functions to make the names unique. Fix CFA offset for two blocks.
7503 2003-06-25 Ulrich Drepper <drepper@redhat.com>
7505 * sysdeps/pthread/pthread.h (class __pthread_cleanup_class): Add
7506 missing closing braces.
7507 Patch by Christophe Saout <christophe@saout.de>.
7509 2003-06-24 Roland McGrath <roland@redhat.com>
7511 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Typo fix.
7513 2003-06-24 Ulrich Drepper <drepper@redhat.com>
7515 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: New file.
7516 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: New file.
7518 * pthreadP.h: Declare __find_thread_by_id.
7519 * allocatestack.c [HP_TIMING_AVAIL]: Define __find_thread_by_id.
7520 * pthread_clock_gettime.c: Allow using other thread's clock.
7521 * pthread_clock_settime.c: Likewise.
7522 * sysdeps/pthread/pthread_getcpuclockid.c: Likewise.
7523 * Makefile: Add rules to build and run tst-clock2.
7524 * tst-clock2.c: New file.
7526 2003-06-23 Ulrich Drepper <drepper@redhat.com>
7528 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Rewrite
7529 to use exception-based cleanup handler.
7530 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
7532 * tst-cond8.c (ch): Announce that we are done.
7534 * pthreadP.h (__pthread_mutex_cond_lock): Mark with internal_function.
7536 * tst-cancel17.c (tf): Retry aio_suspend in case of EINTR.
7537 Also test aio_suspend with timeout value.
7539 2003-06-22 Ulrich Drepper <drepper@redhat.com>
7541 * pthreadP.h: Mark __pthread_mutex_unlock_usercnt also hidden.
7542 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Add
7545 * pthreadP.h (__pthread_mutex_init_internal): Mark hidden.
7546 (__pthread_mutex_lock_internal): Likewise.
7547 (__pthread_mutex_unlock_internal): Likewise.
7548 (__pthread_mutex_unlock_usercnt): Declare.
7549 * pthread_mutex_destroy.c: Always fail if used in any way.
7550 * pthread_mutex_init.c: Update comment.
7551 * pthread_mutex_lock.c: If NO_INCR is not defined adjust __nusers.
7552 * pthread_mutex_timedlock.c: Adjust __nusers.
7553 * pthread_mutex_trylock.c: Adjust __nusers.
7554 * pthread_mutex_unlock.c: Old code is in __pthread_mutex_unlock_usercnt
7555 and public interfaces are wrapper with pass additional parameter.
7556 __pthread_mutex_unlock_usercnt does not adjust __nusers if second
7558 * tst-mutex8.c: New file.
7559 * Makefile (tests): Add tst-mutex8.
7560 * sysdeps/pthread/pthread_cond_timedwait.c: Call
7561 __pthread_mutex_unlock_usercnt.
7562 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
7563 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
7564 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
7565 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
7566 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
7567 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Define NO_INCR.
7568 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
7570 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
7571 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
7572 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
7573 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
7574 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
7576 * pthread_mutex_lock.c: Don't store THREAD_ID in __owner, use TID.
7577 * pthread_mutex_timedlock.c: Likewise.
7578 * pthread_mutex_trylock.c: Adjust __nusers.
7579 * pthread_mutex_unlock.c: Compare with TID not THREAD_ID.
7580 * tst-mutex9.c: New file.
7581 * Makefile (tests): Add tst-mutex9.
7582 * sysdeps/i386/tls.h: Remove THREAD_ID definition.
7583 * sysdeps/ia64/tls.h: Likewise.
7584 * sysdeps/powerpc/tls.h: Likewise.
7585 * sysdeps/s390/tls.h: Likewise.
7586 * sysdeps/sh/tls.h: Likewise.
7587 * sysdeps/x86_64/tls.h: Likewise.
7588 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
7589 Change type of __owner.
7590 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
7591 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
7592 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
7593 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
7594 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
7596 2003-06-19 Jakub Jelinek <jakub@redhat.com>
7598 * sysdeps/unix/sysv/linux/ia64/sem_post.c: Move to...
7599 * sysdeps/unix/sysv/linux/sem_post.c: ...here.
7601 * sysdeps/unix/sysv/linux/sem_post.c: Move to...
7602 * sysdeps/unix/sysv/linux/powerpc/sem_post.c: ... here. Pass nr + 1
7603 instead of nr to lll_futex_wake. Only set errno and return -1
7606 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (lll_futex_wait,
7607 lll_futex_timed_wait, lll_futex_wake, lll_futex_requeue): On success
7608 return actual return value from the syscall, not 0.
7610 2003-06-18 Ulrich Drepper <drepper@redhat.com>
7612 * tst-cancel4.c (tf_msgsnd): Don't always use 100 as the type,
7613 find a random value.
7614 (tf_msgrcv): Likewise. Also don't report msgrcv returns if
7617 * sysdeps/unix/sysv/linux/timer_settime.c: Add prototype for
7618 compat_timer_settime.
7619 * sysdeps/unix/sysv/linux/timer_gettime.c: Add prototype for
7620 compat_timer_gettime.
7621 * sysdeps/unix/sysv/linux/timer_getoverr.c: Add prototype for
7622 compat_timer_getoverrun.
7623 * sysdeps/unix/sysv/linux/timer_delete.c: Add prototype for
7624 compat_timer_delete.
7626 * pthread_mutex_destroy.c (__pthread_mutex_destroy): For
7627 error-checking mutex detect busy mutexes.
7629 2003-06-17 Ulrich Drepper <drepper@redhat.com>
7631 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_mutex_lock):
7632 Add ax to clobber list.
7633 (lll_mutex_cond_lock): Likewise.
7634 (lll_mutex_unlock): Likewise.
7635 (lll_lock): Likewise.
7636 (lll_unlock): Likewise.
7638 * Makefile: Add rules to build and run tst-cancel18 and tst-cancelx18.
7639 * tst-cancel18.c: New file.
7640 * tst-cancelx18.c: New file.
7642 * tst-cancel4.c: Test connect, creat, msgrcv, msgsnd, sendmsg, sendto,
7645 * Makefile: Add rules to build and run tst-cancel17 and tst-cancel17x.
7646 * tst-cancel17.c: New file.
7647 * tst-cancelx17.c: New file.
7649 * sysdeps/unix/sysv/linux/sigtimedwait.c: New file.
7650 * sysdeps/unix/sysv/linux/sigwait.c: New file.
7651 * sysdeps/unix/sysv/linux/sigwaitinfo.c: New file.
7653 * tst-cancel4.c: Test open, close, pread, pwrite, fsync, and msync.
7655 2003-06-16 Jakub Jelinek <jakub@redhat.com>
7657 * sysdeps/pthread/createthread.c (create_thread): Set
7658 header.multiple_threads unconditionally.
7659 * allocatestack.c (allocate_stack): Likewise.
7660 * descr.h (struct pthread): Add header.multiple_threads
7662 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (CENABLE, CDISABLE):
7663 Define for librt. #error if neither libpthread, libc nor librt.
7664 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (CENABLE, CDISABLE):
7666 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (CENABLE,
7667 CDISABLE): Likewise.
7668 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (CENABLE,
7669 CDISABLE): Likewise.
7670 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h (CENABLE,
7671 CDISABLE): Likewise.
7672 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (CENABLE,
7673 CDISABLE): Likewise. Access header.multiple_threads outside of
7674 libc and libpthread.
7675 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (CENABLE, CDISABLE):
7677 * sysdeps/x86_64/tls.h (tcbhead_t): Add multiple_threads.
7678 * sysdeps/x86_64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Define.
7680 2003-06-17 Ulrich Drepper <drepper@redhat.com>
7682 * tst-cancel4.c: Add tests for the socket and signal functions, pause.
7683 Also test early cancellation before the thread reaches the cancellation
7686 * Makefile: Compile forward.c with exceptions.
7688 * sysdeps/unix/sysv/linux/sleep.c: New file.
7690 2003-06-16 Ulrich Drepper <drepper@redhat.com>
7692 * Makefile: Add CFLAGS definition to compile function wrappers
7693 duplicated from libc with exceptions.
7694 * tst-cancel4.c: Also check cancellation handlers.
7696 * Makefile: Add rules to build and run tst-cancel16 and
7697 tst-cancelx16. Add missing CFLAGS definitions.
7698 * tst-cancel16.c: New file.
7699 * tst-cancelx16.c: New file.
7701 2003-06-15 Ulrich Drepper <drepper@redhat.com>
7703 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
7704 (DL_SYSINFO_IMPLEMENTATION): Use CFI opcodes.
7705 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h
7706 (DL_SYSINFO_IMPLEMENTATION): Likewise.
7708 * pthreadP.h (LIBC_CANCEL_ASYNC): Also define for librt.
7709 (LIBC_CANCEL_RESET): Likewise.
7710 Declare __librt_enable_asynccancel and __librt_disable_asynccancel.
7711 * sysdeps/pthread/Makefile (librt-sysdep_routines): Add
7713 (CFLAGS-libcrt-cancellation.c): Define.
7714 * sysdeps/pthread/librt-cancellation.c: New file.
7715 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define all the nice
7716 macros also when compiling librt.
7717 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
7718 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
7719 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
7720 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
7721 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
7722 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
7723 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
7725 * sysdeps/unix/sysv/linux/timer_create.c: Add prototype for
7726 compat_timer_create.
7728 2003-06-14 Ulrich Drepper <drepper@redhat.com>
7730 * sysdeps/pthread/posix-timer.h (timespec_compare): Always inline.
7732 * sysdeps/unix/sysv/linux/fork.h: Add libc_hidden_proto for
7734 * sysdeps/unix/sysv/linux/register-atfork.c (__register_atfork):
7735 Add libc_hidden_def.
7737 2003-06-13 Roland McGrath <roland@redhat.com>
7739 * sysdeps/x86_64/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Pass FS
7740 constant from <sys/reg.h> to ps_get_thread_area, not register contents.
7742 2003-06-11 Ulrich Drepper <drepper@redhat.com>
7744 * allocatestack.c (queue_stack): Always inline.
7745 * ptreadhP.h (__do_cancel): Likewise.
7747 2003-06-10 Jakub Jelinek <jakub@redhat.com>
7749 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c (sem_timedwait): Fix
7752 2003-06-10 Ulrich Drepper <drepper@redhat.com>
7754 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
7755 (__pthread_cond_signal): Remove incorrect second addition for
7758 2003-06-09 Ulrich Drepper <drepper@redhat.com>
7760 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
7761 (__pthread_cond_signal): Use correct futex pointer in
7762 __lll_mutex_lock_wait call.
7764 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
7765 (__pthread_cond_signal): Some more tweaks to handle cond_lock!=0.
7767 2003-06-08 Ulrich Drepper <drepper@redhat.com>
7769 * sysdeps/unix/sysv/linux/s390/sem_wait.c (__new_sem_wait): Make
7771 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c (sem_timedwait):
7774 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Remove
7775 hand-written CFI generation code. Since ENTRY/END also initiated
7776 CFI frames this caused two CFI sets to be generated.
7778 2003-06-07 Ulrich Drepper <drepper@redhat.com>
7780 * cleanup_routine.c: New file.
7781 * Versions (libpthread) [GLIBC_2.3.3]: Add __pthread_cleanup_routine.
7782 * sysdeps/pthread/pthread.h: Add support for fully exception-based
7784 * Makefile (libpthread-routines): Add cleanup_routine.
7785 Add more CFLAGS variables to compile with exceptions. Add comments
7786 why which file needs unwind tables.
7787 (tests) [have-forced-unwind==yes]: Add tst-cancelx* and tst-cleanupx*
7789 * tst-cancelx1.c: New file.
7790 * tst-cancelx2.c: New file.
7791 * tst-cancelx3.c: New file.
7792 * tst-cancelx4.c: New file.
7793 * tst-cancelx5.c: New file.
7794 * tst-cancelx6.c: New file.
7795 * tst-cancelx7.c: New file.
7796 * tst-cancelx8.c: New file.
7797 * tst-cancelx9.c: New file.
7798 * tst-cancelx10.c: New file.
7799 * tst-cancelx11.c: New file.
7800 * tst-cancelx12.c: New file.
7801 * tst-cancelx13.c: New file.
7802 * tst-cancelx14.c: New file.
7803 * tst-cancelx15.c: New file.
7804 * tst-cleanupx0.c: New file.
7805 * tst-cleanupx0.expect: New file.
7806 * tst-cleanupx1.c: New file.
7807 * tst-cleanupx2.c: New file.
7808 * tst-cleanupx3.c: New file.
7810 * tst-cleanup0.c: Make standard compliant.
7811 * tst-cleanup1.c: Likewise.
7813 * sysdeps/unix/sysv/linux/sem_timedwait.c: Add cancellation support.
7814 * sysdeps/unix/sysv/linux/sem_wait.c: Likewise.
7815 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
7816 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
7817 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
7818 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
7819 * sysdeps/i386/tcb-offsets.sym: Add RESULT, CANCELHANDLING, and
7821 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
7822 * tst-cancel12.c: New file.
7823 * tst-cancel13.c: New file.
7824 * tst-cancel14.c: New file.
7825 * tst-cancel15.c: New file.
7826 * Makefile (tests): Add tst-cancel12, tst-cancel13, tst-cancel14,
7829 * tst-cancel1.c: Add some comments.
7831 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Compute relative
7834 2003-06-06 Ulrich Drepper <drepper@redhat.com>
7836 * Makefile (CFLAGS-pthread_cancel.c): Define.
7838 2003-06-05 Ulrich Drepper <drepper@redhat.com>
7840 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_rwlock_t):
7841 Change type of __writer element to int.
7842 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
7843 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
7844 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
7845 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
7846 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
7847 * sysdeps/i386/tcb-offsets.sym: Replace SELF entry with TID entry.
7848 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
7849 * pthread_rwlock_trywrlock.c: Store TID not self pointer in __writer.
7850 Compare with TID to determine deadlocks.
7851 * sysdeps/pthread/pthread_rwlock_rdlock.c: Likewise.
7852 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Likewise.
7853 * sysdeps/pthread/pthread_rwlock_timedwrlock.: Likewise.
7854 * sysdeps/pthread/pthread_rwlock_wrlock.c: Likewise.
7855 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
7856 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
7858 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
7860 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
7861 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
7862 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
7864 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
7866 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
7867 * Makefile (tests): Add tst-rwlock12.
7868 * tst-rwlock12.c: New file.
7870 2003-06-05 Jakub Jelinek <jakub@redhat.com>
7872 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait,
7873 __lll_timedlock_wait, lll_unlock_wake_cb, __lll_timedwait_tid):
7874 Remove bogus hidden_proto.
7875 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c (___lll_lock):
7877 * sysdeps/unix/sysv/linux/s390/lowlevellock.c (___lll_lock,
7878 lll_unlock_wake_cb, ___lll_timedwait_tid): Likewise.
7879 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c (___lll_mutex_lock,
7880 ___lll_mutex_timedlock): Likewise.
7882 2003-06-04 Ulrich Drepper <drepper@redhat.com>
7884 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
7885 (__pthread_cond_signal): Add some code to eventually handle
7888 2003-06-01 Ulrich Drepper <drepper@redhat.com>
7890 * Makefile (tests): Add tst-exec4.
7891 (tst-exec4-ARGS): Define.
7892 * tst-exec4.c: New file.
7894 2003-05-31 Ulrich Drepper <drepper@redhat.com>
7896 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait):
7897 Also fail if tv_nsec < 0.
7898 (__lll_timedwait_tid): Likewise.
7899 * sysdeps/unix/sysv/linux/sem_timedwait.c (sem_timedwait): Likewise.
7900 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_timedwait_tid):
7902 * sysdeps/unix/sysv/linux/s390/lowlevellock.c (___lll_timedwait_tid):
7904 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c (__lll_mutex_timedlock):
7906 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c (sem_timedwait):
7908 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_timedwait_tid):
7910 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_timedwait_tid):
7913 * Makefile (tests): Add tst-sem8 and tst-sem9.
7914 * tst-sem8.c: New file.
7915 * tst-sem9.c: New file.
7916 * sem_open.c: Fix creation of in_use record if the file exists but
7919 * posix-timer.h: Remove old, unused timer_id2ptr and timer_ptr2id
7922 * sysdeps/pthread/timer_create.c (timer_create): In case
7923 evp==NULL, assign timer ID to sival_ptr.
7925 * descr.h (struct pthread_unwind_buf): Change type of prev element to
7926 struct pthread_unwind_buf *.
7927 (struct pthread): Likewise for cleanup_jmp_buf element.
7929 * cleanup.c (__pthread_register_cancel): Add cast to avoid warning.
7930 * cleanup_defer.c (__pthread_register_cancel_defer): Likewise.
7931 * unwind.c (__pthread_unwind_next): Likewise.
7933 2003-05-30 Ulrich Drepper <drepper@redhat.com>
7935 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
7936 (lll_futex_timed_wait): Use int for futex value parameter.
7937 (lll_futex_wake): Likewise.
7938 (lll_futex_requeue): Likewise.
7940 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait):
7941 Replace one memory operation with one register operation.
7943 * tst-join4.c (do_test): Fix error message.
7945 * tst-rwlock6.c (do_test): Use correct format specifier.
7947 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S
7948 (__lll_mutex_lock_wait): Replace one memory operation with one
7950 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S
7951 (__lll_mutex_lock_wait): Likewise.
7953 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
7954 (__lll_mutex_cond_lock): Add one to value parameter of
7955 __lll_lock_wait to reflect reality in the futex syscall.
7956 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
7957 (lll_mutex_cond_lock): Likewise.
7959 2003-05-30 Jakub Jelinek <jakub@redhat.com>
7961 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (__lll_mutex_cond_lock):
7963 (lll_mutex_cond_lock): Define.
7965 2003-05-29 Ulrich Drepper <drepper@redhat.com>
7967 * Makefile (tests): Add tst-signal6.
7968 * tst-signal6.c: New file.
7970 * sysdeps/unix/sysv/linux/s390/lowlevellock.h
7971 (__lll_mutex_unlock_force): New function
7972 (lll_mutex_unlock_force): Use __lll_mutex_unlock_force.
7974 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
7975 (__lll_mutex_unlock_force): New function.
7976 (lll_mutex_unlock_force): Use __lll_mutex_unlock_force.
7978 * tst-rwlock7.c (do_test): Use correct format specifier.
7980 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_requeue):
7981 Find break parameter in correct asm argument.
7983 2003-05-27 Jakub Jelinek <jakub@redhat.com>
7985 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_clobbers):
7987 (lll_futex_requeue): Fix __o3 constraint, return negative errno if
7989 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
7991 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_REQUEUE,
7992 lll_futex_requeue, lll_mutex_unlock_force): Define.
7994 2003-05-30 Jakub Jelinek <jakub@redhat.com>
7996 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
7997 (pthread_cond_t): Add __mutex.
7998 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_REQUEUE,
7999 lll_futex_requeue, lll_mutex_unlock_force): Define.
8001 2003-05-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
8003 * sysdeps/sh/tcb-offsets.sym: Define MUTEX_FUTEX.
8004 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
8006 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (SYSCALL_WITH_INST_PAD):
8008 (lll_futex_wait, lll_futex_wake): Define.
8009 * sysdeps/unix/sysv/linux/sh/sh4/lowlevellock.h: New file.
8010 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Try using
8011 FUTEX_REQUEUE instead of FUTEX_WAIT.
8012 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Likewise.
8013 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Remember
8014 mutex which was used in condvar structure. Call
8015 __pthread_mutex_cond_lock instead of __pthread_mutex_lock_internal.
8016 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Likewise.
8018 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Don't
8019 include tcb-offsets.h. Read wakeup value in locked region.
8020 Use the value of gbr register as THREAD_ID.
8021 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
8022 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
8023 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
8025 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Remove futex related
8028 2003-05-28 Ulrich Drepper <drepper@redhat.com>
8030 * sysdeps/pthread/pthread_cond_broadcast.c
8031 (__pthread_cond_broadcast): Fix typo: MAX_INT -> INT_MAX.
8033 2003-05-26 Ulrich Drepper <drepper@redhat.com>
8035 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Fix
8036 typo in register name.
8037 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Use parameters
8038 correctly. Actually use requeue. Little optimization.
8039 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Store
8040 mutex address early. Handle cancellation state as 32-bit value.
8041 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
8042 Remove unnecessary label.
8044 2003-05-25 Ulrich Drepper <drepper@redhat.com>
8046 * sysdeps/pthread/pthread_cond_broadcast.c: Try using FUTEX_REQUEUE
8047 instead of FUTEX_WAIT.
8048 * sysdeps/pthread/pthread_cond_signal.c: Likewise.
8049 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
8050 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
8051 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
8052 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
8053 * sysdeps/pthread/pthread_cond_timedwait.c: Remember mutex which was
8054 used in condvar structure. Call __pthread_mutex_cond_lock instead
8055 of __pthread_mutex_lock_internal.
8056 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
8057 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
8058 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
8059 (__condvar_cleanup): Always call __pthread_mutex_cond_lock.
8060 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
8061 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
8062 * sysdeps/unix/sysv/linux/Makefile (libpthread-sysdep_routines):
8063 Add pthread_mutex_cond_lock.
8064 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Add dep_mutex.
8065 * sysdeps/unix/sysv/linux/pthread_cond_mutex_lock.c: New file.
8066 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define
8067 lll_mutex_cond_lock.
8068 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
8069 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
8070 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
8072 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
8073 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
8075 * sysdeps/i386/tcb-offsets.sym: Define MUTEX_FUTEX.
8076 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
8078 * pthreadP.h: Declare __pthread_mutex_cond_lock.
8079 * pthread_mutex_lock.c: Define LLL_MUTEX_LOCK if not already defined.
8080 Use it instead of lll_mutex_lock. If __pthread_mutex_lock is a
8081 macro don't define aliases.
8083 * cancellation.c: Remove __pthread_enable_asynccancel_2.
8084 * pthreadP.h: Remove declaration of __pthread_enable_asynccancel_2.
8085 * sysdeps/pthread/pthread_cond_timedwait.c: Use
8086 __pthread_enable_asynccancel instead of __pthread_enable_asynccancel_2.
8087 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
8088 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
8089 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
8090 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
8091 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
8093 2003-05-17 Ulrich Drepper <drepper@redhat.com>
8095 * sem_open.c: Fix one endless loop. Implement correct semantics
8096 wrt opening the same semaphore more then once.
8097 * sem_close.c: Adjust for sem_open change.
8098 * semaphoreP.h: Include <semaphore.h>. Define struct inuse_sem.
8099 Declare __sem_mappings, __sem_mappings_lock, __sem_search.
8100 * Makefile (tests): Add tst-sem7.
8101 * tst-sem7.c: New file.
8103 2003-05-16 Roland McGrath <roland@redhat.com>
8105 * sysdeps/unix/sysv/linux/register-atfork.c (libc_freeres_fn): Fix
8106 uninitialized variable braino.
8108 2003-05-16 Ulrich Drepper <drepper@redhat.com>
8110 * sysdeps/unix/sysv/linux/timer_gettime.c (timer_gettime): Correct
8111 test for syscall availability.
8113 * sysdeps/unix/sysv/linux/timer_settime.c (timer_settime): Set
8114 __no_posix_timers to -1 if the syscalls don't exist.
8116 * pthread_join.c (pthread_join): Set tid field of the joined
8117 thread to -1. This isn't necessary but helps to recognize some
8118 error conditions with almost no cost.
8120 * allocatestack.c (FREE_P): Also negative values indicate an
8123 * unwind.c: Include <unistd.h>.
8125 2003-05-14 Ulrich Drepper <drepper@redhat.com>
8127 * Makefile ($(objpfx)$(multidir)): Add rule to create the directory.
8129 2003-05-14 Jakub Jelinek <jakub@redhat.com>
8131 * Makefile (crti-objs, crtn-objs): New variables.
8132 (omit-deps, extra-objs): Add crtn.
8133 ($(objpfx)libpthread.so): Depend on both crti and crtn
8134 and links to them in multidir.
8135 ($(objpfx)crtn.S, $(objpfx)crtn.o): New rules.
8137 2003-05-12 Steven Munroe <sjmunroe@us.ibm.com>
8139 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
8140 (lll_mutex_unlock): Use atomic_exchange_rel.
8142 2003-05-11 Ulrich Drepper <drepper@redhat.com>
8144 * cond-perf.c (cons): Add missing locking around setting of alldone.
8146 2003-05-10 Ulrich Drepper <drepper@redhat.com>
8148 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Remove futex
8150 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
8152 2003-05-09 Ulrich Drepper <drepper@redhat.com>
8154 * tst-sem6.c: New file.
8155 * Makefile (tests): Add tst-sem6.
8157 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (___lll_mutex_unlock):
8158 Use atomic_exchange_rel instead of atomic_exchange.
8159 * sysdeps/unix/sysv/linux/lowlevellock.c (lll_unlock_wake_cb):
8162 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Improve quality of
8163 code for lll_futex_wait and lll_futex_wake in static apps. Use
8164 vsyscall is possible.
8166 * sysdeps/unix/sysv/linux/pthread_getaffinity.c: New file.
8167 * sysdeps/unix/sysv/linux/pthread_setaffinity.c: New file.
8168 * sysdeps/pthread/pthread.h: Declare pthread_getaffinity_np and
8169 pthread_setaffinity_np.
8170 * Versions [libpthread] (GLIBC_2.3.3): Add pthread_getaffinity_np
8171 and pthread_setaffinity_np.
8172 * Makefile (libpthread-routines): Add pthread_getaffinity and
8173 pthread_setaffinity.
8175 * allocatestack.c (allocate_stack): If ARCH_RETRY_MMAP is defined,
8176 use it in case mmap to allocate the stack fails.
8177 * sysdeps/unix/sysv/linux/x86_64/Makefile: Don't define
8178 ARCH_MAP_FLAGS here.
8179 * sysdeps/x86_64/pthreaddef.h: Define ARCH_MAP_FLAGS and
8182 2003-05-08 Ulrich Drepper <drepper@redhat.com>
8184 * sysdeps/unix/sysv/linux/fork.c: Complete rewrite of the atfork
8185 handler implementation. It is now lockless in fork().
8186 * sysdeps/unix/sysv/linux/register-atfork.c: Likewise.
8187 * sysdeps/unix/sysv/linux/unregister-atfork.c: Likewise.
8188 * sysdeps/unix/sysv/linux/fork.h: Don't include <link.h>. Don't
8189 declare the __fork_*_lists.
8190 (struct fork_handler): Include pointers to all three functions.
8191 Add next, refcntr and need_signal elements.
8192 (__fork_handlers): New declaration.
8193 (__register_atfork_malloc): Remove declaration.
8194 (HAVE_register_atfork_malloc): Remove definition.
8195 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Remove
8196 __pthread_child_handler variable.
8197 (__libc_pthread_init): Use __register_atfork instead of explicitly
8199 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define lll_futex_wait
8201 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
8203 * unwind.c (unwind_cleanup): Print error message and then abort. This
8204 function must never be reached.
8206 * cond-perf.c: New file.
8208 2003-05-05 Ulrich Drepper <drepper@redhat.com>
8210 * sysdeps/i386/tls.h (TLS_INIT_TP): Include \n in error message.
8212 2003-05-04 Roland McGrath <roland@redhat.com>
8214 * Makefile ($(objpfx)../libc.so): New target.
8216 2003-05-02 Ulrich Drepper <drepper@redhat.com>
8218 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
8219 (pthread_condattr_t): Size is only an int, don't use long for
8221 (pthread_mutexattr_t): Likewise.
8222 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
8223 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
8224 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
8226 2003-05-01 Ulrich Drepper <drepper@redhat.com>
8228 * sysdeps/i386/tls.h: Define THREAD_ID.
8229 * sysdeps/ia64/tls.h: Likewise.
8230 * sysdeps/powerpc/tls.h: Likewise.
8231 * sysdeps/s390/tls.h: Likewise.
8232 * sysdeps/sh/tls.h: Likewise.
8233 * sysdeps/x86_64/tls.h: Likewise.
8234 * pthread_mutex_lock.c: Use THREAD_ID instead of THREAD_SELF to
8236 * pthread_mutex_timedlock.c: Likewise.
8237 * pthread_mutex_trylock.c: Likewise.
8238 * pthread_mutex_unlock.c: Likewise.
8239 * pthread_rwlock_trywrlock.c: Likewise.
8240 * sysdeps/pthread/pthread_rwlocklock_rdlock.c: Likewise.
8241 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Likewise.
8242 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
8243 * sysdeps/pthread/pthread_rwlock_wrlock.c: Likewise.
8245 * sysdeps/pthread/createthread.c (create_thread): Use CLONE_SYSVSEM
8248 2003-04-29 Jakub Jelinek <jakub@redhat.com>
8250 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
8251 (__SIZEOF_PTHREAD_COND_T): Define to 48.
8252 (pthread_rwlock_t): Add 16 bytes of pad instead of 8 before __flags.
8253 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
8254 Make __align long long instead of long.
8255 (pthread_rwlock_t): Formatting.
8256 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h
8257 (pthread_rwlock_t): Formatting.
8258 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
8259 (pthread_cond_t): Make __align long long instead of long.
8260 (pthread_rwlock_t): Move __flags field to the same position as in
8263 2003-04-30 Ulrich Drepper <drepper@redhat.com>
8265 * tst-rwlock6.c (do_test): Use correct printf format specifiers.
8266 * tst-rwlock7.c (do_test): Likewise.
8268 2003-04-26 Roland McGrath <roland@redhat.com>
8270 * Makefile ($(test-modules)): Depend on $(common-objpfx)shlib.lds.
8272 2003-04-22 Jakub Jelinek <jakub@redhat.com>
8274 * allocatestack.c (TLS_TPADJ): Add TLS_PRE_TCB_SIZE instead of
8275 sizeof (struct pthread).
8276 (allocate_stack): Subtract TLS_PRE_TCB_SIZE bytes instead of
8278 * sysdeps/powerpc/tls.h (TLS_INIT_TCB_SIZE, TLS_TCB_SIZE): Define
8280 (TLS_INIT_TCB_ALIGN, TLS_TCB_ALIGN): Define to alignment of
8282 (TLS_PRE_TCB_SIZE): Increase to cover tcbhead_t preceeded by pad
8284 (INSTALL_DTV, GET_DTV, THREAD_DTV): tcbhead_t is immediately before
8286 (TLS_INIT_TP, THREAD_SELF, INIT_THREAD_SELF): Don't add TLS_TCB_SIZE
8288 (NO_TLS_OFFSET): Define.
8289 * sysdeps/unix/sysv/linux/powerpc/createthread.c (TLS_VALUE): Don't
8290 add TLS_TCB_SIZE unnecessarily.
8292 2003-04-22 Roland McGrath <roland@redhat.com>
8294 * Makeconfig (shared-thread-library): Reverse link order to work
8297 2003-04-22 Ulrich Drepper <drepper@redhat.com>
8299 * semaphore.h: Fix typo in comment.
8301 2003-04-21 Ulrich Drepper <drepper@redhat.com>
8303 * sysdeps/pthread/sigfillset.c: New file.
8305 * init.c (__pthread_initialize_minimal): Don't block SIGTIMER.
8306 * pthreadP.h: Make SIGTIMER and SIGCANCEL the same.
8307 * sysdeps/pthread/pthread_sigmask.c: Remove handling of SIGTIMER.
8308 * sysdeps/pthread/sigaction.c: Likewise.
8309 * sysdeps/pthread/sigprocmask.c: New file.
8310 * sysdeps/unix/sysv/linux/allocrtsig.c (current_rtmin): Define as
8312 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
8313 Block SIGTIMER. Also handle SI_TKILL events and terminate thread
8316 2003-04-19 Ulrich Drepper <drepper@redhat.com>
8318 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
8319 (DL_SYSINFO_IMPLEMENTATION): Add .eh_frame information.
8321 * sysdeps/unix/sysv/linux/unregister-atfork.c
8322 (__unregister_atfork): Don't free memory not allocated dynamically.
8324 * semaphore.h: Remove __THROW marker from cancellation points.
8325 * nptl/sysdeps/pthread/pthread.h: Likewise.
8327 2003-04-18 Ulrich Drepper <drepper@redhat.com>
8329 * sysdeps/pthread/pthread.h: Don't mark pthread_testcancel,
8330 pthread_cancel, pthread_setcancelstate, and pthread_setcanceltype with
8333 2003-04-16 Jakub Jelinek <jakub@redhat.com>
8335 * tst-cancel4.c (do_test): Use %zd instead of %d when printing cnt.
8337 2003-04-15 Roland McGrath <roland@redhat.com>
8339 * forward.c (__pthread_unwind): Tweak to avoid warning.
8341 2003-04-15 Ulrich Drepper <drepper@redhat.com>
8343 * pthreadP.h: Move THREAD_ATOMIC_* replacements to the top.
8345 2003-04-14 Ulrich Drepper <drepper@redhat.com>
8347 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Don't
8348 overflow CFA advance instructions.
8349 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
8351 2003-04-14 Jakub Jelinek <jakub@redhat.com>
8353 * sysdeps/i386/tls.h: Rename LOCK to LOCK_PREFIX.
8354 * sysdeps/i386/pthread_spin_lock.c: Likewise.
8355 * sysdeps/x86_64/tls.h: Likewise. Define LOCK_PREFIX if not already
8358 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Use
8359 DW_CFA_advance_loc2 for .Laddl-.Lsubl.
8360 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Use
8361 DW_CFA_advance_loc for .Laddl-.Lsubl.
8363 2003-04-13 Ulrich Drepper <drepper@redhat.com>
8365 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Don't use
8366 position-independent unwind data for static libraries.
8367 Add missing unwind info. Add comments.
8369 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Add unwind info.
8370 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
8371 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
8372 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
8374 2003-04-12 Ulrich Drepper <drepper@redhat.com>
8376 * Makefile: Make sure all cancellation points are compiled with
8377 exception and asynchronous unwind tables.
8379 * sysdeps/x86_64/tls.h (THREAD_SETMEM): Word around compiler bug
8380 which mishandles loading of global object addresses in PIC.
8381 (THREAD_SETMEM_NC): Likewise.
8383 2003-04-11 Ulrich Drepper <drepper@redhat.com>
8385 * pthread.h: Define new data structure for cleanup buffer. Declare
8386 new cleanup handler interfaces.
8387 * descr.h: Include <unwind.h> if necessary. Define pthread_unwind_buf.
8388 (struct pthread): Add cleanup_jmp_buf pointer. Define
8389 HAVE_CLEANUP_JMP_BUF and not HAVE_CANCELBUF.
8390 * pthreadP.h: Declare __pthread_unwind. Define __do_cancel to use
8391 it. Declare old cleanup handler installation functions.
8392 * cleanup.c: Rewrite. Install handler for unwind-based cleanup
8394 * cleanup_defer.c: Likewise.
8395 * cleanup_compat.c: New file. Old cleanup code.
8396 * cleanup_def_compat.c: New file. Old cleanup code.
8397 * pthread_create.c (start_thread): Initialize cleanup_jmp_buf element
8398 if own thread descriptor.
8399 * unwind.c: New file.
8400 * forward.c: Add __pthread_unwind.
8401 * init.c (pthread_functions): Add __pthread_unwind.
8402 * sysdeps/pthread/pthread-functions.s (struct pthread_functions):
8403 Add ptr___pthread_unwind.
8404 * Versions [GLIBC_2.3.3] (libpthread): Export new cleanup handling
8405 and unwind function.
8406 * Makefile (libpthread-routines): Add cleanup_compat,
8407 cleanup_def_compat, and unwind. Define CFLAGS to enable unwind
8408 table generation if necessary.
8409 * version.c: Record whether unwind support is compiled in.
8410 * sysdeps/pthread/configure.in: Add checks for unwind unterfaces.
8411 * sysdeps/pthread/bits/libc-lock.h: Add prototypes of the old cleanup
8413 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Add quite a bit of
8414 complication to generate unwind information for syscall wrappers.
8415 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
8416 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Define
8417 __cleanup_fct_attribute.
8419 * Makefile: Add rules to build and run tst-cleanup0.
8420 * tst-cleanup0.c: New file.
8421 * tst-cleanup0.expect: New file.
8423 * pthread_create.c (deallocate_tsd): Don't take parameter. Adjust
8424 caller. Optimize to avoid often unecessary local variable.
8426 2003-04-11 Roland McGrath <roland@redhat.com>
8428 * Makefile ($(objpfx)multidir.mk): New target, generated makefile that
8429 sets variable `multidir'; include that.
8430 (generated): Add it.
8431 ($(objpfx)$(multidir)/crti.o): New target.
8432 [$(multidir) != .] (generated-dirs, extra-objs, omit-deps): Add it.
8434 2003-04-11 Ulrich Drepper <drepper@redhat.com>
8436 * tst-attr2.c (do_test): Add cast to avoid warning.
8437 * tst-mutex4.c (do_test): Likewise.
8439 2003-04-10 Ulrich Drepper <drepper@redhat.com>
8441 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Reset CPU clocks
8444 2003-04-09 Ulrich Drepper <drepper@redhat.com>
8446 * Makefile (tests): Add tst-detach1.
8447 * tst-detach1.c: New file.
8449 2003-04-08 Ulrich Drepper <drepper@redhat.com>
8451 * sysdeps/pthread/pthread.h: Remove duplicate
8452 pthread_cleanup_{push,pop} definitions.
8454 * tst-barrier2.c: Eliminate warnings.
8455 * tst-cancel4.c: Likewise.
8456 * tst-cond4.c: Likewise.
8457 * tst-cond6.c: Likewise.
8458 * tst-detach1.c: Likewise.
8459 * tst-rwlock4.c: Likewise.
8460 * tst-rwlock6.c: Likewise.
8461 * tst-rwlock7.c: Likewise.
8462 * tst-sem3.c: Likewise.
8463 * tst-spin2.c: Likewise.
8464 * tst-umask1.c: Likewise.
8466 2003-04-07 Ulrich Drepper <drepper@redhat.com>
8468 * pthread_detach.c (pthread_detach): Fix test for invalid TID.
8470 2003-04-06 Ulrich Drepper <drepper@redhat.com>
8472 * descr.h (struct pthread): Move cancelhandling member to the front.
8474 2003-04-05 Ulrich Drepper <drepper@redhat.com>
8476 * sysdeps/unix/sysv/linux/register-atfork.c: Define malloc_prepare,
8477 malloc_parent, and malloc_child statically.
8478 (__register_atfork_malloc): New function.
8479 (free_mem): Don't free any of the malloc_* variables on the list.
8480 * sysdeps/unix/sysv/linux/fork.h: Declare __register_atfork_malloc.
8481 Define HAVE_register_atfork_malloc.
8483 2003-04-04 Ulrich Drepper <drepper@redhat.com>
8485 * sysdeps/pthread/createthread.c (create_thread): Add some more
8486 comments explaining when to set multiple_threads and when not.
8488 * pthreadP.h: Define THREAD_ATOMIC_CMPXCHG_VAL and
8489 THREAD_ATOMIC_BIT_SET if not already defined.
8490 * sysdeps/i386/tls.h: Define THREAD_ATOMIC_CMPXCHG_VAL and
8491 THREAD_ATOMIC_BIT_SET:
8492 * sysdeps/x86_64/tls.h: Likewise.
8493 * cleanup_defer.c (_pthread_cleanup_push_defer): Rewrite to use
8494 THREAD_ATOMIC_CMPXCHG_VAL.
8495 (_pthread_cleanup_pop_restore): Likewise.
8496 * cancellation.c (__pthread_enable_asynccancel): Likewise.
8497 (__pthread_enable_asynccancel_2): Likewise.
8498 (__pthread_disable_asynccancel): Likewise.
8499 * libc-cancellation.c (__libc_enable_asynccancel): Likewise.
8500 (__libc_disable_asynccancel): Likewise.
8501 * init.c (sigcancel_handler): Likewise.
8502 * pthread_setcancelstate.c (__pthread_setcancelstate): Likewise.
8503 * pthread_setcanceltype.c (__pthread_setcanceltype): Likewise.
8505 2003-04-03 Ulrich Drepper <drepper@redhat.com>
8507 * init.c (sigcancel_handler): Don't set EXITING_BIT here.
8508 * libc-cancellation.c (__libc_enable_asynccancel): Likewise.
8509 * pthreadP.h (__do_cancel): Set EXITING_BIT here.
8510 * Makefile (tests): Add tst-cancel11.
8511 * tst-cancel11.c: New file.
8513 2003-04-01 Ulrich Drepper <drepper@redhat.com>
8515 * pthread_create.c (deallocate_tsd): Clear/free memory after the last
8516 round, not the first. Use specific_used flag instead of local
8517 found_nonzero variable. Use THREAD_[SG]ETMEM where possible.
8518 (__free_tcb): Don't call deallocate_tsd here.
8519 (start_thread): Call deallocate_tsd here.
8520 * pthread_setspecific.c: Set specific_used flag really only when
8522 * Makefile (tests): Add tst-tsd3.c and tst-tsd4.
8523 * tst-tsd3.c: New file.
8524 * tst-tsd4.c: New file.
8526 2003-03-31 Ulrich Drepper <drepper@redhat.com>
8528 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_mutex_lock):
8529 Use atomic_exchange_and_add instead of __lll_add.
8530 (__lll_mutex_timedlock): Likewise.
8531 Patch by Ian Wienand.
8533 2003-03-24 Steven Munroe <sjmunroe@us.ibm.com>
8535 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
8536 (SINGLE_THREAD_P): Fix typo.
8537 * tst-cancel-wrappers.sh: Handle '.'ed symbols.
8539 2003-03-31 Ulrich Drepper <drepper@redhat.com>
8541 * Makefile (tests): Add tst-align.
8542 * tst-align.c: New file.
8543 * sysdeps/i386/Makefile: Define CFLAGS-tst-align.
8545 * sysdeps/i386/tls.h (CALL_THREAD_FCT): Align stack of called
8548 * tst-tsd2.c: Add casts to avoid warnings.
8550 2003-03-30 Ulrich Drepper <drepper@redhat.com>
8552 * descr.h (struct pthread): Move most often used elements to the front.
8554 2003-03-29 Ulrich Drepper <drepper@redhat.com>
8556 * Makefile (libpthread-routines): Add pthread_atfork.
8557 (libpthread-static-only-routines): Add pthread_atfork.
8559 2003-03-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
8561 * sysdeps/sh/tls.h: Include nptl/descr.h after the definition
8563 (INSTALL_DTV): Add parens.
8564 (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM, THREAD_SETMEM_NC):
8565 Use passed descr instead of THREAD_SELF.
8566 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S
8567 (__lll_mutex_timedlock_wait): Correct expected value after
8569 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S:
8570 Release lock before waking up the waiters.
8571 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Correct exit
8572 criteria. Reorderstruct passed to cleanup handler. Fix
8573 handling of cancellation and failung pthread_mutex_unlock call.
8574 Use __pthread_enable_asynccancel_2 instead of
8575 __pthread_enable_asynccancel.
8576 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
8577 Return result of lock re-get if it fails.
8578 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Fix wrong argument
8579 for __pthread_cleanup_push.
8580 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Fix
8581 completely broken rwlock implementation.
8582 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
8583 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
8584 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
8585 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
8586 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
8587 * sysdeps/unix/sysv/linux/sh/sem_post.S: Fix error value. Use
8588 versioned_symbol macro.
8589 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Use versioned_symbol macro.
8590 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Likewise.
8592 2003-03-27 Ulrich Drepper <drepper@redhat.com>
8594 * sysdeps/unix/sysv/linux/kernel-posix-timers.h: Don't declare
8595 __timer_helper_thread. Declare __start_helper_thread, __helper_once,
8597 (struct timer): Remove th and bar field.
8598 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Remove
8599 debugging code. Create only one helper thread.
8600 * sysdeps/unix/sysv/linux/timer_delete.c (timer_delete): Don't kill
8602 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
8603 Renamed. Define statically. Use thread info from siginfo.
8604 (__helper_once): New variable.
8605 (__helper_tid): New variable.
8606 (__reset_helper_control): New function.
8607 (__start_helper_thread): New function.
8609 * pthread_create.c (start_thread): Don't use setjmp inside
8610 __builtin_expect to work around gcc bug.
8612 * sysdeps/unix/sysv/linux/timer_delete.c (timer_delete): Even if
8613 timer_delete syscall fails, but not with ENOSYS, set
8616 * sysdeps/unix/sysv/linux/timer_settime.c [!__ASSUME_POSIX_TIMERS]
8617 (timer_settime): Fix typo.
8618 * sysdeps/unix/sysv/linux/timer_getoverr.c
8619 [!__ASSUME_POSIX_TIMERS] (timer_getoverrun): Likewise.
8621 2003-03-27 Jakub Jelinek <jakub@redhat.com>
8623 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Fix
8624 offset of cleanupbuf.__prev.
8626 2003-03-26 Jakub Jelinek <jakub@redhat.com>
8628 * sysdeps/unix/sysv/linux/timer_getoverr.c: Fix typo in name
8631 2003-03-26 Ulrich Drepper <drepper@redhat.com>
8633 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): If EVP ==
8634 NULL provide default definition to syscall.
8636 2003-03-25 Roland McGrath <roland@redhat.com>
8638 * sysdeps/pthread/posix-timer.h (TIMER_MAX): Define if not defined.
8639 (timer_id2ptr): Fix typo.
8641 2003-03-25 Ulrich Drepper <drepper@redhat.com>
8643 * pthreadP.h: Define SIGCANCEL and SIGTIMER.
8644 * sysdeps/i386/pthreaddef.h: Remove SIGCANCEL definition.
8645 * sysdeps/ia64/pthreaddef.h: Likewise.
8646 * sysdeps/powerpc/pthreaddef.h: Likewise.
8647 * sysdeps/s390/pthreaddef.h: Likewise.
8648 * sysdeps/sh/pthreaddef.h: Likewise.
8649 * sysdeps/x86_64/pthreaddef.h: Likewise.
8650 * init.c (__pthread_initialize_minimal): Block SIGTIMER.
8651 * sysdeps/pthread/sigaction.c: Also prevent SIGTIMER handler from
8653 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Make sure
8654 SIGTIMER is not unblocked.
8655 * sysdeps/unix/sysv/linux/allocrtsig.c (current_rtmin): One more
8657 * sysdeps/unix/sysv/linux/pthread_kill.c: Do not allow SIGTIMER to
8659 * sysdeps/pthread/posix-timer.h (timer_id2ptr, timer_ptr2id): Just
8660 pass pointer through as ID.
8661 * sysdeps/unix/sysv/linux/bits/local_lim.h (TIMER_MAX): Removed.
8662 * sysdeps/unix/sysv/linux/kernel-posix-timers.h: New file.
8663 * sysdeps/unix/sysv/linux/timer_create.c: New file.
8664 * sysdeps/unix/sysv/linux/timer_delete.c: New file.
8665 * sysdeps/unix/sysv/linux/timer_getoverr.c: New file.
8666 * sysdeps/unix/sysv/linux/timer_gettime.c: New file.
8667 * sysdeps/unix/sysv/linux/timer_routines.c: New file.
8668 * sysdeps/unix/sysv/linux/timer_settime.c: New file.
8669 * sysdeps/unix/sysv/linux/ia64/Versions: New file.
8670 * sysdeps/unix/sysv/linux/ia64/timer_create.c: New file.
8671 * sysdeps/unix/sysv/linux/ia64/timer_delete.c: New file.
8672 * sysdeps/unix/sysv/linux/ia64/timer_getoverr.c: New file.
8673 * sysdeps/unix/sysv/linux/ia64/timer_gettime.c: New file.
8674 * sysdeps/unix/sysv/linux/ia64/timer_settime.c: New file.
8675 * sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions: New file.
8676 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_create.c: New file.
8677 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_delete.c: New file.
8678 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_getoverr.c: New file.
8679 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_gettime.c: New file.
8680 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_settime.c: New file.
8681 * sysdeps/unix/sysv/linux/s390/s390-64/Versions: New file.
8682 * sysdeps/unix/sysv/linux/s390/s390-64/timer_create.c: New file.
8683 * sysdeps/unix/sysv/linux/s390/s390-64/timer_delete.c: New file.
8684 * sysdeps/unix/sysv/linux/s390/s390-64/timer_getoverr.c: New file.
8685 * sysdeps/unix/sysv/linux/s390/s390-64/timer_gettime.c: New file.
8686 * sysdeps/unix/sysv/linux/s390/s390-64/timer_settime.c: New file.
8687 * sysdeps/unix/sysv/linux/x86_64/Versions: New file.
8688 * sysdeps/unix/sysv/linux/x86_64/compat-timer.h: New file.
8689 * sysdeps/unix/sysv/linux/x86_64/timer_create.c: New file.
8690 * sysdeps/unix/sysv/linux/x86_64/timer_delete.c: New file.
8691 * sysdeps/unix/sysv/linux/x86_64/timer_getoverr.c: New file.
8692 * sysdeps/unix/sysv/linux/x86_64/timer_gettime.c: New file.
8693 * sysdeps/unix/sysv/linux/x86_64/timer_settime.c: New file.
8695 * pthreadP.h: Remove FRAME_LEFT definition.
8696 * cleanup.c (_pthread_cleanup_push): Don't check for reference to
8697 already left frame. Programs which have this problem are not POSIX
8699 * cleanup_defer.c (_pthread_cleanup_push_defer): Likewise.
8701 2003-03-24 Ulrich Drepper <drepper@redhat.com>
8703 * sysdeps/pthread/tst-timer.c: Check return values of the
8706 2003-03-23 Roland McGrath <roland@redhat.com>
8708 * tst-tls3.c (do_test) [! HAVE___THREAD]: Don't test anything.
8709 * tst-tls3mod.c: Likewise.
8710 * tst-tls1.c: Likewise.
8711 * tst-tls2.c: Likewise.
8713 * tst-mutex5.c (do_test): Unlock before destroy, otherwise we invoke
8716 * tst-join5.c (tf1, tf2): Add a cast.
8718 * Makeconfig (includes): Append -I$(..)nptl to this variable.
8720 * tst-barrier2.c (do_test) [! _POSIX_THREAD_PROCESS_SHARED]:
8721 Don't test anything.
8722 * tst-cond4.c: Likewise.
8723 * tst-cond6.c: Likewise.
8724 * tst-flock2.c: Likewise.
8725 * tst-mutex4.c: Likewise.
8726 * tst-rwlock4.c: Likewise.
8727 * tst-signal1.c: Likewise.
8728 * tst-spin2.c: Likewise.
8729 * tst-cond11.c [! _POSIX_CLOCK_SELECTION]: Likewise.
8731 * tst-mutex4.c: Use test-skeleton.c.
8732 * tst-spin2.c: Likewise.
8733 * tst-sysconf.c: Likewise.
8734 * tst-barrier2.c: Likewise.
8735 * tst-cond4.c: Likewise.
8736 * tst-cond6.c: Likewise.
8737 * tst-rwlock4.c: Likewise.
8738 * tst-unload.c: Likewise.
8739 * tst-flock2.c (do_test): Use return instead of exit.
8741 2003-03-22 Jakub Jelinek <jakub@redhat.com>
8743 * sysdeps/unix/sysv/linux/fork.c (__fork): Add libc_hidden_def.
8745 2003-03-21 Ulrich Drepper <drepper@redhat.com>
8747 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
8748 (__lll_mutex_trylock): Use atomic_compare_and_exchange_val_acq
8749 instead of __lll_compare_and_swap.
8750 * sysdeps/unix/sysv/linux/ia64/pthread_once.c (__pthread_once):
8752 Removed definition if __lll_compare_and_swap.
8754 * cancellation.c: Adjust for new form of compare&exchange macros.
8755 * cleanup_defer.c: Likewise.
8757 * libc-cancellation.c: Likewise.
8758 * old_pthread_cond_broadcast.c: Likewise.
8759 * old_pthread_cond_signal.c: Likewise.
8760 * old_pthread_cond_timedwait.c: Likewise.
8761 * old_pthread_cond_wait.c: Likewise.
8762 * pthread_cancel.c: Likewise.
8763 * pthread_create.c: Likewise.
8764 * pthread_detach.c: Likewise.
8765 * pthread_join.c: Likewise.
8766 * pthread_key_delete.c: Likewise.
8767 * pthread_setcancelstate.c: Likewise.
8768 * pthread_setcanceltype.c: Likewise.
8769 * pthread_timedjoin.c: Likewise.
8770 * pthread_tryjoin.c: Likewise.
8771 * sysdeps/pthread/createthread.c: Likewise.
8773 2003-03-20 Ulrich Drepper <drepper@redhat.com>
8775 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Include <atomic.h>.
8776 Remove __lll_add, __lll_dec_if_positive, and __lll_test_and_set
8777 definitions. Replace uses with calls to atomic_* functions.
8778 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
8779 * sysdeps/unix/sysv/linux/lowlevellock.c: Replace __lll_add and
8780 __lll_test_and_set calls with atomic_exchange_and_add and
8781 atomic_exchange calls respectively.
8782 * sysdeps/unix/sysv/linux/sem_post.c: Likewise.
8783 * sysdeps/unix/sysv/linux/sem_timedwait.c: Likewise.
8784 * sysdeps/unix/sysv/linux/sem_trywait.c: Likewise.
8785 * sysdeps/unix/sysv/linux/sem_wait.c: Likewise.
8786 * sysdeps/unix/sysv/linux/ia64/pthread_once.c: Likewise.
8787 * sysdeps/unix/sysv/linux/ia64/sem_port.c: Likewise.
8788 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c: Likewise.
8790 * allocatestack.c (allocate_stack): Assume atomic_exchange_and_add
8791 returns the old value.
8793 2003-03-20 Martin Schwidefsky <sky@mschwid3.boeblingen.de.ibm.com>
8795 * sysdeps/s390/pthread_spin_lock.c (pthread_spin_lock): Use type
8796 int for variable OLDVAL and correct inline assembler contraint.
8797 * sysdeps/s390/pthread_spin_trylock.c (pthread_spin_trylock): Use
8798 type int for variable OLD.
8800 * sysdeps/s390/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define it
8802 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
8803 (SINGLE_THREAD_P): Use global variable __local_multiple_threads
8804 instead of multiple_threads field in the TCB.
8806 2003-03-19 Ulrich Drepper <drepper@redhat.com>
8808 * sysdeps/i386/i686/bits/atomic.h: Removed.
8809 * sysdeps/i386/i586/bits/atomic.h: Removed.
8810 * sysdeps/i386/i486/bits/atomic.h: Removed. Moved to glibc.
8811 * sysdeps/x86_64/bits/atomic.h: Removed. Moved to glibc.
8812 * sysdeps/s390/bits/atomic.h: Removed. Moved to glibc.
8813 * sysdeps/sh/bits/atomic.h: Removed. Moved to glibc.
8814 * sysdeps/ia64/bits/atomic.h: Removed. Moved to glibc.
8815 * sysdeps/powerpc/bits/atomic.h: Removed. Moved to glibc.
8816 * atomic.h: Removed. Moved to glibc.
8818 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Add
8819 support for clock selection.
8821 * sysdeps/pthread/pthread_cond_broadcast.c: Release lock before
8824 2003-03-18 Roland McGrath <roland@redhat.com>
8826 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (__lll_test_and_set):
8827 Add __lll_rel_instr first. Add memory clobber.
8828 (lll_mutex_unlock): Use __lll_test_and_set.
8829 From Paul Mackerras <paulus@samba.org>.
8831 * sysdeps/powerpc/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define
8833 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
8834 (SINGLE_THREAD_P): Add `header.' prefix.
8835 From Paul Mackerras <paulus@samba.org>.
8837 * Versions (libpthread: GLIBC_2.3.2): Move pthread_tryjoin_np and
8838 pthread_timedjoin_np to ...
8839 (libpthread: GLIBC_2.3.3): ... here.
8840 (libpthread: GLIBC_2.2): Move pthread_barrierattr_getpshared there too.
8842 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
8843 Avoid shadowing VAL variable.
8845 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (__lll_test_and_set):
8848 2003-03-18 Ulrich Drepper <drepper@redhat.com>
8850 * Makefile (tests): Add tst-cond11.
8851 * tst-cond11.c: New file.
8853 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Reorder
8854 struct passed to cleanup handler to eliminate one more
8856 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
8858 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
8859 (pthrad_cond_t): Replace __unused field with __clock.
8861 * sysdeps/pthread/pthread_cond_wait.c: Release condvar lock before
8862 waken all waiters in cleanup handler.
8863 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
8864 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
8866 * pthread_condattr_getclock.c: New file.
8867 * pthread_condattr_setclock.c: New file.
8868 * sysdeps/pthread/pthread.h: Declare these new functions.
8869 * Versions [GLIBC_2.3.3] (libpthread): Add the new functions.
8870 * Makefile (libpthread-routines): Add the new functions.
8871 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_condattr):
8872 Renamed field to value. Document use of the bits.
8873 * pthread_condattr_getpshared.c: Adjust for struct pthread_condattr
8875 * pthread_condattr_setpshared.c: Likewise.
8876 * pthread_cond_init.c (__pthread_cond_init): Initialized __clock field.
8877 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Add cond_clock symbol.
8878 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
8880 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
8881 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
8882 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
8883 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
8884 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
8885 Implement clock selection.
8886 * sysdeps/pthread/pthread_cond_timedwait.c: Likewise.
8887 * pthread-errnos.sym: Add ENOSYS.
8888 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
8889 _POSIX_CLOCK_SELECTION.
8890 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
8892 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Remove
8893 invalid .size directive.
8895 2003-03-17 Roland McGrath <roland@redhat.com>
8897 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait):
8900 2003-03-17 Ulrich Drepper <drepper@redhat.com>
8902 * sysdeps/unix/sysv/linux/ia64/pthread_once.c: Use __builtin_expect.
8903 Use __lll_add instead of spelling it out. Use protected symbol names.
8904 * sysdeps/unix/sysv/linux/ia64/sem_post.c: Use __builtin_expect.
8906 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_compare_and_swap):
8907 Renamed from lll_compare_and_swap. Use new name where necessary.
8908 (__lll_add): Defined.
8909 (__lll_dec_if_positive): Defined.
8910 (__lll_test_and_set): Defined.
8911 * sysdeps/ia64/pthread_spin_init.c: Removed.
8912 * sysdeps/unix/sysv/linux/ia64/lowlevelmutex.c: Removed.
8913 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: Removed.
8914 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: Removed.
8915 * sysdeps/unix/sysv/linux/ia64/lowlevellock.c: Removed.
8916 * sysdeps/unix/sysv/linux/ia64/libc-lowlevellock.c: Removed.
8917 * sysdeps/unix/sysv/linux/ia64/libc-lowlevelmutex.c: Removed.
8918 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: Removed.
8919 * sysdeps/ia64/bits/atomic.h: Add __builtin_expect where appropriate.
8920 * sysdeps/ia64/pthread_spin_unlock.c (pthread_spin_unlock): Use
8921 __sync_lock_release_si.
8922 Patch by Jakub Jelinek.
8924 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait):
8925 Fix timeout handling.
8926 (__lll_timedwait_tid): Likewise.
8927 (lll_unlock_wake_cb): Wake up other waiters if necessary.
8928 Patch by Jakub Jelinek.
8930 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Pretty printing.
8932 2003-03-17 Roland McGrath <roland@redhat.com>
8934 PowerPC port contributed by Paul Mackerras <paulus@samba.org>.
8935 * sysdeps/pthread/pthread_spin_init.c: New file.
8936 * sysdeps/pthread/pthread_spin_unlock.c: New file.
8937 * sysdeps/powerpc/Makefile: New file.
8938 * sysdeps/powerpc/pthread_spin_lock.c: New file.
8939 * sysdeps/powerpc/pthread_spin_trylock.c: New file.
8940 * sysdeps/powerpc/pthreaddef.h: New file.
8941 * sysdeps/powerpc/tcb-offsets.sym: New file.
8942 * sysdeps/powerpc/td_ta_map_lwp2thr.c: New file.
8943 * sysdeps/powerpc/tls.h: New file.
8944 * sysdeps/powerpc/bits/atomic.h: New file.
8945 * sysdeps/unix/sysv/linux/libc-lowlevelmutex.c: New file.
8946 * sysdeps/unix/sysv/linux/libc-lowlevellock.c: New file.
8947 * sysdeps/unix/sysv/linux/lowlevellock.c: New file.
8949 * sysdeps/unix/sysv/linux/lowlevelmutex.c: New file.
8950 * sysdeps/unix/sysv/linux/sem_post.c: New file.
8951 * sysdeps/unix/sysv/linux/sem_timedwait.c: New file.
8952 * sysdeps/unix/sysv/linux/sem_trywait.c: New file.
8953 * sysdeps/unix/sysv/linux/sem_wait.c: New file.
8954 * sysdeps/unix/sysv/linux/powerpc/Makefile: New file.
8955 * sysdeps/unix/sysv/linux/powerpc/createthread.c: New file.
8956 * sysdeps/unix/sysv/linux/powerpc/fork.c: New file.
8957 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: New file.
8958 * sysdeps/unix/sysv/linux/powerpc/pt-vfork.S: New file.
8959 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c: New file.
8960 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: New file.
8961 * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: New file.
8962 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: New file.
8963 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: New file.
8965 * sysdeps/unix/sysv/linux/ia64/lowlevellock.c: Use __gettimeofday,
8967 * sysdeps/unix/sysv/linux/ia64/lowlevelmutex.c: Likewise.
8968 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: Likewise.
8969 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Likewise.
8970 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c: Likewise.
8971 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
8973 2003-03-17 Ulrich Drepper <drepper@redhat.com>
8975 * sysdeps/pthread/pthread_cond_wait.c: Correct exit criteria.
8976 * sysdeps/pthread/pthread_cond_timedwait.c: Likewise.
8977 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
8978 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
8979 Patch by Ewald Snel <ewald@rambo.its.tudelft.nl>.
8981 2003-03-16 Roland McGrath <roland@redhat.com>
8983 * tst-fork4.c: Include <string.h>.
8984 * tst-signal2.c: Likewise.
8985 * tst-mutex5.c (do_test): exit -> return.
8986 * tst-mutex2.c: Include <stdlib.h>.
8988 2003-03-16 Ulrich Drepper <drepper@redhat.com>
8990 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S
8991 (__lll_mutex_timedlock_wait): Correct expected value after
8992 spurious wakeup. Otherwise we would never wait again.
8994 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Work around red
8995 zone versus inline asm stupidity. Use correct instructions.
8997 * tst-rwlock6.c: Add some more status output.
8999 2003-03-15 Roland McGrath <roland@redhat.com>
9001 * sysdeps/pthread/configure.in: New file.
9002 * sysdeps/pthread/configure: New file (generated).
9004 2003-03-15 Ulrich Drepper <drepper@redhat.com>
9006 * allocatestack.c (allocate_stack): Store the exact stack size of
9007 user allocated stacks.
9009 2003-03-15 Jakub Jelinek <jakub@redhat.com>
9011 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
9012 (SINGLE_THREAD): Use `header' prefix instead of `header.data'.
9013 * sysdeps/sh/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Likewise.
9014 * sysdeps/sh/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define.
9015 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SINGLE_THREAD_P):
9016 Use `header.' prefix.
9017 * sysdeps/ia64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Likewise.
9019 2003-03-15 Ulrich Drepper <drepper@redhat.com>
9021 * sysdeps/x86_64/pthreaddef.h (CURRENT_STACK_FRAME): Don't use
9022 __builtin_frame_address, use stack pointer.
9024 * sysdeps/unix/sysv/linux/jmp-unwind.c: Use CURRENT_STACK_FRAME
9025 instead of __builtin_frame_pointer.
9027 2003-03-14 Ulrich Drepper <drepper@redhat.com>
9029 * tst-basic1.c (do_test): Add cast to avoid warning.
9030 * tst-basic2.c (do_test): Likewise.
9032 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Use correct
9033 amount of stack correction.
9035 * tst-fork4.c: Use test-skeleton.c.
9037 2003-03-14 Roland McGrath <roland@redhat.com>
9039 * init.c: Fix typo "#eli" for "#else".
9041 2003-03-14 Steven Munroe <sjmunroe@us.ibm.com>
9043 * allocatestack.c (__stack_user): Use hidden_data_def.
9044 * pthread_create.c (__pthread_keys): Likewise.
9046 * init.c [__powerpc__] (__NR_set_tid_address): Define it.
9048 2003-03-14 Roland McGrath <roland@redhat.com>
9050 * tst-fork4.c: New file.
9051 * Makefile (tests): Add it.
9053 * descr.h (struct pthread): Move the union out of [!TLS_DTV_AT_TP], so
9054 we always define the padding space.
9055 [!TLS_DTV_AT_TP]: Give tcbhead_t field a name, `header', since GCC
9056 stopped supporting its own extensions fully.
9057 [TLS_MULTIPLE_THREADS_IN_TCB]: Put `multiple_threads' inside a wrapper
9058 struct also called `header', so `header.multiple_threads' is the field
9059 name to use on all machines.
9060 * allocatestack.c (allocate_stack): Use `header.' prefix.
9061 * sysdeps/pthread/createthread.c (create_thread): Likewise.
9062 * pthread_create.c (__pthread_create_2_1): Likewise.
9063 * sysdeps/i386/tls.h (INSTALL_NEW_DTV, THREAD_DTV): Likewise.
9064 (THREAD_SELF): Likewise.
9065 * sysdeps/x86_64/tls.h: Likewise.
9066 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
9067 (SINGLE_THREAD_P): Likewise.
9068 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
9069 (SINGLE_THREAD_P): Likewise.
9070 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
9071 (SINGLE_THREAD_P): Likewise.
9073 * sysdeps/s390/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Use REGS[18]
9076 2003-03-14 Ulrich Drepper <drepper@redhat.com>
9078 * pthread_create.c (start_thread): Use CALL_THREAD_FCT if defined.
9079 * sysdeps/i386/tls.h: Define CALL_THREAD_FCT.
9081 * pthread_create.c (start_thread): setjmp is expected to return 0.
9083 * sysdeps/x86_64/tls.h (THREAD_GETMEM): Mark asms volatile.
9084 (THREAD_GETMEM_NC): Likewise.
9086 2003-03-13 Ulrich Drepper <drepper@redhat.com>
9088 * allocatestack.c (allocate_stack): If MULTI_PAGE_ALIASING is defined
9089 and the size of the stack which must be allocated is a multiple,
9090 allocate one more page.
9091 * sysdeps/i386/i686/Makefile: Don't define COLORING_INCREMENT, but
9092 MULTI_PAGE_ALIASING.
9094 2003-03-13 Roland McGrath <roland@redhat.com>
9096 * pthread_create.c (start_thread): Set EXITING_BIT after the
9097 event-reporting (and destructors), not before.
9099 2003-03-13 Jakub Jelinek <jakub@redhat.com>
9101 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_timed_wait,
9102 lll_futex_wake): Declare register variables as long int instead of
9103 unsigned long int. Patch by Ian Wienand <ianw@gelato.unsw.edu.au>.
9104 Make syscall arguments clobbered by the syscall.
9105 (lll_futex_wait): Define using lll_futex_timed_wait.
9107 * sysdeps/ia64/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Cast regs[13]
9110 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Only declare and set
9113 * allocatestack.c (nptl_ncreated): Only declare if
9114 COLORING_INCREMENT != 0.
9116 * pthreadP.h (__pthread_enable_asynccancel_2): New prototype.
9117 (__libc_enable_asynccancel_2): Remove prototype.
9119 * sysdeps/unix/sysv/linux/ia64/fork.c (ARCH_FORK): Swap ptid and
9120 ctid to match kernel.
9122 2003-03-12 Ulrich Drepper <drepper@redhat.com>
9124 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Add
9125 libc_multiple_threads.
9126 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Move definition of
9127 __libc_multiple_threads to...
9128 * sysdeps/unix/sysv/linux/libc_multiple_threads.c: ...here. New file.
9130 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Remove unnecessary
9132 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
9133 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
9135 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S
9136 (__pthread_once_internal): Define.
9138 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Use shlib-compat.h
9139 macros instead of .symver directly.
9140 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
9141 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
9143 * sysdeps/x86_64/tls.h [__ASSEMBLER__]: Include tcb-offsets.h.
9144 * sysdeps/x86_64/tcb-offsets.sym: New file.
9145 * sysdeps/x86_64/Makefile: New file.
9147 * sysdeps/i386/tcb-offsets.sym: Add SELF.
9148 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Use SELF
9149 to access own pthread_t in TCB.
9150 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
9152 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
9154 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
9156 2003-03-12 Roland McGrath <roland@redhat.com>
9158 * pthread-errnos.sym: New file.
9159 * Makefile (gen-as-const-headers): New variable, list that file.
9160 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Include generated
9161 header <pthread-errnos.h> instead of defining errno values here.
9162 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
9163 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
9164 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
9165 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
9166 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
9168 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
9170 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
9171 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9172 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
9173 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
9174 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
9175 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
9176 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
9177 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
9178 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
9179 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Likewise.
9180 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
9181 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Likewise.
9182 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
9183 * sysdeps/unix/sysv/linux/sh/sem_post.S: Likewise.
9184 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Likewise.
9185 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
9186 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
9187 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
9188 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
9189 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
9190 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
9191 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Likewise.
9192 * sysdeps/i386/i486/pthread_spin_trylock.S: Likewise.
9193 * sysdeps/x86_64/pthread_spin_trylock.S: Likewise.
9194 * sysdeps/sh/pthread_spin_trylock.S: Likewise.
9195 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
9196 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
9198 * sysdeps/unix/sysv/linux/fork.c: Add an assert to check that
9199 CLONE_CHILD_SETTID worked.
9201 2003-03-12 Ulrich Drepper <drepper@redhat.com>
9203 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S: New
9205 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S: New
9208 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
9209 (pthread_cond_t): Add padding.
9211 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: New file.
9212 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: New file.
9213 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: New file.
9215 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
9216 (__pthread_rwlock_timedwrlock): Add missing opcode suffix.
9217 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
9218 (__pthread_rwlock_timedrdlock): Likewise.
9219 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S
9220 (__pthread_rwlock_wrlock): Likewise.
9221 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S
9222 (__pthread_rwlock_rdlock): Likewise.
9224 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: New file.
9226 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Return
9227 result of lock re-get if it fails.
9229 2003-03-11 Ulrich Drepper <drepper@redhat.com>
9231 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Fix asm syntax.
9232 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
9233 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Likewise.
9234 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
9235 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
9236 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
9237 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
9238 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
9239 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
9240 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
9242 * sysdeps/x86_64/tls.h (THREAD_SELF, THREAD_GETMEM, THREAD_GETMEM_NC,
9243 THREAD_SETMEM, THREAD_SETMEM_NC): Correct asm syntax.
9245 * allocatestack.c [! TLS_MULTIPLE_THREADS_IN_TCB] (allocate_stack):
9246 Initialize *__libc_multiple_threads_ptr not __libc_multiple_threads.
9247 * sysdeps/pthread/createthread.c [! TLS_MULTIPLE_THREADS_IN_TCB]
9248 (create_thread): Likewise.
9249 Define __pthread_multiple_threads and __libc_multiple_threads_ptr.
9250 * init.c (__pthread_initialize_minimal_internal): Initialize
9251 __libc_multiple_threads_ptr if necessary.
9252 * pthreadP.h: Adjust prototype for __libc_pthread_init. Declare
9253 __pthread_multiple_threads and __libc_multiple_threads_ptr.
9254 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Define
9255 __libc_multiple_threads.
9256 (__libc_pthread_init): Return pointer to __libc_pthread_init if
9259 * sysdeps/i386/tls.h (THREAD_SETMEM): Fix one-byte variant.
9260 (THREAD_SETMEM_NC): Likewise.
9262 * sysdeps/x86_64/pthread_spin_trylock.c: Removed.
9263 * sysdeps/x86_64/pthread_spin_trylock.S: New file.
9264 * sysdeps/x86_64/pthread_spin_unlock.c: Removed.
9265 * sysdeps/x86_64/pthread_spin_unlock.S: New file.
9267 * sysdeps/i386/i486/pthread_spin_trylock.S (pthread_spin_trylock):
9268 Eliminate one entire instruction.
9270 * cancellation.c (__pthread_enable_asynccancel_2): New function.
9271 * pthreadP.h: Declare __pthread_enable_asynccancel_2.
9272 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
9273 (__pthread_cond_timedwait): Use __pthread_enable_asynccancel_2
9274 instead of __pthread_enable_asynccancel.
9275 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
9276 (__pthread_cond_wait): Likewise.
9277 * sysdeps/pthread/pthread_cond_timedwait.c
9278 (__pthread_cond_timedwait): Likewise.
9279 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
9281 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
9282 (__condvar_cleanup): Wake up all waiters in case we got signaled
9283 after being woken up but before disabling asynchronous
9285 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Likewise.
9286 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
9287 (__condvar_cleanup): Likewise.
9289 * init.c (__NR_set_tid_address): If already defined, don't redefine.
9290 Make it an error if architecture has no #if case. Add x86-64.
9292 * sysdeps/unix/sysv/linux/x86_64/Makefile: Add flags for
9293 pt-initfini.s generation.
9295 * sysdeps/x86_64/tls.h: Include <asm/prctl.h>.
9296 (TLS_INIT_TP): Fix typo.
9298 2003-03-11 Jakub Jelinek <jakub@redhat.com>
9300 * sysdeps/ia64/bits/atomic.h (atomic_exchange_and_add): Swap 2nd and
9301 3rd argument of __arch_compare_and_exchange_{32,64}_val_acq.
9303 * sysdeps/unix/sysv/linux/ia64/sem_post.c: Include semaphore.h.
9304 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: Likewise.
9305 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: Likewise.
9306 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: Likewise.
9307 * sysdeps/unix/sysv/linux/s390/sem_post.c: Likewise.
9308 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
9309 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Likewise.
9310 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Likewise.
9312 2003-03-11 Ulrich Drepper <drepper@redhat.com>
9314 * sysdeps/pthread/pthread_cond_timedwait.c
9315 (__pthread_cond_timedwait): Return the result of the final
9316 locking. If it succeeds, the regular function return value.
9318 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait):
9319 Return result of the final locking.
9320 * version.c (__nptl_main): Work around problems with the strange
9321 INTERNAL_SYSCALL macro on ppc32.
9322 * init.c (__pthread_initialize_minimal_internal): Unblock
9323 SIGCANCEL in case the parent blocked it.
9324 Reported by Paul Mackerras <paulus@samba.org>.
9326 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: New file.
9327 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: New file.
9328 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: New file.
9330 2003-03-11 Jakub Jelinek <jakub@redhat.com>
9332 * sysdeps/pthread/pthread_cond_timedwait.c
9333 (__pthread_cond_timedwait): Unlock and fail if
9334 __pthread_mutex_unlock_internal failed.
9336 * sysdeps/pthread/createthread.c (ARCH_CLONE): Define if not defined.
9337 (create_thread): Only assert PD->tcb != NULL under [TLS_TCB_AT_TP].
9339 * allocatestack.c (ALLOCATE_STACK_PARMS): New macro.
9340 [NEED_SEPARATE_REGISTER_STACK] (STACK_VARIABLES,
9341 STACK_VARIABLES_ARGS, STACK_VARIABLES_PARMS, ALLOCATE_STACK_PARMS,
9342 ALLOCATE_STACK): New macros.
9343 (TLS_TPADJ): New macro.
9344 (get_cached_stack, queue_stack, __deallocate_stack): Use TLS_TPADJ.
9345 (allocate_stack): Handle TLS_DTV_AT_TP and
9346 NEED_SEPARATE_REGISTER_STACK. Use TLS_TPADJ.
9347 * pthread_create.c (__pthread_create_2_1) [! TLS_TCB_AT_TP]:
9349 * init.c [__ia64__] (__NR_set_tid_address): Define.
9351 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: New file.
9352 * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: New file.
9353 * sysdeps/unix/sysv/linux/ia64/fork.c: New file.
9354 * sysdeps/unix/sysv/linux/ia64/createthread.c: New file.
9355 * sysdeps/unix/sysv/linux/ia64/libc-lowlevellock.c: New file.
9356 * sysdeps/unix/sysv/linux/ia64/libc-lowlevelmutex.c: New file.
9357 * sysdeps/unix/sysv/linux/ia64/lowlevellock.c: New file.
9358 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: New file.
9359 * sysdeps/unix/sysv/linux/ia64/lowlevelmutex.c: New file.
9360 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: New file.
9361 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: New file.
9362 * sysdeps/unix/sysv/linux/ia64/pthread_once.c: New file.
9363 * sysdeps/unix/sysv/linux/ia64/sem_post.c: New file.
9364 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: New file.
9365 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: New file.
9366 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: New file.
9367 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: New file.
9368 * sysdeps/ia64/bits/atomic.h: New file.
9369 * sysdeps/ia64/Makefile: New file.
9370 * sysdeps/ia64/pthread_spin_init.c: New file.
9371 * sysdeps/ia64/pthread_spin_lock.c: New file.
9372 * sysdeps/ia64/pthread_spin_trylock.c: New file.
9373 * sysdeps/ia64/pthread_spin_unlock.c: New file.
9374 * sysdeps/ia64/pthreaddef.h: New file.
9375 * sysdeps/ia64/tcb-offsets.sym: New file.
9376 * sysdeps/ia64/td_ta_map_lwp2thr.c: New file.
9377 * sysdeps/ia64/tls.h: New file.
9379 * sysdeps/s390/pthreaddef.h (__exit_thread_inline): Pass 1 argument
9380 to syscall instead of no arguments.
9382 2003-03-10 Ulrich Drepper <drepper@redhat.com>
9384 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: New file.
9385 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: New file.
9386 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: New file.
9387 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: New file.
9389 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Fix error value in
9392 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: New file
9394 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
9395 lowlevelbarrier.sym.
9396 * sysdeps/unix/sysv/linux/lowlevelbarrier.sym: New file.
9397 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S:
9398 Include lowlevelbarrier.h and don't define offsets locally.
9399 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Likewise.
9401 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
9402 (__lll_mutex_lock_wait): Reverse order of first two parameters.
9403 (__lll_mutex_timedlock_wait): Likewise.
9404 (lll_mutex_lock): Adjust asm for that.
9405 (lll_mutex_timedlock): Likewise. Mark cx, cc, r10 as clobbered.
9406 (lll_lock): Adjust asm for operand order change.
9407 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: New file.
9408 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevelmutex.S: New file.
9410 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (__lll_lock_wait):
9411 Reverse order of parameters.
9412 (__lll_timedwait_tid): Remove regparms attribute.
9413 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: New file.
9414 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: New file.
9416 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
9417 (__lll_timedwait_tid): Remove one unnecessary instruction.
9419 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Define
9420 __lll_mutex_timedlock_wait only for NOT_IN_libc.
9421 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: Include
9424 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Define
9425 lll_unlock_wake_cb, __lll_wait_tid, and __lll_timedwait_tid only
9427 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Include
9430 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Don't define
9431 LOCK is already defined. Don't define __lll_mutex_timedlock_wait
9433 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Only
9434 define LOCK here (if UP is not defined). The actual code is in
9437 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Don't define
9438 LOCK is already defined. Don't define lll_unlock_wake_cb and
9439 __lll_timedwait_tid for libc.so.
9440 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Only
9441 define LOCK here (if UP is not defined). The actual code is in
9444 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Not needed anymore.
9445 * sysdeps/unix/sysv/linux/s390/lowlevelsem.h: Likewise.
9446 * sysdeps/unix/sysv/linux/s390/sem_post.c: Include lowlevellock.h
9447 instead of lowlevelsem.h.
9448 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
9449 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Likewise.
9450 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Likewise.
9452 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
9454 * sysdeps/unix/sysv/linux/lowlevelrwlock.sym: New file.
9455 * sysdeps/unix/sysv/linux/i386/lowlevelrwlock.h: Removed.
9456 * sysdeps/unix/sysv/linux/sh/lowlevelrwlock.h: Removed.
9458 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_trylock): Fix
9460 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_trylock): Undo
9463 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: New file.
9465 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove declaration
9466 of __libc_locking_needed.
9467 (lll_trylock): Initialize %eax to zero.
9469 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Update
9470 pthread_cond_t definition.
9472 2003-03-10 Roland McGrath <roland@redhat.com>
9474 * sysdeps/unix/sysv/linux/lowlevelcond.sym: New file.
9475 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add it.
9476 * sysdeps/unix/sysv/linux/sh/lowlevelcond.h: File removed.
9477 * sysdeps/unix/sysv/linux/i386/lowlevelcond.h: Likewise.
9478 * sysdeps/unix/sysv/linux/x86_64/lowlevelcond.h: Likewise.
9480 * allocatestack.c (allocate_stack) [!TLS_MULTIPLE_THREADS_IN_TCB]:
9481 Instead of setting PD->multiple_threads, set globals
9482 __pthread_multiple_threads and __libc_multiple_threads.
9483 * sysdeps/pthread/createthread.c (create_thread): Likewise.
9484 * sysdeps/i386/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define it.
9485 * sysdeps/s390/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Likewise.
9487 * descr.h (struct pthread): Conditionalize first member on
9488 [!TLS_DTV_AT_TP]. Replace the `header' member with an anonymous union
9489 containing an anonymous tcbhead_t. Move `list' member out.
9490 [TLS_MULTIPLE_THREADS_IN_TCB]: Define a `multiple_threads' member.
9491 * allocatestack.c: Remove use of `header.data.' prefix.
9492 * pthread_create.c: Likewise.
9493 * init.c (__pthread_initialize_minimal_internal): Likewise.
9494 * sysdeps/pthread/createthread.c (create_thread): Likewise.
9495 * sysdeps/i386/tls.h (INSTALL_DTV): Add parens.
9496 (THREAD_SELF, THREAD_DTV, INSTALL_NEW_DTV): No `header.data.' prefix.
9497 * sysdeps/x86_64/tls.h: Likewise.
9498 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
9499 (SINGLE_THREAD_P): Likewise.
9500 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
9501 (SINGLE_THREAD_P): Likewise.
9502 * sysdeps/i386/tls.h (tcbhead_t): Remove `list' member.
9503 * sysdeps/s390/tls.h (tcbhead_t): Likewise.
9505 2003-03-09 Ulrich Drepper <drepper@redhat.com>
9507 * sysdeps/unix/sysv/linux/x86_64/lowlevelcond.h: New file.
9509 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: New file.
9510 * sysdeps/unix/sysv/linux/x86_64/fork.c: New file.
9512 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Fix many
9513 leftovers from the ia32 code.
9515 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Remove unneccessary
9517 (clear_once_control): Don't load %esi.
9519 * sysdeps/x86_64/tls.h: Remove all traces of segment descriptor
9522 * sysdeps/unix/sysv/linux/x86_64/fork.c: New file.
9524 * sysdeps/unix/sysv/linux/s390/createthread.c: Moved to...
9525 * sysdeps/unix/sysv/linux/createthread.c: ...here.
9527 * Makefile (tests): Add tst-cond10.
9528 * tst-cond10.c: New file.
9530 2003-03-08 Ulrich Drepper <drepper@redhat.com>
9532 * tst-tls2.c (do_test): Add TEMP_FAILURE_RETRY around sem_wait call.
9533 * tst-signal3.c (do_test): Likewise.
9534 * tst-sem5.c (do_test): Likewise.
9535 * tst-kill6.c (do_test): Likewise.
9536 * tst-tls3.c (do_test): Likewise. Include <errno.h>.
9538 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use add/sub instead
9540 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Likewise.
9541 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise
9542 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
9543 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
9544 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
9545 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
9546 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
9548 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
9550 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
9551 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
9552 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9553 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
9554 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
9555 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
9556 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
9557 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
9559 * allocatestack.c (allocate_stack): If mprotect() fails free the
9562 2003-03-07 Ulrich Drepper <drepper@redhat.com>
9564 * sysdeps/i386/i486/bits/atomic.h: Fix a few unused definitions.
9566 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove all trace of
9567 lll_wake_tid. This was used only to work around kernel limits in
9569 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
9570 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Likewise.
9571 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
9572 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
9574 * init.c (__static_tls_align_m1): Renamed from __static_tls_align.
9575 (__pthread_initialize_minimal_internal): Change initialization of
9576 __static_tls_align_m1 appropriately.
9577 * pthreadP.h (__static_tls_align_m1): Renamed from
9579 * allocatestack.c (allocate_stack): Use __static_tls_align_m1
9580 instead of __static_tls_align-1.
9582 2003-03-04 Ulrich Drepper <drepper@redhat.com>
9584 * sysdeps/unix/sysv/linux/x86_64/Makefile: New file.
9586 * pthread_create.c: Define __pthread_keys using nocommon
9587 attribute, not by placing it explicitly in bss.
9588 Remove DEFINE_DEALLOC definition. Not needed anymore.
9590 * allocatestack.c: Define ARCH_MAP_FLAGS if not already defined.
9591 Use it in mmap call to allocate stacks.
9593 * sysdeps/pthread/createthread.c (create_thread): Fix comment.
9595 * pthread_create.c (start_thread): Use THREAD_SETMEM to store
9596 result of the thread function.
9598 2003-03-03 Ulrich Drepper <drepper@redhat.com>
9600 * sysdeps/unix/sysv/linux/s390/dl-sysdep.h: Removed. The generic
9601 version is just fine.
9603 * sysdeps/unix/sysv/linux/libc_pthread_init.c
9604 (__pthread_child_handler): Renamed from pthread_child_handler,
9605 exported, and marked hidden. Change all users.
9606 * sysdeps/unix/sysv/linux/register-atfork.c (free_mem): Do not
9607 free __pthread_child_handler from child list.
9609 2003-03-03 Martin Schwidefsky <schwidefsky@de.ibm.com>
9611 * atomic.h (atomic_exchange_and_add): Return newval, not oldval.
9613 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
9614 Fix handling of cancellation and failing pthread_mutex_unlock call.
9615 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Likewise.
9616 (__pthread_cond_wait): Likewise.
9618 * sysdeps/pthread/pthread_rwlock_timedrdlock.c
9619 (pthread_rwlock_timedrdlock): Fix clobber of result variable by
9620 lll_futex_timed_wait call.
9621 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
9622 (pthread_rwlock_timedwrlock): Likewise.
9624 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c (___lll_lock):
9625 Don't define lll_unlock_wake_cb and ___lll_timedwait_tid in libc.so.
9626 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Remove XXX comments.
9628 * sysdeps/unix/sysv/linux/s390/sem_post.c (__new_sem_post): Fix
9629 check of lll_futex_wake return value.
9631 2003-03-03 Roland McGrath <roland@redhat.com>
9633 * forward.c: Fix typo in __pthread_attr_init_2_0 compat_symbol decl.
9635 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
9636 Argument to ptr___pthread_cleanup_upto is __jmp_buf, not jmp_buf.
9637 * sysdeps/unix/sysv/linux/jmp-unwind.c: Likewise.
9639 2003-03-02 Ulrich Drepper <drepper@redhat.com>
9641 * sysdeps/pthread/timer_create.c (timer_create): Return correct
9642 error for CPU clocks.
9644 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
9645 _POSIX_MONOTONIC_CLOCK.
9646 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
9648 * tst-cancel4.c (tf_sleep): Lower sleep time a bit to not upset
9651 2003-03-01 Ulrich Drepper <drepper@redhat.com>
9653 * descr.h (struct pthread): Move cleanup field to the front.
9655 2003-03-01 Roland McGrath <roland@redhat.com>
9657 * sem_open.c (sem_open): Braino fix.
9659 2003-03-01 Ulrich Drepper <drepper@redhat.com>
9661 * sysdeps/i386/tcb-offsets.sym: Add CLEANUP and CLEANUP_PREV.
9662 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Inline
9663 __pthread_cleanup_pop functionality.
9664 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9666 * descr.h (struct pthread): Move tid field to the front now that
9669 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S
9670 (__lll_mutex_timedlock_wait): Remove.
9671 (__lll_mutex_unlock_wake): Don't save, load, and restore %esi.
9672 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S
9673 (__lll_mutex_unlock_wake): Don't save, load, and restore %esi.
9674 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
9675 (lll_unlock_wake_cb): Don't save and restore %esi.
9676 (__lll_unlock_wake): Add alignment. Don't save, load, and restore
9678 (__lll_timedwait_tid): Add alignment.
9679 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S
9680 (__lll_unlock_wake): Add alignment. Don't save, load, and restore
9682 (__lll_timedwait_tid): Removed.
9683 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
9684 (__pthread_cond_broadcast): Don't save, load, and restore %esi.
9685 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
9686 (pthread_barrier_wait): Don't save, load, and restore %esi for
9688 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
9689 (__pthread_cond_signal): Don't save, load, and restore %esi.
9690 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
9691 (__pthread_rwlock_unlock): Don't save, load, and restore %esi.
9692 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__new_sem_post):
9693 Don't save, load, and restore %esi.
9695 2003-02-27 Ulrich Drepper <drepper@redhat.com>
9697 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S:
9698 Release lock before waking up the waiters.
9700 * tst-exit1.c (do_test): Don't start more than one thread in parallel.
9702 * tst-rwlock9.c (writer_thread): Correct adding TIMEOUT.
9703 (reader_thread): Likewise.
9705 * sysdeps/pthread/pthread_rwlock_unlock.c
9706 (__pthread_rwlock_unlock): Release internal lock early. Don't try
9707 to wake up readers if there are none.
9709 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
9710 Release internal lock before wake threads.
9712 2003-02-26 Ulrich Drepper <drepper@redhat.com>
9714 * Makefile (tests): Add tst-rwlock10 and tst-rwlock11.
9715 * tst-rwlock8.c: Initialize lock with INIT. Allow INIT to be
9717 * tst-rwlock9.c: Likewise.
9718 * tst-rwlock10.c: New file.
9719 * tst-rwlock11.c: New file.
9721 * Makefile (tests): Add tst-dlsym1.
9722 * tst-dlsym1.c: New file.
9724 * init.c (__pthread_initialize_minimal_internal): Set
9725 GL(dl_error_catch_tsd) to __libc_dl_error_tsd.
9726 * Versions (libc:GLIBC_PRIVATE): Export __libc_dl_error_tsd.
9728 2003-02-24 Ulrich Drepper <drepper@redhat.com>
9730 * sem_open.c (sem_open): Fix handling of O_CREAT without O_EXCL.
9732 * tst-cond2.c: Fix sychronization with child.
9734 * tst-rwlock8.c (reader_thread): Remove unused variable.
9736 * Makefile: Add rules to build and run tst-tls3.
9737 * tst-tls3.c: New file.
9738 * tst-tls3mod.c: New file.
9740 * Makefile (tests): Add tst-rwlock8 and tst-rwlock9.
9741 * tst-rwlock8.c: New file.
9742 * tst-rwlock9.c: New file.
9743 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Fix
9744 complete broken rwlock implementation.
9745 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
9747 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
9749 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
9750 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
9751 * sysdeps/pthread/pthread_rwlock_rdlock.c: Likewise.
9752 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Likewise.
9753 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
9754 * sysdeps/pthread/pthread_rwlock_unlock.c: Likewise.
9755 * sysdeps/pthread/pthread_rwlock_wrlock.c: Likewise.
9757 2003-02-23 Roland McGrath <roland@redhat.com>
9759 * Makefile (nptl-version): Change regexp so case sensitivity is ok.
9761 2003-02-23 Ulrich Drepper <drepper@redhat.com>
9763 * Makefile (tests): Add tst-context1.
9764 * tst-context1.c: New file.
9766 * Makefile (tests): Add tst-tls1 and tst-tls2.
9767 * tst-tls1.c: New file.
9768 * tst-tls2.c: New file.
9770 * libc-cancellation.c (__libc_enable_asynccancel): Correct test
9773 * pthread_create.c (start_thread): Set EXITING_BIT early.
9775 * sysdeps/i386/tls.h (THREAD_GETMEM): Mark asm as volatile.
9776 (THREAD_GETMEM_NC): Likewise.
9778 2003-02-22 Ulrich Drepper <drepper@redhat.com>
9780 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Shave
9781 off 3 more bytes by using offset-less instructions when possible.
9783 * Makefile: Add dependency for $(objpfx)version.d.
9785 * eintr.c (eintr_source): Add unnecessary return but the compiler
9788 * tst-kill3.c: Include <unistd.h>.
9790 2003-02-21 Roland McGrath <roland@redhat.com>
9792 * pthread_create.c (start_thread): Call __libc_thread_freeres.
9794 2003-02-21 Ulrich Drepper <drepper@redhat.com>
9796 * Makefile (tests): Add tst-eintr1.
9797 (distribute): Add eintr.c.
9798 * tst-eintr1.c: New file.
9799 * eintr.c: New file.
9801 * pthread_cancel.c (pthread_cancel): Use tkill directly.
9803 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill):
9804 Disallow sending SIGCANCEL.
9806 * Makefile (tests): Remove tst-basic7. Add tst-kill1, tst-kill2,
9807 tst-kill3, tst-kill4, tst-kill5, tst-kill6.
9808 * tst-kill1.c: New file.
9809 * tst-kill2.c: New file.
9810 * tst-kill3.c: New file.
9811 * tst-kill5.c: New file.
9812 * tst-kill6.c: New file.
9813 * tst-basic7.c: Renamed to...
9814 * tst-kill4.c: ...this.
9816 2003-02-21 Roland McGrath <roland@redhat.com>
9818 * Makefile (install-lib-ldscripts): New variable.
9820 2003-02-21 Ulrich Drepper <drepper@redhat.com>
9822 * pthreadP.h: Define INVALID_TD_P and INVALID_NOT_TERMINATED_TD_P.
9823 * pthread_cancel.c: Use INVALID_TD_P.
9824 * pthread_detach.c: Likewise.
9825 * pthread_getschedparam.c: Likewise.
9826 * pthread_setschedparam.c: Likewise.
9827 * sysdeps/pthread/pthread_getcpuclockid.c: Likewise.
9828 * sysdeps/unix/sysv/linux/pthread_kill.c: Likewise.
9829 * pthread_join.c: Use INVALID_NOT_TERMINATED_TD_P.
9830 * pthread_timedjoin.c: Likewise.
9832 * tst-basic7.c: Include <signal.h>.
9834 * pthread_join.c (pthread_join): Limited checking for invalid
9836 * pthread_timedjoin.c (pthread_timedjoin_np): Likewise.
9838 2003-02-20 Ulrich Drepper <drepper@redhat.com>
9840 * pthread_create.c (deallocate_tsd): Reset found_nonzero at the
9841 beginning of the loop. Clear the entire first block of TSD.
9842 * Makefile (tests): Add tst-key4.
9843 * tst-key4.c: New file.
9845 2003-02-18 Ulrich Drepper <drepper@redhat.com>
9847 * Makefile (tests): Add tst-basic7.
9848 * tst-basic7.c: New file.
9850 * pthread_create.c (deallocate_tsd): Mark as internal_function.
9851 Add some more __builtin_expect.
9853 * pthreadP.h: Define dummy version of DEBUGGING_P.
9855 2003-02-17 Ulrich Drepper <drepper@redhat.com>
9857 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remnove
9858 _POSIX_THREAD_PRIORITY_SCHEDULING.
9859 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remove
9860 _XOPEN_REALTIME_THREADS.
9861 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
9863 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): The
9864 kernel returns EINVAL for PID <= 0, work around it.
9866 * Makefile (tests): Add tst-signal5.
9867 * tst-signal5.c: New file.
9869 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define TTY_NAME_MAX
9872 * tst-cancel1.c (tf): Block all signals.
9874 * Makefile (tests): Add tst-basic6.
9875 * tst-basic6.c: New file.
9877 * tst-basic1.c: Add test for process ID.
9879 * Makefile (tests): Add tst-cancel10.
9880 * tst-cancel10.c: New file.
9882 * Makefile (tests): Add tst-signal4.
9883 * tst-signal4.c: New file.
9885 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Use
9886 __sigismember instead of sigismember. Add __builtin_expect.
9888 2003-02-16 Ulrich Drepper <drepper@redhat.com>
9890 * tst-attr1.c (do_test): Add tests for pthread_setcanceltype,
9891 pthread_setcancelstate, and pthread_rwlock_setpshared.
9893 * tst-cancel7.c (do_test): Make sure the pid file exists before
9894 canceling the thread.
9896 * tst-rwlock6.c: More pthread_rwlock_timedwrlock and
9897 pthread_rwlock_timedrdlock tests.
9898 * tst-rwlock7.c: More pthread_rwlock_timedwrlock tests.
9899 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
9900 Check for invalid tv_nsec field.
9901 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
9904 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Protect
9905 recursive mutex of overflow.
9907 * tst-attr1.c (do_test): Add test for pthread_mutexattr_setpshared.
9909 * libc-cancellation.c (__libc_enable_asynccancel): Rewrite to avoid
9910 going into an endless loop.
9911 * Makefile (tests): Add tst-cancel9.
9912 * tst-cancel9.c: New file.
9914 * pthread_cancel.c (pthread_cancel): Use the result of __pthread_kill.
9916 2003-02-15 Ulrich Drepper <drepper@redhat.com>
9918 * tst-mutex5.c (do_test): Add more timedlock tests.
9920 * tst-mutex2.c: Tests of trylock and unlock with ERROR mutexes.
9921 * tst-mutex3.c (do_test): Add tests for trylock with RECURSIVE mutexes.
9923 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): Don't
9924 use INLINE_SYSCALL. Error number is returned, not -1.
9926 * pthreadP.h: Mark declarations of __find_in_stack_list, __free_tcb,
9927 and __deallocate_stack with internal_function.
9928 * pthread_create.c: Adjust definitions appropriately.
9929 * allocatestack.c: Likewise.
9931 * pthread_join.c: Add one more __builtin_expect.
9932 * pthread_timedjoin.c: Likewise.
9934 * pthread_getspecific.c (__pthread_getspecific): Clear data->data
9935 not data of sequence number does not match.
9936 Add one __builtin_expect.
9938 * Makefile (tests): Add tst-clock1.
9939 * tst-clock1.c: New file.
9941 * pthread_setconcurrency.c (pthread_setconcurrency): Fail for
9943 * Makefile (tests): Add tst-basic5.
9944 * tst-basic5.c: New file.
9946 2003-02-14 Ulrich Drepper <drepper@redhat.com>
9948 * Makefile (tests): Add tst-basic4.
9949 * tst-basic4.c: New file.
9951 * pthreadP.h: Add declaraction for __nptl_nthreads.
9952 * pthread_create.c: Define __nptl_nthreads
9953 (start_thread): Increment __nptl_nthreads at beginning. Decrement
9954 after thread is done. If then zero, call exit(0).
9955 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
9956 Add ptr_nthreads. Define HAVE_PTR_NTHREADS.
9957 * init.c (pthread_functions): Initialize ptr_nthreads.
9958 * allocatestack.c (nptl_nthreads): Remove definition and all uses.
9959 (__reclaim_stacks): Decrement __nptl_nthreads.
9960 * sysdeps/pthread/Makefile [$(subdir)==csu] (CFLAGS-libc-start.c):
9962 * Makefile (tests): Add tst-basic3.
9963 * tst-basic3.c: New file.
9965 * descr.h: Define CANCELING_BIT and CANCELING_BITMASK. Introduce
9966 after CANCELTYPE_BIT, move the other bits up. Update CANCEL_RESTMASK.
9967 * init.c (sigcancel_handler): Also set CANCELING_BITMASK bit in newval.
9968 * pthread_cancel.c (pthread_cancel): Likewise. Also set CANCELING_BIT
9969 if asynchronous canceling is enabled.
9970 * pthread_join.c (pthread_join): When recognizing circular joins,
9971 take into account the other thread might be already canceled.
9972 * Makefile (tests): Add tst-join5.
9973 * tst-join5.c: New file.
9975 * Makefile (tests): Add tst-join4.
9976 * tst-join4.c: New file.
9978 2003-02-13 Ulrich Drepper <drepper@redhat.com>
9980 * tst-cond4.c (main): Add test of pthread_attr_getpshared.
9982 2003-02-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
9984 * sysdeps/s390/tls.h (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM,
9985 THREAD_SETMEM_NC): Use passed descr instead of THREAD_SELF.
9986 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c (_longjmp_unwind): Avoid
9988 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Include <sys/time.h>
9990 * sysdeps/unix/sysv/linux/s390/sem_post.c (__new_sem_post): Return
9991 error if lll_futex_wake failed.
9993 2003-02-13 Ulrich Drepper <drepper@redhat.com>
9995 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Fix
9996 handling of cancellation and failung pthread_mutex_unlock call.
9997 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9998 * Makefile (tests): Add tst-cond8 and tst-cond9.
9999 * tst-cond8.c: New file.
10000 * tst-cond9.c: New file.
10002 * tst-cond7.c (do_test): Unlock the mutex before canceling the thread.
10004 * sysdeps/pthread/pthread.h: Add missing initializers. Protect
10005 non-standard initializers with __USE_GNU.
10007 * Makefile (tests): Add tst-cleanup3.
10008 * tst-cleanup3.c: New file.
10010 2003-02-12 Ulrich Drepper <drepper@redhat.com>
10012 * Makefile (tests): Add tst-attr1 and tst-attr2.
10013 * tst-attr1.c: New file.
10014 * tst-attr2.c: New file.
10016 * Makefile: Add rules to build and run tst-atfork2 test.
10017 * tst-atfork2.c: New file.
10018 * tst-atfork2mod.c: New file.
10020 * sysdeps/unix/sysv/linux/unregister-atfork.c
10021 (__unregister_atfork): Free the memory allocated for the handlers
10022 after removing them from the lists.
10024 * sysdeps/unix/sysv/linux/register-atfork.c: Define memeory
10027 * tst-atfork1.c (do_test): Wait for the child we forked.
10028 Report error in child.
10030 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Fix comment.
10032 * sysdeps/pthread/Makefile: Define CFLAGS-confstr.c.
10034 2003-02-10 Ulrich Drepper <drepper@redhat.com>
10036 * Makefile (tests): Add tst-cancel8.
10037 * tst-cancel8.c: New file.
10039 * sysdeps/unix/sysv/linux/i386/pthread_once.S (clear_once_control): Fix
10040 clearing of control variable.
10041 * Makefile (tests): Add tst-once3 and tst-once4.
10042 * tst-once3.c: New file.
10043 * tst-once4.c: New file.
10045 2003-02-08 kaz Kojima <kkojima@rr.iij4u.or.jp>
10047 * sysdeps/sh/Makefile: New file.
10048 * sysdeps/sh/bits/atomic.h: New file.
10049 * sysdeps/sh/pthread_spin_init.c: New file.
10050 * sysdeps/sh/pthread_spin_lock.c: New file.
10051 * sysdeps/sh/pthread_spin_trylock.S: New file.
10052 * sysdeps/sh/pthread_spin_unlock.S: New file.
10053 * sysdeps/sh/pthreaddef.h: New file.
10054 * sysdeps/sh/tcb-offsets.sym: New file.
10055 * sysdeps/sh/td_ta_map_lwp2thr.c: New file.
10056 * sysdeps/sh/tls.h: New file.
10057 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: New file.
10058 * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: New file.
10059 * sysdeps/unix/sysv/linux/sh/createthread.c: New file.
10060 * sysdeps/unix/sysv/linux/sh/fork.c: New file.
10061 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: New file.
10062 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: New file.
10063 * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h: New file.
10064 * sysdeps/unix/sysv/linux/sh/lowlevelcond.h: New file.
10065 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: New file.
10066 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: New file.
10067 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: New file.
10068 * sysdeps/unix/sysv/linux/sh/lowlevelrwlock.h: New file.
10069 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: New file.
10070 * sysdeps/unix/sysv/linux/sh/pt-vfork.S: New file.
10071 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: New file.
10072 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: New file.
10073 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: New file.
10074 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: New file.
10075 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: New file.
10076 * sysdeps/unix/sysv/linux/sh/pthread_once.S: New file.
10077 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: New file.
10078 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: New file.
10079 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: New file.
10080 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: New file.
10081 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: New file.
10082 * sysdeps/unix/sysv/linux/sh/sem_post.S: New file.
10083 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: New file.
10084 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: New file.
10085 * sysdeps/unix/sysv/linux/sh/sem_wait.S: New file.
10086 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: New file.
10088 2003-02-08 Ulrich Drepper <drepper@redhat.com>
10090 * tst-cond2.c: Rearrange code to not rely on behavior undefined
10091 according to POSIX.
10093 * tst-basic2.c (do_test): Lock mutex before creating the thread.
10095 2003-02-07 Ulrich Drepper <drepper@redhat.com>
10097 * sysdeps/x86_64/tls.h: Remove unnecessary macros, left over from x86.
10098 (TLS_GET_FS): New #define.
10099 (TLS_SET_FS): New #define.
10100 Correct value of __NR_set_thread_area.
10102 * sysdeps/x86_64/td_ta_map_lwp2thr.c: New file.
10104 2003-02-06 Ulrich Drepper <drepper@redhat.com>
10106 * Makefile (tests): Add tst-popen1.
10107 * tst-popen1.c: New file.
10109 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Remove wrong
10110 but inactive generalization.
10111 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
10112 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
10113 Minor optimization, remove one instruction.
10114 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
10116 2003-02-04 Martin Schwidefsky <schwidefsky@de.ibm.com>
10118 * sysdeps/unix/sysv/linux/s390/fork.c: Correct order of parameters.
10120 2003-01-31 Martin Schwidefsky <schwidefsky@de.ibm.com>
10122 * init.c (__NR_set_tid_address): Add #ifdef for s390.
10123 * sysdeps/pthread/pthread_barrier_wait.c: New file.
10124 * sysdeps/pthread/pthread_cond_broadcast.c: New file.
10125 * sysdeps/pthread/pthread_cond_signal.c: New file.
10126 * sysdeps/pthread/pthread_cond_timedwait.c: New file.
10127 * sysdeps/pthread/pthread_cond_wait.c: New file.
10128 * sysdeps/pthread/pthread_rwlock_rdlock.c: New file.
10129 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: New file.
10130 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: New file.
10131 * sysdeps/pthread/pthread_rwlock_unlock.c: New file.
10132 * sysdeps/pthread/pthread_rwlock_wrlock.c: New file.
10133 * sysdeps/s390/Makefile: New file.
10134 * sysdeps/s390/bits/atomic.h: New file.
10135 * sysdeps/s390/pthread_spin_init.c: New file.
10136 * sysdeps/s390/pthread_spin_lock.c: New file.
10137 * sysdeps/s390/pthread_spin_trylock.c: New file.
10138 * sysdeps/s390/pthread_spin_unlock.c: New file.
10139 * sysdeps/s390/pthreaddef.h: New file.
10140 * sysdeps/s390/tcb-offsets.sym: New file.
10141 * sysdeps/s390/td_ta_map_lwp2thr.c: New file.
10142 * sysdeps/s390/tls.h: New file.
10143 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: New file.
10144 * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: New file.
10145 * sysdeps/unix/sysv/linux/s390/createthread.c: New file.
10146 * sysdeps/unix/sysv/linux/s390/dl-sysdep.h: New file.
10147 * sysdeps/unix/sysv/linux/s390/fork.c: New file.
10148 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: New file.
10149 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: New file.
10150 * sysdeps/unix/sysv/linux/s390/libc-lowlevelmutex.c: New file.
10151 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: New file.
10152 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: New file.
10153 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c: New file.
10154 * sysdeps/unix/sysv/linux/s390/lowlevelsem.h: New file.
10155 * sysdeps/unix/sysv/linux/s390/pthread_once.c: New file.
10156 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c: New file.
10157 * sysdeps/unix/sysv/linux/s390/s390-32/pt-vfork.S: New file.
10158 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: New file.
10159 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: New file.
10160 * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S: New file.
10161 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: New file.
10162 * sysdeps/unix/sysv/linux/s390/sem_post.c: New file.
10163 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: New file.
10164 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: New file.
10165 * sysdeps/unix/sysv/linux/s390/sem_wait.c: New file.
10167 2003-02-04 Ulrich Drepper <drepper@redhat.com>
10169 * atomic.h: Add a couple more default implementations.
10170 (atomic_compare_and_exchange_acq): Use
10171 __arch_compare_and_exchange_32_acq in return value definition. It
10173 (atomic_bit_set): Renamed from atomic_set_bit.
10174 Add missing atomic_ prefixes.
10176 * sysdeps/pthread/bits/libc-lock.h (__libc_once): In case no
10177 thread library is available, use correct value to mark initialized
10180 2003-02-03 Ulrich Drepper <drepper@redhat.com>
10182 * allocatestack.c (allocate_stack): Use __getpagesize instead of
10183 __sysconf to determine pagesize.
10185 * pthread_create.c: Include <atomic.h>.
10186 * allocatestack.c (allocate_stack): Implement coloring of the
10187 allocated stack memory. Rename pagesize to pagesize_m1. It's the
10188 size minus one. Adjust users.
10189 * sysdeps/i386/i686/Makefile: New file.
10191 2003-02-02 Ulrich Drepper <drepper@redhat.com>
10193 * allocatestack.c: Improve comment throughout the file.
10195 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
10196 (__lll_lock_wait): Add branch prediction.
10197 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S
10198 (__lll_lock_wait): Likewise.
10199 (lll_unlock_wake_cb): Removed.
10201 2003-01-31 Ulrich Drepper <drepper@redhat.com>
10203 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Remove
10204 _POSIX_THREAD_PRIORITY_SCHEDULING.
10206 2003-01-30 Jakub Jelinek <jakub@redhat.com>
10208 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
10209 Fix return type of ptr___pthread_getspecific.
10211 2003-01-29 Ulrich Drepper <drepper@redhat.com>
10213 * Makefile (tests): Add tst-umask1.
10214 (tst-umask1-ARGS): Define.
10215 * tst-umask1.c: New file.
10217 2003-01-28 Ulrich Drepper <drepper@redhat.com>
10219 * Makefile (libpthread-routines): Remove lowlevelrwlock. Add
10220 pthread_rwlock_rdlock, pthread_rwlock_timedrdlock,
10221 pthread_rwlock_wrlock, pthread_rwlock_timedwrlock, and
10222 pthread_rwlock_unlock.
10223 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Removed
10224 * sysdeps/unix/sysv/linux/i386/i586/lowlevelrwlock.S: Removed
10225 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrwlock.S: Removed
10226 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: New file.
10227 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
10229 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: New file.
10230 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
10232 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: New file.
10233 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_rdlock.S: New file.
10234 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_timedrdlock.S:
10236 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_wrlock.S: New file.
10237 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_timedwrlock.S:
10239 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_unlock.S: New file.
10240 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_rdlock.S: New file.
10241 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_timedrdlock.S:
10243 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_wrlock.S: New file.
10244 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_timedwrlock.S:
10246 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_unlock.S: New file.
10248 * Makefile (libpthread-routines): Remove lowlevelcond and
10249 lowlevelsem. Add sem_wait, sem_trywait, sem_timedwait, sem_post,
10250 pthread_cond_wait, pthread_cond_timedwait, pthread_cond_signal,
10251 and pthread_cond_broadcast.
10252 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Removed
10253 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Removed
10254 * sysdeps/unix/sysv/linux/i386/i586/lowlevelsem.S: Removed
10255 * sysdeps/unix/sysv/linux/i386/i586/lowlevelcond.S: Removed
10256 * sysdeps/unix/sysv/linux/i386/i686/lowlevelsem.S: Removed
10257 * sysdeps/unix/sysv/linux/i386/i686/lowlevelcond.S: Removed
10258 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: New file.
10259 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: New file.
10260 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: New file.
10261 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: New file.
10262 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: New file.
10263 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: New file.
10264 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: New file.
10265 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: New file.
10266 * sysdeps/unix/sysv/linux/i386/i586/sem_wait.S: New file.
10267 * sysdeps/unix/sysv/linux/i386/i586/sem_trywait.S: New file.
10268 * sysdeps/unix/sysv/linux/i386/i586/sem_timedwait.S: New file.
10269 * sysdeps/unix/sysv/linux/i386/i586/sem_post.S: New file.
10270 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_wait.S: New file.
10271 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_timedwait.S: New file.
10272 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_signal.S: New file.
10273 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_broadcast.S: New file.
10274 * sysdeps/unix/sysv/linux/i386/i686/sem_wait.S: New file.
10275 * sysdeps/unix/sysv/linux/i386/i686/sem_trywait.S: New file.
10276 * sysdeps/unix/sysv/linux/i386/i686/sem_timedwait.S: New file.
10277 * sysdeps/unix/sysv/linux/i386/i686/sem_post.S: New file.
10278 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_wait.S: New file.
10279 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_timedwait.S: New file.
10280 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_signal.S: New file.
10281 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_broadcast.S: New file.
10282 * sysdeps/unix/sysv/linux/i386/lowlevelcond.h: New file.
10284 * sysdeps/unix/sysv/linux/i386/createthread.c: Define
10285 PREPARE_CREATE and TLS_VALUE with x86-specific bits. All the rest
10286 of the code is moved to ...
10287 * sysdeps/pthread/createthread.c: ...here. New file.
10289 2003-01-27 Ulrich Drepper <drepper@redhat.com>
10291 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S
10292 (__new_sem_post): Clear %eax before returning.
10293 Reported by MAEDA Naoaki <maeda.naoaki@jp.fujitsu.com>.
10295 * Makefile (tests): Add tst-cleanup2.
10296 * tst-cleanup2.c: New file.
10298 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start):
10299 Interpret first parameter correctly.
10301 2003-01-17 Ulrich Drepper <drepper@redhat.com>
10303 * Makefile (headers): Add bits/semaphore.h.
10305 2003-01-16 Jakub Jelinek <jakub@redhat.com>
10307 * sysdeps/i386/tls.h (INIT_SYSINFO): Initialize _head->sysinfo even
10310 2003-01-14 Ulrich Drepper <drepper@redhat.com>
10312 * sem_open.c (sem_open): Return SEM_FAILED if existing semaphore
10313 must be used and mapping failed.
10314 Reported by Luke Elliott <luke.elliott@activfinancial.com>.
10316 * Makefile (CFLAGS-pthread_self.os): Define this, not
10317 CFLAGS-pthread_self.c.
10319 2003-01-13 Ulrich Drepper <drepper@redhat.com>
10321 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Don't export
10322 lll_unlock_wake_cb.
10324 * Makefile (libpthread-routines): Add version. Add rules to build
10325 version.os and banner.h.
10326 * version.c: New file.
10328 2003-01-13 Jakub Jelinek <jakub@redhat.com>
10330 * pthread_mutex_lock.c (__pthread_mutex_lock_internal): Make
10331 the alias unconditional.
10332 * pthread_mutex_unlock.c (__pthread_mutex_unlock_internal): Likewise.
10334 2003-01-13 Ulrich Drepper <drepper@redhat.com>
10336 * Makefile (CFLAGS-pthread_self.c): New definition.
10338 2003-01-06 Jakub Jelinek <jakub@redhat.com>
10340 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Add
10341 INTERNAL_SYSCALL_DECL, add err argument to INTERNAL_SYSCALL* macros.
10342 * sysdeps/unix/sysv/linux/raise.c (raise): Likewise.
10343 * init.c (__pthread_initialize_minimal_internal): Likewise.
10345 2003-01-07 Jakub Jelinek <jakub@redhat.com>
10347 * pthreadP.h (__pthread_cond_timedwait): Add prototype.
10349 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
10350 (RTLD_CORRECT_DYNAMIC_WEAK): Remove.
10351 (DL_SYSINFO_IMPLEMENTATION): Change into .text section and back.
10352 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h
10353 (RTLD_CORRECT_DYNAMIC_WEAK): Remove.
10354 (DL_SYSINFO_IMPLEMENTATION): Change into .text section and back.
10356 2003-01-06 Jakub Jelinek <jakub@redhat.com>
10358 * pthreadP.h (LIBC_CANCEL_HANDLED): Define.
10359 * pt-system.c (LIBC_CANCEL_HANDLED): Add.
10360 * tst-cancel-wrappers.sh: Remove all exceptions.
10362 2003-01-05 Ulrich Drepper <drepper@redhat.com>
10364 * tst-cancel-wrappers.sh: Invoke gawk not awk since we use GNU awk
10365 features. Reported by Marijn Ros <marijn@mad.scientist.com>.
10367 * sysdeps/unix/sysv/linux/jmp-unwind.c: Include <pthread-functions.h>.
10368 Use __libc_pthread_functions array if SHARED.
10370 * pthreadP.h: Move pthread_cond_2_0_t definition to...
10371 * sysdeps/unix/sysv/linux/internaltypes.h: ...here.
10373 * sysdeps/pthread/bits/libc-lock.h (__libc_ptf_call): New #define.
10374 (__libc_rwlock_rdlock, __libc_rwlock_wrlock, __libc_rwlock_unlock,
10375 __libc_key_create, __libc_getspecific, __libc_setspecific): Use
10376 __libc_ptf_call instead of __libc_maybe_call.
10377 (PTF): New #define.
10378 (__libc_cleanup_region_start): Wrap function name with PTF call.
10379 (__libc_cleanup_region_end): Likewise.
10380 (__libc_cleanup_end): Likewise.
10382 * pthread_getspecific.c: Add __pthread_getspecific_internal alias.
10383 * pthread_setspecific.c: Add __pthread_setspecific_internal alias.
10384 * pthread_key_create.c: Add __pthread_key_create_internal alias.
10385 * pthreadP.h: Add prototypes.
10387 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Add
10388 __pthread_rwlock_rdlock, __pthread_rwlock_wrlock, and
10389 __pthread_rwlock_unlock aliases.
10390 * pthreadP.h: Add prototypes for new aliases.
10392 * pthreadP.h (struct pthead_functions): Moved to...
10393 * sysdeps/pthread/pthread-functions.h: ...here. New file.
10394 * init.c (pthread_functions): Add initializers for new elements.
10396 * cleanup_defer.c: Add __pthread_cleanup_push_defer and
10397 __pthread_cleanup_pop_restore aliases.
10398 * pthreadP.h: Add prototypes.
10400 * cleanup.c: Rename _GI_pthread_cleanup_push to __pthread_cleanup_push
10401 and _GI_pthread_cleanup_pop to __pthread_cleanup_pop.
10402 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Adjust caller.
10403 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
10404 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
10405 * pthreadP.h: Adjust prototypes and callers.
10407 2003-01-04 Ulrich Drepper <drepper@redhat.com>
10409 * Makefile (tests): Add tst-cancel7.
10410 (tst-cancel7-ARGS): New variable.
10411 * tst-cancel7.c: New file.
10413 * old_pthread_cond_broadcast.c: Optimize initialization a bit to work
10414 around gcc defficiencies.
10415 * old_pthread_cond_signal.c: Likewise.
10416 * old_pthread_cond_timedwait.c: Likewise.
10417 * old_pthread_cond_wait.c: Likewise.
10419 * pthreadP.h (pthread_cond_2_0_t): Remove unneeded lock element.
10421 2003-01-03 Ulrich Drepper <drepper@redhat.com>
10423 * Makefile (tests): Add tst-cond7.
10424 * tst-cond7.c: New file.
10426 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S
10427 (condvar_cleanup): Get condvar address from the right place.
10429 * atomic.h: Correct definitions of atomic_full_barrier,
10430 atomic_read_barrier, atomic_write_barrier.
10432 * old_pthread_cond_broadcast.c: Make memory allocate and initialization
10434 * old_pthread_cond_signal.c: Likewise.
10435 * old_pthread_cond_timedwait.c: Likewise.
10436 * old_pthread_cond_wait.c: Likewise.
10438 2003-01-03 Jakub Jelinek <jakub@redhat.com>
10440 * Makefile ($(objpfx)libpthread.so): Depend on ld.so.
10442 2003-01-03 Ulrich Drepper <drepper@redhat.com>
10444 * pthreadP.h (pthread_cond_2_0_t): New type.
10445 (struct pthread_functions): Use new type for 2.0 condvar callbacks.
10446 Use new type for the 2.0 condvar function prototypes.
10447 * forward.c: Use pthread_cond_2_0_t for 2.0 condvar functions.
10448 * old_pthread_cond_init.c: Use pthread_cond_2_0_t for condvar
10450 * old_pthread_cond_destroy.c: Likewise.
10451 * old_pthread_cond_broadcast.c: Likewise. Lock appropriately.
10452 * old_pthread_cond_signal.c: Likewise.
10453 * old_pthread_cond_timedwait.c: Likewise.
10454 * old_pthread_cond_wait.c: Likewise.
10456 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S
10457 (__pthread_cond_wait): Don't save cancellation mode and seq value
10460 * herrno.c (__h_errno_location): Don't define as weak.
10462 2003-01-02 Jakub Jelinek <jakub@redhat.com>
10464 * Versions [libc] (GLIBC_2.3.2): Export pthread_cond_broadcast,
10465 pthread_cond_destroy, pthread_cond_init, pthread_cond_signal
10466 and pthread_cond_wait.
10467 * old_pthread_cond_broadcast.c (__old_pthread_cond_broadcast):
10469 (__pthread_cond_broadcast_2_0): ... this.
10470 * old_pthread_cond_destroy.c (__old_pthread_cond_destroy):
10472 (__pthread_cond_destroy_2_0): ... this.
10473 * old_pthread_cond_init.c (__old_pthread_cond_init):
10475 (__pthread_cond_init_2_0): ... this.
10476 * old_pthread_cond_signal.c (__old_pthread_cond_signal):
10478 (__pthread_cond_signal_2_0): ... this.
10479 * old_pthread_cond_wait.c (__old_pthread_cond_wait):
10481 (__pthread_cond_wait_2_0): ... this.
10482 * pthread_cond_destroy.c: Include shlib-compat.h.
10483 (pthread_cond_destroy): Change strong_alias into versioned_symbol.
10484 * pthread_cond_init.c: Include shlib-compat.h.
10485 (pthread_cond_init): Change strong_alias into versioned_symbol.
10486 * pthreadP.h (struct pthread_functions): Rename ptr_pthread_cond_*
10487 fields to ptr___pthread_cond_* and add ptr___pthread_cond_*_2_0
10489 (__pthread_cond_broadcast_2_0, __pthread_cond_destroy_2_0,
10490 __pthread_cond_init_2_0, __pthread_cond_signal_2_0,
10491 __pthread_cond_wait_2_0): New prototypes.
10492 (__old_pthread_cond_broadcast, __old_pthread_cond_destroy,
10493 __old_pthread_cond_init, __old_pthread_cond_signal,
10494 __old_pthread_cond_wait): Removed.
10495 * init.c: Include shlib-compat.h.
10496 (pthread_functions): Guard ptr___pthread_attr_init_2_0
10497 initialization with SHLIB_COMPAT (GLIBC_2_0, GLIBC_2_1).
10498 Rename ptr_pthread_cond_* to ptr___pthread_cond_*, initialize
10499 ptr___pthread_cond_*_2_0 fields.
10500 * forward.c: Export both pthread_cond_*@@GLIBC_2.3.2 and
10501 pthread_cond_*@GLIBC_2.0 compatibility symbols.
10503 * sysdeps/pthread/sigaction.c (SIGCANCEL): Only define if
10504 LIBC_SIGACTION was not yet defined.
10505 [!defined LIBC_SIGACTION]: Define LIBC_SIGACTION, #include self.
10506 [!defined LIBC_SIGACTION] (__sigaction): New function and
10508 [!defined LIBC_SIGACTION] (sigaction): New weak_alias.
10509 [defined LIBC_SIGACTION]: #include_next <sigaction.c>.
10511 2003-01-02 Jakub Jelinek <jakub@redhat.com>
10513 * Makefile (CFLAGS-pthread_atfork.c): Add -DNOT_IN_libc.
10515 2003-01-02 Ulrich Drepper <drepper@redhat.com>
10517 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
10518 New, larger type definition.
10519 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: New condvar
10521 * Versions [libpthread]: Add definitions for new pthread_cond_*
10522 interfaces for version GLIBC_2.3.2.
10523 * pthread_cond_init.c: Update initialization for new type definition.
10524 * Makefile (libpthread-routines): Remove pthread_cond_wait,
10525 pthread_cond_timedwait, pthread_cond_signal, and
10526 pthread_cond_broadcast. Add old_pthread_cond_init,
10527 old_pthread_cond_destroy, old_pthread_cond_wait,
10528 old_pthread_cond_timedwait, old_pthread_cond_signal, and
10529 old_pthread_cond_broadcast.
10530 * old_pthread_cond_broadcast.c: New file.
10531 * old_pthread_cond_destroy.c: New file.
10532 * old_pthread_cond_init.c: New file.
10533 * old_pthread_cond_signal.c: New file.
10534 * old_pthread_cond_timedwait.c: New file.
10535 * old_pthread_cond_wait.c: New file.
10536 * pthreadP.h: Add prototypes for the compatibility interfaces.
10538 * pthread_cond_destroy.c: Don't include <errno.h>.
10540 2003-01-01 Ulrich Drepper <drepper@redhat.com>
10542 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Avoid
10543 unnecessary zero offset when addressing MUTEX.
10545 2002-12-31 Ulrich Drepper <drepper@redhat.com>
10547 * sysdeps/unix/sysv/linux/fork.h: Add libc_hidden_proto for
10549 * sysdeps/unix/sysv/linux/register-atfork.c: Add libc_hidden_def
10550 for __register_atfork.
10552 2002-12-31 Jakub Jelinek <jakub@redhat.com>
10554 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Use __ASSEMBLER__
10555 instead of ASSEMBLER test macro.
10557 * sysdeps/unix/sysv/linux/allocrtsig.c (__libc_current_sigrtmin,
10558 __libc_current_sigrtmax): Add libc_hidden_def.
10560 * sysdeps/pthread/list.h: Remove assert.h include.
10562 2002-12-31 Ulrich Drepper <drepper@redhat.com>
10564 * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Use
10565 __pthread_initialize_minimal_internal not
10566 __pthread_initialize_minimal.
10568 2002-12-30 Ulrich Drepper <drepper@redhat.com>
10570 * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Mark
10571 __pthread_initialize_minimal as hidden.
10573 * init.c (__pthread_initialize_minimal_internal): Don't mark as
10576 2002-12-31 Jakub Jelinek <jakub@redhat.com>
10578 * Makefile ($(inst_libdir)/libpthread.so): Depend on
10579 $(common-objpfx)format.lds, include that into the output script.
10581 (extra-B-pthread.so): Change linuxthreads/ into nptl/.
10583 2002-12-28 Andreas Jaeger <aj@suse.de>
10585 * sysdeps/unix/sysv/linux/xstatconv.c (xstat_conv): Adjust for
10586 nsec resolution changes.
10587 (xstat64_conv): Likewise.
10588 (xstat32_conv): Likewise.
10589 * sysdeps/unix/sysv/linux/kernel_stat.h: Add nsec resolution for
10590 struct kernel_stat.
10591 * sysdeps/unix/sysv/linux/bits/stat.h: Add nsec resolution for
10592 structs stat and stat64.
10593 * time/time.h (__timespec_defined): Define for __USE_MISC.
10594 * io/sys/stat.h [__USE_MISC]: Define __need_timespec for struct stat.
10596 2002-12-30 Jakub Jelinek <jakub@redhat.com>
10598 * forward.c (FORWARD2): Renamed from FORWARD3. Remove unused export
10600 (pthread_attr_init_2_0, pthread_attr_init_2_1): Use FORWARD macro.
10601 (pthread_exit): Use strong_alias to avoid warnings.
10602 * pthreadP.h (struct pthread_functions): Rename ptr_pthread_exit
10603 and ptr_pthread_attr_init_2_* to ptr___pthread_exit and
10604 ptr___pthread_attr_init_2_*.
10605 * init.c (pthread_functions): Adjust.
10607 2002-12-29 Ulrich Drepper <drepper@redhat.com>
10609 * forward.c: Make all functions available by default again. It
10610 caused too much trouble.
10612 * pt-siglongjmp.c: Removed.
10614 2002-12-28 Jakub Jelinek <jakub@redhat.com>
10616 * sysdeps/i386/tls.h: Include tcb-offsets.h in assembler.
10617 (SYSINFO_OFFSET, MULTIPLE_THREADS_OFFSET): Remove.
10618 * sysdeps/i386/Makefile: New file.
10619 * sysdeps/i386/tcb-offsets.sym: New file.
10620 * sysdeps/pthread/tcb-offsets.h: New file.
10621 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
10622 Remove MULTIPLE_THREADS_OFFSET and SYSINFO_OFFSET checks.
10624 * sysdeps/unix/sysv/linux/Versions [libc] (GLIBC_PRIVATE): Move
10625 __register_atfork...
10626 (GLIBC_2.3.2): ...here.
10628 2002-12-28 Ulrich Drepper <drepper@redhat.com>
10630 * sysdeps/pthread/pthread.h: Mark pthread_attr_getstackaddr and
10631 pthread_attr_setstackaddr with __attribute_deprecated__.
10633 2002-12-27 Jakub Jelinek <jakub@redhat.com>
10635 * pt-system.c (system): Remove cancellation handling.
10636 * tst-cancel-wrappers.sh: Allow pt-system.o* to not use the
10637 cancellation routines.
10639 2002-12-28 Ulrich Drepper <drepper@redhat.com>
10641 * descr.h: Include <dl-sysdep.h>.
10642 (struct pthread): Move header.data.list to the back of the struct.
10643 * sysdeps/i386/tls.h (tcbhead_t): Move list to the back of the struct.
10644 (MULTIPLE_THREADS_OFFSET): Adjust offset.
10645 (SYSINFO_OFFSEET): Likewise.
10647 2002-12-27 Jakub Jelinek <jakub@redhat.com>
10649 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h (USE_DL_SYSINFO):
10651 (DL_SYSINFO_DEFAULT): Cast to uintptr_t to avoid warnings.
10652 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h (NEED_DL_SYSINFO,
10653 DL_SYSINFO_DEFAULT, DL_SYSINFO_IMPLEMENTATION): Define.
10654 (USE_DL_SYSINFO): Undef.
10656 2002-12-22 Jakub Jelinek <jakub@redhat.com>
10658 * Makefile (tests-reverse): Use $(objpfx)../libc.so instead of
10659 $(common-objpfx)libc.so.
10660 * tst-cancel4.c (tf_write, tf_writev): Increase buf sizes so that
10661 it is bigger than pipe buffer size even on arches with bigger
10663 (tf_usleep): Cast usleep argument to useconds_t to avoid warnings.
10665 2002-12-25 Ulrich Drepper <drepper@redhat.com>
10667 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Implement
10668 correct errno access for case that USE___THREAD is not defined.
10670 2002-12-24 Ulrich Drepper <drepper@redhat.com>
10672 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Add missing #endif.
10673 Patch by Marijn Ros <marijn@mad.scientist.com>.
10675 2002-12-22 Roland McGrath <roland@redhat.com>
10677 * Makefile (omit-deps): Add $(unix-syscalls:%=ptw-%).
10679 2002-12-20 Ulrich Drepper <drepper@redhat.com>
10681 * sysdeps/pthread/bits/stdio-lock.h (_IO_lock_inexpensive): Define.
10683 2002-12-19 Ulrich Drepper <drepper@redhat.com>
10685 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Don't define
10686 NEED_DL_SYSINFO since no processor < i686 had the sysenter opcode.
10687 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h: New file.
10689 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Use ENTER_KERNEL instead
10691 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
10692 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Likewise.
10693 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Likewise.
10694 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
10695 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
10696 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Likewise.
10697 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Likewise.
10698 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
10700 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Add support for using
10702 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Likewise.
10704 * sysdeps/i386/tls.h: Unconditionally include <dl-sysdep.h>.
10706 * allocatestack.c (allocate_stack) [NEED_DL_SYSINFO]: Set sysinfo
10708 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Check
10709 that sysinfo is properly initialized.
10710 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define RTLD_PRIVATE_ERRNO
10711 to 1 only for ld.so.
10713 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define
10714 RTLD_CORRECT_DYNAMIC_WEAK.
10716 2002-12-19 Jakub Jelinek <jakub@redhat.com>
10718 * forward.c (pthread_attr_init_2_0, pthread_attr_init_2_1):
10719 Use return 0 as 6th argument to FORWARD4.
10720 * pthread_equal.c: Include pthreadP.h instead of pthread.h.
10722 2002-12-18 Ulrich Drepper <drepper@redhat.com>
10724 * descr.h (struct pthread) [NEED_DL_SYSINFO]: Add sysinfo member.
10725 * sysdeps/i386/tls.h (tcbhead_t): Add sysinfo member.
10726 Define SYSINFO_OFFSEET if NEED_DL_SYSINFO is defined.
10727 (INIT_SYSINFO): New #define.
10728 (TLS_TP_INIT): Use INIT_SYSINFO.
10729 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
10730 At test to make sure SYSINFO_OFFSET value is correct.
10731 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: New file.
10733 2002-12-18 Jakub Jelinek <jakub@redhat.com>
10735 * sysdeps/pthread/flockfile.c (flockfile): Change into weak alias.
10736 * sysdeps/unix/sysv/linux/raise.c (gsignal): Add weak alias to raise.
10737 * Versions [libc: GLIBC_2.0]: Add pthread_attr_init.
10738 [libpthread: GLIBC_2.1]: Remove __pthread_rwlock_init,
10739 __pthread_rwlock_destroy, __pthread_rwlock_rdlock,
10740 __pthread_rwlock_wrlock, __pthread_rwlock_unlock,
10741 __pthread_rwlock_tryrdlock and __pthread_rwlock_trywrlock.
10743 2002-12-18 Ulrich Drepper <drepper@redhat.com>
10745 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Use ENTER_KERNEL
10746 macro instead of using int $0x80 directly.
10748 * sysdeps/pthread/bits/stdio-lock.h: New file.
10749 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: New file.
10750 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevelmutex.S: New file.
10751 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevelmutex.S: New file.
10752 * Makefile (routines): Add libc-lowlevelmutex.
10754 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Remove
10755 __i686.get_pc_thunk.dx.
10757 2002-12-17 Jakub Jelinek <jakub@redhat.com>
10759 * Makefile (libpthread-shared-only-routines): Add pt-allocrtsig.
10760 (tests): Depend on $(objpfx)tst-cancel-wrappers.out.
10761 ($(objpfx)tst-cancel-wrappers.out): New rule.
10762 * tst-cancel-wrappers.sh: New test.
10763 * tst-locale1.c: Include signal.h.
10764 (uselocale): Test static linking of __libc_current_sigrt*.
10766 2002-12-17 Ulrich Drepper <drepper@redhat.com>
10768 * Makefile (tests): Add tst-cancel6.
10769 * tst-cancel6.c: New file
10771 2002-12-17 Jakub Jelinek <jakub@redhat.com>
10773 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (SINGLE_THREAD_P):
10774 Define meaningfully for assembler as well.
10775 * pthreadP.h (struct pthread_functions): Remove
10776 ptr_pthread_attr_init field. Add ptr_pthread_attr_init_2_0
10777 and ptr_pthread_attr_init_2_1 fields.
10778 * init.c (pthread_functions): Initialize ptr_pthread_attr_init_2_0
10779 and ptr_pthread_attr_init_2_1 instead of ptr_pthread_attr_init.
10780 * forward.c (FORWARD4): Renamed from FORWARD3. Add export argument.
10781 (FORWARD3): Define using FORWARD4.
10782 (pthread_attr_init): Provide both @GLIBC_2.0 and @@GLIBC_2.1
10784 * pt-system.c: Remove duplicate stdlib.h include.
10786 2002-12-16 Ulrich Drepper <drepper@redhat.com>
10788 * sem_init.c: Define sem_init@GLIBC_2.0.
10789 * sem_destroy.c: Define sem_destroy@GLIBC_2.0.
10790 * sem_getvalue.c: Define sem_getvalue@GLIBC_2.0.
10792 * flockfile.c: Moved to...
10793 * sysdeps/pthread/flockfile.c: ...here. New file.
10794 * funlockfile.c: Moved to...
10795 * sysdeps/pthread/funlockfile.c: ...here. New file.
10796 * ftrylockfile.c: Moved to...
10797 * sysdeps/pthread/ftrylockfile.c: ...here. New file.
10799 2002-12-16 Jakub Jelinek <jakub@redhat.com>
10801 * libc-cancellation.c: Guard both function with
10802 #if !defined NOT_IN_libc.
10803 * Makefile (libpthread-routines): Use ptw-, not pt- prefix for the
10804 automatically provided pthread wrappers.
10805 * pthreadP.h (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): Define to
10806 CANCEL_* if IS_IN_libpthread and to dummy versions if not in libc
10808 * pt-open.c: Removed.
10809 * pt-fcntl.c: Removed.
10810 * pt-fsync.c: Removed.
10811 * pt-lseek.c: Removed.
10812 * pt-msgrcv.c: Removed.
10813 * pt-msgsnd.c: Removed.
10814 * pt-msync.c: Removed.
10815 * pt-nanosleep.c: Removed.
10816 * pt-open64.c: Removed.
10817 * pt-pause.c: Removed.
10818 * pt-pread.c: Removed.
10819 * pt-pread64.c: Removed.
10820 * pt-pwrite.c: Removed.
10821 * pt-pwrite64.c: Removed.
10822 * pt-read.c: Removed.
10823 * pt-recv.c: Removed.
10824 * pt-recvfrom.c: Removed.
10825 * pt-recvmsg.c: Removed.
10826 * pt-send.c: Removed.
10827 * pt-sendto.c: Removed.
10828 * pt-sigtimedwait.c: Removed.
10829 * pt-sigwait.c: Removed.
10830 * pt-wait.c: Removed.
10831 * pt-waitpid.c: Removed.
10832 * pt-write.c: Removed.
10833 * pt-accept.c: Removed.
10834 * pt-close.c: Removed.
10835 * pt-connect.c: Removed.
10836 * pt-lseek64.c: Removed.
10837 * pt-sendmsg.c: Removed.
10838 * pt-tcdrain.c: Removed.
10840 2002-12-15 Ulrich Drepper <drepper@redhat.com>
10842 * init.c (__pthread_initialize_minimal_internal): Renamed from
10843 __pthread_initialize_minimal. Make old name an alias. This
10844 converts a normal relocation into a relative relocation.
10846 * pt-fcntl.c (__fcntl): Use fcntl64 syscall, not fcntl.
10848 * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect,
10849 readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev.
10850 * Makefile (libpthread-routines): Remove pt-creat, pt-poll,
10851 pt-pselect, pt-readv, pt-select, pt-sigpause, pt-sigsuspend,
10852 pt-sigwaitinfo, pt-waitid, and pt-writev.
10853 * pt-creat.c: Removed.
10854 * pt-poll.c: Removed.
10855 * pt-pselect.c: Removed.
10856 * pt-readv.c: Removed.
10857 * pt-select.c: Removed.
10858 * pt-sigpause.c: Removed.
10859 * pt-sigsuspend.c: Removed.
10860 * pt-sigwaitinfo.c: Removed.
10861 * pt-waitid.c: Removed.
10862 * pt-writev.c: Removed.
10864 * init.c (pthread_functions): New variable.
10865 (__pthread_initialize_minimal): Pass pointer to pthread_functions
10866 (or NULL) to __libc_pthread_init.
10867 * forward.c: Rewrite to use __libc:pthread_functions array to get
10868 function addresses.
10869 * sysdeps/unix/sysv/linux/fork.h: Remove __libc_pthread_init
10871 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
10872 Take new parameter. Copy content of variable pointed to by it
10873 to __libc_pthread_init.
10875 * pthreadP.h (struct pthread_functions): New type.
10876 (__libc_pthread_init): Declare.
10878 * pthread_attr_destroy.c: Add namespace protected alias.
10879 * pthread_attr_getdetachstate.c: Likewise.
10880 * pthread_attr_getinheritsched.c: Likewise.
10881 * pthread_attr_getschedparam.c: Likewise.
10882 * pthread_attr_getschedpolicy.c: Likewise.
10883 * pthread_attr_getscope.c: Likewise.
10884 * pthread_attr_setdetachstate.c: Likewise.
10885 * pthread_attr_setinheritsched.c: Likewise.
10886 * pthread_attr_setschedparam.c: Likewise.
10887 * pthread_attr_setschedpolicy.c: Likewise.
10888 * pthread_attr_setscope.c: Likewise.
10889 * pthread_cond_broadcast.c: Likewise.
10890 * pthread_cond_destroy.c: Likewise.
10891 * pthread_cond_init.c: Likewise.
10892 * pthread_cond_signal.c: Likewise.
10893 * pthread_cond_wait.c: Likewise.
10894 * pthread_condattr_destroy.c: Likewise.
10895 * pthread_condattr_init.c: Likewise.
10896 * pthread_equal.c: Likewise.
10897 * pthread_exit.c: Likewise.
10898 * pthread_getschedparam.c: Likewise.
10899 * pthread_self.c: Likewise.
10900 * pthread_setcancelstate.c: Likewise.
10901 * pthread_setschedparam.c: Likewise.
10902 * pthread_mutex_destroy.c: Likewise.
10903 * pthread_mutex_init.c: Likewise.
10904 * pthreadP.h: Add prototypes for the aliases.
10906 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Set
10907 multiple_threads member in correct TCB to 1.
10909 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define
10910 SINGLE_THREAD_P. If in libc or libpthread examine multiple_thread
10911 member of thread decriptor, otherwise return unconditionally 1.
10913 2002-12-14 Ulrich Drepper <drepper@redhat.com>
10915 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Changes folded into the
10916 regular Linux version. Remove file.
10917 * sysdeps/unix/sysv/linux/connect.S: Likewise. Remove file.
10918 * sysdeps/unix/sysv/linux/llseek.c: Likewise. Remove file.
10919 * sysdeps/unix/sysv/linux/msgrcv.c: Likewise. Remove file.
10920 * sysdeps/unix/sysv/linux/msgsnd.c: Likewise. Remove file.
10921 * sysdeps/unix/sysv/linux/open64.c: Likewise. Remove file.
10922 * sysdeps/unix/sysv/linux/poll.c: Likewise. Remove file.
10923 * sysdeps/unix/sysv/linux/pread.c: Likewise. Remove file.
10924 * sysdeps/unix/sysv/linux/pread64.c: Likewise. Remove file.
10925 * sysdeps/unix/sysv/linux/pselect.c: Likewise. Remove file.
10926 * sysdeps/unix/sysv/linux/pwrite.c: Likewise. Remove file.
10927 * sysdeps/unix/sysv/linux/pwrite64.c: Likewise. Remove file.
10928 * sysdeps/unix/sysv/linux/readv.c: Likewise. Remove file.
10929 * sysdeps/unix/sysv/linux/recv.S: Likewise. Remove file.
10930 * sysdeps/unix/sysv/linux/recvfrom.S: Likewise. Remove file.
10931 * sysdeps/unix/sysv/linux/recvmsg.S: Likewise. Remove file.
10932 * sysdeps/unix/sysv/linux/send.S: Likewise. Remove file.
10933 * sysdeps/unix/sysv/linux/sendmsg.S: Likewise. Remove file.
10934 * sysdeps/unix/sysv/linux/sendto.S: Likewise. Remove file.
10935 * sysdeps/unix/sysv/linux/sigpause.c: Likewise. Remove file.
10936 * sysdeps/unix/sysv/linux/sigsuspend.c: Likewise. Remove file.
10937 * sysdeps/unix/sysv/linux/sigtimedwait.c: Likewise. Remove file.
10938 * sysdeps/unix/sysv/linux/sigwait.c: Likewise. Remove file.
10939 * sysdeps/unix/sysv/linux/sigwaitinfo.c: Likewise. Remove file.
10940 * sysdeps/unix/sysv/linux/system.c: Likewise. Remove file.
10941 * sysdeps/unix/sysv/linux/tcdrain.c: Likewise. Remove file.
10942 * sysdeps/unix/sysv/linux/wait.c: Likewise. Remove file.
10943 * sysdeps/unix/sysv/linux/waitid.c: Likewise. Remove file.
10944 * sysdeps/unix/sysv/linux/waitpid.c: Likewise. Remove file.
10945 * sysdeps/unix/sysv/linux/writev.c: Likewise. Remove file.
10946 * sysdeps/unix/sysv/linux/i386/fcntl.c: Likewise. Remove file.
10948 2002-12-14 Jakub Jelinek <jakub@redhat.com>
10950 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: New file.
10951 * sysdeps/unix/sysv/linux/open.c: Removed.
10952 * sysdeps/unix/sysv/linux/fsync.c: Removed.
10953 * sysdeps/unix/sysv/linux/lseek.c: Removed.
10954 * sysdeps/unix/sysv/linux/msync.c: Removed.
10955 * sysdeps/unix/sysv/linux/read.c: Removed.
10956 * sysdeps/unix/sysv/linux/close.c: Removed.
10957 * sysdeps/unix/sysv/linux/creat.c: Removed.
10958 * sysdeps/unix/sysv/linux/nanosleep.c: Removed.
10959 * sysdeps/unix/sysv/linux/pause.c: Removed.
10960 * sysdeps/unix/sysv/linux/select.c: Removed.
10961 * sysdeps/unix/sysv/linux/write.c: Removed.
10963 2002-12-14 Ulrich Drepper <drepper@redhat.com>
10965 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Check multiple_threads
10966 element in TCB to see whether locking is needed.
10968 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Check that
10969 MULTIPLE_THREADS_OFFSET value is correct.
10971 * sysdeps/unix/sysv/linux/close.c: New file.
10972 * sysdeps/unix/sysv/linux/connect.S: New file.
10973 * sysdeps/unix/sysv/linux/creat.c: New file.
10974 * sysdeps/unix/sysv/linux/fsync.c: New file.
10975 * sysdeps/unix/sysv/linux/llseek.c: New file.
10976 * sysdeps/unix/sysv/linux/lseek.c: New file.
10977 * sysdeps/unix/sysv/linux/msgrcv.c: New file.
10978 * sysdeps/unix/sysv/linux/msgsnd.c: New file.
10979 * sysdeps/unix/sysv/linux/msync.c: New file.
10980 * sysdeps/unix/sysv/linux/nanosleep.c: New file.
10981 * sysdeps/unix/sysv/linux/open.c: New file.
10982 * sysdeps/unix/sysv/linux/open64.c: New file.
10983 * sysdeps/unix/sysv/linux/pause.c: New file.
10984 * sysdeps/unix/sysv/linux/poll.c: New file.
10985 * sysdeps/unix/sysv/linux/pread.c: New file.
10986 * sysdeps/unix/sysv/linux/pread64.c: New file.
10987 * sysdeps/unix/sysv/linux/pselect.c: New file.
10988 * sysdeps/unix/sysv/linux/pwrite.c: New file.
10989 * sysdeps/unix/sysv/linux/pwrite64.c: New file.
10990 * sysdeps/unix/sysv/linux/readv.c: New file.
10991 * sysdeps/unix/sysv/linux/recv.S: New file.
10992 * sysdeps/unix/sysv/linux/recvfrom.S: New file.
10993 * sysdeps/unix/sysv/linux/recvmsg.S: New file.
10994 * sysdeps/unix/sysv/linux/select.c: New file.
10995 * sysdeps/unix/sysv/linux/send.S: New file.
10996 * sysdeps/unix/sysv/linux/sendmsg.S: New file.
10997 * sysdeps/unix/sysv/linux/sendto.S: New file.
10998 * sysdeps/unix/sysv/linux/sigpause.c: New file.
10999 * sysdeps/unix/sysv/linux/sigsuspend.c: New file.
11000 * sysdeps/unix/sysv/linux/sigtimedwait.c: New file.
11001 * sysdeps/unix/sysv/linux/sigwait.c: New file.
11002 * sysdeps/unix/sysv/linux/sigwaitinfo.c: New file.
11003 * sysdeps/unix/sysv/linux/system.c: New file.
11004 * sysdeps/unix/sysv/linux/tcdrain.c: New file.
11005 * sysdeps/unix/sysv/linux/wait.c: New file.
11006 * sysdeps/unix/sysv/linux/waitid.c: New file.
11007 * sysdeps/unix/sysv/linux/waitpid.c: New file.
11008 * sysdeps/unix/sysv/linux/writev.c: New file.
11009 * sysdeps/unix/sysv/linux/i386/fcntl.c: New file.
11011 * pt-readv.c: Fix comment.
11013 2002-12-14 Jakub Jelinek <jakub@redhat.com>
11015 * tst-cleanup1.c: Include stdlib.h.
11017 * tst-cancel5.c: New test.
11018 * Makefile (tests): Add tst-cancel5.
11019 (tst-cancel5): Link against libc.so libpthread.so in that order.
11021 2002-12-13 Ulrich Drepper <drepper@redhat.com>
11023 * forward.c (test_loaded): Prevent recursive calls.
11025 * Makefile (routines): Add libc-cancellation.
11026 * libc-cancellation.c: New file.
11027 * descr.h (struct pthread): Add multiple_threads field.
11028 * allocatestack.c (allocate_stack): Initialize multiple_header field of
11029 new thread descriptor to 1.
11030 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread):
11031 Initialize multiple_thread field after successful thread creation.
11032 * cancellation.c (__do_cancel): Move to pthreadP.h.
11033 (__pthread_enable_asynccancel): Remove parameter from __do_cancel call.
11034 (__pthread_disable_asynccancel): Add internal_function attribute.
11035 * init.c (sigcancel_handler): Remove parameter from __do_cancel call.
11036 * pthread_setcancelstate.c: Likewise.
11037 * pthread_setcanceltype.c: Likewise.
11038 * pthread_exit.c: Likewise.
11039 * pthreadP.h (CANCELLATION_P): Likewise.
11040 (__do_cancel): Define as static inline.
11041 (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): New #defines.
11042 (__libc_enable_asynccancel, __libc_disable_asynccancel): New
11044 * sysdeps/i386/tls.h (tcbhead_t): Add list and multiple_threads
11045 fields. Define MULTIPLE_THREADS_OFFSET.
11046 * sysdeps/pthread/bits/libc-lock.h: Remove __libc_locking_needed
11048 * sysdeps/unix/sysv/linux/accept.S: New file.
11049 * sysdeps/unix/sysv/linux/read.c: New file.
11050 * sysdeps/unix/sysv/linux/write.c: New file.
11051 * sysdeps/unix/sysv/linux/i386/pt-socket.S: New file.
11052 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Remove definition and
11053 initialization of __libc_locking_needed.
11054 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Don't use
11055 __libc_locking_needed, use multiple_threads field in TCB.
11056 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
11058 2002-12-12 Ulrich Drepper <drepper@redhat.com>
11060 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: Use i486
11062 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: Likewise.
11064 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Correct
11065 access to __libc_locking_needed for PIC.
11067 2002-12-12 Jakub Jelinek <jakub@redhat.com>
11069 * sysdeps/pthread/bits/libc-lock.h (__libc_locking_needed): Only
11070 declare for libc.so.
11071 (__libc_lock_init, __libc_lock_init_recursive): Change into comma
11073 (__libc_lock_lock): Put into statement expression.
11074 (__libc_lock_unlock): Remove trailing semicolon.
11075 * sysdeps/unix/sysv/linux/fork.h (__libc_pthread_init): Fix typo.
11077 2002-12-12 Roland McGrath <roland@redhat.com>
11079 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use asm operand with
11080 "m" constraint to refer to __libc_locking_needed. Declare it here.
11082 2002-12-12 Ulrich Drepper <drepper@redhat.com>
11084 * sysdeps/unix/sysv/linux/fork-gen.c: Renamed to...
11085 * sysdeps/unix/sysv/linux/libc_pthread_init.c: ...this.
11086 Initialize __libc_locking_needed.
11087 * init.c (__pthread_initialize_minimal): Call __libc_pthread_init
11088 instead of __register_pthread_fork_handler.
11089 * sysdeps/pthread/bits/libc-lock.h: Declare __libc_locking_needed.
11090 * sysdeps/unix/sysv/linux/Makefile (sysdep_routimes): Replace
11091 fork-gen with libc_pthread_init.
11092 * sysdeps/unix/sysv/linux/Versions: Use __libc_pthread_init instead
11093 of __register_pthread_fork_handler.
11094 * sysdeps/unix/sysv/linux/fork.h: Declare __libc_pthread_init instead
11095 of __register_pthread_fork_handler.
11096 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use
11097 __libc_locking_needed to determine whether lock prefix can be avoided.
11098 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
11100 2002-12-11 Ulrich Drepper <drepper@redhat.com>
11102 * Makefile (tests): Add tst-cleanup1.
11103 * tst-cleanup1.c: New file.
11104 * cancellation.c (__cleanup_thread): Removed.
11105 (__do_cancel): Remove call to __cleanup_thread.
11106 * pthreadP.h: Remove __cleanup_thread prorotype.
11108 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start):
11109 Remember function and argument even if cancellation handler
11110 function is not available.
11111 (__libc_cleanup_region_end): Execute registered function directly if
11112 pthread functions are not available.
11113 (__libc_cleanup_end): Likewise.
11115 * init.c (__pthread_initialize_minimal): Fix initialization in
11116 static lib by preventing gcc from being too clever.
11118 2002-12-10 Ulrich Drepper <drepper@redhat.com>
11120 * init.c (__pthread_initialize_minimal): Remove unneccesary
11123 * Makefile (tests): We can run tst-locale2 now.
11125 2002-12-09 Ulrich Drepper <drepper@redhat.com>
11127 * Versions: Remove duplicated sigwait entry.
11129 2002-12-08 Ulrich Drepper <drepper@redhat.com>
11131 * pthreadP.h: Enable pthread_cleanup_{push,pop} optimizations only
11134 * pt-fcntl.c (__fcntl): Initialize oldtype to avoid warning.
11136 * pthreadP.h: Declare __pthread_enable_asynccancel and
11137 __pthread_disable_asynccancel.
11138 (CANCEL_ASYNC): Use __pthread_enable_asynccancel.
11139 (CANCEL_RESET): Use __pthread_disable_asynccancel.
11140 * cancellation.c (__pthread_enable_asynccancel): New function.
11141 (__pthread_disable_asynccancel): New function.
11142 * pt-accept.c: Adjust for CANCEL_ASYNC and CANCEL_RESET change.
11143 * pt-close.c: Likewise.
11144 * pt-connect.c: Likewise.
11145 * pt-creat.c: Likewise.
11146 * pt-fcntl.c: Likewise.
11147 * pt-fsync.c: Likewise.
11148 * pt-lseek.c: Likewise.
11149 * pt-lseek64.c: Likewise.
11150 * pt-msgrcv.c: Likewise.
11151 * pt-msgsnd.c: Likewise.
11152 * pt-msync.c: Likewise.
11153 * pt-nanosleep.c: Likewise.
11154 * pt-open.c: Likewise.
11155 * pt-open64.c: Likewise.
11156 * pt-pause.c: Likewise.
11157 * pt-poll.c: Likewise.
11158 * pt-pread.c: Likewise.
11159 * pt-pread64.c: Likewise.
11160 * pt-pselect.c: Likewise.
11161 * pt-pwrite.c: Likewise.
11162 * pt-pwrite64.c: Likewise.
11163 * pt-read.c: Likewise.
11164 * pt-readv.c: Likewise.
11165 * pt-recv.c: Likewise.
11166 * pt-recvfrom.c: Likewise.
11167 * pt-recvmsg.c: Likewise.
11168 * pt-select.c: Likewise.
11169 * pt-send.c: Likewise.
11170 * pt-sendmsg.c: Likewise.
11171 * pt-sendto.c: Likewise.
11172 * pt-sigpause.c: Likewise.
11173 * pt-sigsuspend.c: Likewise.
11174 * pt-sigtimedwait.c: Likewise.
11175 * pt-sigwait.c: Likewise.
11176 * pt-sigwaitinfo.c: Likewise.
11177 * pt-system.c: Likewise.
11178 * pt-tcdrain.c: Likewise.
11179 * pt-wait.c: Likewise.
11180 * pt-waitid.c: Likewise.
11181 * pt-waitpid.c: Likewise.
11182 * pt-write.c: Likewise.
11183 * pt-writev.c: Likewise.
11184 * pthread_join.c: Likewise.
11185 * pthread_timedjoin.c: Likewise.
11187 * pt-sigpause.c (sigsuspend): Call __sigsuspend.
11188 (__xpg_sigpause): New function.
11189 * Versions (libpthread:GLIBC_2.3.2): Add __xpg_sigpause.
11191 2002-12-07 Ulrich Drepper <drepper@redhat.com>
11193 * Makefile (CFLAGS-ftrylockfile.c): Add -D_IO_MTSAFE_IO.
11195 * cleanup.c: Move declarations of _GI_pthread_cleanup_push and
11196 _GI_pthread_cleanup_pop to pthreadP.h.
11198 * ftrylockfile.c: Use _IO_lock_trylock instead of
11199 pthread_mutex_trylock.
11201 * pthreadP.h (CANCEL_ASYNC): Use __pthread_setcanceltype.
11202 (CANCEL_RESET): Likewise.
11203 (__pthread_setcanceltype_): Declare.
11204 (__pthread_mutex_lock_internal): Declare.
11205 (__pthread_mutex_unlock_internal): Declare.
11206 (__pthread_once_internal): Declare.
11207 (pthread_cleanup_push): Redefine using _GI_pthread_cleanup_push.
11208 (pthread_cleanup_pop): Redefine using _GI_pthread_cleanup_pop.
11210 * pthread_cond_timedwait.c: Use INTUSE is calls to pthread_mutex_lock
11211 and pthread_mutex_unlock.
11212 * pthread_cond_wait.c: Likewise.
11213 * pthread_mutex_lock.c: Use INTDEF to define alias if needed.
11214 * pthread_mutex_unlock.c: Likewise.
11216 * pthread_setcanceltype.c: Add additional alias
11217 __pthread_setcanceltype.
11219 * sem_unlink.c (sem_unlink): Use __pthread_once with INTDEF.
11220 * sem_open.c (sem_open): Likewise.
11221 Use __libc_open, __libc_write, and __libc_close instead of
11222 open, write, and close respectively.
11224 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_trylock_internal):
11225 Rewrite as statement expression since it must return a value.
11227 * pthread_cancel.c: Use __pthread_kill instead of pthread_kill.
11228 * sysdeps/unix/sysv/linux/pthread_kill.c: Define additional alias
11231 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Define additional
11232 alias __pthread_once_internal.
11234 * sysdeps/unix/sysv/linux/raise.c: Use libc_hidden_def for raise.
11236 2002-12-06 Ulrich Drepper <drepper@redhat.com>
11238 * Makefile (tests): Add tst-stdio1 and tst-stdio2.
11239 * tst-stdio1.c: New file.
11240 * tst-stdio2.c: New file.
11242 * init.c (__pthread_initialize_minimal): Correct INIT_LIST_HEAD use.
11244 * Makefile (tests): Comment out tst-locale2 for now.
11245 (CFLAGS-flockfile.c, CFLAGS-funlockfile.c): Define to -D_IO_MTSAFE_IO.
11247 * sysdeps/unix/sysv/linux/Makefile: Define CFLAGS-fork.c to
11249 * sysdeps/unix/sysv/linux/fork.c: Include <bits/stdio-lock.h>.
11250 Use _IO_lock_init instead of explicit assignment.
11252 * sysdeps/pthread/bits/libc-lock.h: Define __rtld_lock_* macros.
11253 Define __libc_lock_* and __libc_lock_recursive macros with
11254 lowlevellock macros, not pthread mutexes.
11256 * flockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_lock instead
11257 of pthread_mutex_lock.
11258 * funlockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_unlock
11259 instead of pthread_mutex_unlock.
11261 2002-12-06 Roland McGrath <roland@redhat.com>
11263 * allocatestack.c (__stack_user): Use uninitialized defn.
11264 * init.c (__pthread_initialize_minimal): Initialize it here.
11266 2002-12-05 Roland McGrath <roland@redhat.com>
11268 * sysdeps/i386/tls.h (TLS_INIT_TP): Make it return zero or an error
11270 * sysdeps/x86_64/tls.h (TLS_INIT_TP): Likewise.
11272 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Add
11273 missing & here too.
11275 2002-12-05 Ulrich Drepper <drepper@redhat.com>
11277 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
11279 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: New file.
11280 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: New file.
11281 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: New file.
11282 * sysdeps/pthread/bits/libc-lock.h: Use lowlevellock implementation
11283 for __libc_lock_* macros.
11284 * Makefile (routines): Add libc-lowlevellock.
11286 2002-10-09 Roland McGrath <roland@redhat.com>
11288 * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call): New macro.
11289 Under [__PIC__], call the function via the pointer fetched for
11290 comparison rather than a call by name that uses the PLT.
11291 (__libc_lock_init, __libc_rwlock_init, __libc_lock_fini)
11292 (__libc_rwlock_fini, __libc_lock_lock, __libc_rwlock_rdlock)
11293 (__libc_rwlock_wrlock, __libc_lock_trylock, __libc_rwlock_tryrdlock)
11294 (__libc_rwlock_trywrlock, __libc_lock_unlock, __libc_rwlock_unlock)
11295 (__libc_key_create, __libc_getspecific, __libc_setspecific): Use it.
11297 2002-12-04 Roland McGrath <roland@redhat.com>
11299 * forward.c (pthread_self): Use FORWARD3 macro to correct return type.
11301 * sysdeps/i386/td_ta_map_lwp2thr.c: Moved from ../nptl_db.
11302 * sysdeps/generic/td_ta_map_lwp2thr.c: New file.
11304 * pthread_create.c (start_thread): Add missing & on __nptl_last_event.
11306 2002-12-04 Ulrich Drepper <drepper@redhat.com>
11308 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Make pthread_t
11309 a completely opaque, non-integer type.
11310 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
11312 2002-12-05 Jakub Jelinek <jakub@redhat.com>
11314 * sysdeps/i386/tls.h: Include stdlib.h.
11315 * sysdeps/x86_64/tls.h: Likewise.
11317 2002-12-04 Ulrich Drepper <drepper@redhat.com>
11319 * Makefile (tests): Add tst-locale2.
11320 (tests-static): Likewise.
11321 * tst-locale2.c: New file.
11323 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Mark asms as
11324 volatile and add memory clobbers to lock operations.
11326 2002-12-03 Ulrich Drepper <drepper@redhat.com>
11328 * sysdeps/i386/i686/bits/atomic.h: Use i486 version.
11329 * sysdeps/i386/i486/bits/atomic.h: New file.
11330 * sysdeps/i386/i586/bits/atomic.h: New file.
11331 * sysdeps/i386/i686/pthread_spin_trylock.S: Define HAVE_CMOV and
11332 include i486 version.
11333 * sysdeps/i386/i486/pthread_spin_trylock.S: New file.
11334 * sysdeps/i386/i586/pthread_spin_trylock.S: New file.
11335 Patch by Marijn Ros <marijn@mad.scientist.com>.
11337 * allocatestack.c (get_cached_stack): Don't crash if we first
11338 found a stack with a larger size then needed.
11339 Reported by Hui Huang <hui.huang@sun.com>.
11341 * Makefile (tests): Add tst-sysconf.
11342 * tst-sysconf.c: New file.
11344 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine
11345 PTHREAD_THREADS_MAX.
11347 2002-12-02 Roland McGrath <roland@redhat.com>
11349 * pthreadP.h (__stack_user, __nptl_create_event, __nptl_death_event):
11350 Declare using hidden_proto instead of attribute_hidden, so there are
11351 non-.hidden static symbols for gdb to find.
11352 (__pthread_keys): Likewise.
11353 * events.c (__nptl_create_event, __nptl_death_event): Add hidden_def.
11354 * allocatestack.c (__stack_user): Likewise.
11355 * pthread_create.c (__pthread_keys): Likewise.
11356 (__nptl_threads_events, __nptl_last_event): Make these static instead
11358 * pthread_key_create.c (__pthread_pthread_keys_max,
11359 __pthread_pthread_key_2ndlevel_size): Renamed from __linuxthreads_*.
11361 2002-12-02 Ulrich Drepper <drepper@redhat.com>
11363 * Makefile (tests): Add tst-locale1. If buid-static is yes link
11365 * tst-locale1.c: New file.
11367 * pthread_cond_timedwait.c: Include <stdlib.h>.
11369 * Makefile (tests): Add tst-fork2 and tst-fork3.
11370 * tst-fork2.c: New file.
11371 * tst-fork3.c: New file.
11373 2002-11-28 Ulrich Drepper <drepper@redhat.com>
11375 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: New file.
11377 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define macros which
11378 require it to 200112L.
11380 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Use cmov
11381 instruction only if HAVE_CMOV is defined.
11382 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrwlock.S: Define HAVE_CMOV.
11384 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: New file.
11386 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: New file.
11388 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: New file.
11390 * sysdeps/unix/sysv/linux/x86_64/pt-vfork.S: New file.
11392 2002-11-27 Ulrich Drepper <drepper@redhat.com>
11394 * sysdeps/x86_64/bits/atomic.h: New file.
11396 * sysdeps/i386/i686/bits/atomic.h: Fix asm syntax for 8- and
11399 * sysdeps/unix/sysv/linux/raise.c (raise): Use INTERNAL_SYSCALL if
11400 possible since gettid cannot fail.
11402 * sysdeps/x86_64/pthreaddef.h: New file.
11404 * sysdeps/i386/pthreaddef.h (gettid): Removed.
11406 * sysdeps/x86_64/pthread_spin_init.c: New file.
11407 * sysdeps/x86_64/pthread_spin_lock.c: New file.
11408 * sysdeps/x86_64/pthread_spin_trylock.c: New file.
11409 * sysdeps/x86_64/pthread_spin_unlock.c: New file.
11411 * sysdeps/i386/i686/pthread_spin_trylock.S (pthread_spin_trylock):
11412 Add missing lock prefix. Minute optimization.
11414 * tst-spin2.c (main): Also check successful trylock call.
11416 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Use correct
11417 syscall. Fix typo in case INTERNAL_SYSCALL is not used.
11419 * sysdeps/i386/pthread_spin_destroy.c: Moved to...
11420 * sysdeps/pthread/pthread_spin_destroy.c: ...here. New file.
11422 * sysdeps/i386/pthread_sigmask.c: Removed. Use the generic code.
11423 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Return correct
11424 value in case of an error. Add support for INTERNAL_SYSCALL.
11426 * sysdeps/i386/pthread_sigmask.c (pthread_sigmask): Return correct
11427 value in case of an error.
11429 * sysdeps/x86_64/tls.h: New file.
11431 2002-11-26 Ulrich Drepper <drepper@redhat.com>
11433 * sysdeps/i386/tls.h (THREAD_GETMEM_NC): Change interface. It now
11434 takes the array member name and the index as parameters.
11435 (THREAD_SETMEM_NC): Likewise.
11436 * pthread_getspecific.c: Use new THREAD_GETMEM_NC interface.
11437 * pthread_setspecific.c: Use new THREAD_GETMEM_NC and THREAD_SETMEM_NC
11440 * sysdeps/i386/tls.h (THREAD_SETMEM): Use size of member element
11441 to decide which code to use.
11442 (THREAD_SETMEM_NC): Likewise.
11444 * allocatestack.c (queue_stack): Don't remove stack from list here.
11445 Do it in the caller. Correct condition to prematurely terminate
11446 loop to free stacks.
11447 (__deallocate_stack): Remove stack from list here.
11449 2002-11-26 Ulrich Drepper <drepper@redhat.com>
11451 * Makefile (tests): Add tst-stack1.
11452 * tst-stack1.c: New file.
11454 * allocatestack.c (allocate_stack): Initialize the TCB on a user
11457 * pthread_attr_getstack.c: Return bottom of the thread area.
11459 2002-11-25 Ulrich Drepper <drepper@redhat.com>
11461 * Makefile (libpthread-routines): Add pt-allocrtsig and
11462 pthread_kill_other_threads.
11463 * pt-allocrtsig.c: New file.
11464 * pthread_kill_other_threads.c: New file.
11465 * sysdeps/unix/sysv/linux/allocrtsig.c: Add additional aliases for
11466 all three functions.
11467 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
11469 * sysdeps/unix/sysv/linux/Versions (libc:GLIBC_PRIVATE): Export
11470 __libc_current_sigrtmin_private, __libc_current_sigrtmax_private,
11471 and __libc_allocate_rtsig_private.
11472 * Versions (libpthread): Export pthread_kill_other_threads_np,
11473 __libc_current_sigrtmin, and __libc_current_sigrtmax.
11475 2002-11-24 Ulrich Drepper <drepper@redhat.com>
11477 * allocatestack.c (allocate_stack): stackaddr in attribute points to
11478 the end of the stack. Adjust computations.
11479 When mprotect call fails dequeue stack and free it.
11480 * pthread_attr_setstack.c: Store top of the stack in stackaddr
11482 * pthread_getattr_np.c: Likewise.
11484 * descr.h (IS_DETACHED): Add some more parenthesis to prevent
11487 2002-11-23 Ulrich Drepper <drepper@redhat.com>
11489 * sysdeps/pthread/pthread.h (pthread_self): __THROW must come before
11490 attribute definitions. Patch by Luca Barbieri <ldb@ldb.ods.org>.
11492 2002-11-22 Ulrich Drepper <drepper@redhat.com>
11494 * pthread_getspecific.c: Optimize access to first 2nd-level array.
11495 * pthread_setspecific.c: Likewise.
11497 2002-11-21 Ulrich Drepper <drepper@redhat.com>
11499 * sysdeps/unix/sysv/linux/i386/createthread.c: Remove CLONE_ flags
11500 definitions. Get them from the official place.
11501 * sysdeps/unix/sysv/linux/i386/fork.c: Likewise.
11503 * sysdeps/unix/sysv/linux/i386/createthread.c: Update CLONE_* flags.
11504 Use new CLONE_ flags in clone() calls.
11506 * sysdeps/unix/sysv/linux/fork.c: Use ARCH_FORK to actually fork.
11507 * sysdeps/unix/sysv/linux/i386/fork.c: New file.
11509 * Versions: Add pthread_* functions for libc.
11510 * forward.c: New file.
11512 * sysdeps/pthread/Makefile (libpthread-sysdeps_routines): Add
11514 * herrno.c: New file.
11517 * Makefile (libpthread-routines): Remove sem_post, sem_wait,
11518 sem_trywait, and sem_timedwait. Add herrno and res.
11519 * sem_init.c: Don't initialize lock and waiters members.
11520 * sem_open.c: Likewise.
11521 * sem_post.c: Removed.
11522 * sem_wait.c: Removed.
11523 * sem_trywait.c: Removed.
11524 * sem_timedwait.c: Removed.
11525 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Complete rewrite.
11526 Includes full implementations of sem_post, sem_wait, sem_trywait,
11528 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Adjust
11529 for new implementation.
11530 * sysdeps/unix/sysv/linux/internaltypes.h (struct sem): Remove lock
11531 and waiters fields.
11533 * tst-sem3.c: Improve error message.
11534 * tst-signal3.c: Likewise.
11536 * init.c (__pthread_initialize_minimal): Use set_tid_address syscall
11537 to tell the kernel about the termination futex and to initialize tid
11538 member. Don't initialize main_thread.
11539 * descr.h (struct pthread): Remove main_thread member.
11540 * cancelllation.c (__do_cancel): Remove code handling main thread.
11541 The main thread is not special anymore.
11543 * allocatestack.c (__reclaim_stacks): Mark stacks as unused. Add
11544 size of the stacks to stack_cache_actsize.
11546 * pt-readv.c: Add missing "defined".
11547 * pt-sigwait.c: Likewise.
11548 * pt-writev.c: Likewise.
11550 2002-11-09 Ulrich Drepper <drepper@redhat.com>
11552 * Versions: Export __connect from libpthread.
11553 Patch by Luca Barbieri <ldb@ldb.ods.org>.
11555 * Makefile (libpthread-routines): Add pt-raise.
11556 * sysdeps/unix/sysv/linux/raise.c: New file.
11557 * sysdeps/unix/sysv/linux/pt-raise.c: New file.
11558 * sysdeps/generic/pt-raise.c: New file.
11560 * pthread_cond_init.c: Initialize all data elements of the condvar
11561 structure. Patch by Luca Barbieri <ldb@ldb.ods.org>.
11563 * pthread_attr_init.c: Actually implement 2.0 compatibility version.
11564 * pthread_create.c: Likewise.
11566 * Makefile (tests): Add tst-key1, tst-key2, tst-key3.
11567 * tst-key1.c: New file.
11568 * tst-key2.c: New file.
11569 * tst-key3.c: New file.
11571 * Versions: Export pthread_detach for version GLIBC_2.0.
11572 Reported by Saurabh Desai <sdesai@austin.ibm.com>.
11574 2002-11-08 Ulrich Drepper <drepper@redhat.com>
11576 * pthread_key_create.c: Terminate search after an unused key was found.
11577 Patch by Luca Barbieri <ldb@ldb.ods.org>.
11579 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Return zero.
11580 Patch by Luca Barbieri <ldb@ldb.ods.org>.
11582 2002-10-10 Ulrich Drepper <drepper@redhat.com>
11584 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Use slow generic
11585 dynamic lookup for errno in PIC.
11587 * allocatestack.c (get_cached_stack): Rearrange code slightly to
11588 release the stack lock as soon as possible.
11589 Call _dl_allocate_tls_init for TCB from the cache to re-initialize
11590 the static TLS block.
11591 (allocate_stack): Call _dl_allocate_tls_init for user-provided stack.
11593 * cancellation.c: Renamed from cancelation.c.
11594 * Makefile: Adjust accordingly.
11595 * pthreadP.h (CANCELLATION_P): Renamed from CANCELATION_P.
11596 * cleanup_defer.c: Use CANCELLATION_P.
11597 * pthread_testcancel.c: Likewise.
11598 * descr.h: Fix spelling in comments.
11599 * init.c: Likewise.
11600 * pthread_getattr_np.c: Likewise.
11601 * pthread_getschedparam.c: Likewise.
11602 * pthread_setschedparam.c: Likewise.
11603 * Versions: Likewise.
11605 * pt-pselect.c: New file.
11606 * Makefile (libpthread-routines): Add pt-pselect.
11607 * Versions: Add pselect.
11609 * tst-cancel4.c: New file.
11610 * Makefile (tests): Add tst-cancel4.
11612 2002-10-09 Ulrich Drepper <drepper@redhat.com>
11614 * pthread_mutex_lock.c: Always record lock ownership.
11615 * pthread_mutex_timedlock.c: Likewise.
11616 * pthread_mutex_trylock.c: Likewise.
11618 * pt-readv.c: New file.
11619 * pt-writev.c: New file.
11620 * pt-creat.c: New file.
11621 * pt-msgrcv.c: New file.
11622 * pt-msgsnd.c: New file.
11623 * pt-poll.c: New file.
11624 * pt-select.c: New file.
11625 * pt-sigpause.c: New file.
11626 * pt-sigsuspend.c: New file.
11627 * pt-sigwait.c: New file.
11628 * pt-sigwaitinfo.c: New file.
11629 * pt-waitid.c: New file.
11630 * Makefile (libpthread-routines): Add pt-readv, pt-writev, pt-creat,
11631 pt-msgrcv, pt-msgsnd, pt-poll, pt-select, pt-sigpause, pt-sigsuspend,
11632 pt-sigwait, pt-sigwaitinfo, and pt-waitid.
11633 * Versions: Add all the new functions.
11635 * tst-exit1.c: New file.
11636 * Makefile (tests): Add tst-exit1.
11638 * sem_timedwait.c: Minor optimization for more optimal fastpath.
11640 2002-10-08 Ulrich Drepper <drepper@redhat.com>
11642 * pt-fcntl.c: Only enable asynchronous cancellation for F_SETLKW.
11644 * pthread_join.c: Enable asynchronous cancellation around lll_wait_tid
11645 call. pthread_join is an official cancellation point.
11646 * pthread_timedjoin.c: Likewise.
11648 * pthread_cond_wait.c: Revert order in which internal lock are dropped
11649 and the condvar's mutex are retrieved.
11650 * pthread_cond_timedwait.c: Likewise.
11651 Reported by dice@saros.East.Sun.COM.
11653 2002-10-07 Ulrich Drepper <drepper@redhat.com>
11655 * pthreadP.h: Cut out all type definitions and move them...
11656 * sysdeps/unix/sysv/linux/internaltypes.h: ...here. New file.
11657 * pthreadP.h: Include <internaltypes.h>.
11659 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Little
11660 performance tweaks.
11662 * sem_trywait.c: Shuffle #includes around to get right order.
11663 * sem_timedwait.c: Likewise.
11664 * sem_post.c: Likewise.
11665 * sem_wait.c: Likewise.
11667 * nptl 0.3 released.
11669 * Makefile (tests): Add tst-signal3.
11670 * tst-signal3.c: New file.
11672 2002-10-05 Ulrich Drepper <drepper@redhat.com>
11674 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Tell the compiler that
11675 the asms modify the sem object.
11676 (__lll_sem_timedwait): Now takes struct sem* as first parameter.
11678 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h (sem_t): Don't expose
11679 the actual members.
11680 * pthreadP.h (struct sem): New type. Actual semaphore type.
11681 * semaphoreP.h: Include pthreadP.h.
11682 * sem_getvalue.c: Adjust to sem_t change.
11683 * sem_init.c: Likewise.
11684 * sem_open.c: Likewise.
11685 * sem_post.c: Likewise.
11686 * sem_timedwait.c: Likewise.
11687 * sem_trywait.c: Likewise.
11688 * sem_wait.c: Likewise.
11690 2002-10-04 Ulrich Drepper <drepper@redhat.com>
11692 * Makefile (tests): Add tst-basic2, tst-exec1, tst-exec3, tst-exec3.
11693 * tst-basic2.c: New file.
11694 * tst-exec1.c: New file.
11695 * tst-exec2.c: New file.
11696 * tst-exec3.c: New file.
11698 * tst-fork1.c: Remove extra */.
11700 * nptl 0.2 released. The API for IA-32 is complete.