]> git.ipfire.org Git - thirdparty/glibc.git/blame - nptl/ChangeLog
Complete _BSD_SOURCE / _SVID_source followup cleanup.
[thirdparty/glibc.git] / nptl / ChangeLog
CommitLineData
6e89caf1
JM
12014-02-14 Joseph Myers <joseph@codesourcery.com>
2
3 * Makefile ($(objpfx)tst-cleanup0.out): Do not run cmp.
4 [$(run-built-tests) = yes] (tests): Depend on
5 $(objpfx)tst-cleanup0-cmp.out.
6 ($(objpfx)tst-cleanup0-cmp.out): New rule.
7
a1ffb40e
OB
82014-02-10 Ondřej Bílka <neleai@seznam.cz>
9
10 * allocatestack.c (queue_stack, allocate_stack,
11 __deallocate_stack, __reclaim_stacks): Use glibc_likely instead
12 __builtin_expect.
13 * cancellation.c (__pthread_enable_asynccancel,
14 __pthread_disable_asynccancel): Likewise.
15 * cleanup_defer.c (__pthread_register_cancel_defer,
16 __pthread_unregister_cancel_restore): Likewise.
17 * cleanup_defer_compat.c (_pthread_cleanup_push_defer,
18 _pthread_cleanup_pop_restore): Likewise.
19 * cond-perf.c (main): Likewise.
20 * nptl-init.c (sigcancel_handler, sighandler_setxid): Likewise.
21 * perf.c (get_clockfreq): Likewise.
22 * pthread_barrier_destroy.c (pthread_barrier_destroy): Likewise.
23 * pthread_barrier_init.c (pthread_barrier_init): Likewise.
24 * pthread_cond_timedwait.c (__pthread_cond_timedwait): Likewise.
25 * pthread_cond_wait.c (__pthread_cond_wait): Likewise.
26 * pthread_create.c (__free_tcb, start_thread, __pthread_create_2_1):
27 Likewise.
28 * pthread_getattr_np.c (pthread_getattr_np): Likewise.
29 * pthread_getspecific.c (__pthread_getspecific): Likewise.
30 * pthread_join.c (pthread_join): Likewise.
31 * pthread_key_delete.c (pthread_key_delete): Likewise.
32 * pthread_mutex_init.c (__pthread_mutex_init): Likewise.
33 * pthread_mutex_lock.c (__pthread_mutex_lock,
34 __pthread_mutex_lock_full): Likewise.
35 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Likewise.
36 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Likewise.
37 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Likewise.
38 * pthread_rwlock_rdlock.c (__pthread_rwlock_rdlock): Likewise.
39 * pthread_rwlock_timedrdlock.c (pthread_rwlock_timedrdlock): Likewise.
40 * pthread_rwlock_timedwrlock.c (pthread_rwlock_timedwrlock): Likewise.
41 * pthread_rwlock_tryrdlock.c (__pthread_rwlock_tryrdlock): Likewise.
42 * pthread_setcancelstate.c (__pthread_setcancelstate): Likewise.
43 * pthread_setcanceltype.c (__pthread_setcanceltype): Likewise.
44 * pthread_setschedprio.c (pthread_setschedprio): Likewise.
45 * pthread_setspecific.c (__pthread_setspecific): Likewise.
46 * sem_init.c (__new_sem_init): Likewise.
47 * sem_open.c (__where_is_shmfs): Likewise.
48 * sigaction.c: Likewise.
49 * sockperf.c (get_clockfreq): Likewise.
50 * sysdeps/pthread/createthread.c (do_clone, create_thread): Likewise.
51 * sysdeps/pthread/setxid.h: Likewise.
52 * sysdeps/pthread/timer_create.c (timer_create): Likewise.
53 * sysdeps/pthread/unwind-forcedunwind.c (pthread_cancel_init,
54 __unwind_freeres, _Unwind_Resume, __gcc_personality_v0,
55 _Unwind_ForcedUnwind): Likewise.
56 * sysdeps/unix/sysv/linux/getpid.c (__getpid): Likewise.
57 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
58 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): Likewise.
59 * sysdeps/unix/sysv/linux/mq_notify.c (mq_notify): Likewise.
60 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
61 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): Likewise.
62 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
63 (__pthread_setaffinity_new): Likewise.
64 * sysdeps/unix/sysv/linux/pthread_sigqueue.c (pthread_sigqueue):
65 Likewise.
66 * sysdeps/unix/sysv/linux/pt-raise.c (raise): Likewise.
67 * sysdeps/unix/sysv/linux/raise.c (raise): Likewise.
68 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (__lll_robust_trylock,
69 __lll_robust_lock, __lll_cond_lock, __lll_robust_timedlock): Likewise.
70 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (__lll_lock,
71 __lll_cond_lock, __lll_timedlock, __lll_robust_timedlock): Likewise.
72 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_destroy.c
73 (pthread_barrier_destroy): Likewise.
74 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_init.c
75 (pthread_barrier_init): Likewise.
76 * sysdeps/unix/sysv/linux/sparc/sem_init.c (__new_sem_init): Likewise.
77 * sysdeps/unix/sysv/linux/x86_64/timer_create.c (__timer_create_old):
78 Likewise.
79 * unwind.c (unwind_stop): Likewise.
80
6fc8123f
MF
812014-02-08 Mike Frysinger <vapier@gentoo.org>
82
83 * sem_open.c (__where_is_shmfs): Compare f.f_type to RAMFS_MAGIC too.
84
f877c4f2
CD
852014-02-05 Carlos O'Donell <carlos@redhat.com>
86
87 * sysdeps/unix/sysv/linux/tst-setgetname.c (do_test): Skip the
88 test if !__ASSUME_PROC_PID_TASK_COMM and get_self_comm returns
89 ENOENT.
90
e6848539
SL
912014-01-23 Stefan Liebler <stli@linux.vnet.ibm.com>
92
93 * tst-tls7.c: Adjust testcase timeout
94
2145f8b5
L
952014-01-18 H.J. Lu <hongjiu.lu@intel.com>
96
97 [BZ #14782]
98 * tst-cancel-wrappers.sh: Remove system.
99
2112e176
PP
1002014-01-11 Paul Pluzhnikov <ppluzhnikov@google.com>
101
102 * tst-tls7.c (action): New function.
103 (do_test): Call it.
104 * tst-tls7mod.c (action): Move sem_post to caller.
105
73d61e4f 1062011-12-12 Adhemerval Zanella <azanella@linux.vnet.ibm.com>
5b9bf191
AZ
107
108 * sysdeps/powerpc/tls.h (struct tcbhead_t): Add DSO and TAR fields.
109 * nptl/sysdeps/powerpc/tcb-offsets.sym: Likewise.
110
1db94db1
CD
1112013-12-09 Carlos O'Donell <carlos@redhat.com>
112
113 * sysdeps/unix/sysv/linux/tst-setgetname.c: New file.
114 * sysdeps/unix/sysv/linux/Makefile (tests): Add tst-setgetname.
115
caecf2a0
AS
1162013-12-09 Andreas Schwab <schwab@suse.de>
117
118 [BZ #15843]
119 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
120 (__pthread_cond_timedwait): Remove wrong cfi_adjust_cfa_offset
121 before __condvar_tw_cleanup2 label.
122
8b8a692c
UW
1232013-12-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
124
125 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
126 (CANCEL_FRAMESIZE, CANCEL_PARM_SAVE): New macros to save parameters
127 into our own stack frame instead of the caller's.
128 (PSEUDO): Use them. Use symbolic stack frame offsets.
129 (DOCARGS_1, UNDOCARGS_1): Use CANCEL_PARM_SAVE.
130 (DOCARGS_2, UNDOCARGS_2): Likewise.
131 (DOCARGS_3, UNDOCARGS_3): Likewise.
132 (DOCARGS_4, UNDOCARGS_4): Likewise.
133 (DOCARGS_5, UNDOCARGS_5): Likewise.
134 (DOCARGS_6, UNDOCARGS_6): Likewise.
135
d1d9eaf4 1362013-11-26 Ondřej Bílka <neleai@seznam.cz>
b0ef3aec 137
d1d9eaf4
OB
138 * sysdeps/i386/tls.h: Use __glibc_reserved instead __unused.
139 * sysdeps/x86_64/tls.h: Likewise.
140
67ea2c9a
PP
1412013-11-25 Paul Pluzhnikov <ppluzhnikov@google.com>
142
143 [BZ #11214]
144 * Makefile (tst-getpid2-ENV): New variable.
145
4b98b2dc 1462013-11-20 Paul Pluzhnikov <ppluzhnikov@google.com>
c8b82b81
PP
147
148 * Makefile (tst-cleanup2, tst-cleanupx2): Add -fno-builtin
149
cb8a6dbd
MF
1502013-10-30 Mike Frysinger <vapier@gentoo.org>
151
152 * sysdeps/pthread/configure.in: Moved to ...
153 * sysdeps/pthread/configure.ac: ... here.
154 * sysdeps/x86_64/configure.in: Moved to ...
155 * sysdeps/x86_64/configure.ac: ... here.
156 * sysdeps/pthread/configure: Regenerated.
157 * sysdeps/x86_64/configure: Likewise.
158
53247a0b
MR
1592013-10-04 Maciej W. Rozycki <macro@codesourcery.com>
160
161 * tst-mutex8.c (check_type) [ENABLE_PI]: Handle ENOTSUP failure
162 from pthread_mutex_init.
163
ad4e70da
SP
1642013-10-01 Siddhesh Poyarekar <siddhesh@redhat.com>
165
166 [BZ #15988]
167 * pthread_cond_broadcast.c (__pthread_cond_broadcast)
168 [lll_futex_cmp_requeue_pi && __ASSUME_REQUEUE_PI]: Use
169 USE_REQUEUE_PI.
170 * pthread_cond_signal.c (__pthread_cond_signal)
171 [lll_futex_cmd_requeue_pi && __ASSUME_REQUEUE_PI]: Likewise.
172
c04d498c
SP
1732013-09-27 Siddhesh Poyarekar <siddhesh@redhat.com>
174
175 * sysdeps/pthread/bits/libc-lock.h [_LIBC && (!NOT_IN_libc ||
176 IS_IN_libpthread)] (__libc_lock_fini_recursive): Use the mutex
177 member of the argument.
178 (__libc_lock_trylock_recursive): Likewise.
179 (__libc_lock_unlock_recursive): Likewise.
180
3f2e46a4
JM
1812013-09-04 Joseph Myers <joseph@codesourcery.com>
182
183 * sysdeps/unix/sysv/linux/x86_64/cancellation.S
184 [SHARED && DO_VERSIONING && !NO_HIDDEN]: Change conditional to
185 [SHARED && !NO_HIDDEN].
186
6c8bbad9
SP
1872013-09-03 Siddhesh Poyarekar <siddhesh@redhat.com>
188
189 [BZ #15921]
190 * tst-cleanup2.c (do_test): New volatile variable RET to
191 return success.
192
382466e0
OB
1932013-08-30 Ondřej Bílka <neleai@seznam.cz>
194
195 * sysdeps/pthread/pthread.h: Fix typos.
196 * sysdeps/unix/sysv/linux/internaltypes.h: Likewise.
197 * tst-cancel4.c: Likewise.
198
c0c3f78a
OB
1992013-08-21 Ondřej Bílka <neleai@seznam.cz>
200
201 * pthread_getschedparam.c: Fix typos.
202 * sysdeps/unix/sysv/linux/register-atfork.c: Likewise.
203
135529b4
DM
2042013-07-23 David S. Miller <davem@davemloft.net>
205
206 * tst-cancel4.c (WRITE_BUFFER_SIZE): Adjust comment.
207
e7074e4c
DM
2082013-07-22 David S. Miller <davem@davemloft.net>
209
210 * tst-cancel4.c (WRITE_BUFFER_SIZE): Increase to 16384.
211
d3d3ce98
DV
2122013-07-19 Dominik Vogt <vogt@de.ibm.com>
213
075b9322
DV
214 * pthread_mutex_lock.c: Fix whitespace.
215 * pthread_mutex_trylock.c: Likewise.
216 * sysdeps/unix/sysv/linux/x86/bits/pthreadtypes.h: Likewise.
217 * sysdeps/unix/sysv/linux/x86/elision-conf.c: Likewise.
218 * sysdeps/unix/sysv/linux/x86/elision-conf.h: Likewise.
219 * sysdeps/unix/sysv/linux/x86/elision-lock.c: Likewise.
220 * sysdeps/unix/sysv/linux/x86/elision-timed.c: Likewise.
221 * sysdeps/unix/sysv/linux/x86/elision-trylock.c: Likewise.
222 * sysdeps/unix/sysv/linux/x86/force-elision.h: Likewise.
223 * sysdeps/unix/sysv/linux/x86/hle.h: Likewise.
224 * sysdeps/unix/sysv/linux/x86/pthread_mutex_cond_lock.c: Likewise.
225 * sysdeps/unix/sysv/linux/x86/pthread_mutex_lock.c: Likewise.
226 * sysdeps/unix/sysv/linux/x86/pthread_mutex_timedlock.c: Likewise.
227 * sysdeps/unix/sysv/linux/x86/pthread_mutex_trylock.c: Likewise.
228
d3d3ce98
DV
229 * sysdeps/unix/sysv/linux/x86/elision-conf.c:
230 Remove __rwlock_rtm_enabled and __rwlock_rtm_read_retries.
231 (elision_init): Don't set __rwlock_rtm_enabled.
232 * sysdeps/unix/sysv/linux/x86/elision-conf.h:
233 Remove __rwlock_rtm_enabled.
234
e2a32bee
L
2352013-07-03 H.J. Lu <hongjiu.lu@intel.com>
236
237 * sysdeps/unix/sysv/linux/x86/init-arch.c: New file.
238 * sysdeps/unix/sysv/linux/x86/init-arch.h: Likewise.
239
1717da59
AK
2402013-07-02 Andi Kleen <ak@linux.intel.com>
241
242 * sysdeps/unix/sysv/linux/x86/elision-conf.c (elision_init):
243 Check ENABLE_LOCK_ELISION.
244
49186d21
AK
2452013-07-02 Andi Kleen <ak@linux.intel.com>
246
247 * pthread_mutexattr_settype.c (__pthread_mutexattr_settype):
248 Disable elision for PTHREAD_MUTEX_DEFAULT.
249
e8c659d7
AK
2502013-07-02 Andi Kleen <ak@linux.intel.com>
251 Hongjiu Lu <hongjiu.lu@intel.com>
252
253 * pthread_mutex_lock.c
254 (__pthread_mutex_lock): Add lock elision support.
255 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Likewise.
256 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Likewise.
257 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Likewise.
258 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
259 * sysdeps/unix/sysv/linux/x86/bits/pthreadtypes.h: Likewise.
260 * sysdeps/unix/sysv/linux/x86/Makefile: New file.
261 * sysdeps/unix/sysv/linux/x86/force-elision.h: New file
262 * sysdeps/unix/sysv/linux/x86/pthread_mutex_cond_lock.c: Likewise.
263 * sysdeps/unix/sysv/linux/x86/pthread_mutex_lock.c: Likewise.
264 * sysdeps/unix/sysv/linux/x86/pthread_mutex_timedlock.c: Likewise.
265 * sysdeps/unix/sysv/linux/x86/pthread_mutex_trylock.c: Likewise.
266 * sysdeps/unix/sysv/linux/x86/pthread_mutex_unlock.c: Likewise.
267
68cc2935
AK
2682013-07-02 Andi Kleen <ak@linux.intel.com>
269
270 * tst-mutex5.c: Include config.h.
271 (do_test): Add checks for ENABLE_LOCK_ELISION.
272 * tst-mutex8.c: Include config.h
273 (tf): Add checks for ENABLE_LOCK_ELISION.
274 (check_type): Likewise.
275
b023e4ca
AK
2762013-07-02 Andi Kleen <ak@linux.intel.com>
277
278 * pthreadP.h: Add elision types.
279 (PTHREAD_MUTEX_TYPE_ELISION): Add.
280 * sysdeps/pthread/pthread.h: Add elision initializers.
281 (PTHREAD_MUTEX_ELISION_NP, PTHREAD_MUTEX_NO_ELISION_NP,
282 PTHREAD_MUTEX_PSHARED_NP): Add new flags.
283 (__PTHREAD_SPINS): Add.
284
1cdbe579
AK
2852013-07-02 Andi Kleen <ak@linux.intel.com>
286 Hongjiu Lu <hongjiu.lu@intel.com>
287
288 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (__lll_timedwait_tid,
289 lll_timedlock_elision, __lll_lock_elision, __lll_unlock_elision,
290 __lll_trylock_elision, lll_lock_elision, lll_unlock_elision,
291 lll_trylock_elision): Add.
292 * sysdeps/unix/sysv/linux/x86/Makefile: Imply x86.
293 * sysdeps/unix/sysv/linux/x86/elision-conf.c: New file.
294 * sysdeps/unix/sysv/linux/x86/elision-conf.h: New file.
295 * sysdeps/unix/sysv/linux/x86/elision-lock.c: New file.
296 * sysdeps/unix/sysv/linux/x86/elision-timed.c: New file.
297 * sysdeps/unix/sysv/linux/x86/elision-trylock.c: New file.
298 * sysdeps/unix/sysv/linux/x86/elision-unlock.c: New file.
299 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (__lll_timedwait_tid,
300 lll_timedlock_elision, __lll_lock_elision, __lll_unlock_elision,
301 __lll_trylock_elision, lll_lock_elision, lll_unlock_elision,
302 lll_trylock_elision): Add.
303 * nptl/sysdeps/unix/sysv/linux/x86/hle.h: New file.
304 * elision-conf.h: New file.
305
e1f0b2cf
VN
3062013-06-24 Vladimir Nikulichev <v.nikulichev@gmail.com>
307
308 [BZ #12310]
309 * pthread_exit.c: Add reference to pthread_create.
310
e781d7c5
JM
3112013-06-22 Joseph Myers <joseph@codesourcery.com>
312
313 * pthread_getattr_default_np.c: Include <string.h>.
314
61dd6208
SP
3152013-06-15 Siddhesh Poyarekar <siddhesh@redhat.com>
316
317 * Versions (libpthread): Add GLIBC_2.18.
318 (GLIBC_2.18): Add pthread_setattr_default_np and
319 pthread_getattr_default_np.
320 * allocatestack.c (allocate_stack): Synchronize read from
321 __default_pthread_attr.
322 (__reclaim_stacks): Initialize __default_pthread_attr_lock.
323 * nptl-init.c (__pthread_initialize_minimal_internal):
324 Synchronize write to __default_pthread_attr.
325 * pthreadP.h (__default_pthread_attr_lock): Declare.
326 * pthread_attr_getstacksize (__pthread_attr_getstacksize):
327 Synchronize read from __default_pthread_attr.
328 * pthread_create.c (__pthread_create_2_1): Make a local copy of
329 __default_pthread_attr. Check value of flags in IATTR even if
330 input ATTR is NULL.
331 * pthread_getattr_default_np.c: New file.
332 * pthread_setattr_default_np.c: New file.
333 * sysdeps/pthread/pthread.h [__USE_GNU]
334 (pthread_getattr_default_np, pthread_setattr_default_np):
335 Declare.
336 * tst-default-attr.c: New test case.
337 * Makefile (libpthread-routines): Add
338 pthread_setattr_default_np and pthread_getattr_default_np.
339 (tests): Add tst-default-attr.
340 * vars.c (__default_pthread_attr_lock): Declare and initialize.
341
5865a56b
SP
3422013-06-13 Siddhesh Poyarekar <siddhesh@redhat.com>
343 Carlos O'Donell <carlos@redhat.com>
344
345 [BZ #15618]
346 * tst-pthread-attr-affinity: New test case.
347 * Makefile (tests): Add it.
348 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c
349 (__pthread_attr_getaffinity_new): Copy minimum of source and
350 destination sizes to avoid a buffer overrun.
351
be11d713
CD
3522013-06-10 Carlos O'Donell <carlos@redhat.com>
353
354 * sysdeps/unix/sysv/linux/i386/lowlevellock.h
355 (lll_futex_wake): Return syscall error.
356 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
357 (lll_futex_wake): Return syscall error.
358
e3f36662
OB
3592013-08-06 Ondřej Bílka <neleai@seznam.cz>
360
361 * sysdeps/pthread/allocalim.h: (__libc_use_alloca): Fix warning.
362
350635a5
OB
3632013-06-06 Ondřej Bílka <neleai@seznam.cz>
364
365 * tst-cond22.c: Fix leading whitespaces.
366 * tst-umask1.c: Likewise.
367
c7afae94
JM
3682013-06-06 Joseph Myers <joseph@codesourcery.com>
369
370 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Remove
371 trailing whitespace.
372 * sysdeps/unix/sysv/linux/powerpc/pt-longjmp.c: Likewise.
373 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
374 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Likewise.
375 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Likewise.
376 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Likewise.
377 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
378 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Likewise.
379 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Likewise.
380 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
381 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
382 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
383 * tst-mutexpp10.c: Likewise.
384 * tst-stackguard1.c: Likewise.
385
fab7ce3f
JM
3862013-05-31 Joseph Myers <joseph@codesourcery.com>
387
388 * Makefile ($(objpfx)libpthread.so): Remove dependencies on libc
389 and ld.so.
390
e054f494
RA
3912013-05-16 Ryan S. Arnold <rsa@linux.vnet.ibm.com>
392
393 * pthread_create.c: Add missing #include <stdint.h> due to uint64_t or
394 uint32_t usage.
395 * sysdeps/pthread/createthread.c: Likewise.
396
ecbf4342
AJ
3972013-05-14 Andreas Jaeger <aj@suse.de>
398
399 [BZ #10686]
400 * sysdeps/x86_64/tls.h (struct tcbhead_t): Add __private_ss field.
401 * sysdeps/i386/tls.h (struct tcbhead_t): Likewise.
402
66c13581
AK
4032013-05-09 Andi Kleen <ak@linux.intel.com>
404
405 * tst-mutex8.c (do_test): Check for ENABLE_PI.
406
da1304bc
SP
4072013-04-22 Siddhesh Poyarekar <siddhesh@redhat.com>
408
409 * pthreadP.h (check_sched_policy_attr): New inline function.
410 (check_sched_priority_attr): Likewise.
411 (check_stacksize_attr): Likewise.
412 (__kernel_cpumask_size, __determine_cpumask_size): Declare
413 extern.
414 (check_cpuset_attr): New inline function.
415 * pthread_attr_setschedparam (__pthread_attr_setschedparam):
416 Use check_sched_priority_attr.
417 * pthread_attr_setschedpolicy.c
418 (__pthread_attr_setschedpolicy): Use check_sched_policy_attr.
419 * pthread_attr_setstack.c (__pthread_attr_setstack): Use
420 check_stacksize_attr.
421 * pthread_attr_setstacksize.c (__pthread_attr_setstacksize):
422 Likewise.
423 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
424 (__pthread_attr_setaffinity_new): Use check_cpuset_attr.
425
4f682b2a
AS
4262013-04-11 Andreas Schwab <schwab@suse.de>
427
428 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
429 (__pthread_cond_timedwait): If possible use FUTEX_WAIT_BITSET to
430 directly use absolute timeout.
431
96497bb8
CD
4322013-04-07 Carlos O'Donell <carlos@redhat.com>
433
434 * sysdeps/unix/sysv/linux/sem_post.c: Include atomic.h.
435
9ac3b504
SP
4362013-04-04 Siddhesh Poyarekar <siddhesh@redhat.com>
437
438 [BZ #15337]
439 * sysdeps/unix/sysv/linux/x86_64/cancellation.S
440 [IS_IN_libpthread]
441 [SHARED && defined DO_VERSIONING && !defined NO_HIDDEN]: Mark
442 __pthread_unwind hidden.
443
e57b0c61
RM
4442013-03-28 Roland McGrath <roland@hack.frob.com>
445
446 * pthread_create.c (start_thread) [!SHARED]:
447 Call __call_tls_dtors only if it's not NULL.
448
e903a713
SP
4492013-03-19 Siddhesh Poyarekar <siddhesh@redhat.com>
450
5cebee5d
SP
451 * allocatestack.c (allocate_stack): Use __default_pthread_attr
452 instead of __default_stacksize.
e903a713
SP
453 * nptl-init.c (__pthread_initialize_minimal_internal):
454 Likewise. Initialize guardsize.
5cebee5d 455 * pthreadP.h (__default_pthread_attr): Declare.
e903a713 456 * pthread_attr_getstacksize.c (__pthread_attr_getstacksize):
5cebee5d 457 Use __default_pthread_attr instead of __default_stacksize.
e903a713 458 * pthread_create.c (default_attr): Remove.
5cebee5d 459 (__pthread_create_2_1): Use __default_pthread_attr instead of
e903a713
SP
460 default_attr.
461 * vars.c (__default_stacksize): Remove.
5cebee5d 462 (__default_pthread_attr): New static variable to store
e903a713
SP
463 default thread attributes.
464
69854bb5
SP
4652013-03-18 Siddhesh Poyarekar <siddhesh@redhat.com>
466
467 * pthread_barrier_init.c (default_attr): Rename to
468 default_barrierattr.
469 (pthread_barrier_init): Adjust for the rename.
470 * pthread_mutex_init.c (default_attr): Rename to
471 default_mutexattr.
472 (__pthread_mutex_init): Adjust for the rename.
473 * pthread_rwlock_init.c (default_attr): Rebane to
474 default_rwlockattr.
475 (__pthread_rwlock_init): Adjust for the rename.
476
05087fbb
CD
4772013-03-12 Carlos O'Donell <carlos@redhat.com>
478
479 * sysdeps/unix/sysv/linux/lowlevellock.c: Include <atomic.h>.
480
b43769a3
RM
4812013-03-04 Roland McGrath <roland@hack.frob.com>
482
483 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h:
484 Change multiple inclusion guard to _LINUX_I686_DL_SYSDEP_H.
485 Use #include_next.
486 (HAVE_DL_DISCOVER_OSVERSION): Remove definition, now redundant.
487 (RTLD_PRIVATE_ERRNO): Likewise.
488 (NEED_DL_SYSINFO, DL_SYSINFO_DEFAULT, DL_SYSINFO_IMPLEMENTATION):
489 Move macros and associated declaration to ...
490 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: ... here.
491 Change multiple include guard to _LINUX_I386_DL_SYSDEP_H.
492 Use #include_next.
493
4e9b5995
CD
4942013-03-01 Carlos O'Donell <carlos@redhat.com>
495
496 * Makefile (tests): Revert last change.
497 (tst-pthread-stack-env-ENV): Likewise.
498 * nptl-init.c (set_default_stacksize): Likewise.
499 (__pthread_initialize_minimal_internal): Likewise.
500 * tst-pthread-stack-env.c: Likewise.
501
e23872c8
SP
5022013-03-01 Siddhesh Poyarekar <siddhesh@redhat.com>
503
ace4acc8
SP
504 * tst-oddstacklimit.c: Include stdlib.h.
505
e23872c8
SP
506 * Makefile (tests): Add tst-pthread-stack-env.
507 (tst-pthread-stack-env-ENV): Set environment for test.
508 * nptl-init.c (set_default_stacksize): New function.
509 (__pthread_initialize_minimal_internal): Accept ARGC, ARGV and
510 ENVP. Initialize __ENVIRON and set __DEFAULT_STACKSIZE.
511 * tst-pthread-stack-env.c: New test case.
512
2b7ae1b2
DM
5132013-02-21 David S. Miller <davem@davemloft.net>
514
515 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h
516 (FUTEX_WAIT_REQUEUE_PI): Define.
517 (FUTEX_CMP_REQUEUE_PI): Likewise.
518 (lll_futex_wait_requeue_pi): Likewise.
519 (lll_futex_timed_wait_requeue_pi): Likewise.
520 (lll_futex_cmp_requeue_pi): Likewise.
521
9bf95cbc
CD
5222013-02-21 Carlos O'Donell <carlos@redhat.com>
523
524 * sysdeps/unix/sysv/linux/fork.c: Fix comment typo.
525
8313cb99
SP
5262013-02-18 Siddhesh Poyarekar <siddhesh@redhat.com>
527
f4804ca2
SP
528 * sysdeps/pthread/tst-timer.c: Include stdlib.h for declaration
529 of exit.
530 * tst-barrier4.c: Likewise.
531 * tst-robust7.c: Likewise.
532
8313cb99
SP
533 [BZ #14920]
534 * pthreadP.h (USE_REQUEUE_PI): New macro to check if mutex is
535 PI-aware.
536 * pthread_cond_broadcast.c (__pthread_cond_broadcast): Use
537 PI-aware futex operations if available and mutex is PI-aware.
538 * pthread_cond_signal.c (__pthread_cond_signal): Likewise.
539 * nptl/pthread_cond_timedwait.c (__pthread_cond_timedwait):
540 Likewise.
541 * pthread_cond_wait.c (__condvar_cleanup): Adjust lock if
542 cancellation occurred just after futex returned successfully
543 from a PI operation with the mutex held.
544 (__pthread_cond_wait): Use PI-aware futex operations if
545 available and mutex is PI-aware.
546 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
547 (FUTEX_WAIT_REQUEUE_PI): Define.
548 (FUTEX_CMP_REQUEUE_PI): Likewise.
549 (lll_futex_wait_requeue_pi): Likewise.
550 (lll_futex_timed_wait_requeue_pi): Likewise.
551 (lll_futex_cmp_requeue_pi): Likewise.
552 * nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h
553 (FUTEX_WAIT_REQUEUE_PI): Define.
554 (FUTEX_CMP_REQUEUE_PI): Likewise.
555 (lll_futex_wait_requeue_pi): Likewise.
556 (lll_futex_timed_wait_requeue_pi): Likewise.
557 (lll_futex_cmp_requeue_pi): Likewise.
558 * sysdeps/unix/sysv/linux/kernel-features.h: Define
559 __ASSUME_REQUEUE_PI for Linux version higher than 2.6.31.
560
903ae060
AS
5612013-02-04 Andreas Schwab <schwab@suse.de>
562
563 [BZ #14142]
564 * tst-cancel14.c: Include <sys/time.h>.
565 * tst-cancel15.c: Likewise.
566 * tst-mutex9.c: Include <stdint.h>, <stdlib.h> and <sys/time.h>.
567 * tst-stackguard1.c: Include <tls.h>
568
cfa8054f
AS
5692013-01-16 Andreas Schwab <schwab@suse.de>
570
571 [BZ #14327]
572 * sem_open.c (sem_open): Use __mktemp instead of mktemp.
573
c0609c5c
CD
5742013-01-11 Carlos O'Donell <codonell@redhat.com>
575
576 * allocatestack.c (allocate_stack): Add comment. Remove assert
577 on attr.
578
740b3dbe
L
5792013-01-11 H.J. Lu <hongjiu.lu@intel.com>
580
581 * Makefile (tst-cancel7-ARGS: Replace $(host-built-program-cmd)
582 with $(host-test-program-cmd).
583 (tst-exec4-ARGS): Likewise.
584 (tst-stackguard1-ARGS): Likewise.
585 ($(objpfx)tst-tls6.out): Don't pass $(elf-objpfx) to tst-tls6.sh.
586 Replace $(rtld-installed-name) with $(test-via-rtld-prefix).
587 * tst-tls6.sh (elf_objpfx): Removed.
588 (rtld_installed_name): Renamed to ...
589 (test_via_rtld_prefix): This.
590 (tst_tls5): Prepend ${test_via_rtld_prefix}.
591
568035b7
JM
5922013-01-02 Joseph Myers <joseph@codesourcery.com>
593
594 * All files with FSF copyright notices: Update copyright dates
595 using scripts/update-copyrights.
596
f4cf5f2d
JM
5972013-01-01 Joseph Myers <joseph@codesourcery.com>
598
599 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Reformat
600 copyright notice.
601
c93c5dec
AK
6022012-12-28 Andi Kleen <ak@linux.intel.com>
603
740b3dbe 604 * pthread_rwlock_tryrdlock.c (__pthread_rwlock_tryrdlock): Convert
c93c5dec 605 to prototype.
740b3dbe 606 * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock):
c93c5dec
AK
607 Likewise.
608
9c7595bd
DM
6092012-12-27 David S. Miller <davem@davemloft.net>
610
611 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h
612 (lll_futex_timed_wait_bitset): New macro.
613
8ebac778
SP
6142012-12-27 Siddhesh Poyarekar <siddhesh@redhat.com>
615
616 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (SYS_futex):
617 Remove definition.
618 (lll_futex_timed_wait): Replace assembly code with
619 INTERNAL_SYSCALL.
620 (lll_futex_timed_wait_bitset): Likewise.
621 (lll_futex_wake): Likewise.
622 (lll_futex_requeue): Likewise.
623 (lll_futex_wake_unlock): Likewise.
624
56e7d3ad
SP
6252012-12-08 Siddhesh Poyarekar <siddhesh@redhat.com>
626
627 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c (_longjmp_unwind):
628 Declare LOCAL_VAR as char.
629
d39b9545
JM
6302012-12-04 Joseph Myers <joseph@codesourcery.com>
631
632 * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__old_sem_post):
633 Cast result of atomic_increment_val to (void) instead of storing
634 in otherwise-unused variable.
635
e30907c3
AM
6362012-12-03 Allan McRae <allan@archlinux.org>
637
638 * Makefile (LDFLAGS-tst-cond24, LDFLAGS-tst-cond25): Remove.
639
c515fb51
L
6402012-11-26 H.J. Lu <hongjiu.lu@intel.com>
641
642 * unwind.c (__pthread_unwind): Pass address of unwind_cleanup
643 to THREAD_SETMEM.
644 * sysdeps/i386/tls.h: Include <libc-internal.h>.
645 (THREAD_SETMEM): Use cast_to_integer before casting to uint64_t.
646 (THREAD_SETMEM_NC): Likewise.
647 * sysdeps/x86_64/tls.h: Include <libc-internal.h>.
648 (THREAD_SETMEM): Use cast_to_integer before casting to uint64_t.
649 (THREAD_SETMEM_NC): Likewise.
650
fac9916c
JM
6512012-11-21 Joseph Myers <joseph@codesourcery.com>
652
09e958ed
JM
653 * sysdeps/unix/sysv/linux/sem_post.c (__old_sem_post): Cast result
654 of atomic_increment_val to (void) instead of storing in
655 otherwise-unused variable.
656
fac9916c
JM
657 * pthread_cond_timedwait.c (__pthread_cond_timedwait)
658 [__NR_clock_gettime]: Cast result of INTERNAL_VSYSCALL to void
659 instead of storing in otherwise-unused variable.
660
c485e4d2
MS
6612012-11-14 Marcus Shawcroft <marcus.shawcroft@linaro.org>
662
663 * Makefile (CFLAGS-open.c, CFLAGS-open64.c, CFLAGS-pause.c)
664 (CFLAGS-recv.c, CFLAGS-send.c): Define.
665
91e0d40e
CM
6662012-11-06 Chris Metcalf <cmetcalf@tilera.com>
667
668 * tst-sem14.c (TIMEOUT): Set timeout to 10 seconds.
669 * tst-cond24.c (TIMEOUT): Increase from 10 to 20 seconds.
670
8f861542
SP
6712012-11-05 Siddhesh Poyarekar <siddhesh@redhat.com>
672
673 * pthread_cond_timedwait.c (__pthread_cond_timedwait): Time out
674 if absolute timeout is negative.
675 [__ASSUME_FUTEX_CLOCK_REALTIME &&
676 lll_futex_timed_wait_bitset]: Use lll_futex_timed_wait_bitset.
677 * pthread_rwlock_timedrdlock.c (pthread_rwlock_timedrdlock):
678 Likewise.
679 * pthread_rwlock_timedwrlock.c (pthread_rwlock_timedwrlock):
680 Likewise.
681 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
682 (__lll_robust_timedlock_wait): Likewise.
683 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
684 (lll_futex_timed_wait_bitset): New macro.
685 * sysdeps/unix/sysv/linux/s390/lowlevellock.h
686 (lll_futex_timed_wait_bitset): Likewise.
687
d3bd58cf
DM
6882012-11-03 David S. Miller <davem@davemloft.net>
689
690 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (BUSY_WAIT_NOP):
691 Add missing spaces.
692 (__cpu_relax): Likewise.
693
f62c8abc
L
6942012-11-02 H.J. Lu <hongjiu.lu@intel.com>
695
696 * sysdeps/x86_64/tls.h: Don't include <xmmintrin.h>.
697 (__128bits): New struct typedef.
698 (tcbhead_t): Replace __m128 with __128bits.
699
a9879fee
AJ
7002012-10-30 Aurelien Jarno <aurelien@aurel32.net>
701 Joseph Myers <joseph@codesourcery.com>
702
703 * Makefile (tst-cancel7-ARGS): Use exec in --command argument.
704
19f1dd5f
DM
7052012-10-28 David S. Miller <davem@davemloft.net>
706
707 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (BUSY_WAIT_NOP):
708 Define when we have v9 instructions available.
709 * sysdeps/unix/sysv/linux/sparc/sparc64/cpu_relax.S: New file.
710 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/cpu_relax.S: New
711 file.
712 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/Makefile: New
713 file.
714 * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: Add cpu_relax
715 to libpthread-routines.
716
b9473651
RM
7172012-10-25 Roland McGrath <roland@hack.frob.com>
718
719 * tst-cond-except.c (TEST_FUNCTION): New macro.
720
6a345e42
JM
7212012-10-25 Joseph Myers <joseph@codesourcery.com>
722
723 * Makefile ($(objpfx)tst-tls6.out): Use $(BASH) not $(SHELL) to
724 run tst-tls6.sh.
725 * tst-tls6.sh: Use /bin/bash not /bin/sh.
726
c0a1472e
RM
7272012-10-25 Roland McGrath <roland@hack.frob.com>
728
729 * tst-basic2.c (do_test): Return RESULT, not always zero.
730
731 * tst-cond25.c: Include <stdint.h>
732 (waiter): Add casts to uintptr_t between casting integer<->pointer.
733 (timed_waiter): Likewise.
734 (do_test_wait): Likewise.
735 * tst-cond-except.c (thr): Likewise.
736 (do_test): Use prototype definition.
737
cc1290d0
JM
7382012-10-24 Joseph Myers <joseph@codesourcery.com>
739 Jim Blandy <jimb@codesourcery.com>
740
741 * Makefile ($(objpfx)tst-tls6.out): Pass $(test-wrapper-env) to
742 tst-tls6.sh.
743 * tst-tls6.sh (test_wrapper_env): New variable. Use it to run
744 programs with LD_PRELOAD set.
745
6e6249d0
RM
7462012-10-24 Roland McGrath <roland@hack.frob.com>
747
748 * Makefile ($(objpfx)tst-cond11, $(objpfx)tst-cond19): Targets removed.
749 ($(objpfx)tst-sem5, $(objpfx)tst-cancel18): Likewise.
750 ((objpfx)tst-cancelx18, $(objpfx)tst-clock2): Likewise.
751 ($(objpfx)tst-rwlock14): Likewise.
752
0bf57f87
JM
7532012-10-24 Joseph Myers <joseph@codesourcery.com>
754
755 * Makefile (tests): Remove tst-oddstacklimit.
756 (test-srcs): New variable.
757 (tst-oddstacklimit-ENV): Remove.
758 [$(run-built-tests) = yes] (tests): Depend on
759 $(objpfx)tst-oddstacklimit.out.
760 [$(run-built-tests) = yes] ($(objpfx)tst-oddstacklimit.out): New
761 target.
762 * tst-oddstacklimit.c: Do not include "tst-basic1.c". Use
763 setrlimit before executing tst-basic1 test passed to --command.
764
03ac099f
JM
7652012-10-23 Joseph Myers <joseph@codesourcery.com>
766
767 * Makefile [$(cross-compiling) = no]: Change condition to
768 [$(run-built-tests) = yes].
769
166bca24
JB
7702012-10-23 Jim Blandy <jimb@codesourcery.com>
771 Joseph Myers <joseph@codesourcery.com>
772
773 * Makefile (tst-cancel7-ARGS): Use $(host-built-program-cmd).
774 (tst-exec4-ARGS): Likewise.
775 (tst-stackguard1-ARGS): Likewise.
776
aba75984
JB
7772012-10-21 Jim Blandy <jimb@codesourcery.com>
778 Joseph Myers <joseph@codesourcery.com>
779
780 * Makefile ($(objpfx)tst-cancel-wrappers.out): Pass $(NM) to
781 tst-cancel-wrappers.sh.
782 * tst-cancel-wrappers.sh: Use nm program given as first argument,
783 not hardcoded "nm".
784
37785907
SP
7852012-10-17 Siddhesh Poyarekar <siddhesh@redhat.com>
786
370539fb 787 * tst-cond25.c (do_test_wait): Don't check for return value from
37785907
SP
788 pthread_cancel.
789
9485a404
SP
7902012-10-16 Siddhesh Poyarekar <siddhesh@redhat.com>
791
792 [BZ #14652]
793 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
794 (__condvar_tw_cleanup): Adjust the mutex data structure if it
795 was locked by FUTEX_WAIT_REQUEUE_PI.
796 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait
797 (__condvar_w_cleanup): Likewise.
798 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
799 (__condvar_cleanup2): Likewise.
800 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
801 (__condvar_cleanup1): Likewise.
802
0d522f64
CD
8032012-10-10 Carlos O'Donell <carlos@systemhalted.org>
804
54a41734
CD
805 * sysdeps/pthread/pthread.h [!(defined __GNUC__ &&
806 defined __EXCEPTIONS) && defined __USE_GNU]
807 (pthread_cleanup_push_defer_np): Fix formatting.
0d522f64 808
0e3b5d6a
SP
8092012-10-10 Siddhesh Poyarekar <siddhesh@redhat.com>
810
811 [BZ #14652]
812 * Makefile (tests): New test case tst-cond25.
813 (LDFLAGS-tst-cond25): Link tst-cond25 against librt.
814 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
815 (__condvar_tw_cleanup): Lock mutex only if we don't already
816 own it.
817 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
818 (__condvar_w_cleanup): Likewise.
819 * sysdeps/unix/sysv/linux/pthread-pi-defines.sym: Add TID_MASK.
820 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
821 (__condvar_cleanup2): Lock mutex only if we don't already
822 own it.
823 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
824 (__condvar_cleanup1): Likewise.
825 * tst-cond25.c: New test case.
826
b8493de0
RM
8272012-10-09 Roland McGrath <roland@hack.frob.com>
828
829 * sysdeps/pthread/configure: Regenerated.
830 * sysdeps/x86_64/configure: Regenerated.
831
f0762164
DM
8322012-10-05 David S. Miller <davem@davemloft.net>
833
834 [BZ #14568]
835 * sysdeps/sparc/tls.h (DB_THREAD_SELF_INCLUDE): Delete.
836 (DB_THREAD_SELF): Use constants for the register offsets. Correct
837 the case of a 64-bit debugger with a 32-bit inferior.
838
1d1b34df
L
8392012-10-05 H.J. Lu <hongjiu.lu@intel.com>
840
841 [BZ #14557]
842 * Makefile (tests-static): Add tst-cancel24-static,
843 tst-cond8-static tst-mutex8-static, tst-mutexpi8-static,
844 tst-sem11-static and tst-sem12-static.
845 (tests): Likewise.
846 (LDLIBS-tst-cancel24-static): New macro.
847 * tst-cancel24-static.cc: New file.
848 * tst-cond8-static.c: Likewise.
849 * tst-mutex8-static.c: Likewise.
850 * tst-mutexpi8-static.c: Likewise.
851 * tst-sem11-static.c: Likewise.
852 * tst-sem12-static.c: Likewise.
853
c30e8edf
SP
8542012-10-05 Siddhesh Poyarekar <siddhesh@redhat.com>
855
856 [BZ #14417]
857 * Makefile (tests): New test case tst-cond24.
858 (LDFLAGS-tst-cond24): Link tst-cond24 against librt.
859 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
860 (__pthread_cond_timedwait): Unlock mutex before going back to
861 wait in PI case.
862 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
863 (__pthread_cond_wait): Likewise. Revert handling of EAGAIN
864 return from futex_wait.
865 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
866 (__pthread_cond_timedwait): Unlock mutex before going back to
867 wait in PI case. Set requeue_pi flag only if wait returned 0.
868 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
869 (__pthread_cond_wait): Likewise. Revert handling of EAGAIN
870 return from futex_wait.
871 * tst-cond24.c: New test case.
872
9043e228
RM
8732012-10-04 Roland McGrath <roland@hack.frob.com>
874
875 * pthread_create.c (start_thread): Use __madvise, not madvise.
876
b2f80a47
L
8772012-10-02 H.J. Lu <hongjiu.lu@intel.com>
878
879 * sysdeps/i386/tls.h: Update copyright years.
880
adcdc775
SP
8812012-10-02 Siddhesh Poyarekar <siddhesh@redhat.com>
882
883 * pthread_create.c (start_thread): Fix clone flag name in
884 comment to CLONE_CHILD_CLEARTID.
885 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
886 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
887 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
888 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
889 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
890 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
891
55a051c9
SP
8922012-10-01 Siddhesh Poyarekar <siddhesh@redhat.com>
893
894 [BZ #14477]
895 * Makefile (tests): Add tst-cond-except.
896 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
897 (__pthread_cond_timedwait): Mark instructions where %ebx is
898 incremented in PI case.
899 (.gcc_except_table): Add entry to jump to __condvar_tw_cleanup2
900 for the marked PI case instructions.
901 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
902 (__pthread_cond_wait): Mark instructions where %ebx is
903 incremented in PI case.
904 (.gcc_except_table): Add entry to jump to __condvar_w_cleanup2
905 for the marked PI case instructions.
906 * tst-cond-except.c: New test case.
907
9a9028b1
DL
9082012-09-24 Dmitry V. Levin <ldv@altlinux.org>
909
57c69bef
DL
910 * tst-tls6.sh: Add "set -e".
911 * Makefile: Do not specify -e option when running testsuite
912 shell scripts.
913
9a9028b1
DL
914 * tst-tls6.sh: Add copyright header.
915
620f3d26
L
9162012-09-24 H.J. Lu <hongjiu.lu@intel.com>
917
918 * sysdeps/x86_64/tls.h (THREAD_SETMEM): Add "()" when casting
919 to uint64_t for 64-bit store.
920 (THREAD_SETMEM_NC): Likewise.
921
ae30640a
L
9222012-09-19 H.J. Lu <hongjiu.lu@intel.com>
923
924 * sysdeps/i386/tls.h (THREAD_SETMEM): Cast to uint64_t for
925 64-bit store.
926 (THREAD_SETMEM_NC): Likewise.
927
97bc38d7
JL
9282012-09-14 Jeff Law <law@redhat.com>
929
930 [BZ #14583]
931 * sysdeps/pthread/pthread.h: Fix prototype of __sigsetjmp.
932
9503345f
L
9332012-09-13 H.J. Lu <hongjiu.lu@intel.com>
934
935 [BZ #14576]
936 * sysdeps/pthread/bits/libc-lockP.h (__rtld_lock_init_recursive):
937 Removed.
938
e9ceaf25
L
9392012-09-07 H.J. Lu <hongjiu.lu@intel.com>
940
70d37fe0 941 * Makefile (LDFLAGS-tst-cancel24): Renamed to ...
e9ceaf25
L
942 (LDLIBS-tst-cancel24): This.
943
f5fce062
L
9442012-09-06 H.J. Lu <hongjiu.lu@intel.com>
945
946 [BZ #14545]
947 * Makefile (tests-static): Add tst-cancel21-static.
948 (tests): Likewise.
949 * tst-cancel21-static.c: New file.
950
26889eac
JM
9512012-09-01 Joseph Myers <joseph@codesourcery.com>
952
953 * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c
954 [!__ASSUME_POSIX_CPU_TIMERS]: Remove conditional code.
955 [__NR_clock_getres]: Make code unconditional.
956 (pthread_getcpuclockid): Remove code left unreachable by removal
957 of conditionals.
958
033d54a2 9592012-08-31 Joseph Myers <joseph@codesourcery.com>
b2e1c562 960
033d54a2
JM
961 [BZ #14532]
962 * sysdeps/unix/sysv/linux/sem_post.c (__new_sem_post): Use
963 atomic_compare_and_exchange_bool_rel.
964 * tst-sem14.c: New file.
965 * Makefile (tests): Add tst-sem14.
b2e1c562 966
c75ccd4c
RM
9672012-08-15 Roland McGrath <roland@hack.frob.com>
968
969 * Makefile (CFLAGS-flockfile.c): Use $(libio-mtsafe) instead
970 of -D_IO_MTSAFE_IO.
971 (CFLAGS-ftrylockfile.c, CFLAGS-funlockfile.c): Likewise.
b2e1c562 972 * sysdeps/unix/sysv/linux/Makefile (CFLAGS-fork.c): Likewise.
c75ccd4c 973
93a78ac4
JM
9742012-08-16 Joseph Myers <joseph@codesourcery.com>
975
976 * pthread_cond_timedwait.c (__pthread_cond_timedwait)
977 [!__ASSUME_POSIX_TIMERS]: Remove conditional code.
978 * pthread_condattr_setclock.c (pthread_condattr_setclock)
979 [!__ASSUME_POSIX_TIMERS]: Likewise.
980 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
981 (__pthread_cond_timedwait) [!__ASSUME_POSIX_TIMERS]: Likewise.
982 * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c
983 [!__ASSUME_POSIX_TIMERS]: Likewise.
984 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
985 (__pthread_cond_timedwait) [!__ASSUME_POSIX_TIMERS]: Likewise.
986 * sysdeps/unix/sysv/linux/timer_create.c [__NR_timer_create]: Make
987 code unconditional.
988 [!__NR-timer_create]: Remove conditional code.
989 (timer_create) [!__ASSUME_POSIX_TIMERS]: Likewise.
990 * sysdeps/unix/sysv/linux/timer_delete.c [__NR_timer_delete]: Make
991 code unconditional.
992 [!__NR_timer_delete]: Remove conditional code.
993 (timer_delete) [!__ASSUME_POSIX_TIMERS]: Likewise.
994 * sysdeps/unix/sysv/linux/timer_getoverr.c
995 [__NR_timer_getoverrun]: Make code unconditional.
996 [!__NR_timer_getoverrun]: Remove conditional code.
997 (timer_getoverrun) [!__ASSUME_POSIX_TIMERS]: Likewise.
998 * sysdeps/unix/sysv/linux/timer_gettime.c [__NR_timer_gettime]:
999 Make code unconditional.
1000 [!__NR_timer_gettime]: Remove conditional code.
1001 (timer_gettime) [!__ASSUME_POSIX_TIMERS]: Likewise.
1002 * sysdeps/unix/sysv/linux/timer_routines.c [__NR_timer_create]:
1003 Make code unconditional.
1004 [!__ASSUME_POSIX_TIMERS]: Remove conditional code.
1005 * sysdeps/unix/sysv/linux/timer_settime.c [__NR_timer_settime]:
1006 Make code unconditional.
1007 [!__NR_timer_settime]: Remove conditional code.
1008 (timer_settime) [!__ASSUME_POSIX_TIMERS]: Likewise.
1009 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
1010 (__pthread_cond_timedwait) [!__ASSUME_POSIX_TIMERS]: Remove
1011 conditional code.
1012
309becf1
MK
10132012-08-15 Tom de Vries <vries@codesourcery.com>
1014 Maxim Kuvyrkov <maxim@codesourcery.com>
1015
1016 * sysdeps/pthread/bits/libc-lockP.h (__libc_lock_lock)
1017 (__libc_lock_trylock): Allow pre-existing definitions.
1018
ef400973
MK
10192012-08-15 Maxim Kuvyrkov <maxim@codesourcery.com>
1020
1021 * pthread_spin_lock.c: New file.
1022 * pthread_spin_trylock.c: New file.
1023
b36137f1
JM
10242012-08-08 Joseph Myers <joseph@codesourcery.com>
1025
1026 * allocatestack.c (setxid_signal_thread) [__ASSUME_TGKILL]: Make
1027 code unconditional.
1028 (setxid_signal_thread) [!__ASSUME_TGKILL]: Remove conditional code.
1029 * pthread_cancel.c (pthread_cancel) [__ASSUME_TGKILL]: Make code
1030 unconditional.
1031 (pthread_cancel) [!__ASSUME_TGKILL]: Remove conditional code.
1032 * sysdeps/pthread/createthread.c (do_clone) [__ASSUME_TGKILL]:
1033 Make code unconditional.
1034 (do_clone) [!__ASSUME_TGKILL]: Remove conditional code.
1035 * sysdeps/unix/sysv/linux/pt-raise.c (raise) [__ASSUME_TGKILL ||
1036 __NR_tgkill]: Make code unconditional.
1037 (raise) [__ASSUME_TGKILL]: Likewise.
1038 (raise) [!__ASSUME_TGKILL]: Remove conditional code.
1039 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill)
1040 [__ASSUME_TGKILL]: Make code unconditional.
1041 (__pthread_kill) [!__ASSUME_TGKILL]: Remove conditional code.
1042 * sysdeps/unix/sysv/linux/raise.c (raise) [__ASSUME_TGKILL ||
1043 __NR_tgkill]: Make code unconditional.
1044 (raise) [__ASSUME_TGKILL]: Likewise.
1045 (raise) [!__ASSUME_TGKILL]: Remove conditional code.
1046
93df14ee
JM
10472012-08-07 Joseph Myers <joseph@codesourcery.com>
1048
1049 * sysdeps/pthread/createthread.c (create_thread)
1050 [!__ASSUME_NO_CLONE_DETACHED]: Remove conditional code.
1051
85fe1997
JM
10522012-08-03 Joseph Myers <joseph@codesourcery.com>
1053
1054 * nptl-init.c (sigcancel_handler) [__ASSUME_CORRECT_SI_PID]: Make
1055 code unconditional.
1056 (sighandler_setxid) [__ASSUME_CORRECT_SI_PID]: Likewise.
1057
fc56c5bb
SP
10582012-07-28 Siddhesh Poyarekar <siddhesh@redhat.com>
1059
1060 * tst-pthread-getattr.c (MAX_STACK_SIZE): New macro.
1061 (pagesize): New static variable.
1062 (allocate_and_test): Return MEM. Rename parameter to TARGET.
1063 (check_stack_top): New local variables MEM and PAGEMASK. Cap
1064 stack size to MAX_STACK_SIZE. Call allocate_and_test for
1065 halfway up the stack top page. Verify that the top page was
1066 written into.
1067 (do_test): Get pagesize using sysconf.
1068
842a39cd
AS
10692012-07-25 Andreas Schwab <schwab@linux-m68k.org>
1070
1071 * sysdeps/unix/sysv/linux/i386/pt-vfork.S: Remove pseudo_end
1072 label.
1073 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (PSEUDO): Likewise.
1074 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (PSEUDO):
1075 Likewise.
1076
77b32274
SP
10772012-07-25 Siddhesh Poyarekar <siddhesh@redhat.com>
1078
1079 * tst-pthread-getattr.c: Revert last change.
1080
b2ae49da
SP
10812012-07-20 Siddhesh Poyarekar <siddhesh@redhat.com>
1082
1083 * tst-pthread-getattr.c (MAX_STACK_SIZE): New max cap for stack
1084 size.
1085 (_MIN): New macro.
1086 (allocate_and_test): Return STACKADDR. Access STACKADDR instead
1087 of MEM to test.
1088 (check_stack_top): Read valued written into STACKADDR in
1089 allocate_and_test. Cap stack size to MAX_STACK_SIZE.
1090
a9843058
SP
10912012-07-19 Siddhesh Poyarekar <siddhesh@redhat.com>
1092
1093 * nptl-init.c (sighandler_setxid): Fix the comment that
1094 describes it.
1095
4b2c8da7
TS
10962012-06-23 Thomas Schwinge <thomas@codesourcery.com>
1097
1098 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S
1099 (__lll_robust_timedlock_wait): Simplify CFI directives.
1100
18b5e737
SP
11012012-06-20 Siddhesh Poyarekar <siddhesh@redhat.com>
1102
1103 [BZ #12416]
1104 * Makefile (tests): Add test case.
1105 * pthread_getattr_np.c (pthread_getattr_np): Deduct pages below
1106 the __libc_stack_end page from stacksize. Truncate stacksize to
1107 make it page aligned when it is computed from RLIMIT_STACK.
1108 * tst-pthread-getattr.c: New test case. Verify that stackaddr is
1109 accessible.
1110
24a6dbed
CSLL
11112012-06-07 Carlos Sánchez de La Lama <csanchezdll@gmail.com>
1112
1113 [BZ #14205]
1114 * sysdeps/sparc/sparc32/pthread_spin_lock.S: Do not use v9
1115 branches.
1116
4af3879c
SP
11172012-06-04 Siddhesh Poyarekar <siddhesh@redhat.com>
1118 Jakub Jelinek <jakub@redhat.com>
1119
1120 [BZ #14188]
1121 * sysdeps/pthread/pthread.h
1122 [!(defined __GNUC__ && defined __EXCEPTIONS)]
1123 (pthread_cleanup_push, pthread_cleanup_push_defer_np): Use
1124 __libc_unlikely instead of __builtin_expect.
1125
0e20515a
L
11262012-05-30 H.J. Lu <hongjiu.lu@intel.com>
1127
1128 [BZ #14117]
1129 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Removed.
1130 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h: Likewise.
1131 * sysdeps/unix/sysv/linux/i386/Implies: New file.
1132 * sysdeps/unix/sysv/linux/x86_64/Implies: Likewise.
1133 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Renamed
1134 to ...
1135 * sysdeps/unix/sysv/linux/x86/bits/pthreadtypes.h: This.
1136 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Renamed
1137 to ...
1138 * sysdeps/unix/sysv/linux/x86/bits/semaphore.h: This.
1139
865eac65
AS
11402012-05-30 Andreas Schwab <schwab@linux-m68k.org>
1141
1142 [BZ #14132]
1143 * nptl-init.c (pthread_functions): Remove use of INTUSE and
1144 _internal aliases.
1145 (__pthread_initialize_minimal_internal): Likewise.
1146 * sem_open.c: Likewise.
1147 * sem_unlink.c: Likewise.
1148 * pthreadP.h: Replace _internal aliases by hidden_proto
1149 declarations.
1150 * pthread_getspecific.c: Replace _internal alias by hidden_def.
1151 * pthread_key_create.c: Likewise.
1152 * pthread_mutex_destroy.c: Likewise.
1153 * pthread_mutex_init.c: Likewise.
1154 * pthread_mutex_lock.c: Likewise.
1155 * pthread_mutex_unlock.c: Likewise.
1156 * pthread_once.c: Likewise.
1157 * pthread_rwlock_rdlock.c: Likewise.
1158 * pthread_rwlock_unlock.c: Likewise.
1159 * pthread_rwlock_wrlock.c: Likewise.
1160 * pthread_setspecific.c: Likewise.
1161 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S:
1162 Likewise.
1163 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
1164 Likewise.
1165 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S:
1166 Likewise.
1167 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
1168 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c: Likewise.
1169 * sysdeps/unix/sysv/linux/s390/pthread_once.c: Likewise.
1170 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Likewise.
1171 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
1172 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
1173 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
1174 * sysdeps/unix/sysv/linux/sparc/pthread_once.c: Likewise.
1175 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
1176 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S:
1177 Likewise.
1178 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S:
1179 Likewise.
1180 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S:
1181 Likewise.
1182
65a4de4e
CLT
11832012-05-27 Chung-Lin Tang <cltang@codesourcery.com>
1184
d701a1ab
CLT
1185 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (PSEUDO, LOAD_ARGS_1)
1186 (LOAD_ARGS_2 ,LOAD_ARGS_3 ,LOAD_ARGS_4): Add CFI restores.
1187
65a4de4e
CLT
1188 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_lock_wait_private)
1189 (__lll_lock_wait, __lll_timedlock_wait, __lll_timedwait_tid): Add CFI
1190 directives.
1191 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S
1192 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): Likewise.
1193 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S
1194 (pthread_barrier_wait): Likewise.
1195 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
1196 (__pthread_cond_broadcast): Likewise.
1197 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S
1198 (__pthread_cond_signal): Likewise.
1199 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
1200 (__pthread_cond_timedwait): Likewise.
1201 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S (__pthread_cond_wait):
1202 Likewise.
1203 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S
1204 (__pthread_rwlock_rdlock): Likewise.
1205 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S
1206 (pthread_rwlock_timedrdlock): Likewise.
1207 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S
1208 (pthread_rwlock_timedwrlock): Likewise.
1209 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S
1210 (__pthread_rwlock_unlock): Likewise.
1211 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S
1212 (__pthread_rwlock_wrlock): Likewise.
1213 * sysdeps/unix/sysv/linux/sh/sem_post.S (__new_sem_post): Likewise.
1214 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait): Likewise.
1215 * sysdeps/unix/sysv/linux/sh/sem_trywait.S (__new_sem_trywait):
1216 Likewise.
1217 * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait): Likewise.
1218
9c6ea9fa
SP
12192012-05-26 Siddhesh Poyarekar <siddhesh@redhat.com>
1220
1221 [BZ #12416]
1222 * nptl/pthread_getattr_np.c (pthread_getattr_np): Use
1223 __libc_stack_end rounded to the end of containing page as the
1224 real stack end.
1225
17557282
RH
12262012-05-25 Rayson Ho <rho@redhat.com>
1227
1228 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Low-level SystemTap
1229 probes for i386.
1230 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
1231 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
1232 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
1233 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
1234 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
1235 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
1236 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
1237 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
1238
5acf7263
RM
12392012-05-25 Rayson Ho <rho@redhat.com>
1240 Roland McGrath <roland@hack.frob.com>
1241
1242 * DESIGN-systemtap-probes.txt: New file.
1243 * pthread_cond_broadcast.c: SystemTap probes.
1244 * pthread_cond_init.c: Likewise.
1245 * pthread_cond_signal.c: Likewise.
1246 * pthread_cond_wait.c: Likewise.
1247 * pthread_cond_destroy.c: Likewise.
1248 * pthread_create.c: Likewise.
1249 * pthread_join.c: Likewise.
1250 * pthread_mutex_destroy.c: Likewise.
1251 * pthread_mutex_init.c: Likewise.
1252 * pthread_mutex_lock.c: Likewise.
1253 * pthread_mutex_timedlock.c: Likewise.
1254 * pthread_mutex_unlock.c: Likewise.
1255 * pthread_rwlock_destroy.c: Likewise.
1256 * pthread_rwlock_rdlock.c: Likewise.
1257 * pthread_rwlock_unlock.c: Likewise.
1258 * pthread_rwlock_wrlock.c: Likewise.
1259 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
1260 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
1261 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
1262 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
1263 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
1264 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
1265 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
1266 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
1267
3a097cc7
RM
12682012-05-24 Roland McGrath <roland@hack.frob.com>
1269
1270 * pthread_create.c (start_thread): Define pthread_start LIBC_PROBE.
1271
de7f5ce7
AJ
12722012-05-17 Andreas Jaeger <aj@suse.de>
1273
1274 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h
1275 (HAVE_DL_DISCOVER_OSVERSION): Don't declare _dl_discover_osversion
1276 only for older kernels.
1277
04807399
JM
12782012-05-15 Joseph Myers <joseph@codesourcery.com>
1279
1280 * pthreadP.h [!__NR_set_robust_list] (__NR_set_robust_list): Do
1281 not define.
1282
f16af742
L
12832012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1284
1285 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_lock): Load
1286 futex pointer into RDI_LP. Use RSP_LP to operate on stack.
1287 (lll_robust_lock): Likewise.
1288 (lll_cond_lock): Likewise.
1289 (lll_robust_cond_lock): Likewise.
1290 (lll_timedlock): Likewise.
1291 (lll_robust_timedlock): Likewise.
1292 (lll_unlock): Likewise.
1293 (lll_robust_unlock): Likewise.
1294
d9754f55
L
12952012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1296
1297 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Use
1298 LP_OP(cmp) and RCX_LP on dep_mutex pointer.
1299
dde05f00
L
13002012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1301
1302 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Use LP_OP(op)
1303 on NWAITERS.
1304 (__gcc_personality_v0): Replace 8-byte data alignment with
1305 LP_SIZE alignment and .quad with ASM_ADDR.
1306
9dba3b5c
L
13072012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1308
1309 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Use LP_OP(op)
1310 on NWAITERS.
1311 (__gcc_personality_v0): Replace 8-byte data alignment with
1312 LP_SIZE alignment and .quad with ASM_ADDR.
1313
5f658cf1
L
13142012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1315
1316 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Use LP_OP(cmp) on
1317 NWAITERS, which is unsigned long int.
1318
6cae4b26
L
13192012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1320
1321 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S
1322 (__gcc_personality_v0): Replace 8-byte data alignment with
1323 LP_SIZE alignment and .quad with ASM_ADDR.
1324
592f90e6
L
13252012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1326
1327 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Use
1328 LP_OP(cmp), RSI_LP and R8_LP on dep_mutex pointer. Load
1329 __vdso_clock_gettime pointer into RAX_LP.
1330 (__gcc_personality_v0): Replace 8-byte data alignment with
1331 LP_SIZE alignment and .quad with ASM_ADDR.
1332
0e8860ad
L
13332012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1334
1335 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Use
1336 LP_OP(cmp), RSI_LP and R8_LP on dep_mutex pointer. Load
1337 __vdso_clock_gettime pointer into RAX_LP.
1338 (__gcc_personality_v0): Replace 8-byte data alignment with
1339 LP_SIZE alignment and .quad with ASM_ADDR.
1340
30996e93
L
13412012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1342
1343 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Use
1344 LP_OP(cmp) and R8_LP on dep_mutex pointer.
1345
289ac435
L
13462012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1347
1348 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: Use LP_OP(mov)
1349 to update pointer in memory. Load pointer into RDI_LP.
1350
10f74fbc
L
13512012-05-15 H.J. Lu <hongjiu.lu@intel.com>
1352
1353 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
1354 (LLL_STUB_UNWIND_INFO_START): Align label to LP_SIZE instead
1355 of 8.
1356 (LLL_STUB_UNWIND_INFO_END): Likewise.
1357 (lll_timedlock): Load timeout pointer into RDX_LP.
1358 (lll_robust_timedlock): Likewise.
1359
439bf404
SP
13602012-05-15 Siddhesh Poyarekar <siddhesh@redhat.com>
1361 Jakub Jelinek <jakub@redhat.com>
1362
1363 [BZ #13613]
1364 * Makefile (tests): Add test cases.
1365 * descr.h (struct pthread): Add a comment describing multiple_threads.
1366 * pthreadP.h (__pthread_multiple_threads): Expand comment to include
1367 single-process case.
1368 * pthread_cancel.c (pthread_cancel): Enable multiple_threads
1369 before setting cancelstate of the thread.
1370 * sysdeps/unix/sysv/linux/libc_multiple_threads.c
1371 (__libc_multiple_threads): Add explanatory comment.
1372 * tst-cancel-self-cancelstate.c: New test case.
1373 * tst-cancel-self-canceltype.c: Likewise.
1374 * tst-cancel-self-cleanup.c: Supporting file for test cases.
1375 * tst-cancel-self-testcancel.c: New test case.
1376 * tst-cancel-self.c: Likewise.
1377 * vars.c: Expand comment to include single-process case.
1378
2949684c
L
13792012-05-14 H.J. Lu <hongjiu.lu@intel.com>
1380
1381 * sysdeps/x86_64/tls.h: Don't include <bits/wordsize.h>.
1382 (tcbhead_t): Remove __x86_64__ check. Align rtld_savespace_sse
1383 to 32 bytes.
1384
245a11d7
L
13852012-05-14 H.J. Lu <hongjiu.lu@intel.com>
1386
1387 * sysdeps/pthread/pthread.h (__PTHREAD_RWLOCK_INT_FLAGS_SHARED):
1388 New.
1389 (PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP): Check
1390 __PTHREAD_RWLOCK_INT_FLAGS_SHARED instead of __WORDSIZE.
1391
0b254d8f
L
13922012-05-14 H.J. Lu <hongjiu.lu@intel.com>
1393
1394 * shlib-versions: Move x86_64-.*-linux.* entry to ...
1395 * sysdeps/x86_64/64/shlib-versions: Here. New file.
1396 * sysdeps/x86_64/x32/shlib-versions: New file.
1397
b8caea2c
L
13982012-05-14 H.J. Lu <hongjiu.lu@intel.com>
1399
1400 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Define x32
1401 __SIZEOF_PTHREAD_XXX_T.
1402 (__pthread_internal_list): Check __x86_64__ instead of __WORDSIZE.
1403 (pthread_mutex_t): Likewise.
1404 (pthread_rwlock_t): Likewise.
1405 (__PTHREAD_RWLOCK_INT_FLAGS_SHARED): New. Defined if __x86_64__
1406 is defined.
1407
60d45b36
L
14082012-05-11 H.J. Lu <hongjiu.lu@intel.com>
1409
1410 * sysdeps/x86_64/x32/tls.h: New file.
1411
a04e06bc
L
14122012-05-11 H.J. Lu <hongjiu.lu@intel.com>
1413
1414 * sysdeps/x86_64/tls.h (THREAD_SETMEM): Use uint64_t on 64-bit
1415 integer.
1416 (THREAD_SETMEM_NC): Likewise.
1417
512ec530
L
14182012-05-11 H.J. Lu <hongjiu.lu@intel.com>
1419
1420 * sysdeps/x86_64/tls.h (THREAD_SELF): Replace movq/%q0 with
1421 mov/%0.
1422
c0d2c853
L
14232012-05-11 H.J. Lu <hongjiu.lu@intel.com>
1424
1425 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
1426 (__cleanup_fct_attribute): Check __x86_64__ instead of
eae2d36a 1427 __WORDSIZE.
c0d2c853 1428
1f59b0b1
L
14292012-05-11 H.J. Lu <hongjiu.lu@intel.com>
1430
1431 * sysdeps/pthread/pthread.h (PTHREAD_MUTEX_INITIALIZER): Check
1432 __PTHREAD_MUTEX_HAVE_PREV instead of __WORDSIZE.
1433 (PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP): Likewise.
1434 (PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP): Likewise.
1435 (PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP): Likewise.
1436
c252ec15
L
14372012-05-11 H.J. Lu <hongjiu.lu@intel.com>
1438
1439 * pthread_create.c (start_thread): Check __PTHREAD_MUTEX_HAVE_PREV
1440 instead of __WORDSIZE.
1441
be971a2b
TS
14422012-05-10 Thomas Schwinge <thomas@schwinge.name>
1443
1444 [BZ #3748]
1445 * sysdeps/pthread/bits/libc-lockP.h (__libc_once_get): New macro.
1446
e1b4354e
CLT
14472012-05-09 Chung-Lin Tang <cltang@codesourcery.com>
1448
1449 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
1450 (__pthread_cond_timedwait): Use CFI directives.
1451 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S
1452 (__pthread_cond_wait): Likewise.
1453 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait): Likewise.
1454 * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait): Likewise.
1455
76e835cf
DM
14562012-05-03 David S. Miller <davem@davemloft.net>
1457
1458 * sysdeps/sparc/sparc64/pthread_spin_unlock.S: Fix thinko, we
1459 always have to return 0, especially for the pthread_spin_init
1460 alias.
1461 * sysdeps/sparc/sparc32/pthread_spin_lock.S: Add missing trailing
1462 newline.
1463 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_lock.S: Likewise.
1464 * sysdeps/sparc/sparc64/pthread_spin_lock.S: Likewise.
1465
e2dbf201
DM
14662012-05-02 David S. Miller <davem@davemloft.net>
1467
1468 * sysdeps/sparc/sparc64/pthread_spin_lock.S: New.
1469 * sysdeps/sparc/sparc64/pthread_spin_lock.c: Delete.
1470 * sysdeps/sparc/sparc64/pthread_spin_unlock.S: New.
1471 * sysdeps/sparc/sparc64/pthread_spin_unlock.c: Delete.
1472 * sysdeps/sparc/sparc64/pthread_spin_trylock.S: New.
1473 * sysdeps/sparc/sparc64/pthread_spin_trylock.c: Delete.
1474 * sysdeps/sparc/sparc64/pthread_spin_init.c: New.
1475 * sysdeps/sparc/sparc32/pthread_spin_lock.S: New.
1476 * sysdeps/sparc/sparc32/pthread_spin_lock.c: Delete.
1477 * sysdeps/sparc/sparc32/pthread_spin_trylock.S: New.
1478 * sysdeps/sparc/sparc32/pthread_spin_trylock.c: Delete.
1479 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_lock.S: New.
1480 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_lock.c: Delete.
1481 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_trylock.S: New.
1482 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_trylock.c: Delete.
1483 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_unlock.S: New.
1484 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_unlock.c: Delete.
1485 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_init.c: New.
1486
d4c2917f
AM
14872012-05-02 Allan McRae <allan@archlinux.org>
1488
1489 * Makefile: (LDFLAGS-tst-tls5): Use $(no-as-needed).
1490 (LDFLAGS-tst-cancel24): Likewise.
1491
b93d565a
PP
14922012-05-02 Paul Pluzhnikov <ppluzhnikov@google.com>
1493
1494 * sysdeps/i386/pthread_spin_lock.S: New.
1495 * sysdeps/i386/pthread_spin_lock.c: Delete.
1496 * sysdeps/x86_64/pthread_spin_lock.S: New.
1497 * sysdeps/x86_64/pthread_spin_lock.c: Delete.
1498
6d5c57fa
AS
14992012-04-28 Andreas Schwab <schwab@linux-m68k.org>
1500
1501 * Makefile ($(objpfx)tst-stack3-mem, $(objpfx)tst-tls6.out): Don't
1502 run when cross-compiling.
1503
6e236b92
SP
15042012-04-26 Siddhesh Poyarekar <siddhesh@redhat.com>
1505
1506 * sysdeps/pthread/unwind-forcedunwind.c: Include gnu/lib-names.h
1507 instead of libgcc_s.h.
1508
0cec7c54
PP
15092012-04-20 Paul Pluzhnikov <ppluzhnikov@google.com>
1510
1511 * sysdeps/x86_64/tls.h (TLS_GET_FS, TLS_SET_FS): Delete.
1512
7ac88e38
DM
15132012-03-27 David S. Miller <davem@davemloft.net>
1514
1515 * tst-cond16.c (do_test): Use a thread stack size which is either
1516 PTHREAD_STACK_MIN or the page size, whichever is larger.
1517 * tst-cond18.c (do_test): Likewise.
1518
24d8f4b7
L
15192012-03-19 H.J. Lu <hongjiu.lu@intel.com>
1520
1521 * sysdeps/x86_64/pthreaddef.h (CURRENT_STACK_FRAME): Use
1522 register char * __asm__("rsp") to get stack frame.
1523
4adaaafc
L
15242012-03-19 H.J. Lu <hongjiu.lu@intel.com>
1525
1526 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (SYS_futex): Use
1527 __NR_futex directly.
1528
ca7b8af5
L
15292012-03-19 H.J. Lu <hongjiu.lu@intel.com>
1530
1531 * unwind.c (unwind_stop): Cast _Unwind_GetCFA return to
1532 _Unwind_Ptr first.
1533
7e7fa5f8
DM
15342012-03-16 David S. Miller <davem@davemloft.net>
1535
1536 [BZ #13844]
1537 * sysdeps/unix/sysv/linux/libc-lowlevellock.c: Include using <..>
1538 instead of "...".
1539 * sysdeps/unix/sysv/linux/sparc/sparc32/libc-lowlevellock.c:
1540 Delete, not needed.
1541
c4a7b16e
DM
15422012-03-15 David S. Miller <davem@davemloft.net>
1543
1544 [BZ #13844]
1545 * sysdeps/unix/sysv/linux/sparc/sparc32/libc-lowlevellock.c: New file.
1546
c524201a
PE
15472012-03-09 Paul Eggert <eggert@cs.ucla.edu>
1548
1549 [BZ #13673]
1550 * pt-crti.S: Replace FSF snail mail address with URL.
1551
90ad551f
JM
15522012-03-09 Joseph Myers <joseph@codesourcery.com>
1553
1554 * sysdeps/pthread/pthread.h (__need_clockid_t, __need_timespec):
1555 Do not define before including <time.h>.
1556
c64bf5fe
DM
15572012-03-08 David S. Miller <davem@davemloft.net>
1558
1559 * sysdeps/unix/sysv/linux/sparc/sem_post.c: Update copyright year.
1560
48aff776
TS
15612012-03-08 Thomas Schwinge <thomas@codesourcery.com>
1562
2edd9a79
TS
1563 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_timedlock_wait):
1564 Check for timestamp before the Epoch.
1565
c564a812
TS
1566 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait): Fix
1567 updating nwaiters.
1568
48aff776
TS
1569 * tst-sem13.c (do_test): Add another test case.
1570 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
1571 Fix updating nwaiters.
1572
e7dbb1be
JM
15732012-03-07 Joseph Myers <joseph@codesourcery.com>
1574
1575 [BZ #10545]
1576 * sysdeps/pthread/configure.in (libc_cv_forced_unwind): Change
1577 link test to a compile test.
1578 (libc_cv_c_cleanup): Likewise. Declare puts rather than including
1579 <stdio.h>.
1580 * sysdeps/pthread/configure: Regenerated.
1581
a4300c7a
UD
15822012-03-07 Ulrich Drepper <drepper@gmail.com>
1583
1584 * Makefile (distribute): Remove variable.
1585
840df61e
TS
15862012-01-23 Thomas Schwinge <thomas@codesourcery.com>
1587
1588 * sysdeps/unix/sysv/linux/sem_timedwait.c (sem_timedwait): Get rid of
1589 superfluous assignment.
1590 * sysdeps/unix/sysv/linux/sparc/sem_timedwait.c (sem_timedwait):
1591 Likewise.
1592 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c
1593 (sem_timedwait): Likewise.
1594
9463518d
UD
15952012-03-06 Ulrich Drepper <drepper@gmail.com>
1596
abdf2e19
UD
1597 * sysdeps/pthread/bits/libc-lock.h: Move information not needed in
1598 installed headers to...
9463518d
UD
1599 * sysdeps/pthread/bits/libc-lockP.h: ...here. New file.
1600
e9258400
DM
16012012-03-06 David S. Miller <davem@davemloft.net>
1602
1603 * sysdeps/unix/sysv/linux/sparc/sem_post.c (__new_sem_post): Use
1604 atomic_increment and remove unused local variable.
1605 (__old_sem_post): Likewise.
1606
22f9d9df
DM
16072012-02-27 David S. Miller <davem@davemloft.net>
1608
9463518d
UD
1609 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Don't refer to
1610 non-existing __pthread_attr.
22f9d9df
DM
1611 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
1612 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
1613 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
1614 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
1615 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
1616
4efeffc1
UD
16172012-02-26 Ulrich Drepper <drepper@gmail.com>
1618
d94a4670
UD
1619 * sysdeps/pthread/pthread.h: Define __need_clockid_t for __USE_XOPEN2K.
1620
4efeffc1
UD
1621 * sysdeps/pthread/pthread.h: Define __need_timespec before including
1622 <time.h>.
1623 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Name pthread_attr_t
1624 union.
1625 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
1626 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
1627 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
1628 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
1629 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
1630
0e7dfaef
JM
16312012-02-21 Joseph Myers <joseph@codesourcery.com>
1632
1633 [BZ #13695]
1634 * Makefile (generated): Remove crti.S, crtn.S, defs.h and
1635 pt-initfini.s.
1636 [crti.S not in sysdirs] (omit-deps): Do not append.
1637 [crti.S not in sysdirs] (CFLAGS-pt-initfini.s): Remove variable.
1638 [crti.S not in sysdirs] (pt-initfini.c): Remove vpath directive.
1639 [crti.S not in sysdirs] ($(objpfx)crti.S): Remove rule.
1640 [crti.S not in sysdirs] ($(objpfx)crtn.S): Likewise.
1641 [crti.S not in sysdirs] ($(objpfx)defs.h): Likewise.
1642 [crti.S not in sysdirs] ($(objpfx)crti.o): Likewise.
1643 [crti.S not in sysdirs] ($(objpfx)crtn.o): Likewise.
1644 [crti.S in sysdirs] (extra-objs): Append unconditionally.
1645 [crti.S in sysdirs] ($(objpfx)crti.o): Define rule
1646 unconditionally.
1647 * sysdeps/pthread/pt-initfini.c: Remove file.
1648
e3b69ca7
RH
16492012-02-16 Richard Henderson <rth@twiddle.net>
1650
959e12e3
UD
1651 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c: Remove file.
1652 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: Remove file.
e3b69ca7 1653
df83af67
KK
16542012-02-15 Kaz Kojima <kkojima@rr.iij4u.or.jp>
1655
1656 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: Remove file.
1657
f63f3380
DM
16582012-02-16 David S. Miller <davem@davemloft.net>
1659
1660 * sysdeps/sparc/Makefile: Add -fPIC when building pt-crti.S and crtn.S
1661
d463ab10
MP
16622012-02-15 Marek Polacek <polacek@redhat.com>
1663
1664 * sysdeps/unix/sysv/linux/x86_64/Makefile: Remove file.
1665
59ba27a6
PE
16662012-02-09 Paul Eggert <eggert@cs.ucla.edu>
1667
1668 Replace FSF snail mail address with URLs, as per GNU coding standards.
1669
28328403
AS
16702012-02-08 Andreas Schwab <schwab@linux-m68k.org>
1671
1672 * Makefile (extra-objs) [crti.S in sysdirs]: Add pt-crti.o.
1673
3add8e13
JM
16742012-02-08 Joseph Myers <joseph@codesourcery.com>
1675
1676 Support crti.S and crtn.S provided directly by architectures.
1677 * Makefile [crti.S in sysdirs] (omit-deps): Do not append.
1678 [crti.S in sysdirs] (CFLAGS-pt-initfini.s): Do not define variable.
1679 [crti.S in sysdirs] ($(objpfx)pt-initfini.s): Disable rule.
1680 [crti.S in sysdirs] ($(objpfx)crti.S): Likewise.
1681 [crti.S in sysdirs] ($(objpfx)crtn.S): Likewise.
1682 [crti.S in sysdirs] ($(objpfx)defs.h): Likewise.
1683 [crti.S in sysdirs] ($(objpfx)crti.o): Likewise.
1684 [crti.S in sysdirs] ($(objpfx)crtn.o): Likewise.
1685 [crti.S in sysdirs] (pt-initfini.c): Remove vpath directive.
1686 [crti.S in sysdirs] ($(objpfx)crti.o): New rule.
1687 * pt-crti.S: New file.
1688 * sysdeps/unix/sysv/linux/i386/Makefile: Remove file.
1689
9a1d9254
JM
16902012-02-03 Joseph Myers <joseph@codesourcery.com>
1691
1692 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Use
1693 macros for PIC register setup.
1694 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
1695 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
1696 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
1697 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
1698 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
1699
5452bffe
UD
17002012-01-11 Marek Polacek <polacek@redhat.com>
1701
1702 * forward.c (FORWARD_NORETURN): Define macro.
1703 (__pthread_unwind): Use FORWARD_NORETURN macro to avoid warning.
1704 (__pthread_exit): Likewise.
1705
356fa562
UD
17062012-01-10 Ulrich Drepper <drepper@gmail.com>
1707
8898f020
UD
1708 * sysdeps/pthread/pthread.h: Add const attribute to pthread_equal.
1709
356fa562
UD
1710 * pthreadP.h: Add noreturn to __pthread_exit.
1711 * sysdeps/pthread/pthread-functions.h: Likewise for ptr___pthread_exit.
1712
f5420cf0
AZ
17132011-12-30 Adhemerval Zanella <azanella@linux.vnet.ibm.com>
1714
1715 * sysdeps/unix/sysv/linux/aio_misc.h (__aio_create_helper_thread):
1716 Call pthread_attr_setstacksize() with result of
1717 __pthread_get_minstack() to account for application TLS usage.
1718
c473bd1c
MP
17192012-01-08 Marek Polacek <polacek@redhat.com>
1720
1721 * sysdeps/unix/sysv/linux/mq_notify.c: Include <nptl/pthreadP.h>.
1722
120ced3f
UD
17232012-01-07 Ulrich Drepper <drepper@gmail.com>
1724
a784e502
UD
1725 [BZ #13553]
1726 * pthreadP.h: Use const instead of __const.
1727 * semaphore.h: Likewise.
1728 * sysdeps/pthread/bits/libc-lock.h: Likewise.
1729 * sysdeps/pthread/bits/sigthread.h: Likewise.
1730 * sysdeps/pthread/pthread.h: Likewise.
1731
0269750c
UD
1732 * Makefile: Remove elf=yes test, only ELF is supported.
1733
ecb6fb48
UD
1734 * shlib-versions: Remove entries for ports architectures.
1735
120ced3f
UD
1736 In case anyone cares, the IA-64 architecture could move to ports.
1737 * sysdeps/ia64/*: Removed.
1738 * sysdeps/unix/sysv/linux/ia64/*: Removed.
1739
2c1094bd
UD
17402011-12-22 Ulrich Drepper <drepper@gmail.com>
1741
ee9e0640
UD
1742 * sysdeps/pthread/gai_misc.h (__gai_create_helper_thread): Use
1743 __pthread_get_minstack.
1744 * sysdeps/unix/sysv/linux/mq_notify.c (init_mq_netlink): Likewise.
1745
2c1094bd
UD
1746 [BZ #13088]
1747 * sysdeps/unix/sysv/linux/timer_routines.c: Get minimum stack size
1748 through __pthread_get_minstack.
1749 * nptl-init.c (__pthread_initialize_minimal_internal): Get page size
1750 directly from _rtld_global_ro.
1751 (__pthread_get_minstack): New function.
1752 * pthreadP.h: Declare __pthread_get_minstack.
1753 * Versions (libpthread) [GLIBC_PRIVATE]: Add __pthread_get_minstack.
1754
60e8585f
UD
17552011-12-21 Ulrich Drepper <drepper@gmail.com>
1756
1757 [BZ #13515]
1758 * sysdeps/unix/sysv/linux/pthread_getname.c (pthread_getname_np):
1759 Correct reading name from file.
1760
caafb2b0
CD
17612011-12-14 Carlos O'Donell <carlos@systemhalted.org>
1762
1763 * allocatestack.c (allocate_stack): Return errno on failure.
1764
e988dba9
JL
17652011-12-14 Jeff Law <law@redhat.com>
1766
1767 [BZ #5245]
1768 * pthread_create.c (__pthread_create_2_1): Translate ENOMEM to EAGAIN.
1769
ade60c89
UD
17702011-11-28 Andreas Schwab <schwab@redhat.com>
1771
1772 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Handle
1773 EAGAIN from FUTEX_WAIT_REQUEUE_PI.
1774 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
1775
312be3f9
UD
17762011-11-15 Ulrich Drepper <drepper@gmail.com>
1777
1778 * pthread_getattr_np.c (pthread_getattr_np): Set FD_CLOEXEC for
1779 /proc/self/maps.
1780
c2b18f7a
UD
17812011-10-29 Ulrich Drepper <drepper@gmail.com>
1782
1783 [BZ #13358]
1784 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
1785 (__pthread_cond_timedwait): Initialize %r15 correctly also for code
1786 path for kernels with FUTEX_CLOCK_REALTIME.
1787 Debugged by H.J. Lu <hjl.tools@gmail.com>.
1788
3871f58f
AS
17892011-10-27 Andreas Schwab <schwab@redhat.com>
1790
1791 [BZ #13344]
1792 * sysdeps/pthread/pthread.h: Use __THREADNL instead of __THREAD
1793 for memory synchronization functions.
1794 * semaphore.h: Likewise.
1795
485683c3
UD
17962011-10-24 Ulrich Drepper <drepper@gmail.com>
1797
1798 * tst-cancel7.c: Avoid warning.
1799 * tst-mutex6.c: Likewise.
1800 * tst-mutex9.c: Likewise.
1801 * tst-mutexpi6.c: Likewise.
1802
10d005f7
UD
18032011-10-23 Ulrich Drepper <drepper@gmail.com>
1804
1805 * sysdeps/i386/tls.h: Remove #include <list.h>.
1806
fd5bdc09
UD
18072011-10-15 Ulrich Drepper <drepper@gmail.com>
1808
10d005f7 1809 * pthread_create.c (start_thread): Call __ctype_init.
fd5bdc09 1810
7a775e6b
AS
18112011-09-15 Andreas Schwab <schwab@redhat.com>
1812
1813 * sysdeps/pthread/list.h: Define only list_t if __need_list_t is
1814 defined.
1815 (list_add): Add atomic_write_barrier.
1816 * descr.h: Define __need_list_t before including <list.h>.
1817 * nptl-init.c: Include <list.h>
1818 * allocatestack.c: Likewise.
1819
83cd1420
UD
18202011-09-11 Ulrich Drepper <drepper@gmail.com>
1821
1822 * sysdeps/i386/tls.h: Remove HAVE_TLS_SUPPORT test.
1823 * sysdeps/ia64/tls.h: Likewise.
1824 * sysdeps/powerpc/tls.h: Likewise.
1825 * sysdeps/s390/tls.h: Likewise.
1826 * sysdeps/sh/tls.h: Likewise.
1827 * sysdeps/sparc/tls.h: Likewise.
1828 * sysdeps/x86_64/tls.h: Likewise.
1829
3ce1f295
UD
18302011-09-10 Ulrich Drepper <drepper@gmail.com>
1831
02d46fc4
UD
1832 * sysdeps/pthread/malloc-machine.h: Define MUTEX_INITIALIZER.
1833
d063d164
UD
1834 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Don't handle
1835 !USE___THREAD.
1836 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
1837 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
1838 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
1839 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
1840 * sysdeps/unix/sysv/linux/sh/sem_post.S: Likewise.
1841 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
1842 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Likewise.
1843 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Likewise.
1844 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
1845 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
1846 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
1847 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
1848
3ce1f295
UD
1849 * tst-tls1.c: Support for __thread is now mandatory.
1850 * tst-tls2.c: Likewise.
1851 * tst-tls3.c: Likewise.
1852 * tst-tls3mod.c: Likewise.
1853 * tst-tls4.c: Likewise.
1854 * tst-tls4moda.c: Likewise.
1855 * tst-tls4modb.c: Likewise.
1856 * tst-tls5.h: Likewise.
1857
1e4bd093
L
18582011-09-08 Ulrich Drepper <drepper@gmail.com>
1859
1860 [BZ #12403]
1861 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
1862 (pthread_rwlock_timedwrlock): Use correct macro in test.
1863 Patch by H.J. Lu <hongjiu.lu@intel.com>.
1864
a0e1f41b
UD
18652011-09-06 Ulrich Drepper <drepper@gmail.com>
1866
1867 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait): Don't
1868 use gettimeofday vsyscall, just call gettimeofday.
9e5c9dcd
UD
1869 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
1870 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Likewise.
1871 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
1872 Likewise.
1873 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
1874 Likewise.
1875 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
1876 Simplify __vdso_clock_gettime use.
a0e1f41b 1877
39c4451c
DM
18782011-09-05 David S. Miller <davem@davemloft.net>
1879
1880 * sysdeps/unix/sysv/linux/sem_timedwait.c (do_futex_timed_wait):
1881 New function.
1882 (sem_timedwait): Call it to force an exception region around
1883 the async cancel enable and the futex operation.
1884 * sysdeps/unix/sysv/linux/sparc/sem_timedwait.c: Likewise.
1885 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c: Likewise.
1886 * sysdeps/unix/sysv/linux/sem_wait.c (do_futex_wait): New function.
1887 (__new_sem_wait): Call it to force an exception region around
1888 the async cancel enable and the futex operation.
1889 * sysdeps/unix/sysv/linux/sparc/sem_wait.c: Likewise.
1890 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c: Likewise.
1891
523df511
AS
18922011-08-31 Andreas Schwab <schwab@redhat.com>
1893
1894 * allocatestack.c (setxid_mark_thread): Ensure that the exiting
1895 thread is woken up.
1896
e315850c
DM
18972011-08-20 David S. Miller <davem@davemloft.net>
1898
1899 * Makefile (tst-cleanup0.out): Fix typo in output redirection.
1900
5744c68d
RM
19012011-08-14 Roland McGrath <roland@hack.frob.com>
1902
1903 * sysdeps/i386/pthreaddef.h (TCB_ALIGNMENT): Set to 64, optimal on Atom.
1904 * sysdeps/x86_64/pthreaddef.h (TCB_ALIGNMENT): Likewise.
1905
a724d1b9
AS
19062011-08-08 Andreas Schwab <schwab@redhat.com>
1907
1908 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: Maintain aligned
1909 stack.
1910 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
1911 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
1912
7a03a9c8
UD
19132011-07-22 Ulrich Drepper <drepper@gmail.com>
1914
1915 * sysdeps/pthread/unwind-forcedunwind.c (_Unwind_Resume): Add read
1916 barrier.
1917 (__gcc_personality_v0): Likewise.
1918 (_Unwind_ForcedUnwind): Likewise.
1919 (_Unwind_GetCFA): Likewise.
1920
4b3d3e28
RM
19212011-07-14 Roland McGrath <roland@hack.frob.com>
1922
1923 * allocatestack.c (__reclaim_stacks): Use uintptr_t cast rather than
1924 UINTMAX_C.
1925
6f8326ca
UD
19262011-06-30 Ulrich Drepper <drepper@gmail.com>
1927
1928 * nptl-init.c (__nptl_set_robust): New function.
1929 (pthread_functions): Add reference.
1930 * npthreadP.h: Declare __nptl_set_robust.
1931 * sysdeps/pthread/pthread-functions.h (pthread_functions): Add
1932 ptr_set_robust member.
1933 * sysdeps/unix/sysv/linux/fork.c: Call set_robust_list syscall in
1934 child if threads are used.
1935
c71ca1f8
AJ
19362011-06-14 Andreas Jaeger <aj@suse.de>
1937
1938 * pthread_rwlock_init.c: Include <string.h> for memset declaration.
1939
5bdcc103
UD
19402011-05-11 Ulrich Drepper <drepper@gmail.com>
1941
1942 [BZ #386]
1943 * allocatestack.c (allocate_stack): Convert ENOMEM error to EAGAIN.
1944
e6c61494
UD
19452011-04-10 Ulrich Drepper <drepper@gmail.com>
1946
1947 [BZ #12650]
1948 * allocatestack.c (get_cached_stack): Deallocate DTV entries before
1949 clearing memory.
1950 Patch partly by Robert Rex <robert.rex@exasol.com>.
1951
c5be0f71
RM
19522011-01-19 Roland McGrath <roland@redhat.com>
1953
1954 * pthread_cond_wait.c (__pthread_cond_wait): Fix comment typo.
1955 * pthread_cond_timedwait.c (__pthread_cond_timedwait): Likewise.
1956 * pthread_rwlock_rdlock.c (__pthread_rwlock_rdlock): Likewise.
1957 * pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock): Likewise.
1958 * pthread_rwlock_timedrdlock.c (pthread_rwlock_timedrdlock): Likewise.
1959 * pthread_rwlock_timedwrlock.c (pthread_rwlock_timedwrlock): Likewise.
1960
1f20b93a
AS
19612011-01-16 Andreas Schwab <schwab@linux-m68k.org>
1962
1963 * Makefile (test-extras): Add tst-cleanup4aux.
1964
70181fdd
UD
19652011-01-14 Ulrich Drepper <drepper@gmail.com>
1966
1967 [BZ #10563]
1968 * sysdeps/pthread/setxid.h (__SETXID_1): Add cast to assignment.
1969 (__SETXID_2): Likewise.
1970 (__SETXID_3): Likewise.
1971
451f001b
UD
19722011-01-13 Ulrich Drepper <drepper@gmail.com>
1973
1974 [BZ #10484]
1975 * Versions [libc] (GLIBC_PRIVATE): Export __libc_alloca_cutoff.
a85b5cb4 1976 * alloca_cutoff.c: Add libc_hidden_def.
451f001b 1977
f9068148
L
19782010-10-13 H.J. Lu <hongjiu.lu@intel.com>
1979
1980 [BZ #12113]
1981 * sysdeps/x86_64/pthreaddef.h (TCB_ALIGNMENT): Changed to 32.
1982 * sysdeps/x86_64/tls.h (TLS_TCB_ALIGN): Defined with alignment
1983 of "struct pthread".
1984
c3758fee
AS
19852010-09-21 Andreas Schwab <schwab@redhat.com>
1986
1987 * sysdeps/pthread/pthread.h (pthread_cleanup_push)
1988 [!__EXCEPTIONS]: Mangle local variable not_first_call.
1989 (pthread_cleanup_push_defer_np): Likewise.
1990
4ac42e19
UD
19912010-09-03 Ulrich Drepper <drepper@redhat.com>
1992
1993 * sysdeps/pthread/allocalim.h (__libc_use_alloca): Expect blocks are
1994 small.
1995
022f6b89
DG
19962010-08-10 Dinakar Guniguntala <dino@in.ibm.com>
1997 Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
1998
1999 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: If
2000 FUTEX_WAKE_OP fails make sure to call FUTEX_WAKE instead.
2001
f8392f40
L
20022010-08-12 H.J. Lu <hongjiu.lu@intel.com>
2003
93f17abf 2004 * sysdeps/unix/sysv/linux/i386/Makefile: New file.
f8392f40 2005
bebff237
AM
20062010-05-01 Alan Modra <amodra@gmail.com>
2007
2008 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
2009 (PSEUDO): Use correct cr save. Don't use wrong parm save area
2010 to save temps. Correct cfi for possible later frame manipulation.
2011 (DOCARGS_1, UNDOCARGS_1): Use the correct parm save area.
2012 (DOCARGS_2, UNDOCARGS_2, DOCARGS_3, UNDOCARGS_3): Likewise.
2013 (DOCARGS_4, UNDOCARGS_4, DOCARGS_5, UNDOCARGS_5): Likewise.
2014 (DOCARGS_6, UNDOCARGS_6): Likewise.
2015 (CENABLE, CDISABLE): Add nops for non-shared calls.
2016
e8ee8bdf
AS
20172010-07-06 Andreas Schwab <schwab@redhat.com>
2018
2019 * sysdeps/unix/sysv/linux/pthread_getname.c (pthread_getname_np):
2020 Fix type mismatch.
2021
03e87550
UD
20222010-07-03 Ulrich Drepper <drepper@redhat.com>
2023
2024 * tst-abstime.c (do_test): Some more cleanups
2025
145569dc
UD
20262010-07-02 Ulrich Drepper <drepper@redhat.com>
2027
2028 * tst-abstime.c: Correct testing and add test for sem_timedwait.
2029
2983d85e
AS
20302010-07-01 Andreas Schwab <schwab@redhat.com>
2031 Ulrich Drepper <drepper@redhat.com>
2032
2033 * Makefile (tests): Add tst-abstime.
2034 * tst-abstime.c: New file.
2035 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
2036 (__lll_timedlock_wait): Check for timestamp before the Epoch.
2037 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
2038 (__lll_timedlock_wait): Likewise.
2039 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S
2040 (__lll_robust_timedlock_wait): Likewise.
2041 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
2042 (__pthread_cond_timedwait): Likewise.
2043 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
2044 (pthread_rwlock_timedrdlock): Likewise.
2045 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
2046 (pthread_rwlock_timedwrlock): Likewise.
2047 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
2048 Likewise.
2049
72b6e8c8
UD
20502010-07-01 Ulrich Drepper <drepper@redhat.com>
2051
2052 * Makefile (tst-_res1): Add tst-_res1mod1 to dependency list.
2053
4bc93b30
TY
20542010-06-01 Takashi Yoshii <takashi.yoshii.zj@renesas.com>
2055
2056 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Fix incorrect
2057 location of ifndef __ASSUME_FUTEX_CLOCK_REALTIME.
2058
86a4c67f
UD
20592010-04-09 Ulrich Drepper <drepper@redhat.com>
2060
2061 [BZ #11390]
2062 * sysdeps/unix/sysv/linux/pthread_getname.c: New file.
2063 * sysdeps/unix/sysv/linux/pthread_setname.c: New file.
2064 * nptl/sysdeps/pthread/pthread.h: Declare pthread_getname and
2065 pthread_setname.
2066 * Makefile (libpthread-routines): Add pthread_getname and
2067 pthread_setname.
2068 * Versions: Export pthread_getname and pthread_setname for GLIBC_2.12.
2069
f571a994
RM
20702010-04-05 Thomas Schwinge <thomas@schwinge.name>
2071
2072 * sysdeps/pthread/unwind-resume.c: Moved to main tree sysdeps/gnu/.
2073 * sysdeps/pthread/rt-unwind-resume.c: Likewise.
2074 * sysdeps/pthread/Makefile: Remove csu section and rt section's
2075 unwind-resume bits, now in main tree sysdeps/gnu/Makefile instead.
2076
7749bf5f
LM
20772010-03-23 Luis Machado <luisgpm@br.ibm.com>
2078
2079 * pthread_cond_timedwait.c: Add check for
2080 HAVE_CLOCK_GETTIME_VSYSCALL to use VDSO whenever possible.
2081 (pthread_cond_timedwait): Use INTERNAL_VSYSCALL instead of
2082 INTERNAL_SYSCALL.
2083
1d78f299
UD
20842010-03-09 Ulrich Drepper <drepper@redhat.com>
2085
2086 * pthread_create.c (__pthread_create_2_1): If priorities are incorrect
2087 and the call fails wake eventually waiting setxid threads. Don't free
2088 stack here if we try starting a thread.
2089 * sysdeps/pthread/createthread.c (do_clone): Only wake setxid waiter
2090 if the clone call failed.
2091
058e9ba9
AS
20922010-03-08 Andreas Schwab <schwab@redhat.com>
2093
2094 * pthread_create.c (__pthread_create_2_1): Don't set setxid_futex.
2095 * allocatestack.c (get_cached_stack): Set setxid_futex.
2096 (allocate_stack): Likewise.
2097
66f1b8ee
UD
20982010-03-05 Andreas Schwab <schwab@redhat.com>
2099 Ulrich Drepper <drepper@redhat.com>
2100
2101 * allocatestack.c (setxid_mark_thread): Delay handling of thread if
2102 it is creating a thread or it is just being created.
2103 * pthread_create.c (start_thread): Wake setxid thread if it is
2104 waiting.
2105 (__pthread_create_2_1): Initialize setxid_futex.
2106 * sysdeps/pthread/createthread.c (do_clone): Wake setxid thread if it
2107 is waiting.
2108
893549c5
MS
21092010-01-15 Ulrich Drepper <drepper@redhat.com>
2110
2111 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
2112 Fix unwind info.
2113 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
2114
21152010-01-15 Michal Schmidt <mschmidt@redhat.com>
2116
2117 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
2118 Fix pthread_cond_timedwait with requeue-PI.
2119 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
2120 Fix pthread_cond_wait with requeue-PI.
2121
402cd987
UD
21222010-01-14 Ulrich Drepper <drepper@redhat.com>
2123
78ee2185
UD
2124 * Versions: Add pthread_mutex_consistent, pthread_mutexattr_getrobust,
2125 and pthread_mutexattr_setrobust for GLIBC_2.12.
402cd987 2126 * pthread_mutex_consistent.c: Define alias pthread_mutex_consistent.
78ee2185
UD
2127 * pthread_mutexattr_getrobust.c: Define alias
2128 pthread_mutexattr_getrobust.
2129 * pthread_mutexattr_setrobust.c: Define alias
2130 pthread_mutexattr_setrobust.
402cd987 2131
d3c7e686
UD
21322010-01-12 Ulrich Drepper <drepper@redhat.com>
2133
2134 * sysdeps/pthread/pthread.h: Cleanup. Fix up for XPG7.
2135
f095bb72
UD
21362010-01-08 Ulrich Drepper <drepper@redhat.com>
2137
2138 * sysdeps/pthread/pthread.h: Fix pthread_mutex_consistent declaration.
2139
d34bd80f
TS
21402009-12-18 Thomas Schwinge <thomas@codesourcery.com>
2141
2142 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c (_init): Don't
2143 call __gmon_start__.
2144 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c (_init): Likewise.
2145
f01c2359
UD
21462009-12-17 Ulrich Drepper <drepper@redhat.com>
2147
2148 * pthread_rwlock_init.c (__pthread_rwlock_init): Simplify code by
2149 using memset.
2150
75956694
DG
21512009-12-01 Dinakar Guniguntala <dino@in.ibm.com>
2152
2153 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.h: Define
2154 FUTEX_WAIT_REQUEUE_PI and FUTEX_CMP_REQUEUE_PI.
2155 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: If mutex
2156 is a non robust PI mutex, then use FUTEX_CMP_REQUEUE_PI.
2157 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
2158 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: If mutex
2159 is a non robust PI mutex, then use FUTEX_WAIT_REQUEUE_PI.
2160 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
2161
9554ebf2
UD
21622009-12-12 Ulrich Drepper <drepper@redhat.com>
2163
2164 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
2165 Don't update nwaiters after invalid timeout is recognized.
2166
ebb92a49
TS
21672009-11-27 Thomas Schwinge <thomas@codesourcery.com>
2168
2169 * sysdeps/unix/sysv/linux/sh/pt-initfini.c (_init): Don't call
2170 __gmon_start__.
2171
b55ec98c
AS
21722009-11-27 Andreas Schwab <schwab@redhat.com>
2173
2174 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: Reload
2175 THREAD_SELF->cancelhandling after returning from futex call.
2176
80b3a4ea
UD
21772009-11-24 Ulrich Drepper <drepper@redhat.com>
2178
2179 * tst-sem13.c: New file.
2180 * Makefile (tests): Add tst-sem13.
2181
57a299fe
RM
21822009-11-22 Roland McGrath <roland@redhat.com>
2183
2184 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: # include "i686/dl-sysdep.h"
2185 instead of recapitulating its contents.
2186
dfedb126
UD
21872009-11-18 Ulrich Drepper <drepper@redhat.com>
2188
2189 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Minor
2190 optimizations and cleanups.
2191
dd7106b3
DG
21922009-11-18 Dinakar Guniguntala <dino@in.ibm.com>
2193
2194 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S:
2195 Remove redundant code. Fix cfi offsets.
2196 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S:
2197 Fix cfi offsets.
2198
f8c10bb4
UD
21992009-11-17 Ulrich Drepper <drepper@redhat.com>
2200
62616842
UD
2201 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Minimally
2202 reduce size of unwind info.
2203
f8c10bb4
UD
2204 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Convert to use
2205 cfi directives.
2206 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
2207 Based on a patch by Dinakar Guniguntala <dino@in.ibm.com>.
2208
13f6812f
AS
22092009-11-03 Andreas Schwab <schwab@linux-m68k.org>
2210
2211 [BZ #4457]
2212 * sysdeps/pthread/unwind-resume.c: Include <libgcc_s.h> and use
2213 LIBGCC_S_SO.
2214 * sysdeps/pthread/unwind-forcedunwind.c: Likewise.
2215
25db0f6c
DJ
22162009-10-30 Ulrich Drepper <drepper@redhat.com>
2217
9c04f7c1
UD
2218 * tst-sem11.c (main): Rewrite to avoid aliasing problems.
2219
25db0f6c
DJ
2220 [BZ #3270]
2221 * allocatestack.c (__nptl_setxid): Perform the operation in multiple
2222 steps to avoid races with creation and terminations.
2223 * nptl-init.c (sighandler_setxid): Adjust.
2224 Patch by Daniel Jacobowitz.
2225
3d60eb17
AS
22262009-09-07 Andreas Schwab <schwab@redhat.com>
2227
2228 * sysdeps/pthread/bits/libc-lock.h (BP_SYM): Remove space before paren.
2229
38eb6136
SP
22302009-09-02 Suzuki K P <suzuki@in.ibm.com>
2231 Joseph Myers <joseph@codesourcery.com>
2232
2233 [BZ #7094]
2234 * sysdeps/unix/sysv/linux/timer_create.c (timer_create):
2235 Initialize the sigev_notify field for newly created timer to make sure
01034d75 2236 the timer gets deleted from the active timer's list upon timer_delete.
38eb6136 2237
7812c65b
AS
22382009-08-27 Andrew Stubbs <ams@codesourcery.com>
2239
2240 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_timedlock_wait):
2241 Correct a logic error.
2242
84088310
UD
22432009-08-25 Ulrich Drepper <drepper@redhat.com>
2244
2245 * sysdeps/x86_64/tls.h (RTLD_ENABLE_FOREIGN_CALL): Store old value
2246 of the field in local variables.
2247 (RTLD_FINALIZE_FOREIGN_CALL): Restore rtld_must_xmm_save from local
2248 variable and don't unconditionally clear it.
2249
b42a214c
UD
22502009-08-24 Ulrich Drepper <drepper@redhat.com>
2251
2252 * pthread_create.c (start_thread): Hint to the kernel that memory for
2253 the stack can be reused. We do not mark all the memory. The part
2254 still in use and some reserve are kept.
2255
2d094b73
UD
22562009-08-23 Ulrich Drepper <drepper@redhat.com>
2257
2258 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Clean up namespace.
2259
ae0d5450
UD
22602009-08-11 Ulrich Drepper <drepper@redhat.com>
2261
2262 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Add CFI
2263 directives.
2264
1bc2b97e
UD
22652009-08-10 Ulrich Drepper <drepper@redhat.com>
2266
2267 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Add CFI
2268 directives.
2269 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
2270
ec492239
AS
22712009-08-10 Andreas Schwab <schwab@redhat.com>
2272
2273 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
2274 (__pthread_cond_signal): Don't clobber register used for syscall
2275 number.
2276
49eea97b
UD
22772009-08-08 Ulrich Drepper <drepper@redhat.com>
2278
efa0569d
UD
2279 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
2280 Optimize code path used when FUTEX_CLOCK_REALTIME is supported.
2281
49eea97b
UD
2282 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
2283 (__pthread_cond_wait): Optimize by avoiding use of callee-safe
2284 register.
2285
9083bcc5
UD
22862009-08-07 Ulrich Drepper <drepper@redhat.com>
2287
2288 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Little optimizations
2289 enabled by the special *_asynccancel functions.
2290 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
2291 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
2292
2293 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: Include lowlevellock.h.
2294
421665c4
UD
22952009-08-04 Ulrich Drepper <drepper@redhat.com>
2296
2297 * sysdeps/unix/sysv/linux/x86_64/cancellation.S: New file.
2298 * sysdeps/unix/sysv/linux/x86_64/libc-cancellation.S: New file.
2299 * sysdeps/unix/sysv/linux/x86_64/librt-cancellation.S: New file.
2300 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (PSEUDO): Optimize
2301 since we can assume the special __*_{en,dis}able_asynccancel
2302 functions.
2303 (PUSHARGS_*, POPARGS_*, SAVESTK_*, RESTSTK_*): Removed.
2304 * sysdeps/x86_64/tcb-offsets.sym: Add cancellation-related bits
2305 and PTHREAD_CANCELED.
2306
bd03a1af
UD
23072009-07-31 Ulrich Drepper <drepper@redhat.com>
2308
2309 * descr.h: Better definition of *_BITMASK macros for cancellation.
2310
b48a267b
UD
23112009-07-29 Ulrich Drepper <drepper@redhat.com>
2312
586fa886
UD
2313 * sysdeps/x86_64/tls.h (TLS_TCB_ALIGN): Define explicitly to 32.
2314
b48a267b 2315 * sysdeps/x86_64/tls.h (tcbhead_t): Add room for SSE registers the
586fa886
UD
2316 dynamic linker might have to save.
2317 Define RTLD_CHECK_FOREIGN_CALL, RTLD_ENABLE_FOREIGN_CALL,
2318 RTLD_PREPARE_FOREIGN_CALL, and RTLD_FINALIZE_FOREIGN_CALL. Pretty
2319 printing.
2320
b48a267b
UD
2321 * sysdeps/x86_64/tcb-offsets.sym: Add RTLD_SAVESPACE_SSE.
2322
b0948ffd
UD
23232009-07-28 Ulrich Drepper <drepper@redhat.com>
2324
2325 * pthread_mutex_lock.c [NO_INCR] (__pthread_mutex_cond_lock_adjust):
2326 New function.
2327 * pthreadP.h: Declare __pthread_mutex_cond_lock_adjust.
2328 * sysdeps/unix/sysv/linux/pthread-pi-defines.sym: Add ROBUST_BIT.
2329 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Don't use
2330 requeue_pi for robust mutexes.
2331 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
2332 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
2333 Don't only skip __pthread_mutex_cond_lock. Call instead
2334 __pthread_mutex_cond_lock_adjust.
2335 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
2336
2337 * pthread_mutex_unlock.c (__pthread_mutex_unlock_full): Minor
2338 optimization of PI mutex handling.
2339
e73e694e
UD
23402009-07-27 Ulrich Drepper <drepper@redhat.com>
2341
2342 [BZ #10418]
2343 * pthread_mutex_unlock.c (__pthread_mutex_unlock_full): Use _rel
2344 instead of of _acq variants of cmpxchg.
2345
f1adf1f4
UD
23462009-07-23 Ulrich Drepper <drepper@redhat.com>
2347
01b597da
UD
2348 * sysdeps/x86_64/configure.in: New file.
2349
f1adf1f4
UD
2350 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Fix error
2351 path when not using absolute timeout futex.
2352
c3db953c
UD
23532009-07-20 Ulrich Drepper <drepper@redhat.com>
2354
2355 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Minor
2356 optimizations of last changes.
2357 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
2358
515a8908
UD
23592009-07-19 Ulrich Drepper <drepper@redhat.com>
2360
42e69bcf
UD
2361 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Define
2362 FUTEX_WAIT_REQUEUE_PI and FUTEX_CMP_REQUEUE_PI.
2363 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: If mutex
2364 is a PI mutex, then use FUTEX_CMP_REQUEUE_PI.
2365 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
2366 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: If mutex
2367 is a PI mutex, then use FUTEX_WAIT_REQUEUE_PI.
2368 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
2369
515a8908
UD
2370 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
2371 (__pthread_cond_timedwait): Make more robust.
2372
30b1954a
UD
23732009-07-18 Ulrich Drepper <drepper@redhat.com>
2374
e2dca2fe
UD
2375 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S
2376 (__lll_robust_timedlock_wait): If possible use FUTEX_WAIT_BITSET to
2377 directly use absolute timeout.
2378
3d77b268
UD
2379 * tst-sem5.c (do_test): Add test for premature timeout.
2380 * Makefile: Linu tst-sem5 with librt.
2381
d979611e
UD
2382 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S
2383 (pthread_rwlock_timedwrlock): If possible use FUTEX_WAIT_BITSET to
2384 directly use absolute timeout.
32c6c342
UD
2385 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
2386 (pthread_rwlock_timedrdlock): Likewise.
d979611e 2387
f8b6cd21
UD
2388 * tst-cond11.c (run_test): Add test to check that the timeout is
2389 long enough.
2390
e88726b4
UD
2391 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
2392 (__pthread_cond_timedwait): If possible use FUTEX_WAIT_BITSET to
2393 directly use absolute timeout.
2394
30b1954a
UD
2395 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
2396 (__pthread_cond_wait): Convert to using exception handler instead of
2397 registered unwind buffer.
92618c95
UD
2398 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
2399 (__pthread_cond_timedwait): Likewise.
30b1954a 2400
d52c96e7
UD
24012009-07-17 Ulrich Drepper <drepper@redhat.com>
2402
f351f2b7
UD
2403 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
2404 If possible use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME to directly
2405 use absolute timeout.
2406
0adae468
UD
2407 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S (sem_wait): Optimize
2408 handling of uncontested semaphore.
2409
d52c96e7
UD
2410 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
2411 (__condvar_cleanup): Rewrite to use cfi directives instead of
2412 hand-coded unwind tables.
63601ccd
UD
2413 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S (__pthread_once):
2414 Likewise.
c3c2f3cf 2415 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S (sem_wait): Likewise.
aee2665a
UD
2416 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
2417 Likewise.
d52c96e7 2418
bfdb73e1
UD
24192009-06-12 Ulrich Drepper <drepper@redhat.com>
2420
2421 * Makefile (libpthread-routines): Add pthread_sigqueue.
2422 * Versions: Add pthread_sigqueue for GLIBC_2.11.
2423 * sysdeps/pthread/bits/sigthread.h: Declare pthread_sigqueue.
2424 * sysdeps/unix/sysv/linux/pthread_sigqueue.c: New file.
2425
1828530f
BK
24262009-06-11 Ulrich Drepper <drepper@redhat.com>
2427
2428 [BZ #10262]
2429 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
2430 (LOAD_FUTEX_WAIT_ABS): Fix futex parameter in case private futexes
2431 cannot be assumed.
2432 Patch by Bryan Kadzban <bz-glibc@kdzbn.homelinux.net>.
2433
a5b8b56d
UD
24342009-05-16 Ulrich Drepper <drepper@redhat.com>
2435
e20c4ef0
UD
2436 * libc-cancellation.c: Move __libc_cleanup_routine to...
2437 * libc-cleanup.c: ...here. New file.
2438 * Makefile (routines): Add libc-cleanup.
2439
cba0ca79
UD
2440 * cancellation.c (__pthread_disable_asynccancel): Remove unnecessary
2441 test.
2442 * libc-cancellation.c: Use <nptl/cancellation.c: to define the code.
2443 * sysdeps/pthread/librt-cancellation.c: Likewise.
2444
a5b8b56d
UD
2445 [BZ #9924]
2446 * nptl-init.c: Renamed from init.c.
2447 * Makefile: Change all occurences of init.c to nptl-init.c.
2448
1a7f254b
UD
24492009-05-15 Ulrich Drepper <drepper@redhat.com>
2450
9437b427
UD
2451 * cancellation.c (__pthread_disable_asynccancel): Correct the bits
2452 to test when deciding on the delay.
2453 * libc-cancellation.c (__libc_disable_asynccancel): Likewise.
2454 * pthread_cancel.c: Close race between deciding on sending a signal
2455 and setting the CANCELING_BIT bit.
2456
1a7f254b
UD
2457 * cancellation.c (__pthread_disable_asynccancel): Don't return if
2458 thread is canceled.
2459 * libc-cancellation.c (__libc_disable_asynccancel): Likewise.
2460
d5c157a9
UD
24612009-04-27 Ulrich Drepper <drepper@redhat.com>
2462
2463 * cancellation.c (__pthread_disable_asynccancel): Use THREAD_ATOMIC_AND
2464 is available.
2465 * libc-cancellation.c (__libc_disable_asynccancel): Likewise.
2466 * sysdeps/x86_64/tls.h: Define THREAD_ATOMIC_AND.
2467 * sysdeps/i386/tls.h: Likewise.
2468 (tcbhead_t): Add __private_tm member.
2469
f521be31
UD
24702009-04-26 Ulrich Drepper <drepper@redhat.com>
2471
5efe8650
UD
2472 * sem_open.c (sem_open): Rewrite initialization of initsem to
2473 avoid warnings.
2474
f521be31
UD
2475 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
2476 Avoid warning by using may_alias attribute on ptrhack.
2477
d301a6e1
UD
24782009-04-22 Ulrich Drepper <drepper@redhat.com>
2479
5497de87 2480 [BZ #10090]
d301a6e1
UD
2481 * pthread_attr_setschedparam.c (__pthread_attr_setschedparam):
2482 Check policy and priority for validity.
2483 Patch mostly by Zhang Xiliang <zhangxiliang@cn.fujitsu.com>.
2484
71a5bd3e
UD
24852009-03-15 Ulrich Drepper <drepper@redhat.com>
2486
2487 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
2488 (__pthread_cond_timedwait): Change to use cfi directives instead of
2489 hand-coded unwind sections.
2490
30991b8b
UD
24912009-03-10 Ulrich Drepper <drepper@redhat.com>
2492
2493 * init.c (nptl_freeres): Compile only for SHARED.
2494
9920a6b8
JJ
24952009-03-09 Jakub Jelinek <jakub@redhat.com>
2496
2497 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Define
2498 FUTEX_WAIT_BITSET, FUTEX_WAKE_BITSET, FUTEX_CLOCK_REALTIME and
2499 FUTEX_BITSET_MATCH_ANY.
2500
e965d514
RM
25012009-02-27 Roland McGrath <roland@redhat.com>
2502
2503 * init.c (__nptl_initial_report_events): Mark __attribute_used__.
2504 * pthread_create.c (__nptl_threads_events, __nptl_last_event): Likewise.
2505
6cbe890a
UD
25062009-02-26 Ulrich Drepper <drepper@redhat.com>
2507
2508 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
2509 _POSIX_THREAD_ROBUST_PRIO_INHERIT and
2510 _POSIX_THREAD_ROBUST_PRIO_PROTECT. Reset value of macros from
2511 200112L to 200809L.
2512
77db439e
UD
25132009-02-25 Ulrich Drepper <drepper@redhat.com>
2514
2515 * sysdeps/pthread/pthread.h: The robust mutex functions are in
2516 POSIX 2008.
2517
5be0a688
UD
25182009-02-24 Ulrich Drepper <drepper@redhat.com>
2519
2520 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_BITS_POSIX_OPT_H):
2521 Unify name of include protector macro.
2522
4c869eb6
UD
25232009-02-14 SUGIOKA Toshinobu <sugioka@itonet.co.jp>
2524
2525 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Define
2526 LOAD_FUTEX_WAIT_ABS even if (FUTEX_WAIT == 0).
2527
cca50323
UD
25282009-01-29 Ulrich Drepper <drepper@redhat.com>
2529
7f901dd7
UD
2530 * sysdeps/pthread/unwind-forcedunwind.c: Encrypt all function
2531 pointer variables.
2532
cca50323
UD
2533 * allocatestack.c (__free_stacks): Renamed from free_stacks.
2534 (__free_stack_cache): Removed. Change callers to call __free_stacks.
2535 * init.c (nptl_freeres): New function.
2536 (pthread_functions): Initialize ptr_freeres to nptl_freeres.
2537 * pthreadP.h: Don't declare __free_stack_cache. Declare __free_stacks.
2538 * sysdeps/pthread/unwind-forcedunwind.c (libgcc_s_handle): New
2539 variable.
2540 (pthread_cancel_init): Depend in libgcc_s_handle for decision to
2541 load DSO. Assign last.
2542 (__unwind_freeres): New function.
2543
2544 * allocatestack.c (__reclaim_stacks): Reset in_flight_stack later
2545 for better debugging. No need to use stack_list_add here.
2546
a7bd183f
UD
25472009-01-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2548
2549 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
2550 (__lll_timedlock_wait): Use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME
2551 instead of computing relative timeout.
2552 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Define
2553 FUTEX_CLOCK_REALTIME and FUTEX_BITSET_MATCH_ANY.
2554
563ee1cb
UD
25552009-01-25 Ulrich Drepper <drepper@redhat.com>
2556
2557 * pthread_mutex_lock.c (__pthread_mutex_lock): Remove unused label out.
2558
f25c7b08
UD
25592009-01-08 Ulrich Drepper <drepper@redhat.com>
2560
2561 * sysdeps/pthread/list.h (list_add): Initialize new element first.
2562 (list_add_tail): Removed.
2563
40de0fe3
JJ
25642009-01-07 Ulrich Drepper <drepper@redhat.com>
2565
2566 * (in_flight_stack): New variable.
2567 (stack_list_del): New function. Use instead of list_del.
2568 (stack_list_add): New function. Use instead of list_add when adding to
2569 stack_cache and stack_used lists.
2570 (__reclaim_stacks): Complete operations on stack_cache and stack_used lists
2571 when the fork call interrupted another thread.
2572
3c612057
UD
25732009-01-04 Ulrich Drepper <drepper@redhat.com>
2574
2575 * init.c (__pthread_initialize_minimal_internal): Optimize test
2576 FUTEX_CLOCK_REALTIME a bit.
2577
19834b42
UD
25782009-01-03 Ulrich Drepper <drepper@redhat.com>
2579
2580 * init.c (__pthread_initialize_minimal_internal): Cheat a bit by
2581 only passing five parameters to FUTEX_WAIT_BITSET call.
2582
2583 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
a9fa090b 2584 (__lll_timedlock_wait): Use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME
19834b42
UD
2585 instead of computing relative timeout.
2586
7dd650d7
UD
25872009-01-02 Ulrich Drepper <drepper@redhat.com>
2588
cbd8aeb8
UD
2589 * init.c (__pthread_initialize_minimal_internal): Check for
2590 FUTEX_CLOCK_REALTIME flag.
2591 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S (__lll_timedlock_wait):
a9fa090b 2592 Use FUTEX_WAIT_BITSET|FUTEX_CLOCK_REALTIME instead of computing
cbd8aeb8
UD
2593 relative timeout.
2594
7dd650d7
UD
2595 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Define
2596 FUTEX_CLOCK_REALTIME and FUTEX_BITSET_MATCH_ANY.
2597 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
2598 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
2599 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
2600 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
2601
217d45cd
UD
26022008-12-09 Ulrich Drepper <drepper@redhat.com>
2603
2604 * sysdeps/pthread/pthread.h (pthread_cleanup_pop): Use { } as empty
2605 loop body instead of ; to avoid gcc warnings.
2606 (pthread_cleanup_pop_restore_np): Likewise.
2607 Patch by Caolán McNamara <caolanm@redhat.com>.
2608
6de79a49
UD
26092008-12-09 Jakub Jelinek <jakub@redhat.com>
2610
2611 * pthread_mutex_lock.c (__pthread_mutex_lock): Handle only the
2612 fast path here, for robust/PI/PP mutexes call
2613 __pthread_mutex_lock_full. Don't use switch, instead use a series
2614 of ifs according to their probability.
2615 (__pthread_mutex_lock_full): New function.
2616 * pthread_mutex_unlock.c: Include assert.h.
2617 (__pthread_mutex_unlock_usercnt): Handle only the
2618 fast path here, for robust/PI/PP mutexes call
2619 __pthread_mutex_unlock_full. Don't use switch, instead use a series
2620 of ifs according to their probability.
2621 (__pthread_mutex_unlock_full): New function.
2622 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c
2623 (__pthread_mutex_lock_full): Define.
2624
71bb2639
UD
26252008-12-08 Ulrich Drepper <drepper@redhat.com>
2626
2627 * sysdeps/x86_64/tls.h (tcbhead_t): Add fields reserved for TM
2628 implementation. Add necessary padding and.
2629 * descr.h (struct pthread): Increase padding for tcbhead_t to 24
2630 words.
2631
247626f3
UD
26322008-12-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2633
2634 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Define FUTEX_WAIT_BITSET
2635 and FUTEX_WAKE_BITSET.
2636
da5ac135
UD
26372008-12-02 Ulrich Drepper <drepper@redhat.com>
2638
2639 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define FUTEX_WAIT_BITSET
2640 and FUTEX_WAKE_BITSET.
2641 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
2642 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
2643 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
2644 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
2645
c0439b95
RM
26462008-11-25 Roland McGrath <roland@redhat.com>
2647
2648 * sysdeps/alpha, sysdeps/unix/sysv/linux/alpha:
2649 Subdirectories moved to ports repository as
2650 sysdeps/.../nptl subdirectories.
2651
0e54a725
UD
26522008-11-12 Jakub Jelinek <jakub@redhat.com>
2653
2654 [BZ #7008]
2655 * pthread_condattr_setclock.c (pthread_condattr_setclock): Fix masking
2656 of old value.
2657 * pthread_cond_init.c (__pthread_cond_init): Fix
2658 cond->__data.__nwaiters initialization.
2659 * Makefile (tests): Add tst-cond23.
2660 * tst-cond23.c: New test.
2661
4b23f9bd
JJ
26622008-11-07 Jakub Jelinek <jakub@redhat.com>
2663
2664 * sysdeps/pthread/malloc-machine.h (MALLOC): Adjust __libc_tsd_define
2665 arguments.
2666 (tsd_setspecific, tsd_getspecific): Adjust __libc_tsd_{set,get}
2667 arguments.
2668
efac1fce
UD
26692008-11-01 Ulrich Drepper <drepper@redhat.com>
2670
2671 [BZ #6955]
2672 * pthread_mutex_lock.c: Add support for private PI mutexes.
2673 * pthread_mutex_timedlock.c: Likewise.
2674 * pthread_mutex_trylock.c: Likewise.
2675 * pthread_mutex_unlock.c: Likewise.
2676 Patch mostly by Ben Jackson <ben@ben.com>.
2677
bf837fa3
UD
26782008-10-31 Ulrich Drepper <drepper@redhat.com>
2679
2680 [BZ #6843]
2681 * sysdeps/pthread/gai_misc.h (__gai_create_helper_thread):
2682 Increase stack size for helper thread.
2683
208bc836
UD
26842008-10-06 Martin Schwidefsky <schwidefsky@de.ibm.com>
2685
2686 * sysdeps/s390/tls.h (THREAD_SET_STACK_GUARD): Add empty inline
2687 assembly with a clobber list for access registers a0 and a1.
2688
17f8b4a9
UD
26892008-09-11 Martin Schwidefsky <schwidefsky@de.ibm.com>
2690
2691 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Add memory barrier
2692 to force runp->refcntr to be read from memory.
2693
2458c748
AJ
26942008-09-08 Richard Guenther <rguenther@suse.de>
2695
2696 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_lock,
2697 lll_robust_lock, lll_cond_lock, lll_robust_cond_lock,
2698 lll_timedlock, lll_robust_timedlock, lll_unlock,
2699 lll_robust_unlock): Promote private to int.
2700
965805e8
UD
27012008-08-15 Ulrich Drepper <drepper@redhat.com>
2702
2703 * sysdeps/x86_64/pthreaddef.h: Remove ARCH_MAP_FLAGS and
2704 ARCH_RETRY_MMAP definitions.
2705 * allocatestack.c: Remove definition of ARCH_MAP_FLAGS.
2706 Define MAP_STACK when not defined.
2707 (allocate_stack): Use MAP_STACK instead of ARCH_MAP_FLAGS. Remove
2708 handling of ARCH_RETRY_MMAP.
2709
bd7f4857
UD
27102008-07-30 Ulrich Drepper <drepper@redhat.com>
2711
2712 * tst-align2.c (f): Print message that f is reached.
2713
619cc2f6
UD
27142008-04-28 Hiroki Kaminaga <kaminaga@sm.sony.co.jp>
2715
2716 [BZ #6740]
2717 * sysdeps/powerpc/tcb-offsets.sym (PRIVATE_FUTEX_OFFSET): Guard symbol
2718 definition with #ifndef __ASSUME_PRIVATE_FUTEX.
2719
8ccf22f9
UD
27202008-07-25 Ulrich Drepper <drepper@redhat.com>
2721
2722 * sysdeps/unix/sysv/linux/mq_notify.c (init_mq_netlink): Use
2723 SOCK_CLOEXEC if possible.
2724
27252008-05-29 Ulrich Drepper <drepper@redhat.com>
2726
2727 * Makefile (tests): Add tst-rwlock2a.
2728 * tst-rwlock2.c: Use TYPE macro to decide what rwlock type to use.
2729 * tst-rwlock2a.c: New file.
2730
5a337776
UD
27312008-06-12 Ulrich Drepper <drepper@redhat.com>
2732
2733 * sysdeps/pthread/pthread.h: Remove inadvertant checkin.
2734
e4d6e7f5
UD
27352008-05-17 Samuel Thibault <samuel.thibault@ens-lyon.org>
2736
2737 * sysdeps/pthread/pthread.h: Fix typo in comment.
2738
d6296e88
UD
27392008-05-28 Ulrich Drepper <drepper@redhat.com>
2740
2741 * sysdeps/pthread/createthread.c (do_clone): Pass accurate length
2742 of CPU set to the kernel.
2743
62605cbf
UD
27442008-05-23 Paul Pluzhnikov <ppluzhnikov@google.com>
2745
2746 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Add
2747 cfi directives.
2748 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
2749 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
2750 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
2751 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
2752 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
2753 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
2754
27552008-05-22 Paul Pluzhnikov <ppluzhnikov@google.com>
2756
2757 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S: Add
2758 cfi directives.
2759 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
2760 Likewise.
2761 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
2762 Likewise.
2763 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
2764 Likewise.
2765
4b2c85c0
UD
27662008-05-26 Ulrich Drepper <drepper@redhat.com>
2767
2768 * tst-typesizes.c: Explicitly check __SIZEOF_PTHREAD_* constants.
2769
b72f5692 27702008-05-20 Jakub Jelinek <jakub@redhat.com>
4b2c85c0
UD
2771
2772 David S. Miller <davem@davemloft.net>
3b15b590 2773
b72f5692 2774 * sysdeps/unix/sysv/linux/sparc/sparc64/Makefile: New file.
3b15b590 2775
cdffaaa6
UD
27762008-05-10 Ulrich Drepper <drepper@redhat.com>
2777
2778 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Access
2779 __pshared correctly.
2780 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
2781 Likewise.
2782 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
2783 Likewise.
2784 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
2785 Likewise.
2786 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S:
2787 Likewise.
2788 Reported by Clemens Kolbitsch <clemens.kol@gmx.at>.
2789
2313c48f
JJ
27902008-04-14 David S. Miller <davem@davemloft.net>
2791
2792 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
2793 (__old_sem_wait): Fix argument to lll_futex_wait().
2794
2f611ada
UD
27952007-11-26 Daniel Jacobowitz <dan@codesourcery.com>
2796
2797 * pthread_create.c: Require pthread_mutex_trylock and
2798 pthread_key_delete for libgcc.
2799
d24be489
JJ
28002008-04-08 Jakub Jelinek <jakub@redhat.com>
2801
2802 [BZ #6020]
2803 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h
2804 (lll_futex_wake_unlock): Add private argument to the pre-v9 macro.
2805 Patch by Sunil Amitkumar Janki <devel.sjanki@gmail.com>.
2806
f96853be
UD
28072008-03-27 Ulrich Drepper <drepper@redhat.com>
2808
8ccf22f9 2809 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine ARG_MAX if
f96853be
UD
2810 <linux/limits.h> has defined it.
2811 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
2812 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
2813 * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: Likewise.
2814 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
2815
354b7527
JJ
28162008-03-18 Jakub Jelinek <jakub@redhat.com>
2817
2818 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: Use __ASSEMBLER__ instead
2819 of ASSEMBLER.
2820 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h: Likewise.
2821 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Likewise.
2822
702ae329
UD
28232008-03-14 Ulrich Drepper <drepper@redhat.com>
2824
2825 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define
2826 HAVE_DL_DISCOVER_OSVERSION.
2827 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h: Likewise.
2828 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: Likewise.
2829
443db178
UD
28302008-03-07 Ulrich Drepper <drepper@redhat.com>
2831
2832 [BZ #5778]
2833 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Change
2834 _POSIX_CHOWN_RESTRICTED value to zero.
2835
67fbfa5c
RM
28362008-01-31 Roland McGrath <roland@redhat.com>
2837
2838 * Makefile (omit-deps): Variable removed.
2839
dd3113da
UD
28402008-01-30 Ulrich Drepper <drepper@redhat.com>
2841
2842 * sysdeps/unix/sysv/linux/x86_64/sem_post.S (sem_post): Avoid
2843 unnecessary addr32 prefix.
2844
16cd816f
RM
28452008-01-29 Roland McGrath <roland@redhat.com>
2846
2847 * Makeconfig (ptw-CPPFLAGS, sysd-rules-patterns): New variables.
2848
b4b166af
UD
28492008-01-22 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2850
2851 * sysdeps/unix/sysv/linux/sh/sem_post.S: Don't overflow value field.
2852
28532008-01-21 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2854
2855 * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h (XADD): Use
2856 a scratch register.
2857 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
2858 (__lll_lock_wait_private): Fix typo.
2859 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S
2860 (pthread_barrier_wait): Likewise. Adjust XADD use.
2861 * sysdeps/unix/sysv/linux/sh/sem_post.S (__new_sem_post):
2862 Adjust XADD use.
2863 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S
2864 (pthread_rwlock_timedrdlock): Return correct return value.
2865 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S
16cd816f 2866 (pthread_rwlock_timedwrlock): Likewise.
b4b166af 2867
eaf95a26
UD
28682008-01-15 Ulrich Drepper <drepper@redhat.com>
2869
2870 * tst-eintr2.c (do_test): make sure that if mutex_lock in main
2871 thread returns the program exits with an error code.
2872
ab355d9a
UD
28732008-01-10 Ulrich Drepper <drepper@redhat.com>
2874
2875 * pthread-errnos.sym: Add EOVERFLOW.
2876 * sysdeps/unix/sysv/linux/structsem.sym: Add SEM_VALUE_MAX.
2877 * sysdeps/unix/sysv/linux/sem_post.c: Don't overflow value field.
2878 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
2879 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
2880
b8cca206
UD
28812007-12-14 Ulrich Drepper <drepper@redhat.com>
2882
2883 * sysdeps/x86_64/pthreaddef.h (ARCH_RETRY_MMAP): Take additional
2884 parameter. Passed it as permission to mmap.
2885 * allocatestack.c (allocate_stack): Pass prot as second parameter
2886 to ARCH_RETRY_MMAP.
2887
189dce4f
UD
28882007-12-12 Ulrich Drepper <drepper@redhat.com>
2889
3eb0e1c6
UD
2890 * tst-basic7.c: Allocate memory for the stack.
2891
189dce4f
UD
2892 [BZ #5465]
2893 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S [!SHARED]
2894 (__pthread_cond_timedwait): Don't use VDSO.
58d11795 2895 Patch by Michal Januszewski.
189dce4f 2896
26e21e75
UD
28972007-12-07 Ulrich Drepper <drepper@redhat.com>
2898
2899 [BZ #5455]
2900 * sysdeps/pthread/pthread.h [!__EXCEPTIONS] (pthread_cleanup_pop):
2901 Allow label before pthread_cleanup_pop.
2902 (pthread_cleanup_pop_restore_np): Likewise.
2903
191ec77f
UD
29042007-12-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
2905
2906 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_timedlock_wait):
2907 Store 2 before returning ETIMEDOUT.
2908
c012be6f
UD
29092007-11-23 Ulrich Drepper <drepper@redhat.com>
2910
2911 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S (__lll_timedlock_wait):
2912 Store 2 before returning ETIMEDOUT.
2913 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise
2914 * sysdeps/unix/sysv/linux/lowlevellock.c: Likewise.
2915 (__lll_lock_wait_private): Optimize.
2916 (__lll_lock_wait): Likewise.
2917
77f1e09a
UD
29182007-11-20 Jakub Jelinek <jakub@redhat.com>
2919
2920 * sysdeps/pthread/pthread.h (pthread_cleanup_push,
2921 pthread_cleanup_push_defer_np): Add extra (void *) cast to shut up
2922 g++ 4.1 and 4.2 -Wstrict-aliasing warnings.
2923
0f7e0ee5
UD
29242007-11-08 Ulrich Drepper <drepper@redhat.com>
2925
cbed6a60
UD
2926 [BZ #5240]
2927 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait):
2928 If we time out, try one last time to lock the futex to avoid
2929 losing a wakeup signal.
2930 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
2931 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
2932
0f7e0ee5
UD
2933 [BZ #5245]
2934 * sysdeps/pthread/createthread.c (do_clone): Translate clone error
2935 if necessary.
2936
f6ed654c
UD
29372007-11-07 Ulrich Drepper <drepper@redhat.com>
2938
2939 [BZ #5245]
2940 * allocatestack.c (allocate_stack): Change ENOMEM error in case
2941 mmap failed to EAGAIN.
2942 * Makefile (tests): Add tst-basic7.
2943 * tst-basic7.c: New file.
2944
b92e3780
UD
29452007-11-05 Ulrich Drepper <drepper@redhat.com>
2946
2947 * sysdeps/unix/sysv/linux/register-atfork.c (__register_atfork):
2948 Use __linkin_atfork.
2949
94a749f6
UD
29502007-11-03 Mike Frysinger <vapier@gentoo.org>
2951
2952 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (LOAD_FUTEX_WAIT): Add
2953 missing line continuations.
2954 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S (LOAD_FUTEX_WAIT,
2955 LOAD_FUTEX_WAKE): Likewise. Also add missing 3rd parameter.
2956
f160a450
UD
29572007-10-28 Ulrich Drepper <drepper@redhat.com>
2958
2959 [BZ #5220]
2960 * sysdeps/unix/sysv/linux/kernel-posix-timers.h: Declare
2961 __active_timer_sigev_thread and __active_timer_sigev_thread_lock.
2962 (struct timer): Add next element.
2963 * sysdeps/unix/sysv/linux/timer_create.c: For SIGEV_THREAD timers,
2964 enqueue timer structure into __active_timer_sigev_thread list.
2965 * sysdeps/unix/sysv/linux/timer_delete.c: For SIGEV_THREAD timers,
2966 remove timer struct from __active_timer_sigev_thread.
2967 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
2968 Before using timer structure make sure it is still on the
2969 __active_timer_sigev_thread list. Keep lock until done.
2970 Define __active_timer_sigev_thread and
2971 __active_timer_sigev_thread_lock.
2972
94833f11
UD
29732007-10-27 Ulrich Drepper <drepper@redhat.com>
2974
2975 * sysdeps/pthread/malloc-machine.h: Define ATFORK_MEM.
2976 Redefine thread_atfork for use of ATFORK_MEM.
2977 * sysdeps/unix/sysv/linux/fork.h: Define __linkin_atfork.
2978 * sysdeps/unix/sysv/linux/register-atfork.c (__linkin_atfork): New
2979 function.
2980 * sysdeps/unix/sysv/linux/unregister-atfork.c (__unregister_atfork):
2981 Use atomic operation when removing first element of list.
2982
96c06e08
JJ
29832007-10-17 Jakub Jelinek <jakub@redhat.com>
2984
2985 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__old_sem_post): New
2986 routine instead of an alias to __new_sem_post.
2987
e807818b
JJ
29882007-10-15 Jakub Jelinek <jakub@redhat.com>
2989
2990 * init.c (__pthread_initialize_minimal): Initialize word to appease
2991 valgrind.
2992
59d430c6
UD
29932007-10-10 Jakub Jelinek <jakub@redhat.com>
2994
2995 * sysdeps/pthread/bits/libc-lock.h (__libc_rwlock_init): Inside of
2996 libc.so just clear NAME.
2997 (__libc_rwlock_fini): Nop inside of libc.so.
2998 * tst-initializers1.c (main): Test if PTHREAD_RWLOCK_INITIALIZER is
2999 all zeros.
3000
221d9d8e
UD
30012007-09-02 Ulrich Drepper <drepper@redhat.com>
3002
3003 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
3004 (__pthread_cond_wait): Fix unlocking of internal lock after mutex
3005 unlocking failed.
3006 Patch by Luca Barbieri <luca.barbieri@gmail.com>.
3007
2a01ce56
UD
30082007-08-21 Ulrich Drepper <drepper@redhat.com>
3009
3010 [BZ #4938]
3011 * allocatestack.c (__reclaim_stacks): Clear the TSD in the
3012 reclaimed stack if necessary.
3013 * Makefile (tests): Add tst-tsd6.
3014 * tst-tsd6.c: New file.
3015
c273641b
JJ
30162007-08-21 Jakub Jelinek <jakub@redhat.com>
3017
3018 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_robust_dead):
3019 Add private argument.
3020
fb84593c
UD
30212007-08-20 Ulrich Drepper <drepper@redhat.com>
3022
3023 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
3024 (__pthread_cond_timedwait): Use clock_gettime from VDSO if possible.
3025
3e8d1eab
JJ
30262007-08-16 Jakub Jelinek <jakub@redhat.com>
3027
3028 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h
3029 (__lll_robust_timedlock): Pass private as last argument to
3030 __lll_robust_timedlock_wait.
3031 (__lll_unlock): Fix a pasto.
3032
e4720b0e
JJ
30332007-08-15 Jakub Jelinek <jakub@redhat.com>
3034
3035 * sysdeps/unix/sysv/linux/sparc/internaltypes.h (sparc_new_sem,
3036 sparc_old_sem): New structs.
3037 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c
3038 (__sem_wait_cleanup): New function.
3039 (__new_sem_wait): Use sparc_new_sem structure. Bump and afterwards
3040 decrease nwaiters. Register __sem_wait_cleanup as cleanup handler.
3041 Pass isem->private ^ FUTEX_PRIVATE_FLAG as last argument to
3042 lll_futex_wait.
3043 (__old_sem_wait): New function.
3044 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_wait.c: Include
3045 nptl/sysdeps/unix/sysv/linux/sparc version.
3046 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_timedwait.c:
3047 Likewise.
3048 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_post.c: Likewise.
3049 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_trywait.c
3050 (__new_sem_trywait): Use sparc_old_sem structure.
3051 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c
3052 (sem_timedwait): Use sparc_new_sem structure. Bump and afterwards
3053 decrease nwaiters. Register __sem_wait_cleanup as cleanup handler.
3054 Pass isem->private ^ FUTEX_PRIVATE_FLAG as last argument to
3055 lll_futex_timed_wait.
3056 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_post.c (__new_sem_post):
3057 Use sparc_new_sem structure. Only wake if nwaiters > 0. Pass
3058 isem->private ^ FUTEX_PRIVATE_FLAG as last argument to
3059 lll_futex_wake.
3060 (__old_sem_post): New function.
3061 * sysdeps/unix/sysv/linux/sparc/sem_wait.c: New file.
3062 * sysdeps/unix/sysv/linux/sparc/sem_init.c: New file.
3063 * sysdeps/unix/sysv/linux/sparc/sem_timedwait.c: New file.
3064 * sysdeps/unix/sysv/linux/sparc/sem_post.c: New file.
3065 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_init.c: Remove.
3066 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_init.c: Remove.
3067
d13f4a43
UD
30682007-08-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
3069
3070 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
3071 (__pthread_cond_broadcast): Pass LLL_PRIVATE to lll_* and or
3072 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
3073 Don't use FUTEX_CMP_REQUEUE if dep_mutex is not process private.
3074 * sysdeps/unix/sysv/linux/shpthread_cond_signal.S
3075 (__pthread_cond_signal): Pass LLL_PRIVATE to lll_* and or
3076 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
3077 Use FUTEX_WAKE_OP.
3078 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Include
3079 kernel-features.h and tcb-offsets.h.
3080 (__pthread_cond_wait, __condvar_w_cleanup): Pass LLL_PRIVATE to
3081 lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
3082 process private.
3083 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Include
3084 tcb-offsets.h.
3085 (__pthread_cond_timedwait, __condvar_tw_cleanup): Pass LLL_PRIVATE
3086 to lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
3087 process private.
3088 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Use #ifdef
3089 __ASSUME_PRIVATE_FUTEX instead of #if __ASSUME_PRIVATE_FUTEX.
3090 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
3091 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
3092 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
3093 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
3094 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
3095
702a9414
JJ
30962007-08-14 Jakub Jelinek <jakub@redhat.com>
3097
467d1345
JJ
3098 * sysdeps/unix/sysv/linux/lowlevellock.c: Comment fix.
3099 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c
3100 (__lll_timedwait_tid): Pass LLL_SHARED as 4th argument to
3101 lll_futex_timed_wait.
3102
702a9414
JJ
3103 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (__lll_unlock,
3104 __lll_robust_unlock): Rewrite as macros instead of inline functions.
3105 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (__lll_unlock,
3106 __lll_robust_unlock, __lll_wait_tid): Likewise.
3107
22502ea2
UD
31082007-08-13 Jakub Jelinek <jakub@redhat.com>
3109
3110 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (__lll_private_flag):
3111 Fix a pasto.
3112 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
3113 (__pthread_cond_broadcast): Pass LLL_PRIVATE to lll_* and or
3114 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
3115 Don't use FUTEX_CMP_REQUEUE if dep_mutex is not process private.
3116 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
3117 (__pthread_cond_signal): Pass LLL_PRIVATE to lll_* and or
3118 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
3119 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Include
3120 kernel-features.h.
3121 (__pthread_cond_wait, __condvar_w_cleanup): Pass LLL_PRIVATE to
3122 lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
3123 process private. Switch DW_CFA_advance_loc1 and some
3124 DW_CFA_advance_loc .eh_frame opcodes to DW_CFA_advance_loc4.
3125 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
3126 (__pthread_cond_timedwait, __condvar_tw_cleanup): Pass LLL_PRIVATE to
3127 lll_* and or FUTEX_PRIVATE_FLAG into SYS_futex op if cv is
3128 process private. Switch DW_CFA_advance_loc{1,2} and some
3129 DW_CFA_advance_loc .eh_frame opcodes to DW_CFA_advance_loc4.
3130 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Use
3131 #ifdef __ASSUME_PRIVATE_FUTEX instead of #if __ASSUME_PRIVATE_FUTEX.
3132 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
3133 Likewise.
3134 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
3135 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
3136 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
3137 Likewise.
3138 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
3139 (__pthread_cond_broadcast): Compare %r8 instead of
3140 dep_mutex-cond_*(%rdi) with $-1.
3141 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
3142 (__pthread_cond_signal): Xor FUTEX_WAKE_OP with FUTEX_WAKE instead
3143 of oring.
3144
4baf59ad
UD
31452007-08-13 Ulrich Drepper <drepper@redhat.com>
3146
3147 * sysdeps/unix/sysv/linux/i386/i786/Implies: New file.
3148
9c6f6953
UD
31492007-08-13 Jakub Jelinek <jakub@redhat.com>
3150
3151 * allocatestack.c: Include kernel-features.h.
3152 * pthread_create.c: Likewise.
3153 * pthread_mutex_init.c: Likewise.
3154 * init.c: Likewise.
3155 * pthread_cond_timedwait.c: Likewise.
3156 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
3157 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
3158 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
3159 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
3160 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
3161 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
3162 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
3163 Likewise.
3164 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
3165 Likewise.
3166 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
3167 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
3168 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
3169 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
3170
974a1f0f
UD
31712007-08-12 Jakub Jelinek <jakub@redhat.com>
3172
3173 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h
3174 [__WORDSIZE=32] (pthread_rwlock_t): Split __flags element into four
3175 byte elements. One of them is the new __shared element.
3176 [__WORDSIZE=64] (pthread_rwlock_t): Renamed __pad1 element to __shared,
3177 adjust names of other padding elements.
3178 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h
3179 [__WORDSIZE=32] (pthread_rwlock_t): Split __flags element into four
3180 byte elements. One of them is the new __shared element.
3181 [__WORDSIZE=64] (pthread_rwlock_t): Renamed __pad1 element to __shared,
3182 adjust names of other padding elements.
3183 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_rwlock_t):
3184 Renamed __pad1 element to __shared, adjust names of other padding
3185 elements.
3186 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
3187 (pthread_rwlock_t): Likewise.
3188 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_lock): Fix a
3189 typo.
3190
31912007-08-09 Anton Blanchard <anton@samba.org>
3192
3193 * sysdeps/unix/sysv/linux/powerpc/pthread_spin_unlock.c: New file.
3194
f47e2626
UD
31952007-08-12 Ulrich Drepper <drepper@redhat.com>
3196
3197 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Include
3198 <kernel-features.h>.
3199 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
3200
5bd8a249
UD
32012007-08-11 Ulrich Drepper <drepper@redhat.com>
3202
3203 * pthreadP.h (PTHREAD_ROBUST_MUTEX_PSHARED): Define.
3204 * pthread_mutex_lock.c: Use it instead of PTHREAD_MUTEX_PSHARED when
3205 dealing with robust mutexes.
3206 * pthread_mutex_timedlock.c: Likewise.
3207 * pthread_mutex_trylock.c: Likewise.
3208 * pthread_mutex_unlock.c: Likewise.
3209 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
3210
32112007-08-06 Jakub Jelinek <jakub@redhat.com>
3212
3213 * pthreadP.h (PTHREAD_MUTEX_PSHARED_BIT): Define.
3214 (PTHREAD_MUTEX_TYPE): Mask __kind with 127.
3215 (PTHREAD_MUTEX_PSHARED): Define.
3216 * pthread_mutex_init.c (__pthread_mutex_init): Set
3217 PTHREAD_MUTEX_PSHARED_BIT for pshared or robust
3218 mutexes.
3219 * pthread_mutex_lock.c (LLL_MUTEX_LOCK): Take mutex as argument
3220 instead of its __data.__lock field, pass PTHREAD_MUTEX_PSHARED
3221 as second argument to lll_lock.
3222 (LLL_MUTEX_TRYLOCK): Take mutex as argument
3223 instead of its __data.__lock field.
3224 (LLL_ROBUST_MUTEX_LOCK): Take mutex as argument instead of its
3225 __data.__lock field, pass PTHREAD_MUTEX_PSHARED as second argument
3226 to lll_robust_lock.
3227 (__pthread_mutex_lock): Update LLL_MUTEX_LOCK, LLL_MUTEX_TRYLOCK,
3228 LLL_ROBUST_MUTEX_LOCK users, use PTHREAD_MUTEX_TYPE (mutex)
3229 instead of mutex->__data.__kind directly, pass
3230 PTHREAD_MUTEX_PSHARED (mutex) to lll_unlock and lll_futex_wait.
3231 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Use
3232 PTHREAD_MUTEX_TYPE (mutex) instead of mutex->__data.__kind
3233 directly, pass PTHREAD_MUTEX_PSHARED (mutex) to lll_unlock.
3234 (pthread_mutex_timedlock): Pass PTHREAD_MUTEX_PSHARED (mutex)
3235 to lll_timedlock, lll_robust_timedlock, lll_unlock and
3236 lll_futex_timed_wait. Use PTHREAD_MUTEX_TYPE (mutex) instead
3237 of mutex->__data.__kind directly.
3238 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Pass
3239 PTHREAD_MUTEX_PSHARED (mutex) to lll_timedlock,
3240 lll_robust_timedlock, lll_unlock and lll_futex_timed_wait. Use
3241 PTHREAD_MUTEX_TYPE (mutex) instead of mutex->__data.__kind directly.
3242 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Pass
3243 PTHREAD_MUTEX_PSHARED (mutex) to lll_unlock, lll_robust_unlock
3244 and lll_futex_wake.
3245 * pthread_mutex_setprioceiling.c (pthread_mutex_setprioceiling): Pass
3246 PTHREAD_MUTEX_PSHARED (mutex) to lll_futex_wait and lll_futex_wake.
3247 Use PTHREAD_MUTEX_TYPE (mutex) instead of mutex->__data.__kind
3248 directly.
3249 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c (LLL_MUTEX_LOCK):
3250 Take mutex as argument instead of its __data.__lock field, pass
3251 PTHREAD_MUTEX_PSHARED as second argument to lll_cond_lock.
3252 (LLL_MUTEX_TRYLOCK): Take mutex as argument instead of its
3253 __data.__lock field.
3254 (LLL_ROBUST_MUTEX_LOCK): Take mutex as argument instead of its
3255 __data.__lock field, pass PTHREAD_MUTEX_PSHARED as second argument
3256 to lll_robust_cond_lock.
3257 * pthread_cond_broadcast.c (__pthread_cond_broadcast): Add pshared
3258 variable, pass it to lll_lock, lll_unlock, lll_futex_requeue and
3259 lll_futex_wake. Don't use lll_futex_requeue if dependent mutex
3260 has PTHREAD_MUTEX_PSHARED_BIT bit set in its __data.__kind.
3261 * pthread_cond_destroy.c (__pthread_cond_destroy): Add pshared
3262 variable, pass it to lll_lock, lll_unlock, lll_futex_wake and
3263 lll_futex_wait.
3264 * pthread_cond_signal.c (__pthread_cond_signal): Add pshared
3265 variable, pass it to lll_lock, lll_unlock, lll_futex_wake_unlock and
3266 lll_futex_wake.
3267 * pthread_cond_timedwait.c (__pthread_cond_wait): Add
3268 pshared variable, pass it to lll_lock, lll_unlock,
3269 lll_futex_timedwait and lll_futex_wake.
3270 * pthread_cond_wait.c (__condvar_cleanup, __pthread_cond_wait): Add
3271 pshared variable, pass it to lll_lock, lll_unlock, lll_futex_wait
3272 and lll_futex_wake.
3273 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_futex_requeue,
3274 lll_futex_wake_unlock): Add private argument, use __lll_private_flag
3275 macro.
3276 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_requeue,
3277 lll_futex_wake_unlock): Likewise.
3278 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (lll_futex_requeue):
3279 Likewise.
3280 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (lll_futex_requeue,
3281 lll_futex_wake_unlock): Likewise.
3282 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_futex_requeue):
3283 Likewise.
3284 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue,
3285 lll_futex_wake_unlock): Likewise.
3286 (lll_futex_wake): Fix a typo.
3287 * sysdeps/unix/sysv/linux/pthread-pi-defines.sym (PS_BIT): Add.
3288 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
3289 (__pthread_cond_broadcast): Pass LLL_PRIVATE to lll_* and or
3290 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
3291 Don't use FUTEX_CMP_REQUEUE if dep_mutex is not process private.
3292 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
3293 (__pthread_cond_signal): Pass LLL_PRIVATE to lll_* and or
3294 FUTEX_PRIVATE_FLAG into SYS_futex op if cv is process private.
3295 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
3296 (__pthread_cond_timedwait): Likewise.
3297 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:
3298 (__condvar_cleanup, __pthread_cond_wait): Likewise.
3299
0470fa46
JJ
33002007-08-05 Jakub Jelinek <jakub@redhat.com>
3301
3302 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (PSEUDO):
3303 Don't use CGOTSETUP and CGOTRESTORE macros.
3304 (CGOTSETUP, CGOTRESTORE): Remove.
3305 <IS_IN_rtld> (CENABLE, CDISABLE): Don't use JUMPTARGET, branch to
3306 @local symbol.
3307
64f6281c
UD
33082007-08-01 Kaz Kojima <kkojima@rr.iij4u.or.jp>
3309
3310 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Remove
3311 definitions for private futexes.
3312 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Include
3313 kernel-features.h and lowlevellock.h. Use private futexes if
3314 they are available.
3315 (__lll_lock_wait_private, __lll_unlock_wake_private): New.
3316 (__lll_mutex_lock_wait): Rename to
3317 (__lll_lock_wait): ... this. Don't compile in for libc.so.
3318 (__lll_mutex_timedlock_wait): Rename to ...
3319 (__lll_timedlock_wait): ... this. Use __NR_gettimeofday.
3320 Don't compile in for libc.so.
3321 (__lll_mutex_unlock_wake): Rename to ...
3322 (__lll_unlock_wake): ... this. Don't compile in for libc.so.
3323 (__lll_timedwait_tid): Use __NR_gettimeofday.
3324 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Allow including
3325 the header from assembler. Renamed all lll_mutex_* resp.
3326 lll_robust_mutex_* macros to lll_* resp. lll_robust_*.
3327 Renamed all LLL_MUTEX_LOCK_* macros to LLL_LOCK_*.
3328 (FUTEX_CMP_REQUEUE, FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE):
3329 Define.
3330 (__lll_lock_wait_private): Add prototype.
3331 (__lll_lock_wait, __lll_timedlock_wait, __lll_robust_lock_wait,
3332 __lll_robust_timedlock_wait, __lll_unlock_wake_private,
3333 __lll_unlock_wake): Likewise.
3334 (lll_lock): Add private argument. Call __lll_lock_wait_private
3335 if private is constant LLL_PRIVATE.
3336 (lll_robust_lock, lll_cond_lock, lll_robust_cond_lock,
3337 lll_timedlock, lll_robust_timedlock): Add private argument.
3338 (lll_unlock): Add private argument. Call __lll_unlock_wake_private
3339 if private is constant LLL_PRIVATE.
3340 (lll_robust_unlock, lll_robust_dead): Add private argument.
3341 (lll_lock_t): Remove.
3342 (__lll_cond_wait, __lll_cond_timedwait, __lll_cond_wake,
3343 __lll_cond_broadcast, lll_cond_wait, lll_cond_timedwait,
3344 lll_cond_wake, lll_cond_broadcast): Remove.
3345 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S: Include
3346 kernel-features.h and lowlevellock.h.
3347 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Remove.
3348 (LOAD_FUTEX_WAIT): Define.
3349 (__lll_robust_mutex_lock_wait): Rename to ...
3350 (__lll_robust_lock_wait): ... this. Add private argument.
3351 Use LOAD_FUTEX_WAIT macro.
3352 (__lll_robust_mutex_timedlock_wait): Rename to ...
3353 (__lll_robust_timedlock_wait): ... this. Add private argument.
3354 Use __NR_gettimeofday. Use LOAD_FUTEX_WAIT macro.
3355 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Include
3356 lowlevellock.h.
3357 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Remove.
3358 (pthread_barrier_wait): Use __lll_{lock,unlock}_* instead of
3359 __lll_mutex_{lock,unlock}_*.
3360 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Include
3361 lowlevellock.h and pthread-errnos.h.
3362 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE,
3363 FUTEX_CMP_REQUEUE, EINVAL): Remove.
3364 (__pthread_cond_broadcast): Use __lll_{lock,unlock}_* instead of
3365 __lll_mutex_{lock,unlock}_*.
3366 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Include
3367 lowlevellock.h and pthread-errnos.h.
3368 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE, EINVAL): Remove.
3369 (__pthread_cond_signal): Use __lll_{lock,unlock}_* instead of
3370 __lll_mutex_{lock,unlock}_*.
3371 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Include
3372 lowlevellock.h.
3373 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE): Remove.
3374 (__pthread_cond_timedwait): Use __lll_{lock,unlock}_* instead of
3375 __lll_mutex_{lock,unlock}_*. Use __NR_gettimeofday.
3376 (__condvar_tw_cleanup): Likewise.
3377 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Include
3378 lowlevellock.h.
3379 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Remove.
3380 (__pthread_cond_wait): Use __lll_{lock,unlock}_* instead of
3381 __lll_mutex_{lock,unlock}_*.
3382 ( __condvar_w_cleanup): Likewise.
3383 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Include lowlevellock.h.
3384 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
3385 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Include
3386 lowlevellock.h.
3387 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
3388 (__pthread_rwlock_rdlock): Use __lll_{lock,unlock}_* instead of
3389 __lll_mutex_{lock,unlock}_*.
3390 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Include
3391 lowlevellock.h.
3392 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE,
3393 FUTEX_PRIVATE_FLAG): Remove.
3394 (pthread_rwlock_timedrdlock): Use __lll_{lock,unlock}_* instead of
3395 __lll_mutex_{lock,unlock}_*. Use __NR_gettimeofday.
3396 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Include
3397 lowlevellock.h.
3398 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE,
3399 FUTEX_PRIVATE_FLAG): Remove.
3400 (pthread_rwlock_timedwrlock): Use __lll_{lock,unlock}_* instead of
3401 __lll_mutex_{lock,unlock}_*. Use __NR_gettimeofday.
3402 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Include
3403 lowlevellock.h.
3404 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
3405 (__pthread_rwlock_unlock): Use __lll_{lock,unlock}_* instead of
3406 __lll_mutex_{lock,unlock}_*.
3407 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Include
3408 lowlevellock.h.
3409 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
3410 (__pthread_rwlock_wrlock): Use __lll_{lock,unlock}_* instead of
3411 __lll_mutex_{lock,unlock}_*.
3412 * sysdeps/unix/sysv/linux/sh/sem_post.S: Include lowlevellock.h.
3413 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Remove.
3414 (__new_sem_post): Use standard initial exec code sequences.
3415 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Include
3416 lowlevellock.h.
3417 (SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE,
3418 FUTEX_PRIVATE_FLAG): Remove.
3419 (sem_timedwait): Use __NR_gettimeofday. Use standard initial
3420 exec code sequences.
3421 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Include lowlevellock.h.
3422 (__new_sem_trywait): Use standard initial exec code sequences.
3423 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Include lowlevellock.h.
3424 (__new_sem_wait): Use standard initial exec code sequences.
3425
e51deae7
UD
34262007-07-31 Anton Blanchard <anton@samba.org>
3427
3428 * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__new_sem_post):
3429 Use __asm __volatile (__lll_acq_instr ::: "memory") instead of
3430 atomic_full_barrier.
3431
34322007-07-31 Jakub Jelinek <jakub@redhat.com>
3433
3434 * allocatestack.c (stack_cache_lock): Change type to int.
3435 (get_cached_stack, allocate_stack, __deallocate_stack,
3436 __make_stacks_executable, __find_thread_by_id, __nptl_setxid,
3437 __pthread_init_static_tls, __wait_lookup_done): Add LLL_PRIVATE
3438 as second argument to lll_lock and lll_unlock macros on
3439 stack_cache_lock.
3440 * pthread_create.c (__find_in_stack_list): Likewise.
3441 (start_thread): Similarly with pd->lock. Use lll_robust_dead
3442 macro instead of lll_robust_mutex_dead, pass LLL_SHARED to it
3443 as second argument.
3444 * descr.h (struct pthread): Change lock and setxid_futex field
3445 type to int.
3446 * old_pthread_cond_broadcast.c (__pthread_cond_broadcast_2_0): Use
3447 LLL_LOCK_INITIALIZER instead of LLL_MUTEX_LOCK_INITIALIZER.
3448 * old_pthread_cond_signal.c (__pthread_cond_signal_2_0): Likewise.
3449 * old_pthread_cond_timedwait.c (__pthread_cond_timedwait_2_0):
3450 Likewise.
3451 * old_pthread_cond_wait.c (__pthread_cond_wait_2_0): Likewise.
3452 * pthread_cond_init.c (__pthread_cond_init): Likewise.
3453 * pthreadP.h (__attr_list_lock): Change type to int.
3454 * pthread_attr_init.c (__attr_list_lock): Likewise.
3455 * pthread_barrier_destroy.c (pthread_barrier_destroy): Pass
3456 ibarrier->private ^ FUTEX_PRIVATE_FLAG as second argument to
3457 lll_{,un}lock.
3458 * pthread_barrier_wait.c (pthread_barrier_wait): Likewise and
3459 also for lll_futex_{wake,wait}.
3460 * pthread_barrier_init.c (pthread_barrier_init): Make iattr
3461 a pointer to const.
3462 * pthread_cond_broadcast.c (__pthread_cond_broadcast): Pass
3463 LLL_SHARED as second argument to lll_{,un}lock.
3464 * pthread_cond_destroy.c (__pthread_cond_destroy): Likewise.
3465 * pthread_cond_signal.c (__pthread_cond_singal): Likewise.
3466 * pthread_cond_timedwait.c (__pthread_cond_timedwait): Likewise.
3467 * pthread_cond_wait.c (__condvar_cleanup, __pthread_cond_wait):
3468 Likewise.
3469 * pthread_getattr_np.c (pthread_getattr_np): Add LLL_PRIVATE
3470 as second argument to lll_{,un}lock macros on pd->lock.
3471 * pthread_getschedparam.c (__pthread_getschedparam): Likewise.
3472 * pthread_setschedparam.c (__pthread_setschedparam): Likewise.
3473 * pthread_setschedprio.c (pthread_setschedprio): Likewise.
3474 * tpp.c (__pthread_tpp_change_priority, __pthread_current_priority):
3475 Likewise.
3476 * sysdeps/pthread/createthread.c (do_clone, create_thread):
3477 Likewise.
3478 * pthread_once.c (once_lock): Change type to int.
3479 (__pthread_once): Pass LLL_PRIVATE as second argument to
3480 lll_{,un}lock macros on once_lock.
3481 * pthread_rwlock_rdlock.c (__pthread_rwlock_rdlock): Use
3482 lll_{,un}lock macros instead of lll_mutex_{,un}lock, pass
3483 rwlock->__data.__shared as second argument to them and similarly
3484 for lll_futex_w*.
3485 * pthread_rwlock_timedrdlock.c (pthread_rwlock_timedrdlock):
3486 Likewise.
3487 * pthread_rwlock_timedwrlock.c (pthread_rwlock_timedwrlock):
3488 Likewise.
3489 * pthread_rwlock_tryrdlock.c (__pthread_rwlock_tryrdlock): Likewise.
3490 * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Likewise.
3491 * pthread_rwlock_unlock.c (__pthread_rwlock_unlock): Likewise.
3492 * pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock): Likewise.
3493 * sem_close.c (sem_close): Pass LLL_PRIVATE as second argument
3494 to lll_{,un}lock macros on __sem_mappings_lock.
3495 * sem_open.c (check_add_mapping): Likewise.
3496 (__sem_mappings_lock): Change type to int.
3497 * semaphoreP.h (__sem_mappings_lock): Likewise.
3498 * pthread_mutex_lock.c (LLL_MUTEX_LOCK, LLL_MUTEX_TRYLOCK,
3499 LLL_ROBUST_MUTEX_LOCK): Use lll_{,try,robust_}lock macros
3500 instead of lll_*mutex_*, pass LLL_SHARED as last
3501 argument.
3502 (__pthread_mutex_lock): Use lll_unlock instead of lll_mutex_unlock,
3503 pass LLL_SHARED as last argument.
3504 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c (LLL_MUTEX_LOCK,
3505 LLL_MUTEX_TRYLOCK, LLL_ROBUST_MUTEX_LOCK): Use
3506 lll_{cond_,cond_try,robust_cond}lock macros instead of lll_*mutex_*,
3507 pass LLL_SHARED as last argument.
3508 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Use
3509 lll_{timed,try,robust_timed,un}lock instead of lll_*mutex*, pass
3510 LLL_SHARED as last argument.
3511 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Similarly.
3512 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt):
3513 Similarly.
3514 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_lock,
3515 __libc_lock_lock_recursive, __libc_lock_unlock,
3516 __libc_lock_unlock_recursive): Pass LLL_PRIVATE as second
3517 argument to lll_{,un}lock.
3518 * sysdeps/pthread/bits/stdio-lock.h (_IO_lock_lock,
3519 _IO_lock_unlock): Likewise.
3520 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Don't use
3521 compound literal.
3522 * sysdeps/unix/sysv/linux/unregister-atfork.c (__unregister_atfork):
3523 Pass LLL_PRIVATE as second argument to lll_{,un}lock macros on
3524 __fork_lock.
3525 * sysdeps/unix/sysv/linux/register-atfork.c (__register_atfork,
3526 free_mem): Likewise.
3527 (__fork_lock): Change type to int.
3528 * sysdeps/unix/sysv/linux/fork.h (__fork_lock): Likewise.
3529 * sysdeps/unix/sysv/linux/sem_post.c (__new_sem_post): Pass
3530 isem->private ^ FUTEX_PRIVATE_FLAG as second argument to
3531 lll_futex_wake.
3532 * sysdeps/unix/sysv/linux/sem_timedwait.c (sem_timedwait): Likewise.
3533 * sysdeps/unix/sysv/linux/sem_wait.c (__new_sem_wait): Likewise.
3534 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait_private):
3535 New function.
3536 (__lll_lock_wait, __lll_timedlock_wait): Add private argument and
3537 pass it through to lll_futex_*wait, only compile in when
3538 IS_IN_libpthread.
3539 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
3540 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): Add private
3541 argument and pass it through to lll_futex_*wait.
3542 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Renamed all
3543 lll_mutex_* resp. lll_robust_mutex_* macros to lll_* resp.
3544 lll_robust_*. Renamed all __lll_mutex_* resp. __lll_robust_mutex_*
3545 inline functions to __lll_* resp. __lll_robust_*.
3546 (LLL_MUTEX_LOCK_INITIALIZER): Remove.
3547 (lll_mutex_dead): Add private argument.
3548 (__lll_lock_wait_private): New prototype.
3549 (__lll_lock_wait, __lll_robust_lock_wait, __lll_lock_timedwait,
3550 __lll_robust_lock_timedwait): Add private argument to prototypes.
3551 (__lll_lock): Add private argument, if it is constant LLL_PRIVATE,
3552 call __lll_lock_wait_private, otherwise pass private to
3553 __lll_lock_wait.
3554 (__lll_robust_lock, __lll_cond_lock, __lll_timedlock,
3555 __lll_robust_timedlock): Add private argument, pass it to
3556 __lll_*wait functions.
3557 (__lll_unlock): Add private argument, if it is constant LLL_PRIVATE,
3558 call __lll_unlock_wake_private, otherwise pass private to
3559 __lll_unlock_wake.
3560 (__lll_robust_unlock): Add private argument, pass it to
3561 __lll_robust_unlock_wake.
3562 (lll_lock, lll_robust_lock, lll_cond_lock, lll_timedlock,
3563 lll_robust_timedlock, lll_unlock, lll_robust_unlock): Add private
3564 argument, pass it through to __lll_* inline function.
3565 (__lll_mutex_unlock_force, lll_mutex_unlock_force): Remove.
3566 (lll_lock_t): Remove.
3567 (__lll_cond_wait, __lll_cond_timedwait, __lll_cond_wake,
3568 __lll_cond_broadcast, lll_cond_wait, lll_cond_timedwait,
3569 lll_cond_wake, lll_cond_broadcast): Remove.
3570 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
3571 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
3572 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
3573 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
3574 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Allow including
3575 the header from assembler. Renamed all lll_mutex_* resp.
3576 lll_robust_mutex_* macros to lll_* resp. lll_robust_*.
3577 (LOCK, FUTEX_CMP_REQUEUE, FUTEX_WAKE_OP,
3578 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
3579 (LLL_MUTEX_LOCK_INITIALIZER, LLL_MUTEX_LOCK_INITIALIZER_LOCKED,
3580 LLL_MUTEX_LOCK_INITIALIZER_WAITERS): Remove.
3581 (__lll_mutex_lock_wait, __lll_mutex_timedlock_wait,
3582 __lll_mutex_unlock_wake, __lll_lock_wait, __lll_unlock_wake):
3583 Remove prototype.
3584 (__lll_trylock_asm, __lll_lock_asm_start, __lll_unlock_asm): Define.
3585 (lll_robust_trylock, lll_cond_trylock): Use LLL_LOCK_INITIALIZER*
3586 rather than LLL_MUTEX_LOCK_INITIALIZER* macros.
3587 (lll_trylock): Likewise, use __lll_trylock_asm, pass
3588 MULTIPLE_THREADS_OFFSET as another asm operand.
3589 (lll_lock): Add private argument, use __lll_lock_asm_start, pass
3590 MULTIPLE_THREADS_OFFSET as last asm operand, call
3591 __lll_lock_wait_private if private is constant LLL_PRIVATE,
3592 otherwise pass private as another argument to __lll_lock_wait.
3593 (lll_robust_lock, lll_cond_lock, lll_robust_cond_lock,
3594 lll_timedlock, lll_robust_timedlock): Add private argument, pass
3595 private as another argument to __lll_*lock_wait call.
3596 (lll_unlock): Add private argument, use __lll_unlock_asm, pass
3597 MULTIPLE_THREADS_OFFSET as another asm operand, call
3598 __lll_unlock_wake_private if private is constant LLL_PRIVATE,
3599 otherwise pass private as another argument to __lll_unlock_wake.
3600 (lll_robust_unlock): Add private argument, pass private as another
3601 argument to __lll_unlock_wake.
3602 (lll_robust_dead): Add private argument, use __lll_private_flag
3603 macro.
3604 (lll_islocked): Use LLL_LOCK_INITIALIZER instead of
3605 LLL_MUTEX_LOCK_INITIALIZER.
3606 (lll_lock_t): Remove.
3607 (LLL_LOCK_INITIALIZER_WAITERS): Define.
3608 (__lll_cond_wait, __lll_cond_timedwait, __lll_cond_wake,
3609 __lll_cond_broadcast, lll_cond_wait, lll_cond_timedwait,
3610 lll_cond_wake, lll_cond_broadcast): Remove.
3611 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
3612 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Revert
3613 2007-05-2{3,9} changes.
3614 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Include
3615 kernel-features.h and lowlevellock.h.
3616 (LOAD_PRIVATE_FUTEX_WAIT): Define.
3617 (LOAD_FUTEX_WAIT): Rewritten.
3618 (LOCK, SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't
3619 define.
3620 (__lll_lock_wait_private, __lll_unlock_wake_private): New functions.
3621 (__lll_mutex_lock_wait): Rename to ...
3622 (__lll_lock_wait): ... this. Take futex addr from %edx instead of
3623 %ecx, %ecx is now private argument. Don't compile in for libc.so.
3624 (__lll_mutex_timedlock_wait): Rename to ...
3625 (__lll_timedlock_wait): ... this. Use __NR_gettimeofday. %esi
3626 contains private argument. Don't compile in for libc.so.
3627 (__lll_mutex_unlock_wake): Rename to ...
3628 (__lll_unlock_wake): ... this. %ecx contains private argument.
3629 Don't compile in for libc.so.
3630 (__lll_timedwait_tid): Use __NR_gettimeofday.
3631 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: Include
3632 kernel-features.h and lowlevellock.h.
3633 (LOAD_FUTEX_WAIT): Define.
3634 (LOCK, SYS_gettimeofday, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't
3635 define.
3636 (__lll_robust_mutex_lock_wait): Rename to ...
3637 (__lll_robust_lock_wait): ... this. Futex addr is now in %edx
3638 argument, %ecx argument contains private. Use LOAD_FUTEX_WAIT
3639 macro.
3640 (__lll_robust_mutex_timedlock_wait): Rename to ...
3641 (__lll_robust_timedlock_wait): ... this. Use __NR_gettimeofday.
3642 %esi argument contains private, use LOAD_FUTEX_WAIT macro.
3643 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Include
3644 lowlevellock.h.
3645 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3646 (pthread_barrier_wait): Rename __lll_mutex_* to __lll_*, pass
3647 PRIVATE(%ebx) ^ LLL_SHARED as private argument in %ecx to
3648 __lll_lock_wait and __lll_unlock_wake, pass MUTEX(%ebx) address
3649 to __lll_lock_wait in %edx.
3650 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S:
3651 Include lowlevellock.h and pthread-errnos.h.
3652 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE,
3653 FUTEX_CMP_REQUEUE, EINVAL, LOCK): Don't define.
3654 (__pthread_cond_broadcast): Rename __lll_mutex_* to __lll_*, pass
3655 cond_lock address in %edx rather than %ecx to __lll_lock_wait,
3656 pass LLL_SHARED in %ecx to both __lll_lock_wait and
3657 __lll_unlock_wake.
3658 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S:
3659 Include lowlevellock.h and pthread-errnos.h.
3660 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_WAKE_OP,
3661 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE, EINVAL, LOCK): Don't define.
3662 (__pthread_cond_signal): Rename __lll_mutex_* to __lll_*, pass
3663 cond_lock address in %edx rather than %ecx to __lll_lock_wait,
3664 pass LLL_SHARED in %ecx to both __lll_lock_wait and
3665 __lll_unlock_wake.
3666 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
3667 Include lowlevellock.h.
3668 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE, LOCK):
3669 Don't define.
3670 (__pthread_cond_timedwait): Rename __lll_mutex_* to __lll_*, pass
3671 cond_lock address in %edx rather than %ecx to __lll_lock_wait,
3672 pass LLL_SHARED in %ecx to both __lll_lock_wait and
3673 __lll_unlock_wake. Use __NR_gettimeofday.
3674 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
3675 Include lowlevellock.h.
3676 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3677 (__pthread_cond_wait, __condvar_w_cleanup): Rename __lll_mutex_*
3678 to __lll_*, pass cond_lock address in %edx rather than %ecx to
3679 __lll_lock_wait, pass LLL_SHARED in %ecx to both __lll_lock_wait
3680 and __lll_unlock_wake.
3681 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S:
3682 Include lowlevellock.h.
3683 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3684 (__pthread_rwlock_rdlock): Rename __lll_mutex_* to __lll_*, pass
3685 MUTEX(%ebx) address in %edx rather than %ecx to
3686 __lll_lock_wait, pass PSHARED(%ebx) in %ecx to both __lll_lock_wait
3687 and __lll_unlock_wake. Move return value from %ecx to %edx
3688 register.
3689 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
3690 Include lowlevellock.h.
3691 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE, LOCK):
3692 Don't define.
3693 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*, pass
3694 MUTEX(%ebp) address in %edx rather than %ecx to
3695 __lll_lock_wait, pass PSHARED(%ebp) in %ecx to both __lll_lock_wait
3696 and __lll_unlock_wake. Move return value from %ecx to %edx
3697 register. Use __NR_gettimeofday.
3698 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
3699 Include lowlevellock.h.
3700 (SYS_futex, SYS_gettimeofday, FUTEX_WAIT, FUTEX_WAKE, LOCK):
3701 Don't define.
3702 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*, pass
3703 MUTEX(%ebp) address in %edx rather than %ecx to
3704 __lll_lock_wait, pass PSHARED(%ebp) in %ecx to both __lll_lock_wait
3705 and __lll_unlock_wake. Move return value from %ecx to %edx
3706 register. Use __NR_gettimeofday.
3707 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
3708 Include lowlevellock.h.
3709 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3710 (__pthread_rwlock_unlock): Rename __lll_mutex_* to __lll_*, pass
3711 MUTEX(%edi) address in %edx rather than %ecx to
3712 __lll_lock_wait, pass PSHARED(%edi) in %ecx to both __lll_lock_wait
3713 and __lll_unlock_wake.
3714 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S:
3715 Include lowlevellock.h.
3716 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3717 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*, pass
3718 MUTEX(%ebx) address in %edx rather than %ecx to
3719 __lll_lock_wait, pass PSHARED(%ebx) in %ecx to both __lll_lock_wait
3720 and __lll_unlock_wake. Move return value from %ecx to %edx
3721 register.
3722 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Include
3723 lowlevellock.h.
3724 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Don't
3725 define.
3726 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Include lowlevellock.h.
3727 (LOCK, SYS_futex, FUTEX_WAKE): Don't define.
3728 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Include
3729 lowlevellock.h.
3730 (LOCK, SYS_futex, SYS_gettimeofday, FUTEX_WAIT): Don't define.
3731 (sem_timedwait): Use __NR_gettimeofday.
3732 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Include
3733 lowlevellock.h.
3734 (LOCK): Don't define.
3735 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Include
3736 lowlevellock.h.
3737 (LOCK, SYS_futex, FUTEX_WAIT): Don't define.
3738 * sysdeps/unix/sysv/linux/powerpc/sem_post.c: Wake only when there
3739 are waiters.
3740 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Revert
3741 2007-05-2{3,9} changes.
3742 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Include
3743 kernel-features.h and lowlevellock.h.
3744 (LOAD_PRIVATE_FUTEX_WAIT): Define.
3745 (LOAD_FUTEX_WAIT): Rewritten.
3746 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't define.
3747 (__lll_lock_wait_private, __lll_unlock_wake_private): New functions.
3748 (__lll_mutex_lock_wait): Rename to ...
3749 (__lll_lock_wait): ... this. %esi is now private argument.
3750 Don't compile in for libc.so.
3751 (__lll_mutex_timedlock_wait): Rename to ...
3752 (__lll_timedlock_wait): ... this. %esi contains private argument.
3753 Don't compile in for libc.so.
3754 (__lll_mutex_unlock_wake): Rename to ...
3755 (__lll_unlock_wake): ... this. %esi contains private argument.
3756 Don't compile in for libc.so.
3757 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Include
3758 kernel-features.h and lowlevellock.h.
3759 (LOAD_FUTEX_WAIT): Define.
3760 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE): Don't define.
3761 (__lll_robust_mutex_lock_wait): Rename to ...
3762 (__lll_robust_lock_wait): ... this. %esi argument contains private.
3763 Use LOAD_FUTEX_WAIT macro.
3764 (__lll_robust_mutex_timedlock_wait): Rename to ...
3765 (__lll_robust_timedlock_wait): ... this. %esi argument contains
3766 private, use LOAD_FUTEX_WAIT macro.
3767 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Include
3768 lowlevellock.h.
3769 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3770 (pthread_barrier_wait): Rename __lll_mutex_* to __lll_*, pass
3771 PRIVATE(%rdi) ^ LLL_SHARED as private argument in %esi to
3772 __lll_lock_wait and __lll_unlock_wake.
3773 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S:
3774 Include lowlevellock.h and pthread-errnos.h.
3775 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_REQUEUE,
3776 FUTEX_CMP_REQUEUE, EINVAL, LOCK): Don't define.
3777 (__pthread_cond_broadcast): Rename __lll_mutex_* to __lll_*,
3778 pass LLL_SHARED in %esi to both __lll_lock_wait and
3779 __lll_unlock_wake.
3780 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S:
3781 Include lowlevellock.h and pthread-errnos.h.
3782 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_WAKE_OP,
3783 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE, EINVAL, LOCK): Don't define.
3784 (__pthread_cond_signal): Rename __lll_mutex_* to __lll_*,
3785 pass LLL_SHARED in %esi to both __lll_lock_wait and
3786 __lll_unlock_wake.
3787 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S:
3788 Include lowlevellock.h.
3789 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3790 (__pthread_cond_timedwait): Rename __lll_mutex_* to __lll_*,
3791 pass LLL_SHARED in %esi to both __lll_lock_wait and
3792 __lll_unlock_wake.
3793 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S:
3794 Include lowlevellock.h.
3795 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, LOCK): Don't define.
3796 (__pthread_cond_wait, __condvar_cleanup): Rename __lll_mutex_*
3797 to __lll_*, pass LLL_SHARED in %esi to both __lll_lock_wait
3798 and __lll_unlock_wake.
3799 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S:
3800 Include lowlevellock.h.
3801 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
3802 Don't define.
3803 (__pthread_rwlock_rdlock): Rename __lll_mutex_* to __lll_*,
3804 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
3805 and __lll_unlock_wake.
3806 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
3807 Include lowlevellock.h.
3808 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
3809 Don't define.
3810 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*,
3811 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
3812 and __lll_unlock_wake.
3813 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
3814 Include lowlevellock.h.
3815 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
3816 Don't define.
3817 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*,
3818 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
3819 and __lll_unlock_wake.
3820 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S:
3821 Include lowlevellock.h.
3822 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
3823 Don't define.
3824 (__pthread_rwlock_unlock): Rename __lll_mutex_* to __lll_*,
3825 pass PSHARED(%rdi) in %esi to both __lll_lock_wait
3826 and __lll_unlock_wake.
3827 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S:
3828 Include lowlevellock.h.
3829 (SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG, LOCK):
3830 Don't define.
3831 (__pthread_rwlock_wrlock): Rename __lll_mutex_* to __lll_*,
3832 pass PSHARED(%rdi) in %ecx to both __lll_lock_wait
3833 and __lll_unlock_wake.
3834 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Include
3835 lowlevellock.h.
3836 (LOCK, SYS_futex, FUTEX_WAIT, FUTEX_WAKE, FUTEX_PRIVATE_FLAG): Don't
3837 define.
3838 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Include lowlevellock.h.
3839 (LOCK, SYS_futex, FUTEX_WAKE): Don't define.
3840 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Include
3841 lowlevellock.h.
3842 (LOCK, SYS_futex, FUTEX_WAIT): Don't define.
3843 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Include
3844 lowlevellock.h.
3845 (LOCK): Don't define.
3846 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Include
3847 lowlevellock.h.
3848 (LOCK, SYS_futex, FUTEX_WAIT): Don't define.
3849 * sysdeps/unix/sysv/linux/sparc/internaltypes.h: New file.
3850 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_destroy.c: New file.
3851 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_init.c: New file.
3852 * sysdeps/unix/sysv/linux/sparc/pthread_barrier_wait.c: New file.
3853 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c
3854 (__lll_lock_wait_private): New function.
3855 (__lll_lock_wait, __lll_timedlock_wait): Add private argument, pass
3856 it to lll_futex_*wait. Don't compile in for libc.so.
3857 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_init.c:
3858 Remove.
3859 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_wait.c
3860 (struct sparc_pthread_barrier): Remove.
3861 (pthread_barrier_wait): Use union sparc_pthread_barrier instead of
3862 struct sparc_pthread_barrier. Pass
3863 ibarrier->s.pshared ? LLL_SHARED : LLL_PRIVATE to lll_{,un}lock
3864 and lll_futex_wait macros.
3865 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_init.c:
3866 Remove.
3867 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
3868 Include sparc pthread_barrier_wait.c instead of generic one.
3869
6f59d56e
UD
38702007-07-30 Jakub Jelinek <jakub@redhat.com>
3871
1475e201
UD
3872 * tst-rwlock14.c (do_test): Avoid warnings on 32-bit arches.
3873
6f59d56e
UD
3874 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
3875 (pthread_rwlock_timedrdlock): Copy futex retval to %esi rather than
3876 %ecx.
3877 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
3878 (pthread_rwlock_timedwrlock): Likewise.
3879 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
3880 (__pthread_rwlock_unlock): Fix MUTEX != 0 args to __lll_*.
3881
558f0300
JJ
38822007-07-31 Jakub Jelinek <jakub@redhat.com>
3883
3884 * sysdeps/sparc/tls.h (tcbhead_t): Add private_futex field.
3885
cedb4109
UD
38862007-07-26 Jakub Jelinek <jakub@redhat.com>
3887
3888 * tst-locale2.c (useless): Add return statement.
3889
085a4412
UD
38902007-07-24 Jakub Jelinek <jakub@redhat.com>
3891
3892 * allocatestack.c (__nptl_setxid, __wait_lookup_done): Replace
3893 lll_private_futex_* (*) with lll_futex_* (*, LLL_PRIVATE).
3894 * pthread_create.c (start_thread): Likewise.
3895 * init.c (sighandler_setxid): Likewise.
3896 * sysdeps/alpha/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3897 * sysdeps/ia64/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3898 * sysdeps/i386/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3899 * sysdeps/s390/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3900 * sysdeps/powerpc/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3901 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3902 * sysdeps/sparc/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3903 * sysdeps/sh/tls.h (THREAD_GSCOPE_RESET_FLAG): Likewise.
3904 * sysdeps/pthread/aio_misc.h (AIO_MISC_NOTIFY, AIO_MISC_WAIT):
3905 Likewise.
3906 * sysdeps/pthread/gai_misc.h (GAI_MISC_NOTIFY, GAI_MISC_WAIT):
3907 Likewise.
3908 * sysdeps/unix/sysv/linux/unregister-atfork.c (__unregister_atfork):
3909 Likewise.
3910 * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_waitzero,
3911 __rtld_notify): Likewise.
3912 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Likewise.
3913 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (clear_once_control,
3914 __pthread_once): Likewise.
3915 * sysdeps/unix/sysv/linux/alpha/pthread_once.c (clear_once_control,
3916 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
3917 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_PRIVATE_FLAG,
3918 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
3919 (lll_futex_wait): Add private argument, define as wrapper around
3920 lll_futex_timed_wait.
3921 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
3922 use __lll_private_flag macro.
3923 (lll_robust_mutex_dead, __lll_mutex_unlock, __lll_robust_mutex_unlock,
3924 __lll_mutex_unlock_force): Pass LLL_SHARED as last arg to lll_futex_*.
3925 * sysdeps/unix/sysv/linux/ia64/pthread_once.c (clear_once_control,
3926 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
3927 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_PRIVATE_FLAG,
3928 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
3929 (lll_futex_wait): Add private argument, define as wrapper around
3930 lll_futex_timed_wait.
3931 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
3932 use __lll_private_flag macro.
3933 (__lll_mutex_unlock, __lll_robust_mutex_unlock, lll_wait_tid,
3934 __lll_mutex_unlock_force): Pass LLL_SHARED as last arg to lll_futex_*.
3935 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (__lll_private_flag):
3936 Define.
3937 (lll_futex_timed_wait, lll_futex_wake): Use it.
3938 (lll_private_futex_wait, lll_private_futex_timed_wait,
3939 lll_private_futex_wake): Removed.
3940 * sysdeps/unix/sysv/linux/s390/pthread_once.c (clear_once_control,
3941 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
3942 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_PRIVATE_FLAG,
3943 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
3944 (lll_futex_wait): Add private argument, define as wrapper around
3945 lll_futex_timed_wait.
3946 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
3947 use __lll_private_flag macro.
3948 (lll_robust_mutex_dead, __lll_mutex_unlock, __lll_robust_mutex_unlock,
3949 lll_wait_tid, __lll_mutex_unlock_force): Pass LLL_SHARED as last arg
3950 to lll_futex_*.
3951 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
3952 (lll_private_futex_wait, lll_private_futex_timed_wait,
3953 lll_private_futex_wake): Removed.
3954 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (__lll_private_flag):
3955 Fix !__ASSUME_PRIVATE_FUTEX non-constant private case.
3956 (lll_private_futex_wait, lll_private_futex_timed_wait,
3957 lll_private_futex_wake): Removed.
3958 * sysdeps/unix/sysv/linux/sparc/pthread_once.c (clear_once_control,
3959 __pthread_once): Add LLL_PRIVATE as last argument to lll_futex_*.
3960 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_PRIVATE_FLAG,
3961 LLL_PRIVATE, LLL_SHARED, __lll_private_flag): Define.
3962 (lll_futex_wait): Add private argument, define as wrapper around
3963 lll_futex_timed_wait.
3964 (lll_futex_timed_wait, lll_futex_wake): Add private argument,
3965 use __lll_private_flag macro.
3966 (lll_robust_mutex_dead, __lll_mutex_unlock, __lll_robust_mutex_unlock,
3967 lll_wait_tid, __lll_mutex_unlock_force): Pass LLL_SHARED as last arg
3968 to lll_futex_*.
3969 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (__lll_private_flag):
3970 Define.
3971 (lll_futex_timed_wait, lll_futex_wake): Use it.
3972 (lll_private_futex_wait, lll_private_futex_timed_wait,
3973 lll_private_futex_wake): Removed.
3974
ef0af159
JJ
39752007-07-27 Jakub Jelinek <jakub@redhat.com>
3976
3977 * sysdeps/sparc/tls.h (tcbhead_t): Move gscope_flag to the end
3978 of the structure for sparc32.
3979
39802007-07-26 Aurelien Jarno <aurelien@aurel32.net>
3981
3982 * sysdeps/sparc/tls.h (tcbhead_t): Add gscope_flag.
3983
eb4f5909
UD
39842007-07-23 Ulrich Drepper <drepper@redhat.com>
3985
3986 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S: Fix
3987 code used when private futexes are assumed.
3988 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
3989 Likewise.
3990
b5f13526
UD
39912007-07-23 Jakub Jelinek <jakub@redhat.com>
3992
3993 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
3994 (__lll_private_flag): Define.
3995 (lll_futex_wait): Define as a wrapper around lll_futex_timed_wait.
3996 (lll_futex_timed_wait, lll_futex_wake, lll_futex_wake_unlock): Use
3997 __lll_private_flag.
3998 (lll_private_futex_wait, lll_private_futex_timedwait,
3999 lll_private_futex_wake): Define as wrapper around non-_private
4000 macros.
4001 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
4002 (__lll_private_flag): Define.
4003 (lll_futex_timed_wait, lll_futex_wake): Use __lll_private_flag.
4004 (lll_private_futex_wait, lll_private_futex_timedwait,
4005 lll_private_futex_wake): Define as wrapper around non-_private
4006 macros.
4007
eb7721f2
UD
40082007-07-10 Steven Munroe <sjmunroe@us.ibm.com>
4009
4010 * pthread_rwlock_rdlock.c (__pthread_rwlock_rdlock): Add LLL_SHARED
4011 parameter to lll_futex_wait call.
4012 * pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock): Likewise.
4013
4014 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (__pthread_once):
4015 Replace lll_futex_wait with lll_private_futex_wait.
4016 * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__new_sem_post):
4017 Add LLL_SHARED parameter to lll_futex_wake().
4018
4019 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define LLL_PRIVATE
4020 LLL_SHARED, lll_private_futex_wait, lll_private_futex_timed_wait and
4021 lll_private_futex_wake.
4022 (lll_futex_wait): Add private parameter. Adjust FUTEX_PRIVATE_FLAG
4023 bit from private parm before syscall.
4024 (lll_futex_timed_wait): Likewise.
4025 (lll_futex_wake): Likewise.
4026 (lll_futex_wake_unlock): Likewise.
4027 (lll_mutex_unlock): Add LLL_SHARED parm to lll_futex_wake call.
4028 (lll_robust_mutex_unlock): Likewise.
4029 (lll_mutex_unlock_force): Likewise.
4030 (lll_wait_tid): Add LLL_SHARED parm to lll_futex_wait call.
4031
defc45f2
UD
40322007-07-23 Ulrich Drepper <drepper@redhat.com>
4033
4034 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S: Fix
4035 compilation when unconditionally using private futexes.
4036 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
4037 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
4038 Likewise.
4039 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Likewise.
4040 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
4041
087722b8
UD
40422007-07-17 Jakub Jelinek <jakub@redhat.com>
4043
4044 * sysdeps/pthread/bits/stdio-lock.h (_IO_acquire_lock_clear_flags2):
4045 Define.
4046
765c6b0c
UD
40472007-07-06 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4048
4049 * sysdeps/sh/tls.h: Include stdlib.h, list.h, sysdep.h and
4050 kernel-features.h.
4051
7d9d8bd1
RM
40522007-05-16 Roland McGrath <roland@redhat.com>
4053
4054 * init.c (__nptl_initial_report_events): New variable.
4055 (__pthread_initialize_minimal_internal): Initialize pd->report_events
4056 to that.
4057
a4915df2
UD
40582007-06-22 Jakub Jelinek <jakub@redhat.com>
4059
4060 * pthread_getattr_np.c (pthread_getattr_np): Clear cpuset and
4061 cpusetsize if pthread_getaffinity_np failed with ENOSYS.
4062
e4eb675d
UD
40632007-06-19 Ulrich Drepper <drepper@redhat.com>
4064
4065 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: Remove mrlock
4066 implementation.
4067
ae1ad3ae
UD
40682007-06-18 Ulrich Drepper <drepper@redhat.com>
4069
4070 * pthreadP.h: Define PTHREAD_MUTEX_TYPE.
4071 * phtread_mutex_lock.c: Use PTHREAD_MUTEX_TYPE.
4072 * pthread_mutex_timedlock.c: Likewise.
4073 * pthread_mutex_trylock.c: Likewise.
4074 * pthread_mutex_unlock.c: Likewise.
4075
89074592
UD
40762007-06-17 Andreas Schwab <schwab@suse.de>
4077
4078 * sysdeps/pthread/pt-initfini.c: Tell gcc about the nonstandard
4079 sections.
4080
d4201cc4
UD
40812007-06-17 Ulrich Drepper <drepper@redhat.com>
4082
4083 * allocatestack.c (allocate_stack): Make code compile if
4084 __ASSUME_PRIVATE_FUTEX is set.
4085
339dbf0e
UD
40862007-06-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4087
4088 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S:
4089 (__pthread_rwlock_rdlock): Don't use non SH-3/4 instruction.
4090 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S:
4091 (__pthread_rwlock_wrlock): Likewise.
4092 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S:
4093 (pthread_rwlock_timedrdlock): Likewise.
4094 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S:
4095 (pthread_rwlock_timedwrlock): Likewise.
4096 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S:
4097 (__pthread_rwlock_unlock): Likewise.
4098
40992007-06-10 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4100
4101 * sysdeps/sh/tcb-offsets.sym: Add PRIVATE_FUTEX.
4102 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Include endian.h.
4103 Split __flags into __flags, __shared, __pad1 and __pad2.
4104 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Use private
b42a214c 4105 futexes if they are available.
339dbf0e 4106 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Adjust so that change
b42a214c 4107 in libc-lowlevellock.S allow using private futexes.
339dbf0e
UD
4108 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Define
4109 FUTEX_PRIVATE_FLAG. Add additional parameter to lll_futex_wait,
4110 lll_futex_timed_wait and lll_futex_wake. Change lll_futex_wait
4111 to call lll_futex_timed_wait. Add lll_private_futex_wait,
4112 lll_private_futex_timed_wait and lll_private_futex_wake.
4113 (lll_robust_mutex_unlock): Fix typo.
4114 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Use private
b42a214c 4115 field in futex command setup.
339dbf0e
UD
4116 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Use
4117 COND_NWAITERS_SHIFT instead of COND_CLOCK_BITS.
4118 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Likewise.
4119 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Use private futexes
b42a214c 4120 if they are available. Remove clear_once_control.
339dbf0e
UD
4121 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Use private
4122 futexes if they are available.
4123 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
4124 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
4125 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
4126 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
4127 * sysdeps/unix/sysv/linux/sh/sem_post.S: Add private futex support.
4128 Wake only when there are waiters.
4129 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Add private futex
4130 support. Indicate that there are waiters. Remove unnecessary
b42a214c 4131 extra cancellation test.
339dbf0e
UD
4132 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise. Removed
4133 left-over duplication of __sem_wait_cleanup.
4134
26f56c1c
UD
41352007-06-07 Ulrich Drepper <drepper@redhat.com>
4136
4137 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Add additional
4138 parameter to lll_futex_wait, lll_futex_timed_wait, and
4139 lll_futex_wake. Change lll_futex_wait to call lll_futex_timed_wait.
4140 Add lll_private_futex_wait, lll_private_futex_timed_wait, and
4141 lll_private_futex_wake.
4142 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
4143 * allocatestack.c: Adjust use of lll_futex_* macros.
4144 * init.c: Likewise.
4145 * lowlevellock.h: Likewise.
4146 * pthread_barrier_wait.c: Likewise.
4147 * pthread_cond_broadcast.c: Likewise.
4148 * pthread_cond_destroy.c: Likewise.
4149 * pthread_cond_signal.c: Likewise.
4150 * pthread_cond_timedwait.c: Likewise.
4151 * pthread_cond_wait.c: Likewise.
4152 * pthread_create.c: Likewise.
4153 * pthread_mutex_lock.c: Likewise.
4154 * pthread_mutex_setprioceiling.c: Likewise.
4155 * pthread_mutex_timedlock.c: Likewise.
4156 * pthread_mutex_unlock.c: Likewise.
4157 * pthread_rwlock_timedrdlock.c: Likewise.
4158 * pthread_rwlock_timedwrlock.c: Likewise.
4159 * pthread_rwlock_unlock.c: Likewise.
4160 * sysdeps/alpha/tls.h: Likewise.
4161 * sysdeps/i386/tls.h: Likewise.
4162 * sysdeps/ia64/tls.h: Likewise.
4163 * sysdeps/powerpc/tls.h: Likewise.
4164 * sysdeps/pthread/aio_misc.h: Likewise.
4165 * sysdeps/pthread/gai_misc.h: Likewise.
4166 * sysdeps/s390/tls.h: Likewise.
4167 * sysdeps/sh/tls.h: Likewise.
4168 * sysdeps/sparc/tls.h: Likewise.
4169 * sysdeps/unix/sysv/linux/fork.c: Likewise.
4170 * sysdeps/unix/sysv/linux/lowlevellock.c: Likewise.
4171 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c: Likewise.
4172 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: Likewise.
4173 * sysdeps/unix/sysv/linux/sem_post.c: Likewise.
4174 * sysdeps/unix/sysv/linux/sem_timedwait.c: Likewise.
4175 * sysdeps/unix/sysv/linux/sem_wait.c: Likewise.
4176 * sysdeps/unix/sysv/linux/unregister-atfork.c: Likewise.
4177 * sysdeps/unix/sysv/linux/sparc/pthread_once.c: Likewise.
4178 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_wait.c:
4179 Likewise.
4180 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_post.c: Likewise.
4181 * sysdeps/x86_64/tls.h: Likewise.
4182
ee5d5755
UD
41832007-05-29 Ulrich Drepper <drepper@redhat.com>
4184
b03b0c29
UD
4185 * pthread_getattr_np.c: No need to install a cancellation handler,
4186 this is no cancellation point.
4187 * pthread_getschedparam.c: Likewise.
4188 * pthread_setschedparam.c: Likewise.
4189 * pthread_setschedprio.c: Likewise.
4190 * sysdeps/unix/sysv/linux/lowlevellock.c: Remove all traces of
4191 lll_unlock_wake_cb.
4192 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
4193 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
4194 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
4195 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
4196 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
4197 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
4198 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
4199 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
4200 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
4201 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c: Likewise.
4202 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
4203 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
fc3f0ccb 4204
0154658d
UD
4205 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Checking
4206 whether there are more than one thread makes no sense here since
4207 we only call the slow path if the locks are taken.
4208 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Likewise.
4209
ee5d5755
UD
4210 * sysdeps/unix/sysv/linux/internaltypes.h: Introduce
4211 COND_NWAITERS_SHIFT.
4212 * pthread_cond_destroy.c: Use COND_NWAITERS_SHIFT instead of
4213 COND_CLOCK_BITS.
4214 * pthread_cond_init.c: Likewise.
4215 * pthread_cond_timedwait.c: Likewise.
4216 * pthread_cond_wait.c: Likewise.
4217 * pthread_condattr_getclock.c: Likewise.
4218 * pthread_condattr_setclock.c: Likewise.
4219 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Likewise.
4220 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
4221 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
4222 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
4223 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
4224
991fa82b
UD
42252007-05-28 Jakub Jelinek <jakub@redhat.com>
4226
40f57573
UD
4227 * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstacksize.c: Include
4228 unistd.h.
4229
991fa82b
UD
4230 * sysdeps/i386/tls.h (THREAD_GSCOPE_RESET_FLAG): Use explicit
4231 insn suffix.
4232 (THREAD_GSCOPE_GET_FLAG): Remove.
4233 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_GET_FLAG): Remove.
4234 * allocatestack.c (__wait_lookup_done): Revert 2007-05-24
4235 changes.
4236 * sysdeps/powerpc/tls.h (tcbhead_t): Remove gscope_flag.
4237 (THREAD_GSCOPE_GET_FLAG): Remove.
4238 (THREAD_GSCOPE_RESET_FLAG): Use THREAD_SELF->header.gscope_flag
4239 instead of THREAD_GSCOPE_GET_FLAG.
4240 (THREAD_GSCOPE_SET_FLAG): Likewise. Add atomic_write_barrier after
4241 it.
4242 * sysdeps/s390/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
4243 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
4244 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
4245 THREAD_GSCOPE_WAIT): Define.
4246 * sysdeps/sparc/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
4247 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
4248 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
4249 THREAD_GSCOPE_WAIT): Define.
4250 * sysdeps/sh/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
4251 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
4252 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
4253 THREAD_GSCOPE_WAIT): Define.
4254 * sysdeps/ia64/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
4255 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
4256 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
4257 THREAD_GSCOPE_WAIT): Define.
4258
42592007-05-24 Richard Henderson <rth@redhat.com>
4260
4261 * descr.h (struct pthread): Add header.gscope_flag.
4262 * sysdeps/alpha/tls.h (THREAD_GSCOPE_FLAG_UNUSED,
4263 THREAD_GSCOPE_FLAG_USED, THREAD_GSCOPE_FLAG_WAIT,
4264 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_SET_FLAG,
4265 THREAD_GSCOPE_WAIT): Define.
4266
e59660bc
UD
42672007-05-27 Ulrich Drepper <drepper@redhat.com>
4268
4269 * init.c: Make it compile with older kernel headers.
4270
4271 * tst-initializers1.c: Show through exit code which test failed.
4272
4273 * pthread_rwlock_init.c: Also initialize __shared field.
4274 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Split __flags
4275 element in rwlock structure into four byte elements. One of them is
4276 the new __shared element.
4277 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h [__WORDSIZE=32]:
4278 Likewise.
cd0dbd89 4279 [__WORDSIZE=64]: Renamed __pad1 element int rwlock structure to
e59660bc
UD
4280 __shared, adjust names of other padding elements.
4281 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
4282 * sysdeps/pthread/pthread.h: Adjust rwlock initializers.
4283 * sysdeps/unix/sysv/linux/lowlevelrwlock.sym: Add PSHARED.
4284 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define
4285 FUTEX_PRIVATE_FLAG.
4286 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Change main
4287 futex to use private operations if possible.
4288 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
4289 Likewise.
4290 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
4291 Likewise.
4292 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Likewise.
4293 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
50f1dec5
UD
4294 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
4295 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
4296 Likewise.
4297 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
4298 Likewise.
4299 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
4300 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
e59660bc 4301
d8ff3792
UD
43022007-05-26 Ulrich Drepper <drepper@redhat.com>
4303
546346b6
UD
4304 * pthreadP.h (PTHREAD_RWLOCK_PREFER_READER_P): Define.
4305 * pthread_rwlock_rdlock.c: Use PTHREAD_RWLOCK_PREFER_READER_P.
4306 * pthread_rwlock_timedrdlock.c: Likewise.
4307 * pthread_rwlock_tryrdlock.c: Likewise.
4308
a2dd3360
UD
4309 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S (sem_trywait): Tiny
4310 optimization.
4311
6df7ffad
UD
4312 * sysdeps/unix/sysv/linux/sem_wait.c: Add missing break.
4313 * sysdeps/unix/sysv/linux/sem_timedwait.c: Removed left-over
4314 duplication of __sem_wait_cleanup.
4315
4316 * allocatestack.c: Revert last change.
4317 * init.c: Likewise.
4318 * sysdeps/i386/tls.h: Likewise.
4319 * sysdeps/x86_64/tls.h: Likewise.
4320 * descr.h [TLS_DTV_AT_TP] (struct pthread): Add private_futex field to
4321 header structure.
4322 * sysdeps/powerpc/tcb-offsets.sym: Add PRIVATE_FUTEX_OFFSET.
4323
d8ff3792
UD
4324 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_barrier):
4325 Add private field.
4326 * sysdeps/unix/sysv/linux/lowlevelbarrier.sym: Add PRIVATE definition.
4327 * pthread_barrier_init.c: Set private flag if pshared and private
4328 futexes are supported.
4329 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Use
4330 private field in futex command setup.
4331 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise.
4332
3d2dd6ca
UD
43332007-05-25 Ulrich Drepper <drepper@redhat.com>
4334
42e6c665
UD
4335 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Add private futex
4336 support.
4337 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
4338 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
4339 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
4340 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
4341 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
4342
3d2dd6ca
UD
4343 * semaphoreP.h: Declare __old_sem_init and __old_sem_wait.
4344 * sem_init.c (__new_sem_init): Rewrite to initialize all three
4345 fields in the structure.
4346 (__old_sem_init): New function.
4347 * sem_open.c: Initialize all fields of the structure.
4348 * sem_getvalue.c: Adjust for renamed element.
4349 * sysdeps/unix/sysv/linux/Makefile [subdir=nptl]
4350 (gen-as-const-headers): Add structsem.sym.
4351 * sysdeps/unix/sysv/linux/structsem.sym: New file.
4352 * sysdeps/unix/sysv/linux/internaltypes.h: Rename struct sem to
4353 struct new_sem. Add struct old_sem.
4354 * sysdeps/unix/sysv/linux/sem_post.c: Wake only when there are waiters.
4355 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
4356 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
4357 * sysdeps/unix/sysv/linux/sem_wait.c: Indicate that there are waiters.
4358 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
4359 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
4360 * sysdeps/unix/sysv/linux/sem_timedwait.c: Likewise.
4361 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
4362 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
4363 * Makefile (tests): Add tst-sem10, tst-sem11, tst-sem12.
4364 * tst-sem10.c: New file.
4365 * tst-sem11.c: New file.
4366 * tst-sem12.c: New file.
4367 * tst-typesizes.c: Test struct new_sem and struct old_sem instead
4368 of struct sem.
4369
20a4d722
JJ
43702007-05-25 Ulrich Drepper <drepper@redhat.com>
4371 Jakub Jelinek <jakub@redhat.com>
4372
4373 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
4374 Move __pthread_enable_asynccancel right before futex syscall.
4375 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
4376 Likewise.
4377
43782007-05-24 Jakub Jelinek <jakub@redhat.com>
86acd596
UD
4379
4380 * sysdeps/i386/tls.h (THREAD_SET_PRIVATE_FUTEX,
4381 THREAD_COPY_PRIVATE_FUTEX): Define.
4382 * sysdeps/x86_64/tls.h (THREAD_SET_PRIVATE_FUTEX,
4383 THREAD_COPY_PRIVATE_FUTEX): Define.
4384 * allocatestack.c (allocate_stack): Use THREAD_COPY_PRIVATE_FUTEX.
4385 * init.c (__pthread_initialize_minimal_internal): Use
4386 THREAD_SET_PRIVATE_FUTEX.
0a54ab53
UD
4387
4388 * sysdeps/powerpc/tls.h (tcbhead_t): Add gscope_flag.
4389 (THREAD_GSCOPE_FLAG_UNUSED, THREAD_GSCOPE_FLAG_USED,
4390 THREAD_GSCOPE_FLAG_WAIT): Define.
4391 (THREAD_GSCOPE_GET_FLAG, THREAD_GSCOPE_SET_FLAG,
4392 THREAD_GSCOPE_RESET_FLAG, THREAD_GSCOPE_WAIT): Define.
4393 * sysdeps/i386/tls.h (THREAD_GSCOPE_WAIT): Don't use
4394 PTR_DEMANGLE.
4395 (THREAD_GSCOPE_GET_FLAG): Define.
4396 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_GET_FLAG): Define.
4397 * allocatestack.c (__wait_lookup_done): Use THREAD_GSCOPE_GET_FLAG
4398 instead of ->header.gscope_flag directly.
4399
5a8075b1
UD
44002007-05-23 Ulrich Drepper <drepper@redhat.com>
4401
4402 * init.c (__pthread_initialize_minimal_internal): Check whether
4403 private futexes are available.
4404 * allocatestack.c (allocate_stack): Copy private_futex field from
4405 current thread into the new stack.
4406 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: Use private
4407 futexes if they are available.
4408 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise
4409 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Adjust so that change
4410 in libc-lowlevellock.S allow using private futexes.
4411 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
4412 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Define
4413 FUTEX_PRIVATE_FLAG.
4414 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Likewise.
4415 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Use private futexes
4416 if they are available.
4417 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
4418 * sysdeps/x86_64/tcb-offsets.sym: Add PRIVATE_FUTEX.
4419 * sysdeps/i386/tcb-offsets.sym: Likewise.
4420 * sysdeps/x86_64/tls.h (tcbhead_t): Add private_futex field.
4421 * sysdeps/i386/tls.h (tcbhead_t): Likewise.
4422
6d59823c
UD
44232007-05-21 Ulrich Drepper <drepper@redhat.com>
4424
4425 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
4426 Remove ptr_wait_lookup_done again.
4427 * init.c (pthread_functions): Don't add .ptr_wait_lookup_done here.
4428 (__pthread_initialize_minimal_internal): Initialize
4429 _dl_wait_lookup_done pointer in _rtld_global directly.
4430 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
4431 Remove code to code _dl_wait_lookup_done.
4432 * sysdeps/x86_64/tls.h (THREAD_GSCOPE_WAIT): The pointer is not
4433 encrypted for now.
4434
2c9718f3
JJ
44352007-05-21 Jakub Jelinek <jakub@redhat.com>
4436
4437 * tst-robust9.c (do_test): Don't fail if ENABLE_PI and
4438 pthread_mutex_init failed with ENOTSUP.
4439
df94b641
UD
44402007-05-19 Ulrich Drepper <drepper@redhat.com>
4441
4442 * allocatestack.c (__wait_lookup_done): New function.
4443 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
4444 Add ptr_wait_lookup_done.
4445 * init.c (pthread_functions): Initialize .ptr_wait_lookup_done.
4446 * pthreadP.h: Declare __wait_lookup_done.
4447 * sysdeps/i386/tls.h (tcbhead_t): Add gscope_flag.
4448 Define macros to implement reference handling of global scope.
4449 * sysdeps/x86_64/tls.h: Likewise.
4450 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
4451 Initialize GL(dl_wait_lookup_done).
4452
bec51a30
UD
44532007-05-17 Ulrich Drepper <drepper@redhat.com>
4454
113ad5fc
UD
4455 [BZ #4512]
4456 * pthread_mutex_lock.c: Preserve FUTEX_WAITERS bit when dead owner
4457 is detected.
4458 * pthread_mutex_timedlock.c: Likewise.
4459 * pthread_mutex_trylock.c: Likewise.
4460 Patch in part by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
4461
4462 * Makefile (tests): Add tst-robust9 and tst-robustpi9.
4463 * tst-robust9.c: New file.
4464 * tst-robustpi9.c: New file.
4465
bec51a30
UD
4466 * sysdeps/unix/sysv/linux/sem_wait.c (__new_sem_wait): Remove
4467 unnecessary extra cancellation test.
4468
83d87915
UD
44692007-05-14 Ulrich Drepper <drepper@redhat.com>
4470
83d87915
UD
4471 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Remove unnecessary
4472 extra cancellation test.
4473 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
4474
3771196d
UD
44752007-05-10 Ulrich Drepper <drepper@redhat.com>
4476
341c566f
UD
4477 * descr.h (struct pthread): Rearrange members to fill hole in
4478 64-bit layout.
4479
3771196d
UD
4480 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
4481 (__pthread_setaffinity_new): If syscall was successful and
4482 RESET_VGETCPU_CACHE is defined, use it before returning.
4483 * sysdeps/unix/sysv/linux/x86_64/pthread_setaffinity.c: New file.
4484
7d29b542
JJ
44852007-05-10 Jakub Jelinek <jakub@redhat.com>
4486
4487 [BZ #4455]
4488 * tst-align2.c: Include stackinfo.h.
4489 * tst-getpid1.c: Likewise.
4490
16105fe0
UD
44912007-05-02 Carlos O'Donell <carlos@systemhalted.org>
4492
29c113f0
UD
4493 [BZ #4455]
4494 * tst-align2.c (do_test): Add _STACK_GROWS_UP case.
4495 * tst-getpid1.c (do_test): Likewise.
4496
16105fe0
UD
4497 [BZ #4456]
4498 * allocatestack.c (change_stack_perm): Add _STACK_GROWS_UP case.
4499 (allocate_stack): Likewise.
4500
6780bc44
UD
45012007-05-07 Ulrich Drepper <drepper@redhat.com>
4502
4503 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
4504 (__lll_robust_lock_wait): Fix race caused by reloading of futex value.
4505 (__lll_robust_timedlock_wait): Likewise.
4506 Reported by Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>.
4507
aa75f64c
UD
45082007-05-06 Mike Frysinger <vapier@gentoo.org>
4509
15eca720 4510 [BZ #4465]
aa75f64c
UD
4511 * tst-cancel-wrappers.sh: Set C["fdatasync"] to 1.
4512 * tst-cancel4.c (tf_fdatasync): New test.
4513
f672076e
UD
45142007-04-27 Ulrich Drepper <drepper@redhat.com>
4515
1bb5f5a1
UD
4516 [BZ #4392]
4517 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Treat error
4518 check mutexes like normal mutexes.
4519
f672076e
UD
4520 [BZ #4306]
4521 * sysdeps/unix/sysv/linux/timer_create.c (timer_create):
4522 Initialize the whole sigevent structure to appease valgrind.
4523
bce20b9a
UD
45242007-04-25 Ulrich Drepper <drepper@redhat.com>
4525
4526 * sysdeps/x86_64/tls.h (tcbhead_t): Add vgetcpu_cache.
4527 * sysdeps/x86_64/tcb-offsets.sym: Add VGETCPU_CACHE_OFFSET.
4528
0c786eac
UD
45292007-04-06 Ulrich Drepper <drepper@redhat.com>
4530
4531 * tst-locale1.c: Avoid warnings.
4532 * tst-locale2.c: Likewise.
4533
e1f0c5bc
UD
45342007-03-19 Steven Munroe <sjmunroe@us.ibm.com>
4535
4536 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
4537 (__lll_robust_trylock): Add MUTEX_HINT_ACQ to lwarx instruction.
4538
965cba04
UD
45392007-03-16 Jakub Jelinek <jakub@redhat.com>
4540
4541 * sysdeps/pthread/bits/libc-lock.h: Use __extern_inline and
4542 __extern_always_inline where appropriate.
4543 * sysdeps/pthread/pthread.h: Likewise.
4544
a5ea509b
RH
45452007-03-13 Richard Henderson <rth@redhat.com>
4546
4547 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (PSEUDO): Use two
4548 separate cfi regions for the two subsections.
4549
00a1430e
UD
45502007-02-25 Ulrich Drepper <drepper@redhat.com>
4551
4552 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Reset refcntr in
4553 new thread, don't just decrement it.
4554 Patch by Suzuki K P <suzuki@in.ibm.com>.
4555
63a2f305
UD
45562007-02-21 Ulrich Drepper <drepper@redhat.com>
4557
4558 * sysdeps/pthread/pthread-functions.h: Correct last patch, correct
4559 PTHFCT_CALL definition.
4560
2484468b
UD
45612007-02-18 Ulrich Drepper <drepper@redhat.com>
4562
4563 * sysdeps/pthread/pthread-functions.h: If PTR_DEMANGLE is not
4564 available, don't use it.
4565
5ed61e0f
UD
45662007-02-09 Jakub Jelinek <jakub@redhat.com>
4567
4568 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
4569 (__lll_mutex_timedlock_wait): Use correct pointer when we don't
4570 call into the kernel to delay.
4571
10ccaa5c
UD
45722007-01-18 Ulrich Drepper <drepper@redhat.com>
4573
f8a17855
UD
4574 * tst-initializers1.c: We want to test the initializers as seen
4575 outside of libc, so undefined _LIBC.
4576
10ccaa5c
UD
4577 * pthread_join.c (cleanup): Avoid warning.
4578
ea1533e0
UD
45792007-01-17 Ulrich Drepper <drepper@redhat.com>
4580
1476bce6
UD
4581 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
4582 (__lll_timedwait_tid): Add unwind info.
4583
ea1533e0
UD
4584 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Don't just copy the
4585 function table, mangle the pointers.
4586 * sysdeps/pthread/pthread-functions.h: Define PTHFCT_CALL.
4587 * forward.c: Use PTHFCT_CALL and __libc_pthread_functions_init.
4588 * sysdeps/pthread/bits/libc-lock.h: When using __libc_pthread_functions
4589 demangle pointers before use.
4590 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Use PTHFCT_CALL to
4591 demangle pointer.
4592 * sysdeps/unix/sysv/linux/jmp-unwind.c: Likewise.
4593 * sysdeps/pthread/setxid.h: Likewise.
4594
8980796b
UD
45952007-01-12 Ulrich Drepper <drepper@redhat.com>
4596
4597 * tst-rwlock7.c: Show some more information in case of correct
4598 behavior.
4599
a1d87b5d
UD
46002007-01-11 Ulrich Drepper <drepper@redhat.com>
4601
4602 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
4603 (lll_futex_timed_wait): Undo part of last change, don't negate
4604 return value.
4605
11bf311e 46062007-01-10 Ulrich Drepper <drepper@redhat.com>
66193697 4607
11bf311e
UD
4608 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Cleanups. Define
4609 FUTEX_CMP_REQUEUE and lll_futex_requeue.
66193697 4610
11bf311e 46112006-12-28 David S. Miller <davem@davemloft.net>
14a31e35 4612
11bf311e 4613 * shlib-versions: Fix sparc64 linux target specification.
a744da90 4614
11bf311e 46152007-01-10 Jakub Jelinek <jakub@redhat.com>
a744da90 4616
11bf311e
UD
4617 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
4618 Adjust include path for pthread_barrier_wait.c move.
fc242bef 4619
11bf311e 46202006-12-21 Jakub Jelinek <jakub@redhat.com>
fc242bef 4621
11bf311e
UD
4622 * sysdeps/unix/sysv/linux/pthread_kill.c (pthread_kill): Make sure
4623 tid isn't reread from pd->tid in between ESRCH test and the syscall.
a822d9f4 4624
11bf311e
UD
46252006-12-06 Jakub Jelinek <jakub@redhat.com>
4626
4627 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO): Handle
4628 6 argument cancellable syscalls.
4629 (STM_6, LM_6, LR7_0, LR7_1, LR7_2, LR7_3, LR7_4, LR7_5, LR7_6): Define.
4630 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO): Handle
4631 6 argument cancellable syscalls.
4632 (STM_6, LM_6, LR7_0, LR7_1, LR7_2, LR7_3, LR7_4, LR7_5, LR7_6): Define.
a822d9f4 4633
66f17705
UD
46342006-12-09 Ulrich Drepper <drepper@redhat.com>
4635
4636 * sysdeps/unix/sysv/linux/rtld-lowlevel.h
4637 (__rtld_mrlock_initialize): Add missing closing parenthesis.
4638
11bf311e
UD
46392006-10-30 Jakub Jelinek <jakub@redhat.com>
4640
4641 * sysdeps/ia64/pthread_spin_unlock.c (pthread_spin_unlock): Use
4642 __sync_lock_release instead of __sync_lock_release_si.
4643
536e40e2
UD
46442006-10-29 Jakub Jelinek <jakub@redhat.com>
4645
4646 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (RTLD_SINGLE_THREAD_P):
4647 Define.
4648 (SINGLE_THREAD_P): Define to 1 if IS_IN_rtld.
4649 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Likewise.
4650 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
4651 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
4652 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
4653 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
4654 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
4655 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
4656 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
4657 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
4658 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
4659
11bf311e
UD
46602006-10-27 Ulrich Drepper <drepper@redhat.com>
4661
4662 * sysdeps/pthread/pthread_barrier_wait.c: Move to...
4663 * pthread_barrier_wait.c: ...here.
4664 * sysdeps/pthread/pthread_cond_broadcast.c: Move to...
4665 * pthread_cond_broadcast.c: ...here.
4666 * sysdeps/pthread/pthread_cond_signal.c: Move to...
4667 * pthread_cond_signal.c: ...here.
4668 * sysdeps/pthread/pthread_cond_timedwait.c: Move to...
4669 * pthread_cond_timedwait.c: ...here.
4670 * sysdeps/pthread/pthread_cond_wait.c: Move to...
4671 * pthread_cond_wait.c: ...here.
4672 * sysdeps/pthread/pthread_once.c: Move to...
4673 * pthread_once.c: ...here.
4674 * sysdeps/pthread/pthread_rwlock_rdlock.c: Move to...
4675 * pthread_rwlock_rdlock.c: ...here.
4676 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Move to...
4677 * pthread_rwlock_timedrdlock.c: ...here.
4678 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Move to...
4679 * pthread_rwlock_timedwrlock.c: ...here.
4680 * sysdeps/pthread/pthread_rwlock_unlock.c: Move to...
4681 * pthread_rwlock_unlock.c: ...here.
4682 * sysdeps/pthread/pthread_rwlock_wrlock.c: Move to...
4683 * pthread_rwlock_wrlock.c: ...here.
4684 * sysdeps/pthread/pthread_spin_destroy.c: Move to...
4685 * pthread_spin_destroy.c: ...here.
4686 * sysdeps/pthread/pthread_spin_init.c: Move to...
4687 * pthread_spin_init.c: ...here.
4688 * sysdeps/pthread/pthread_spin_unlock.c: Move to...
4689 * pthread_spin_unlock.c: ...here.
4690 * sysdeps/pthread/pthread_getcpuclockid.c: Move to...
4691 * pthread_getcpuclockid.c: ...here.
4692
4693 * init.c: USE_TLS support is now always enabled.
4694 * tst-tls5.h: Likewise.
4695 * sysdeps/alpha/tls.h: Likewise.
4696 * sysdeps/i386/tls.h: Likewise.
4697 * sysdeps/ia64/tls.h: Likewise.
4698 * sysdeps/powerpc/tls.h: Likewise.
4699 * sysdeps/s390/tls.h: Likewise.
4700 * sysdeps/sh/tls.h: Likewise.
4701 * sysdeps/sparc/tls.h: Likewise.
4702 * sysdeps/x86_64/tls.h: Likewise.
4703
006a8f6f 47042006-10-27 Jakub Jelinek <jakub@redhat.com>
c0a777e8
UD
4705
4706 * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_mrlock_lock,
4707 __rtld_mrlock_change): Update oldval if atomic compare and exchange
4708 failed.
4709
4710 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
4711 Define to THREAD_SELF->header.multiple_threads.
4712 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SINGLE_THREAD_P):
4713 Likewise.
4714 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (SINGLE_THREAD_P):
4715 Likewise.
4716 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
4717 (SINGLE_THREAD_P): Likewise.
4718 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
4719 (SINGLE_THREAD_P): Likewise.
4720 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
4721 (SINGLE_THREAD_P): Likewise.
4722 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
4723 (SINGLE_THREAD_P): Likewise.
4724 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (SINGLE_THREAD_P):
4725 Likewise.
4726 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
4727 (SINGLE_THREAD_P): Likewise.
4728 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
4729 (SINGLE_THREAD_P): Likewise.
4730 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (SINGLE_THREAD_P):
4731 Likewise.
4732
11bf311e 47332006-10-26 Jakub Jelinek <jakub@redhat.com>
32c075e1 4734
11bf311e
UD
4735 * pthread_attr_setstacksize.c (NEW_VERNUM): Define to GLIBC_2_3_3
4736 by default rather than 2_3_3.
32c075e1 4737
11bf311e 47382006-10-17 Jakub Jelinek <jakub@redhat.com>
32c075e1 4739
11bf311e
UD
4740 * sysdeps/unix/sysv/linux/rtld-lowlevel.h (__rtld_mrlock_lock,
4741 __rtld_mrlock_unlock, __rtld_mrlock_change, __rtld_mrlock_done): Use
4742 atomic_* instead of catomic_* macros.
4743
47442006-10-12 Ulrich Drepper <drepper@redhat.com>
4745
4746 [BZ #3285]
4747 * sysdeps/unix/sysv/linux/bits/local_lim.h: Add SEM_VALUE_MAX.
4748 * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: Likewise.
4749 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
4750 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
4751 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
4752 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h: Remove SEM_VALUE_MAX.
4753 * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: Likewise.
4754 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
4755 * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: Likewise.
4756 * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h: Likewise.
4757 * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: Likewise.
4758 * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: Likewise.
4759 * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: Likewise.
4760
47612006-10-11 Ulrich Drepper <drepper@redhat.com>
4762
4763 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Add support for
4764 cancelable syscalls with six parameters.
4765
4766 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: Use catomic_*
4767 operations instead of atomic_*.
32c075e1 4768
11bf311e 47692006-10-09 Ulrich Drepper <drepper@redhat.com>
32c075e1 4770
11bf311e 4771 * sysdeps/unix/sysv/linux/rtld-lowlevel.h: New file..
32c075e1 4772
11bf311e 47732006-10-07 Ulrich Drepper <drepper@redhat.com>
32c075e1 4774
11bf311e
UD
4775 * sysdeps/unix/sysv/linux/powerpc/bits/local_lim.h: New file.
4776 * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstack.c: New file.
4777 * sysdeps/unix/sysv/linux/powerpc/pthread_attr_setstacksize.c:
4778 New file.
4779 * pthread_attr_setstack.c: Allow overwriting the version number of the
4780 new symbol.
4781 * pthread_attr_setstacksize.c: Likewise.
4782 (__old_pthread_attr_setstacksize): If STACKSIZE_ADJUST is defined use
4783 it.
4784 * sysdeps/unix/sysv/linux/powerpc/Versions (libpthread): Add
4785 pthread_attr_setstack and pthread_attr_setstacksize to GLIBC_2.6.
fa279678 4786
457b559e
UD
47872006-09-24 Ulrich Drepper <drepper@redhat.com>
4788
4789 [BZ #3251]
4790 * descr.h (ENQUEUE_MUTEX_BOTH): Add cast to avoid warning.
4791 Patch by Petr Baudis.
4792
0466106e
UD
47932006-09-18 Jakub Jelinek <jakub@redhat.com>
4794
4795 * tst-kill4.c (do_test): Explicitly set tf thread's stack size.
4796
4797 * tst-cancel2.c (tf): Loop as long as something was written.
4798
bd6d3b7d
UD
47992006-09-12 Kaz Kojima <kkojima@rr.iij4u.or.jp>
4800
4801 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: For PI
4802 mutexes wake all mutexes.
4803 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Don't increment
4804 WAKEUP_SEQ if this would increase the value beyond TOTAL_SEQ.
4805 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
4806
30aa5785
UD
48072006-09-12 Ulrich Drepper <drepper@redhat.com>
4808
4809 * tst-cond22.c (tf): Slight changes to the pthread_cond_wait use
4810 to guarantee the thread is always canceled.
4811
2b6a801e
UD
48122006-09-08 Jakub Jelinek <jakub@redhat.com>
4813
4814 * tst-cond22.c: Include pthread.h instead of pthreadP.h.
4815 Include stdlib.h.
4816 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Only
4817 increase FUTEX if increasing WAKEUP_SEQ. Fix comment typo.
4818 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
4819 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
4820 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
bd6d3b7d 4821
346e6ad4
UD
48222006-09-08 Ulrich Drepper <drepper@redhat.com>
4823
4824 [BZ #3123]
4825 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Don't
4826 increment WAKEUP_SEQ if this would increase the value beyond TOTAL_SEQ.
2b6a801e
UD
4827 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
4828 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
4829 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
346e6ad4
UD
4830 * Makefile (tests): Add tst-cond22.
4831 * tst-cond22.c: New file.
4832
b051fc44
UD
48332006-09-05 Ulrich Drepper <drepper@redhat.com>
4834
4835 [BZ #3124]
4836 * descr.h (struct pthread): Add parent_cancelhandling.
4837 * sysdeps/pthread/createthread.c (create_thread): Pass parent
4838 cancelhandling value to child.
4839 * pthread_create.c (start_thread): If parent thread was canceled
4840 reset the SIGCANCEL mask.
4841 * Makefile (tests): Add tst-cancel25.
4842 * tst-cancel25.c: New file.
4843
d052233c 48442006-09-05 Jakub Jelinek <jakub@redhat.com>
b42a214c 4845 Ulrich Drepper <drepper@redhat.com>
d052233c
UD
4846
4847 * sysdeps/pthread/gai_misc.h (GAI_MISC_NOTIFY): Don't decrement
4848 counterp if it is already zero.
4849 * sysdeps/pthread/aio_misc.h (AIO_MISC_NOTIFY): Likewise..
4850
cd248c3f 48512006-03-04 Jakub Jelinek <jakub@redhat.com>
b42a214c 4852 Roland McGrath <roland@redhat.com>
cd248c3f
UD
4853
4854 * sysdeps/unix/sysv/linux/i386/lowlevellock.h
4855 (LLL_STUB_UNWIND_INFO_START, LLL_STUB_UNWIND_INFO_END,
4856 LLL_STUB_UNWIND_INFO_3, LLL_STUB_UNWIND_INFO_4): Define.
4857 (lll_mutex_lock, lll_robust_mutex_lock, lll_mutex_cond_lock,
4858 lll_robust_mutex_cond_lock, lll_mutex_timedlock,
4859 lll_robust_mutex_timedlock, lll_mutex_unlock,
4860 lll_robust_mutex_unlock, lll_lock, lll_unlock): Use them.
4861 Add _L_*_ symbols around the subsection.
4862 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Add unwind info.
4863 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: Likewise.
4864
48652006-03-03 Jakub Jelinek <jakub@redhat.com>
b42a214c 4866 Roland McGrath <roland@redhat.com>
cd248c3f
UD
4867
4868 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
4869 (LLL_STUB_UNWIND_INFO_START, LLL_STUB_UNWIND_INFO_END,
4870 LLL_STUB_UNWIND_INFO_5, LLL_STUB_UNWIND_INFO_6): Define.
4871 (lll_mutex_lock, lll_robust_mutex_lock, lll_mutex_cond_lock,
4872 lll_robust_mutex_cond_lock, lll_mutex_timedlock,
4873 lll_robust_mutex_timedlock, lll_mutex_unlock,
4874 lll_robust_mutex_unlock, lll_lock, lll_unlock): Use them.
4875 Add _L_*_ symbols around the subsection.
4876 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Add unwind info.
4877 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: Likewise.
4878
b80770b2
UD
48792006-08-31 Ulrich Drepper <drepper@redhat.com>
4880
4881 * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Undo last
4882 change because it can disturb too much existing code. If real hard
4883 reader preference is needed we'll introduce another type.
4884 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
4885 (pthread_rwlock_timedwrlock): Likewise.
4886 * sysdeps/pthread/pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock):
4887 Likewise.
4888
bee2df0b
UD
48892006-08-30 Ulrich Drepper <drepper@redhat.com>
4890
4891 * pthread_rwlock_trywrlock.c (__pthread_rwlock_trywrlock): Respect
4892 reader preference.
4893 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
4894 (pthread_rwlock_timedwrlock): Likewise.
4895 * sysdeps/pthread/pthread_rwlock_wrlock.c (__pthread_rwlock_wrlock):
4896 Likewise.
4897
d678ebc1
UD
48982006-08-25 Jakub Jelinek <jakub@redhat.com>
4899
4900 * sysdeps/unix/sysv/linux/libc_pthread_init.c (freeres_libpthread):
4901 Only define ifdef SHARED.
4902
ba408f84
UD
49032006-08-23 Ulrich Drepper <drepper@redhat.com>
4904
4905 * allocatestack.c (queue_stack): Move freeing of surplus stacks to...
4906 (free_stacks): ...here.
4907 (__free_stack_cache): New function.
4908 * pthreadP.h: Declare __free_stack_cache.
4909 * sysdeps/pthread/pthread-functions.h (pthread_functions): Add
4910 ptr_freeres.
4911 * init.c (pthread_functions): Initialize ptr_freeres.
4912 * sysdeps/unix/sysv/linux/libc_pthread_init.c (freeres_libptread):
4913 New freeres function.
4914
376e973a
UD
49152006-07-30 Joseph S. Myers <joseph@codesourcery.com>
4916
4917 [BZ #3018]
4918 * Makefile (extra-objs): Add modules to extra-test-objs instead.
4919
2b34af01
UD
49202006-08-20 Ulrich Drepper <drepper@redhat.com>
4921
4922 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
4923 _XOPEN_REALTIME_THREADS.
4924
89c85f87
UD
49252006-08-15 Jakub Jelinek <jakub@redhat.com>
4926
4927 * sysdeps/unix/sysv/linux/clock_settime.c (INTERNAL_VSYSCALL): Use
4928 HAVE_CLOCK_GETRES_VSYSCALL as guard macro rather than
4929 HAVE_CLOCK_GETTIME_VSYSCALL.
4930 (maybe_syscall_settime_cpu): Use plain INTERNAL_VSYSCALL here.
4931
f17efcb4
UD
49322006-08-14 Jakub Jelinek <jakub@redhat.com>
4933
4934 * sysdeps/unix/sysv/linux/bits/posix_opt.h
4935 (_POSIX_THREAD_PRIO_PROTECT): Define to 200112L.
4936 * descr.h (struct priority_protection_data): New type.
4937 (struct pthread): Add tpp field.
4938 * pthreadP.h (PTHREAD_MUTEX_PP_NORMAL_NP,
4939 PTHREAD_MUTEX_PP_RECURSIVE_NP, PTHREAD_MUTEX_PP_ERRORCHECK_NP,
4940 PTHREAD_MUTEX_PP_ADAPTIVE_NP): New enum values.
4941 * pthread_mutex_init.c (__pthread_mutex_init): Handle non-robust
4942 TPP mutexes.
4943 * pthread_mutex_lock.c (__pthread_mutex_lock): Handle TPP mutexes.
4944 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Likewise.
4945 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Likewise.
4946 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Likewise.
4947 * tpp.c: New file.
4948 * pthread_setschedparam.c (__pthread_setschedparam): Handle priority
4949 boosted by TPP.
4950 * pthread_setschedprio.c (pthread_setschedprio): Likewise.
4951 * pthread_mutexattr_getprioceiling.c
4952 (pthread_mutexattr_getprioceiling): If ceiling is 0, ensure it is
4953 in the SCHED_FIFO priority range.
4954 * pthread_mutexattr_setprioceiling.c
4955 (pthread_mutexattr_setprioceiling): Fix prioceiling validation.
4956 * pthread_mutex_getprioceiling.c (pthread_mutex_getprioceiling): Fail
4957 if mutex is not TPP. Ceiling is now in __data.__lock.
4958 * pthread_mutex_setprioceiling.c: Include stdbool.h.
4959 (pthread_mutex_setprioceiling): Fix prioceiling validation. Ceiling
4960 is now in __data.__lock. Add locking.
4961 * pthread_create.c (__free_tcb): Free pd->tpp structure.
4962 * Makefile (libpthread-routines): Add tpp.
4963 (xtests): Add tst-mutexpp1, tst-mutexpp6 and tst-mutexpp10.
4964 * tst-tpp.h: New file.
4965 * tst-mutexpp1.c: New file.
4966 * tst-mutexpp6.c: New file.
4967 * tst-mutexpp10.c: New file.
4968 * tst-mutex1.c (TEST_FUNCTION): Don't redefine if already defined.
4969 * tst-mutex6.c (TEST_FUNCTION): Likewise.
4970
22bb134c
UD
49712006-08-12 Ulrich Drepper <drepper@redhat.com>
4972
4973 [BZ #2843]
4974 * pthread_join.c (pthread_join): Account for self being canceled
4975 when checking for deadlocks.
4976 * tst-join5.c: Cleanups. Allow to be used in tst-join6.
4977 (tf1): Don't print anything after pthread_join returns, this would be
4978 another cancellation point.
4979 (tf2): Likewise.
4980 * tst-join6.c: New file.
4981 * Makefile (tests): Add tst-join6.
4982
f1762c0c
UD
49832006-08-03 Ulrich Drepper <drepper@redhat.com>
4984
9c06eb66
UD
4985 [BZ #2892]
4986 * pthread_setspecific.c (__pthread_setspecific): Check
4987 out-of-range index before checking for unused key.
4988
f1762c0c
UD
4989 * sysdeps/pthread/gai_misc.h: New file.
4990
7bb1b2c9
UD
49912006-08-01 Ulrich Drepper <drepper@redhat.com>
4992
4993 * sysdeps/unix/sysv/linux/i386/smp.h: New file. Old Linux-specific
4994 file. Don't use sysctl.
4995 * sysdeps/unix/sysv/linux/smp.h: Always assume SMP. Archs can
4996 overwrite the file if this is likely not true.
4997
b06e7e9a
UD
49982006-07-31 Daniel Jacobowitz <dan@codesourcery.com>
4999
5000 * allocatestack.c (__reclaim_stacks): Reset the PID on cached stacks.
5001 * Makefile (tests): Add tst-getpid3.
5002 * tst-getpid3.c: New file.
5003
b894c2ea
RM
50042006-07-30 Roland McGrath <roland@redhat.com>
5005
5006 * Makefile (libpthread-routines): Add ptw-sigsuspend.
5007
5008 * sysdeps/unix/sysv/linux/i386/not-cancel.h
5009 (pause_not_cancel): New macro.
5010 (nanosleep_not_cancel): New macro.
5011 (sigsuspend_not_cancel): New macro.
5012 * pthread_mutex_timedlock.c (pthread_mutex_timedlock): Use
5013 nanosleep_not_cancel macro from <not-cancel.h>.
5014 * pthread_mutex_lock.c (__pthread_mutex_lock): Use pause_not_cancel
5015 macro from <not-cancel.h>.
5016
df47504c
UD
50172006-07-28 Ulrich Drepper <drepper@redhat.com>
5018 Jakub Jelinek <jakub@redhat.com>
5019
5020 * descr.h: Change ENQUEUE_MUTEX and DEQUEUE_MUTEX for bit 0
5021 notification of PI mutex. Add ENQUEUE_MUTEX_PI.
5022 * pthreadP.h: Define PTHREAD_MUTEX_PI_* macros for PI mutex types.
5023 * pthread_mutex_setprioceilining.c: Adjust for mutex type name change.
5024 * pthread_mutex_init.c: Add support for priority inheritance mutex.
5025 * pthread_mutex_lock.c: Likewise.
5026 * pthread_mutex_timedlock.c: Likewise.
5027 * pthread_mutex_trylock.c: Likewise.
5028 * pthread_mutex_unlock.c: Likewise.
5029 * sysdeps/pthread/pthread_cond_broadcast.c: For PI mutexes wake
5030 all mutexes.
5031 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.c: Likewise.
5032 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.c: Likewise.
5033 * sysdeps/unix/sysv/linux/pthread-pi-defines.sym: New file.
5034 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-header): Add
5035 pthread-pi-defines.sym.
5036 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define FUTEX_LOCK_PI,
5037 FUTEX_UNLOCK_PI, and FUTEX_TRYLOCK_PI.
5038 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
d5ba53f9
UD
5039 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Likewise.
5040 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
5041 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
5042 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
5043 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
5044 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
df47504c
UD
5045 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
5046 _POSIX_THREAD_PRIO_INHERIT to 200112L.
5047 * tst-mutex1.c: Adjust to allow use in PI mutex test.
5048 * tst-mutex2.c: Likewise.
5049 * tst-mutex3.c: Likewise.
5050 * tst-mutex4.c: Likewise.
5051 * tst-mutex5.c: Likewise.
5052 * tst-mutex6.c: Likewise.
5053 * tst-mutex7.c: Likewise.
5054 * tst-mutex7a.c: Likewise.
5055 * tst-mutex8.c: Likewise.
5056 * tst-mutex9.c: Likewise.
5057 * tst-robust1.c: Likewise.
5058 * tst-robust7.c: Likewise.
5059 * tst-robust8.c: Likewise.
5060 * tst-mutexpi1.c: New file.
5061 * tst-mutexpi2.c: New file.
5062 * tst-mutexpi3.c: New file.
5063 * tst-mutexpi4.c: New file.
5064 * tst-mutexpi5.c: New file.
5065 * tst-mutexpi6.c: New file.
5066 * tst-mutexpi7.c: New file.
5067 * tst-mutexpi7a.c: New file.
5068 * tst-mutexpi8.c: New file.
5069 * tst-mutexpi9.c: New file.
5070 * tst-robust1.c: New file.
5071 * tst-robust2.c: New file.
5072 * tst-robust3.c: New file.
5073 * tst-robust4.c: New file.
5074 * tst-robust5.c: New file.
5075 * tst-robust6.c: New file.
5076 * tst-robust7.c: New file.
5077 * tst-robust8.c: New file.
5078 * Makefile (tests): Add the new tests.
5079
5080 * pthread_create.c (start_thread): Add some casts to avoid warnings.
5081 * pthread_mutex_destroy.c: Remove unneeded label.
5082
f3be81a9
UD
50832006-07-01 Ulrich Drepper <drepper@redhat.com>
5084
5085 * pthread_mutex_init.c (__pthread_mutex_init): Move some
5086 computations to compile time.
5087
c26ca5e1
UD
50882006-06-04 Ulrich Drepper <drepper@redhat.com>
5089
5090 * sysdeps/pthread/pthread.h: Add pthread_equal inline version.
5091
6f8a7dff
UD
50922006-05-15 Ulrich Drepper <drepper@redhat.com>
5093
c26ca5e1 5094 * sysdeps/unix/sysv/linux/fork.h: Mark __fork_handlers as hidden.
6f8a7dff 5095
3d237e42
UD
50962006-05-11 Ulrich Drepper <drepper@redhat.com>
5097
04974d63
UD
5098 * pthread_key_create.c (__pthread_key_create): Do away with
5099 __pthread_keys_lock.
5100
5101 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
5102 (__kernel_cpumask_size): Mark as hidden.
5103 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: Likewise.
5104
3d237e42
UD
5105 * sem_open.c (__sem_mappings_lock): Mark as hidden.
5106 * semaphoreP.h (__sem_mappings_lock): Likewise.
5107
790fc6e4
UD
51082006-05-10 Ulrich Drepper <drepper@redhat.com>
5109
5110 * pthread_atfork.c: Mark __dso_handle as hidden.
5111
be434a72
UD
51122006-05-09 Ulrich Drepper <drepper@redhat.com>
5113
5114 [BZ #2644]
5115 * sysdeps/pthread/unwind-forcedunwind.c: Different solution for
5116 the reload problem. Change the one path in pthread_cancel_init
5117 which causes the problem. Force gcc to reload. Simplify callers.
5118 * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c
5119 (_Unwind_GetBSP): Undo last patch.
5120
3142b1ac
UD
51212006-05-07 Ulrich Drepper <drepper@redhat.com>
5122
bf3635d3
UD
5123 * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c: Make sure the
5124 function pointer is reloaded after pthread_cancel_init calls.
3142b1ac
UD
5125
5126 [BZ #2644]
5127 * sysdeps/pthread/unwind-forcedunwind.c: Make sure functions
5128 pointers are reloaded after pthread_cancel_init calls.
5129
27488789
UD
51302006-05-01 Ulrich Drepper <drepper@redhat.com>
5131
5132 * sysdeps/pthread/allocalim.h (__libc_use_alloca): Mark with
5133 __always_inline.
5134
a6375d11
UD
51352006-04-27 Ulrich Drepper <drepper@redhat.com>
5136
5137 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
5138 Allocate new object which is passed to timer_sigev_thread so that
5139 the timer can be deleted before the new thread is scheduled.
5140
16a1d952
RM
51412006-04-26 Roland McGrath <roland@redhat.com>
5142
5143 * sysdeps/x86_64/tls.h: Include <asm/prctl.h> inside [! __ASSEMBLER__].
5144
7960f2a7
UD
51452006-04-08 Ulrich Drepper <drepper@redhat.com>
5146
ab9a9ff8
UD
5147 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove branch predicion
5148 suffix for conditional jumps.
5149 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
5150 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
5151 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
5152 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
5153 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
5154 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
5155
7960f2a7
UD
5156 * init.c (sigcancel_handler): Compare with correct PID even if the
5157 thread is in the middle of a fork call.
5158 (sighandler_setxid): Likewise.
5159 Reported by Suzuki K P <suzuki@in.ibm.com> .
5160
2035d91c
UD
51612006-04-07 Jakub Jelinek <jakub@redhat.com>
5162
5163 * pthreadP.h (FUTEX_TID_MASK): Sync with kernel.
5164
0292b0dd
UD
51652006-04-06 Ulrich Drepper <drepper@redhat.com>
5166
5167 * pthread_getattr_np.c (pthread_getattr_np): Close fp if getrlimit
5168 fails [Coverity CID 105].
5169
6738b3c0
UD
51702006-04-05 Ulrich Drepper <drepper@redhat.com>
5171
5172 * sysdeps/pthread/pthread.h: Add nonnull attributes.
5173
359157a5
RM
51742006-04-03 Steven Munroe <sjmunroe@us.ibm.com>
5175
5176 [BZ #2505]
5177 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h [_ARCH_PWR4]:
5178 Define __lll_rel_instr using lwsync.
5179
cd277b2d
UD
51802006-03-27 Ulrich Drepper <drepper@redhat.com>
5181
5182 * allocatestack.c (allocate_stack): Always initialize robust_head.
5183 * descr.h: Define struct robust_list_head.
5184 (struct pthread): Use robust_list_head in robust mutex list definition.
5185 Adjust ENQUEUE_MUTEX and DEQUEUE_MUTEX.
5186 * init.c [!__ASSUME_SET_ROBUST_LIST] (__set_robust_list_avail): Define.
5187 (__pthread_initialize_minimal_internal): Register robust_list with
5188 the kernel.
5189 * pthreadP.h: Remove PRIVATE_ from PTHREAD_MUTEX_ROBUST_* names.
5190 Declare __set_robust_list_avail.
5191 * pthread_create.c (start_thread): Register robust_list of new thread.
5192 [!__ASSUME_SET_ROBUST_LIST]: If robust_list is not empty wake up
5193 waiters.
5194 * pthread_mutex_destroy.c: For robust mutexes don't look at the
5195 number of users, it's unreliable.
5196 * pthread_mutex_init.c: Allow use of pshared robust mutexes if
5197 set_robust_list syscall is available.
5198 * pthread_mutex_consistent.c: Adjust for PTHREAD_MUTEX_ROBUST_* rename.
5199 * pthread_mutex_lock.c: Simplify robust mutex code a bit.
5200 Set robust_head.list_op_pending before trying to lock a robust mutex.
5201 * pthread_mutex_timedlock.c: Likewise.
5202 * pthread_mutex_trylock.c: Likewise.
5203 * pthread_mutex_unlock.c: Likewise for unlocking.
5204 * Makefile (tests): Add tst-robust8.
5205 * tst-robust8.c: New file.
5206
facac085
UD
52072006-03-08 Andreas Schwab <schwab@suse.de>
5208
5209 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h
5210 (DL_SYSINFO_IMPLEMENTATION): Add missing newline.
5211
7ccbe1a1
RM
52122006-03-05 Roland McGrath <roland@redhat.com>
5213
5214 * configure (libc_add_on): Disable add-on when $add_ons_automatic = yes
5215 and $config_os doesn't match *linux*.
5216
043cee37
RM
52172006-03-05 David S. Miller <davem@sunset.davemloft.net>
5218
5219 * sysdeps/unix/sysv/linux/sparc/sparc32/pt-vfork.S:
5220 Use __syscall_error.
5221 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
5222 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: Likewise.
5223 * sysdeps/unix/sysv/linux/sparc/sparc64/pt-vfork.S: Likewise.
5224 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
5225 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: Likewise.
5226 * sysdeps/unix/sysv/linux/sparc/Makefile: New file.
5227
88bce79e
UD
52282006-03-02 Ulrich Drepper <drepper@redhat.com>
5229
5230 * sysdeps/unix/sysv/linux/aio_misc.h: Various cleanups.
5231
672ec465
UD
52322006-03-01 Ulrich Drepper <drepper@redhat.com>
5233
5234 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S
5235 (__lll_robust_lock_wait): Also set FUTEX_WAITERS bit if we got the
5236 mutex.
5237 (__lll_robust_timedlock_wait): Likewise.
5238 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S
5239 (__lll_robust_lock_wait): Likewise.
5240 (__lll_robust_timedlock_wait): Likewise.
5241 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c
5242 (__lll_robust_lock_wait): Likewise.
5243 (__lll_robust_timedlock_wait): Likewise.
5244
c4a4875d
RM
52452006-03-01 Jakub Jelinek <jakub@redhat.com>
5246
5247 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (lll_robust_mutex_dead,
5248 lll_robust_mutex_trylock, lll_robust_mutex_lock,
5249 lll_robust_mutex_cond_lock, lll_robust_mutex_timedlock,
5250 lll_robust_mutex_unlock): Define.
5251 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): New prototypes.
5252
3192fd8e
RM
52532006-02-28 H.J. Lu <hongjiu.lu@intel.com>
5254
5255 * sysdeps/unix/sysv/linux/ia64/clone2.S: Include <clone2.S>
5256 instead of <clone.S>.
5257
14d44b19
RM
52582006-02-27 Jakub Jelinek <jakub@redhat.com>
5259
5260 * Makefile (libpthread-routines): Add
5261 pthread_mutexattr_[sg]etprotocol, pthread_mutexattr_[sg]etprioceiling
5262 and pthread_mutex_[sg]etprioceiling.
5263 * Versions (GLIBC_2.4): Export pthread_mutexattr_getprotocol,
5264 pthread_mutexattr_setprotocol, pthread_mutexattr_getprioceiling,
5265 pthread_mutexattr_setprioceiling, pthread_mutex_getprioceiling and
5266 pthread_mutex_setprioceiling.
5267 * sysdeps/pthread/pthread.h (PTHREAD_PRIO_NONE, PTHREAD_PRIO_INHERIT,
5268 PTHREAD_PRIO_PROTECT): New enum values.
5269 (pthread_mutexattr_getprotocol, pthread_mutexattr_setprotocol,
5270 pthread_mutexattr_getprioceiling, pthread_mutexattr_setprioceiling,
5271 pthread_mutex_getprioceiling, pthread_mutex_setprioceiling): New
5272 prototypes.
5273 * pthreadP.h (PTHREAD_MUTEX_PRIO_INHERIT_PRIVATE_NP,
5274 PTHREAD_MUTEX_PRIO_PROTECT_PRIVATE_NP): New enum values.
5275 (PTHREAD_MUTEX_PRIO_CEILING_SHIFT, PTHREAD_MUTEX_PRIO_CEILING_MASK):
5276 Define.
5277 (PTHREAD_MUTEXATTR_PROTOCOL_SHIFT, PTHREAD_MUTEXATTR_PROTOCOL_MASK,
5278 PTHREAD_MUTEXATTR_PRIO_CEILING_SHIFT,
5279 PTHREAD_MUTEXATTR_PRIO_CEILING_MASK): Define.
5280 (PTHREAD_MUTEXATTR_FLAG_BITS): Or in PTHREAD_MUTEXATTR_PROTOCOL_MASK
5281 and PTHREAD_MUTEXATTR_PRIO_CEILING_MASK.
5282 * pthread_mutex_init.c (__pthread_mutex_init): For the time being
5283 return ENOTSUP for PTHREAD_PRIO_INHERIT or PTHREAD_PRIO_PROTECT
5284 protocol mutexes.
5285 * pthread_mutex_getprioceiling.c: New file.
5286 * pthread_mutex_setprioceiling.c: New file.
5287 * pthread_mutexattr_getprioceiling.c: New file.
5288 * pthread_mutexattr_setprioceiling.c: New file.
5289 * pthread_mutexattr_getprotocol.c: New file.
5290 * pthread_mutexattr_setprotocol.c: New file.
5291
62f6b9b2
RM
52922006-02-27 Daniel Jacobowitz <dan@codesourcery.com>
5293
5294 * sysdeps/unix/sysv/linux/aio_misc.h: Include <limits.h>.
5295
e0a3ed4f
RM
52962006-02-27 Roland McGrath <roland@redhat.com>
5297
5298 * sysdeps/pthread/Subdirs: List nptl here too.
5299 * configure (libc_add_on_canonical): New variable.
5300
5301 * sysdeps/unix/sysv/linux/sh/sh4/lowlevellock.h: Use #include_next.
5302
5303 * sysdeps/unix/sysv/linux/sleep.c: Use #include_next after #include of
5304 self to get main source tree's file.
5305 * sysdeps/unix/sysv/linux/alpha/clone.S: Likewise.
5306 * sysdeps/unix/sysv/linux/i386/clone.S: Likewise.
5307 * sysdeps/unix/sysv/linux/i386/vfork.S: Likewise.
5308 * sysdeps/unix/sysv/linux/ia64/clone2.S: Likewise.
5309 * sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S: Likewise.
5310 * sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S: Likewise.
5311 * sysdeps/unix/sysv/linux/s390/s390-32/clone.S: Likewise.
5312 * sysdeps/unix/sysv/linux/s390/s390-64/clone.S: Likewise.
5313 * sysdeps/unix/sysv/linux/sh/clone.S: Likewise.
5314 * sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: Likewise.
5315 * sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
5316 * sysdeps/unix/sysv/linux/x86_64/clone.S: Likewise.
5317 * sysdeps/unix/sysv/linux/x86_64/vfork.S: Likewise.
5318
5319 * Makefile: Use $(sysdirs) in vpath directive.
5320
5321 * sysdeps/pthread/Makefile (CFLAGS-libc-start.c): Variable removed.
5322 (CPPFLAGS-timer_routines.c): Likewise.
5323
5324 * Makeconfig (includes): Variable removed.
5325
84cfa284
RM
53262006-02-26 Roland McGrath <roland@redhat.com>
5327
5328 * sysdeps/generic/pt-raise.c: Moved to ...
5329 * pt-raise.c: ... here.
5330 * sysdeps/generic/lowlevellock.h: Moved to ...
5331 * lowlevellock.h: ... here.
5332
c5132ca1
RM
53332006-02-23 Roland McGrath <roland@redhat.com>
5334
5335 * descr.h (struct pthread): Add final member `end_padding'.
5336 (PTHREAD_STRUCT_END_PADDING): Use it.
5337
53382006-02-20 Roland McGrath <roland@redhat.com>
5339
5340 * sysdeps/mips: Directory removed, saved in ports repository.
5341 * sysdeps/unix/sysv/linux/mips: Likewise.
5342
a93317a1
UD
53432006-02-18 Ulrich Drepper <drepper@redhat.com>
5344
5345 * tst-robust1.c: Add second mutex to check that the mutex list is
5346 handled correctly.
5347
f1740bc4
UD
53482006-02-17 Jakub Jelinek <jakub@redhat.com>
5349
5350 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_robust_mutex_dead,
5351 lll_robust_mutex_trylock, lll_robust_mutex_lock,
5352 lll_robust_mutex_cond_lock, lll_robust_mutex_timedlock,
5353 lll_robust_mutex_unlock): New macros.
5354 (__lll_robust_lock_wait, __lll_robust_timedlock_wait): New prototypes.
5355 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
5356 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
5357 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
5358 * sysdeps/unix/sysv/linux/lowlevelrobustlock.c: New file.
5359
a7245bf5
UD
53602006-02-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5361
5362 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Add lll_robust_mutex_*
5363 definitions.
5364 * sysdeps/unix/sysv/linux/sh/lowlevelrobustlock.S: New file.
5365
49bfc1fe
UD
53662006-02-17 Ulrich Drepper <drepper@redhat.com>
5367
5368 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
5369 (lll_robust_mutex_unlock): Avoid unnecessary wakeups.
5370 * sysdeps/unix/sysv/linux/i386/lowlevellock.h
5371 (lll_robust_mutex_unlock): Likewise.
5372
56e987ac
UD
53732006-02-13 Jakub Jelinek <jakub@redhat.com>
5374
5375 * descr.h [!__PTHREAD_MUTEX_HAVE_PREV] (DEQUEUE_MUTEX):
5376 Set robust_list.__next rather than robust_list.
5377 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
5378 (__pthread_list_t): New typedef.
5379 (pthread_mutex_t): Replace __next and __prev fields with __list.
5380 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h
5381 (__pthread_list_t): New typedef.
5382 (pthread_mutex_t): Replace __next and __prev fields with __list.
5383 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
5384 (__pthread_list_t, __pthread_slist_t): New typedefs.
5385 (pthread_mutex_t): Replace __next and __prev fields with __list.
5386 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h
5387 (__pthread_list_t, __pthread_slist_t): New typedefs.
5388 (pthread_mutex_t): Replace __next and __prev fields with __list.
5389 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h
5390 (__pthread_list_t, __pthread_slist_t): New typedefs.
5391 (pthread_mutex_t): Replace __next and __prev fields with __list.
5392 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h
5393 (__pthread_slist_t): New typedef.
5394 (pthread_mutex_t): Replace __next field with __list.
5395
683040c3
UD
53962006-02-15 Ulrich Drepper <drepper@redhat.com>
5397
25bc77e6 5398 * pthreadP.h: Define PTHREAD_MUTEX_INCONSISTENT instead of
683040c3
UD
5399 PTHREAD_MUTEX_OWNERDEAD.
5400 (PTHREAD_MUTEX_ROBUST_PRIVATE_NP): Define as 16, not 256.
5401 Define FUTEX_WAITERS, FUTEX_OWNER_DIED, FUTEX_TID_MASK.
5402 * Makefile (libpthread-routines): Add lowlevelrobustlock.
5403 * pthread_create.c (start_thread): Very much simplify robust_list loop.
5404 * pthread_mutex_consistent.c: Inconsistent mutex have __owner now set
5405 to PTHREAD_MUTEX_INCONSISTENT.
5406 * pthread_mutex_destroy.c: Allow destroying of inconsistent mutexes.
5407 * pthread_mutex_lock.c: Reimplement robust mutex handling.
5408 * pthread_mutex_trylock.c: Likewise.
5409 * pthread_mutex_timedlock.c: Likewise.
5410 * pthread_mutex_unlock.c: Likewise.
5411 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
5412 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
5413 lowlevelrobustlock.sym.
5414 * sysdeps/unix/sysv/linux/lowlevelrobustlock.sym: New file.
5415 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Add lll_robust_mutex_*
5416 definitions.
5417 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
5418 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrobustlock.S: New file.
5419 * sysdeps/unix/sysv/linux/i386/i586/lowlevelrobustlock.S: New file.
5420 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrobustlock.S: New file.
5421 * sysdeps/unix/sysv/linux/x86_64/lowlevelrobustlock.S: New file.
5422
bbf209a4
UD
54232006-02-12 Ulrich Drepper <drepper@redhat.com>
5424
b007ce7c
UD
5425 * allocatestack.c (allocate_stack): Initialize robust_list.
5426 * init.c (__pthread_initialize_minimal_internal): Likewise.
5427 * descr.h (struct xid_command): Pretty printing.
5428 (struct pthread): Use __pthread_list_t or __pthread_slist_t for
5429 robust_list. Adjust macros.
5430 * pthread_create.c (start_thread): Adjust robust_list handling.
5431 * phtread_mutex_unlock.c: Don't allow unlocking from any thread
5432 but the owner for all robust mutex types.
5433 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Define
5434 __pthread_list_t and __pthread_slist_t. Use them in pthread_mutex_t.
0ca3379d 5435 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
b007ce7c
UD
5436 * sysdeps/pthread/pthread.h: Adjust mutex initializers.
5437
bbf209a4 5438 * sysdeps/unix/sysv/linux/i386/not-cancel.h: Define openat_not_cancel,
b42a214c 5439 openat_not_cancel_3, openat64_not_cancel, and openat64_not_cancel_3.
bbf209a4 5440
b576fca1
UD
54412006-02-08 Jakub Jelinek <jakub@redhat.com>
5442
5443 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait,
5444 lll_futex_timedwait, lll_wait_tid): Add "memory" clobber.
5445
a6df7387
UD
54462006-01-20 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5447
5448 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_futex_wait):
5449 Return status.
5450 (lll_futex_timed_wait): Define.
5451
7c65e900
UD
54522006-01-19 Ulrich Drepper <drepper@redhat.com>
5453
5454 * tst-cancel4.c: Test ppoll.
5455
5f9f21e8
AJ
54562006-01-18 Andreas Jaeger <aj@suse.de>
5457
cf407dfb 5458 [BZ #2167]
5f9f21e8
AJ
5459 * sysdeps/unix/sysv/linux/mips/bits/pthreadtypes.h
5460 (pthread_mutex_t): Follow changes for other archs. Based on patch
5461 by Jim Gifford <patches@jg555.com>.
5462
251278c6
UD
54632006-01-13 Richard Henderson <rth@redhat.com>
5464
5465 * sysdeps/alpha/tls.h (tcbhead_t): Rename member to __private.
5466
de59a291
RM
54672006-01-10 Roland McGrath <roland@redhat.com>
5468
5469 * sysdeps/alpha/jmpbuf-unwind.h: File moved to main source tree.
5470 * sysdeps/i386/jmpbuf-unwind.h: Likewise.
5471 * sysdeps/mips/jmpbuf-unwind.h: Likewise.
5472 * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
5473 * sysdeps/s390/jmpbuf-unwind.h: Likewise.
5474 * sysdeps/sh/jmpbuf-unwind.h: Likewise.
5475 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
5476 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Likewise.
5477 * sysdeps/x86_64/jmpbuf-unwind.h: Likewise.
0ca13e14 5478 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
de59a291 5479
931786ee
RM
54802006-01-09 Roland McGrath <roland@redhat.com>
5481
5d42c8c3
RM
5482 * tst-initializers1-c89.c: New file.
5483 * tst-initializers1-c99.c: New file.
5484 * tst-initializers1-gnu89.c: New file.
5485 * tst-initializers1-gnu99.c: New file.
5486 * Makefile (tests): Add them.
5487 (CFLAGS-tst-initializers1-c89.c): New variable.
5488 (CFLAGS-tst-initializers1-c99.c): New variable.
5489 (CFLAGS-tst-initializers1-gnu89.c): New variable.
5490 (CFLAGS-tst-initializers1-gnu99.c): New variable.
5491
931786ee
RM
5492 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
5493 Use __extension__ on anonymous union definition.
5494 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
5495 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
5496 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5497 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
3c238452 5498 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
931786ee 5499
8dd18431
RM
55002006-01-08 Jakub Jelinek <jakub@redhat.com>
5501
5502 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_mutex_t):
5503 Don't give the union a name because it changes the mangled name.
5504 Instead name the struct for __data.
5505 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_mutex_t):
5506 Likewise.
5507 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_mutex_t):
5508 Likewise.
5509
ae11e412
UD
55102006-01-09 Jakub Jelinek <jakub@redhat.com>
5511
5512 * sysdeps/sparc/sparc64/jmpbuf-unwind.h (_JMPBUF_UNWINDS_ADJ): Add
5513 stack bias to mc_ftp field.
5514
c6885aa1
UD
55152006-01-07 Ulrich Drepper <drepper@redhat.com>
5516
5517 * sysdeps/pthread/aio_misc.h (AIO_MISC_WAIT): Work around gcc
6e741bc3 5518 being too clever and reloading the futex value where it shouldn't.
c6885aa1 5519
ae4ad00a
UD
55202006-01-06 Ulrich Drepper <drepper@redhat.com>
5521
5522 * descr.h [!__PTHREAD_MUTEX_HAVE_PREV] (DEQUEUE_MUTEX): Use
5523 correct type.
5524
ced368f7
UD
55252006-01-06 Jakub Jelinek <jakub@redhat.com>
5526
5527 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h (PSEUDO):
5528 Add cfi directives.
5529
d804f5df
UD
55302006-01-06 Ulrich Drepper <drepper@redhat.com>
5531
cbbbb188 5532 * sysdeps/ia64/tls.h (tcbhead_t): Rename private member to __private.
719046c1
UD
5533 * sysdeps/ia64/tcb-offsets.sym: Adjust for private->__private
5534 rename in tcbhead_t.
5535
d804f5df
UD
5536 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
5537 Don't give the union a name because it changes the mangled name.
5538 Instead name the struct for __data.
5539 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
5540 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
5541 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5542 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
5543 * pthread_create.c (start_thread): Adjust robust mutex free loop.
5544 * descr.h (ENQUEUE_MUTEX, DEQUEUE_MUTEX): Adjust.
5545
679d83ba
UD
55462006-01-05 Ulrich Drepper <drepper@redhat.com>
5547
5548 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait):
5549 Return status.
5550 (lll_futex_timed_wait): Define.
5551 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
5552 * sysdeps/pthread/aio_misc.h: New file.
5553
06dc5bf3
RM
55542006-01-03 Joseph S. Myers <joseph@codesourcery.com>
5555
5556 * Makefile ($(objpfx)$(multidir)): Use mkdir -p.
5557
9759bbf1
UD
55582006-01-03 Steven Munroe <sjmunroe@us.ibm.com>
5559
5560 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
5561 (PSEUDO): Remove redundant cfi_startproc and cfi_endproc directives.
5562 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
5563
db59b28b
UD
55642006-01-04 Ulrich Drepper <drepper@redhat.com>
5565
5566 * tst-cancel24.cc: Use C headers instead of C++ headers.
5567
b01fe5f7
UD
55682006-01-03 Jakub Jelinek <jakub@redhat.com>
5569
5570 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Remove #error for
5571 sparc-linux configured glibc.
5572 (lll_futex_wake_unlock): Define to 1 for sparc-linux configured glibc.
5573 (__lll_mutex_trylock, __lll_mutex_cond_trylock, __lll_mutex_lock,
5574 __lll_mutex_cond_lock, __lll_mutex_timedlock): Use
5575 atomic_compare_and_exchange_val_24_acq instead of
5576 atomic_compare_and_exchange_val_acq.
5577 (lll_mutex_unlock, lll_mutex_unlock_force): Use atomic_exchange_24_rel
5578 instead of atomic_exchange_rel.
5579 * sysdeps/unix/sysv/linux/sparc/sparc32/lowlevellock.c: New file.
5580 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_init.c: New
5581 file.
5582 * sysdeps/unix/sysv/linux/sparc/sparc32/pthread_barrier_wait.c: New
5583 file.
5584 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_init.c: New file.
5585 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_post.c: New file.
5586 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_timedwait.c: New file.
5587 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_trywait.c: New file.
5588 * sysdeps/unix/sysv/linux/sparc/sparc32/sem_wait.c: New file.
5589 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_init.c:
5590 New file.
5591 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/pthread_barrier_wait.c:
5592 New file.
5593 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_init.c: New file.
5594 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_post.c: New file.
5595 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_timedwait.c: New
5596 file.
5597 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_trywait.c: New
5598 file.
5599 * sysdeps/unix/sysv/linux/sparc/sparc32/sparcv9/sem_wait.c: New file.
5600
35c2fd59
UD
56012006-01-03 Ulrich Drepper <drepper@redhat.com>
5602
5603 * sysdeps/pthread/pthread.h [__WORDSIZE==64]: Don't use cast in
5604 mutex initializers.
5605
305bb37e
UD
56062006-01-02 Jakub Jelinek <jakub@redhat.com>
5607
5608 * sysdeps/sparc/tls.h (tcbhead_t): Add pointer_guard field.
5609 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
5610 THREAD_COPY_POINTER_GUARD): Define.
5611 * sysdeps/sparc/tcb-offsets.sym (POINTER_GUARD): Define.
5612 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Revert 2005-12-27 changes.
5613
cc792128
UD
56142006-01-01 Ulrich Drepper <drepper@redhat.com>
5615
5616 * version.c: Update copyright year.
5617
db0a00d3
UD
56182005-12-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5619
5620 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Remove explicit
5621 .eh_frame section, use cfi_* directives.
5622 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Add cfi instrumentation.
5623
b36205c4
UD
56242005-12-30 Ulrich Drepper <drepper@redhat.com>
5625
5626 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Undo last change for
5627 now.
5628
8b4f1598
UD
56292005-12-29 Ulrich Drepper <drepper@redhat.com>
5630
5631 * sysdeps/pthread/sigaction.c: Removed.
5632 * sigaction.c: New file.
5633 * sysdeps/unix/sysv/linux/Makefile: Define CFLAGS-sigaction.c.
5634
fec5592d
UD
56352005-12-28 Ulrich Drepper <drepper@redhat.com>
5636
5637 * Makefile (tests): Add tst-signal7.
5638 * tst-signal7.c: New file.
5639
db169ed5
RM
56402005-12-27 Roland McGrath <roland@redhat.com>
5641
5642 * sysdeps/x86_64/jmpbuf-unwind.h (_jmpbuf_sp): New inline function.
5643 (_JMPBUF_UNWINDS_ADJ): Use it, to PTR_DEMANGLE before comparison.
5644 * sysdeps/alpha/jmpbuf-unwind.h: Likewise.
5645 * sysdeps/i386/jmpbuf-unwind.h: Likewise.
5646 * sysdeps/mips/jmpbuf-unwind.h: Likewise.
5647 * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
5648 * sysdeps/s390/jmpbuf-unwind.h: Likewise.
5649 * sysdeps/sh/jmpbuf-unwind.h: Likewise.
5650 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
5651 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: Likewise.
5652 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
5653
bfffffae
UD
56542005-12-27 Jakub Jelinek <jakub@redhat.com>
5655
5656 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Add __next
5657 and __prev field to pthread_mutex_t.
5658 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
5659 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
5660 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
5661 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
5662 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Add __next field
5663 to pthread_mutex_t.
5664
1bcfb5a5
UD
56652005-12-26 Ulrich Drepper <drepper@redhat.com>
5666
5667 * pthreadP.h: Define PTHREAD_MUTEX_ROBUST_PRIVATE_NP,
5668 PTHREAD_MUTEX_ROBUST_PRIVATE_RECURSIVE_NP,
5669 PTHREAD_MUTEX_ROBUST_PRIVATE_ERRORCHECK_NP,
5670 PTHREAD_MUTEX_ROBUST_PRIVATE_ADAPTIVE_NP,
5671 PTHREAD_MUTEXATTR_FLAG_ROBUST, PTHREAD_MUTEXATTR_FLAG_PSHARED,
5672 and PTHREAD_MUTEXATTR_FLAG_BITS.
5673 * descr.h (struct pthread): Add robust_list field and define
5674 ENQUEUE_MUTEX and DEQUEUE_MUTEX macros.
5675 * pthread_mutexattr_getrobust.c: New file.
5676 * pthread_mutexattr_setrobust.c: New file.
5677 * pthread_mutex_consistent.c: New file.
5678 * sysdeps/pthread/pthread.h: Declare pthread_mutexattr_getrobust,
5679 pthread_mutexattr_setrobust, and pthread_mutex_consistent.
5680 Define PTHREAD_MUTEX_STALLED_NP and PTHREAD_MUTEX_ROBUST_NP.
5681 Adjust pthread_mutex_t initializers.
5682 * nptl/sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Add __next
5683 field to pthread_mutex_t.
5684 * nptl/sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Add __next
5685 and __prev field to pthread_mutex_t.
5686 * Versions [GLIBC_2.4]: Export pthread_mutexattr_getrobust_np,
5687 pthread_mutexattr_setrobust_np, and pthread_mutex_consistent_np.
5688 * pthread_mutexattr_getpshared.c: Use PTHREAD_MUTEXATTR_FLAG_PSHARED
5689 and PTHREAD_MUTEXATTR_FLAG_BITS macros instead of magic numbers.
5690 * pthread_mutexattr_gettype.c: Likewise.
5691 * pthread_mutexattr_setpshared.c: Likewise.
5692 * pthread_mutexattr_settype.c: Likewise.
5693 * pthread_mutex_init.c: Reject robust+pshared attribute for now.
5694 Initialize mutex kind according to robust flag.
5695 * pthread_mutex_lock.c: Implement local robust mutex.
5696 * pthread_mutex_timedlock.c: Likewise.
5697 * pthread_mutex_trylock.c: Likewise.
5698 * pthread_mutex_unlock.c: Likewise.
5699 * pthread_create.c (start_thread): Mark robust mutexes which remained
5700 locked as dead.
5701 * tst-robust1.c: New file.
5702 * tst-robust2.c: New file.
5703 * tst-robust3.c: New file.
5704 * tst-robust4.c: New file.
5705 * tst-robust5.c: New file.
5706 * tst-robust6.c: New file.
5707 * tst-robust7.c: New file.
5708 * Makefile (libpthread-routines): Add pthread_mutexattr_getrobust,
5709 pthread_mutexattr_setrobust, and pthread_mutex_consistent.
5710 (tests): Add tst-robust1, tst-robust2, tst-robust3, tst-robust4,
5711 tst-robust5, tst-robust6, and tst-robust7.
5712
5713 * tst-typesizes.c: New file.
5714 * Makefile (tests): Add tst-typesizes.
5715
5716 * tst-once3.c: More debug output.
5717
9333ed0d
UD
57182005-12-24 Ulrich Drepper <drepper@redhat.com>
5719
d4d138a4
UD
5720 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Add break
5721 missing after last change.
5722
bfffffae 5723 * version.c: Update copyright year.
9333ed0d 5724
dcc73a8d
UD
57252005-12-23 Ulrich Drepper <drepper@redhat.com>
5726
5727 * pthread_mutex_destroy.c: Set mutex type to an invalid value.
5728 * pthread_mutex_lock.c: Return EINVAL for invalid mutex type.
5729 * pthread_mutex_trylock.c: Likewise.
5730 * pthread_mutex_timedlock.c: Likewise.
5731 * pthread_mutex_unlock.c: Likewise.
5732
879f3ca6
RM
57332005-12-22 Roland McGrath <roland@redhat.com>
5734
5735 * sysdeps/pthread/sigaction.c: Use "" instead of <> to include self,
5736 so that #include_next's search location is not reset to the -I..
5737 directory where <nptl/...> can be found.
5738
077a0da7
UD
57392005-12-22 Ulrich Drepper <drepper@redhat.com>
5740
5741 [BZ #1913]
5742 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
5743 Fix unwind info. Remove useless branch prediction prefix.
7735afa2
UD
5744 * tst-cancel24.cc: New file.
5745 * Makefile: Add rules to build and run tst-cancel24.
077a0da7 5746
8dea90aa
RM
57472005-12-21 Roland McGrath <roland@redhat.com>
5748
5749 * libc-cancellation.c: Use <> rather than "" #includes.
5750 * pt-cleanup.c: Likewise.
5751 * pthread_create.c: Likewise.
5752 * pthread_join.c: Likewise.
5753 * pthread_timedjoin.c: Likewise.
5754 * pthread_tryjoin.c: Likewise.
5755 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Likewise.
5756 * sysdeps/unix/sysv/linux/register-atfork.c: Likewise.
5757 * sysdeps/unix/sysv/linux/unregister-atfork.c: Likewise.
5758 * unwind.c: Likewise.
5759
8da21f96
UD
57602005-12-19 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5761
5762 * sysdeps/sh/tcb-offsets.sym: Add POINTER_GUARD.
5763 * sysdeps/sh/tls.h (tcbhead_t): Remove private and add pointer_guard.
5764 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
5765 THREAD_COPY_POINTER_GUARD): Define.
5766
00c2b3b9
UD
57672005-12-19 Jakub Jelinek <jakub@redhat.com>
5768
5769 * sysdeps/ia64/tls.h (TLS_PRE_TCB_SIZE): Make room for 2 uintptr_t's
5770 rather than one.
5771 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
5772 THREAD_COPY_POINTER_GUARD): Define.
5773 * sysdeps/powerpc/tcb-offsets.sym (POINTER_GUARD): Add.
5774 * sysdeps/powerpc/tls.h (tcbhead_t): Add pointer_guard field.
5775 (THREAD_GET_POINTER_GUARD, THREAD_SET_POINTER_GUARD,
5776 THREAD_COPY_POINTER_GUARD): Define.
5777 * sysdeps/s390/tcb-offsets.sym (STACK_GUARD): Add.
5778 * sysdeps/s390/tls.h (THREAD_GET_POINTER_GUARD,
5779 THREAD_SET_POINTER_GUARD, THREAD_COPY_POINTER_GUARD): Define.
5780 * sysdeps/unix/sysv/linux/ia64/__ia64_longjmp.S (__ia64_longjmp):
5781 Use PTR_DEMANGLE for B0 if defined.
5782
827b7087
UD
57832005-12-17 Ulrich Drepper <drepper@redhat.com>
5784
5785 * pthread_create.c (__pthread_create_2_1): Use
5786 THREAD_COPY_POINTER_GUARD if available.
5787 * sysdeps/i386/tcb-offsets.sym: Add POINTER_GUARD.
5788 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
5789 * sysdeps/i386/tls.h (tcbhead_t): Add pointer_guard.
5790 Define THREAD_SET_POINTER_GUARD and THREAD_COPY_POINTER_GUARD.
5791 * sysdeps/x86_64/tls.h: Likewise.
5792
2826ac7e
RM
57932005-12-15 Roland McGrath <roland@redhat.com>
5794
5795 * sysdeps/unix/sysv/linux/mq_notify.c: Don't use sysdeps/generic.
5796
b6ab06ce
UD
57972005-12-13 Ulrich Drepper <drepper@redhat.com>
5798
5799 * sysdeps/pthread/sigfillset.c: Adjust for files moved out of
5800 sysdeps/generic.
5801 * errno-loc.c: New file.
5802
f0d1a3b5
RM
58032005-12-12 Roland McGrath <roland@redhat.com>
5804
5805 * init.c (__pthread_initialize_minimal_internal): Do __static_tls_size
5806 adjustments before choosing stack size. Update minimum stack size
5807 calculation to match allocate_stack change.
5808
db13ddbc
UD
58092005-12-12 Ulrich Drepper <drepper@redhat.com>
5810
5811 * allocatestack.c (allocate_stack): Don't demand that there is an
5812 additional full page available on the stack beside guard, TLS, the
5813 minimum stack.
5814
088f460f
UD
58152005-11-24 Ulrich Drepper <drepper@redhat.com>
5816
5817 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h
5818 (__cleanup_fct_attribute): Use __regparm__ not regparm.
5819
5820 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: When
5821 compiling 32-bit code we must define __cleanup_fct_attribute.
5822
16feadf2
UD
5823005-11-24 Jakub Jelinek <jakub@redhat.com>
5824
5825 [BZ #1920]
5826 * sysdeps/pthread/pthread.h (__pthread_unwind_next): Use
5827 __attribute__ instead of __attribute.
5828 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h
5829 (__cleanup_fct_attribute): Likewise.
5830
e6e493bb
UD
58312005-11-17 Jakub Jelinek <jakub@redhat.com>
5832
5833 * sysdeps/pthread/unwind-forcedunwind.c (pthread_cancel_init): Put
5834 a write barrier before writing libgcc_s_getcfa.
5835
8e635611
UD
58362005-11-06 Ulrich Drepper <drepper@redhat.com>
5837
5838 * sysdeps/unix/sysv/linux/configure: Removed.
5839
ce33ee7c
UD
58402005-11-05 Ulrich Drepper <drepper@redhat.com>
5841
5842 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Remove trace of
5843 optional init_array/fini_array support.
5844
20d511e0
RM
58452005-10-24 Roland McGrath <roland@redhat.com>
5846
5847 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Remove unnecessary
5848 versioned_symbol use.
5849
fe60d146
RM
58502005-10-16 Roland McGrath <roland@redhat.com>
5851
5852 * init.c (__pthread_initialize_minimal_internal): Even when using a
5853 compile-time default stack size, apply the minimum that allocate_stack
5854 will require, and round up to page size.
5855
0faa1cf5
RM
58562005-10-10 Daniel Jacobowitz <dan@codesourcery.com>
5857
5858 * Makefile ($(test-modules)): Remove static pattern rule.
5859
f9126cc2 58602005-10-14 Jakub Jelinek <jakub@redhat.com>
b42a214c 5861 Ulrich Drepper <drepper@redhat.com>
f9126cc2
UD
5862
5863 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Fix stack
5864 alignment in callback function.
5865 * Makefile: Add rules to build and run tst-align3.
5866 * tst-align3.c: New file.
5867
015a5d22
RM
58682005-10-03 Jakub Jelinek <jakub@redhat.com>
5869
5870 * allocatestack.c (setxid_signal_thread): Add
5871 INTERNAL_SYSCALL_DECL (err).
5872
b71ce910
UD
58732005-10-02 Jakub Jelinek <jakub@redhat.com>
5874
5875 * allocatestack.c (setxid_signal_thread): Need to use
5876 atomic_compare_and_exchange_bool_acq.
5877
dff9a7a1 58782005-10-01 Ulrich Drepper <drepper@redhat.com>
b42a214c 5879 Jakub Jelinek <jakub@redhat.com>
dff9a7a1
UD
5880
5881 * descr.h: Define SETXID_BIT and SETXID_BITMASK. Adjust
5882 CANCEL_RESTMASK.
5883 (struct pthread): Move specific_used field to avoid padding.
5884 Add setxid_futex field.
5885 * init.c (sighandler_setxid): Reset setxid flag and release the
5886 setxid futex.
5887 * allocatestack.c (setxid_signal_thread): New function. Broken
5888 out of the bodies of the two loops in __nptl_setxid. For undetached
5889 threads check whether they are exiting and if yes, don't send a signal.
5890 (__nptl_setxid): Simplify loops by using setxid_signal_thread.
5891 * pthread_create.c (start_thread): For undetached threads, check
5892 whether setxid bit is set. If yes, wait until signal has been
5893 processed.
5894
5895 * allocatestack.c (STACK_VARIABLES): Initialize them.
5896 * pthread_create.c (__pthread_create_2_1): Initialize pd.
5897
560b4709
UD
58982004-09-02 Jakub Jelinek <jakub@redhat.com>
5899
5900 * pthread_cond_destroy.c (__pthread_cond_destroy): If there are
5901 waiters, awake all waiters on the associated mutex.
5902
5eac4760
RM
59032005-09-22 Roland McGrath <roland@redhat.com>
5904
5905 * perf.c [__x86_64__] (HP_TIMING_NOW): New macro (copied from
5906 ../sysdeps/x86_64/hp-timing.h).
5907
a3615024
UD
59082005-08-29 Jakub Jelinek <jakub@redhat.com>
5909
5910 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_WAKE_OP,
5911 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
5912 (lll_futex_wake_unlock): Define.
5913 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_WAKE_OP,
5914 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
5915 (lll_futex_wake_unlock): Define.
5916 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_WAKE_OP,
5917 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
5918 (lll_futex_wake_unlock): Define.
5919 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_WAKE_OP,
5920 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
5921 (lll_futex_wake_unlock): Define.
5922 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_WAKE_OP,
5923 FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
5924 (lll_futex_wake_unlock): Define.
5925 * sysdeps/pthread/pthread_cond_signal.c (__pthread_cond_signal): Use
5926 lll_futex_wake_unlock.
5927 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
5928 (FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
5929 (__pthread_cond_signal): Use FUTEX_WAKE_OP.
5930 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
5931 (FUTEX_WAKE_OP, FUTEX_OP_CLEAR_WAKE_IF_GT_ONE): Define.
5932 (__pthread_cond_signal): Use FUTEX_WAKE_OP.
5933
bf017034
UD
59342005-09-05 Kaz Kojima <kkojima@rr.iij4u.or.jp>
5935
5936 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_mutex_lock_wait):
5937 Fix typo in register name.
5938
fd4af664
UD
59392005-08-23 Ulrich Drepper <drepper@redhat.com>
5940
8558d715
UD
5941 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
5942 Use __sigfillset. Document that sigfillset does the right thing wrt
5943 to SIGSETXID.
fd4af664 5944
3fd1bc67
UD
59452005-07-11 Jakub Jelinek <jakub@redhat.com>
5946
44d75caf 5947 [BZ #1102]
3fd1bc67
UD
5948 * sysdeps/pthread/pthread.h (PTHREAD_MUTEX_INITIALIZER,
5949 PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP,
5950 PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP,
5951 PTHREAD_MUTEX_ADAPTIVE_NP, PTHREAD_RWLOCK_INITIALIZER,
5952 PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP,
5953 PTHREAD_COND_INITIALIZER): Supply zeros for all fields
5954 in the structure.
5955 * Makefile (tests): Add tst-initializers1.
5956 (CFLAGS-tst-initializers1.c): Set.
5957 * tst-initializers1.c: New test.
5958
553185e2
UD
59592005-07-11 Jakub Jelinek <jakub@redhat.com>
5960
5961 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_rwlock_t):
5962 Make sure __flags are located at offset 48 from the start of the
5963 structure.
5964
8df08cb2
RM
59652005-07-02 Roland McGrath <roland@redhat.com>
5966
5967 * Makeconfig: Comment fix.
5968
253eb3a0
UD
59692005-07-05 Jakub Jelinek <jakub@redhat.com>
5970
5971 * descr.h (PTHREAD_STRUCT_END_PADDING): Define.
5972 * sysdeps/ia64/tls.h (TLS_PRE_TCB_SIZE): If PTHREAD_STRUCT_END_PADDING
5973 is smaller than 8 bytes, increase TLS_PRE_TCB_SIZE by 16 bytes.
5974 (THREAD_SYSINFO, THREAD_SELF, DB_THREAD_SELF): Don't assume
5975 TLS_PRE_TCB_SIZE is sizeof (struct pthread).
5976 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
5977 * sysdeps/ia64/tcb-offsets.sym (PID, TID, MULTIPLE_THREADS_OFFSET):
5978 Use TLS_PRE_TCB_SIZE instead of sizeof (struct pthread).
5979 * sysdeps/unix/sysv/linux/ia64/createthread.c (TLS_VALUE): Don't
5980 assume TLS_PRE_TCB_SIZE is sizeof (struct pthread).
5981
bb6e8ca3
UD
59822005-06-25 Jakub Jelinek <jakub@redhat.com>
5983
5984 * sysdeps/i386/tls.h (tcbhead_t): Add stack_guard field.
5985 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
5986 * sysdeps/x86_64/tls.h (tcbhead_t): Add sysinfo and stack_guard
5987 fields.
5988 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
5989 * sysdeps/s390/tls.h (tcbhead_t): Add stack_guard
5990 field. Put in sysinfo field unconditionally.
5991 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
5992 * sysdeps/powerpc/tls.h (tcbhead_t): Add stack_guard field.
5993 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
5994 * sysdeps/sparc/tls.h (tcbhead_t): Add sysinfo and stack_guard
5995 fields.
5996 (THREAD_SET_STACK_GUARD, THREAD_COPY_STACK_GUARD): Define.
5997 * pthread_create.c (__pthread_create_2_1): Use
5998 THREAD_COPY_STACK_GUARD macro.
5999 * Makefile: Add rules to build and run tst-stackguard1{,-static}
6000 tests.
6001 * tst-stackguard1.c: New file.
6002 * tst-stackguard1-static.c: New file.
6003
99c7f870
UD
60042005-06-14 Alan Modra <amodra@bigpond.net.au>
6005
6006 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (PSEUDO):
6007 Invoke CGOTSETUP and CGOTRESTORE.
6008 (CGOTSETUP, CGOTRESTORE): Define.
6009
8074c5c5
RM
60102005-05-29 Richard Henderson <rth@redhat.com>
6011
6012 * tst-cancel4.c (WRITE_BUFFER_SIZE): New.
6013 (tf_write, tf_writev): Use it.
6014 (do_test): Use socketpair instead of pipe. Set SO_SNDBUF to
6015 the system minimum.
6016
c179df4e
UD
60172005-05-23 Jakub Jelinek <jakub@redhat.com>
6018
6019 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
6020 [IS_IN_librt] (CENABLE, CDISABLE): Use JUMPTARGET instead of
6021 __librt_*_asynccancel@local.
6022
b0e196a4
UD
60232005-05-17 Alan Modra <amodra@bigpond.net.au>
6024
6025 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Delete
6026 all occurrences of JUMPTARGET. Instead append @local to labels.
6027
f7d78e18
UD
60282005-05-20 Jakub Jelinek <jakub@redhat.com>
6029
6030 * sysdeps/i386/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN): Define to
6031 size/alignment of struct pthread rather than tcbhead_t.
6032 * sysdeps/x86_64/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
6033 Likewise.
6034 * sysdeps/s390/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
6035 Likewise.
6036 * sysdeps/sparc/tls.h (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN):
6037 Likewise.
6038
363dd976
UD
60392005-05-19 Richard Henderson <rth@redhat.com>
6040
6041 * sysdeps/ia64/pthread_spin_lock.c (pthread_spin_lock): Use
6042 __sync_val_compare_and_swap, not explicit _si variant.
6043 * sysdeps/ia64/pthread_spin_trylock.c (pthread_spin_trylock): Likewise.
6044
1ad9da69
UD
60452005-05-03 Ulrich Drepper <drepper@redhat.com>
6046
6047 [BZ #915]
6048 * sysdeps/pthread/pthread.h: Avoid empty initializers.
6049
5085cd1f
UD
60502005-05-03 Jakub Jelinek <jakub@redhat.com>
6051
6052 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Remove explicit
6053 .eh_frame section, use cfi_* directives.
6054
ad529081
UD
60552005-04-27 Jakub Jelinek <jakub@redhat.com>
6056
6057 * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c: Use <> instead
6058 of "" includes.
6059
dea99685
UD
60602005-04-27 Ulrich Drepper <drepper@redhat.com>
6061
c06aad09 6062 [BZ #1075]
dea99685
UD
6063 * tst-cancel17.c (do_test): Add arbitrary factor to make sure
6064 aio_write blocks.
6065
84060bad
RM
60662005-04-27 Roland McGrath <roland@redhat.com>
6067
5e2d8ac8
RM
6068 * Makefile (tests): Remove tst-clock2.
6069
84060bad
RM
6070 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Handle
6071 CLOCK_PROCESS_CPUTIME_ID and CLOCK_PROCESS_THREAD_ID specially,
6072 translating to the kernel clockid_t for our own process/thread clock.
6073
6074 * sysdeps/unix/sysv/linux/pthread_getcpuclockid.c: New file.
6075
4a035b9d
RM
60762005-04-15 Jakub Jelinek <jakub@redhat.com>
6077
6078 * old_pthread_cond_init.c: Include <errno.h>.
6079 (__pthread_cond_init_2_0): Fail with EINVAL if COND_ATTR is
6080 process shared or uses clock other than CLOCK_REALTIME.
6081 * pthread_cond_init.c (__pthread_cond_init): Remove bogus comment.
6082
edac0e8f
UD
60832005-04-13 David S. Miller <davem@davemloft.net>
6084
6085 * sysdeps/sparc/sparc64/jmpbuf-unwind.h: New file.
6086 * sysdeps/sparc/sparc64/clone.S: New file.
6087
613d8d52
RM
60882005-04-05 Jakub Jelinek <jakub@redhat.com>
6089
44d75caf 6090 [BZ #1102]
613d8d52
RM
6091 * sysdeps/pthread/pthread.h (__pthread_cleanup_routine): Use
6092 __inline instead of inline.
6093 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_routine): Likewise.
6094
ee618985
UD
60952005-03-31 Jakub Jelinek <jakub@redhat.com>
6096
6097 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Use
6098 functionally equivalent, but shorter instructions.
6099 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
6100 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
6101 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
6102 Likewise.
6103 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise.
6104 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
6105 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
6106 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
6107 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
6108 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
6109 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
6110 Likewise.
6111 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
6112 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
6113 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
6114 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
6115 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
6116
f850220b
AJ
61172005-03-28 Daniel Jacobowitz <dan@codesourcery.com>
6118
6119 * sysdeps/mips/Makefile: New file.
6120 * sysdeps/mips/nptl-sysdep.S: New file.
6121 * sysdeps/mips/tcb-offsets.sym: New file.
6122 * sysdeps/mips/pthread_spin_lock.S: New file.
6123 * sysdeps/mips/pthread_spin_trylock.S: New file.
6124 * sysdeps/mips/pthreaddef.h: New file.
6125 * sysdeps/mips/tls.h: New file.
6126 * sysdeps/mips/jmpbuf-unwind.h: New file.
6127 * sysdeps/unix/sysv/linux/mips/lowlevellock.h: New file.
6128 * sysdeps/unix/sysv/linux/mips/bits/pthreadtypes.h: New file.
6129 * sysdeps/unix/sysv/linux/mips/bits/semaphore.h: New file.
6130 * sysdeps/unix/sysv/linux/mips/pthread_once.c: New file.
6131 * sysdeps/unix/sysv/linux/mips/fork.c: New file.
6132 * sysdeps/unix/sysv/linux/mips/pt-vfork.S: New file.
6133 * sysdeps/unix/sysv/linux/mips/vfork.S: New file.
6134 * sysdeps/unix/sysv/linux/mips/clone.S: New file.
6135 * sysdeps/unix/sysv/linux/mips/createthread.c: New file.
6136 * sysdeps/unix/sysv/linux/mips/sysdep-cancel.h: New file.
6137
1e6da2b0
UD
61382005-03-23 Ulrich Drepper <drepper@redhat.com>
6139
c06aad09 6140 [BZ #1112]
1e6da2b0
UD
6141 * pthread_create.c (__pthread_create_2_1): Rename syscall error
6142 variable to scerr.
6143
5233d576
RM
61442005-03-10 Jakub Jelinek <jakub@redhat.com>
6145
6146 * tst-getpid1.c (do_test): Align stack passed to clone{2,}.
6147
3053ff11
RM
61482005-02-25 Roland McGrath <roland@redhat.com>
6149
6150 * alloca_cutoff.c: Correct license text.
6151 * tst-unload.c: Likewise.
6152 * sysdeps/pthread/allocalim.h: Likewise.
6153 * sysdeps/pthread/pt-initfini.c: Likewise.
6154 * sysdeps/pthread/bits/libc-lock.h: Likewise.
6155 * sysdeps/pthread/bits/sigthread.h: Likewise.
6156 * sysdeps/unix/sysv/linux/bits/local_lim.h: Likewise.
6157 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
6158
9cfe5381
RM
61592005-02-16 Roland McGrath <roland@redhat.com>
6160
6161 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
6162 Use unsigned int * for ptr_nthreads.
6163
7de00121
RM
61642005-02-14 Alan Modra <amodra@bigpond.net.au>
6165
20d511e0 6166 [BZ #721]
7de00121
RM
6167 * sysdeps/powerpc/tcb-offsets.sym (thread_offsetof): Redefine to suit
6168 gcc4.
6169
4bae262d
UD
61702005-02-07 Richard Henderson <rth@redhat.com>
6171
613d8d52 6172 [BZ #787]
4bae262d
UD
6173 * sysdeps/pthread/pthread.h (__sigsetjmp): Use pointer as first
6174 argument.
6175
75df54b7
RM
61762004-11-03 Marcus Brinkmann <marcus@gnu.org>
6177
6178 * sysdeps/generic/lowlevellock.h (__generic_mutex_unlock): Fix
6179 order of arguments in invocation of atomic_add_zero.
6180
ea9c93cc
UD
61812005-01-26 Jakub Jelinek <jakub@redhat.com>
6182
9cfe5381 6183 [BZ #737]
ea9c93cc
UD
6184 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S (__new_sem_trywait):
6185 Use direct %gs segment access or, if NO_TLS_DIRECT_SEG_REFS,
6186 at least gotntpoff relocation and addition.
6187 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
6188 Likewise.
6189 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__new_sem_post):
6190 Likewise.
6191 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
6192 Likewise.
6193
9dcafc55
UD
61942005-01-06 Ulrich Drepper <drepper@redhat.com>
6195
6196 * allocatestack.c (init_one_static_tls): Adjust initialization of DTV
6197 entry for static tls deallocation fix.
6198 * sysdeps/alpha/tls.h (dtv_t): Change pointer type to be struct which
6199 also contains information whether the memory pointed to is static
6200 TLS or not.
6201 * sysdeps/i386/tls.h: Likewise.
6202 * sysdeps/ia64/tls.h: Likewise.
6203 * sysdeps/powerpc/tls.h: Likewise.
6204 * sysdeps/s390/tls.h: Likewise.
6205 * sysdeps/sh/tls.h: Likewise.
6206 * sysdeps/sparc/tls.h: Likewise.
6207 * sysdeps/x86_64/tls.h: Likewise.
6208
a71c152c
UD
62092004-12-27 Ulrich Drepper <drepper@redhat.com>
6210
6211 * init.c (__pthread_initialize_minimal_internal): Use __sigemptyset.
6212
d143c49e
UD
62132004-12-21 Jakub Jelinek <jakub@redhat.com>
6214
6215 * sysdeps/i386/tls.h (CALL_THREAD_FCT): Maintain 16 byte alignment of
6216 %esp.
6217 * Makefile (tests): Add tst-align2.
6218 * tst-align2.c: New test.
6219 * sysdeps/i386/Makefile (CFLAGS-tst-align{,2}.c): Add
6220 -mpreferred-stack-boundary=4.
6221
50130ded
RM
62222004-12-18 Roland McGrath <roland@redhat.com>
6223
6224 * sysdeps/unix/sysv/linux/powerpc/powerpc64/bits/local_lim.h:
6225 New file removed withdrawn for the moment.
6226
cbc53df0
RH
62272004-12-17 Richard Henderson <rth@redhat.com>
6228
6229 * sysdeps/unix/sysv/linux/alpha/clone.S: New file.
6230 * sysdeps/alpha/tcb-offsets.sym (TID_OFFSET): New.
50130ded 6231
fb9d5c73
UD
62322004-12-16 Ulrich Drepper <drepper@redhat.com>
6233
03332aa6
UD
6234 * sysdeps/unix/sysv/linux/powerpc/powerpc64/bits/local_lim.h: New file.
6235 Increased PTHREAD_STACK_MIN.
6236
fb9d5c73
UD
6237 * tst-context1.c (stacks): Use bigger stack size.
6238
e853ea00
UD
62392004-12-16 Jakub Jelinek <jakub@redhat.com>
6240
6241 * sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: New file.
6242 * sysdeps/sparc/tcb-offsets.sym: Add TID.
6243
f23673fc
UD
62442004-12-15 Jakub Jelinek <jakub@redhat.com>
6245
6246 * sysdeps/unix/sysv/linux/s390/s390-32/clone.S: New file.
6247 * sysdeps/unix/sysv/linux/s390/s390-64/clone.S: New file.
6248 * sysdeps/s390/tcb-offsets.sym (TID): Add.
6249
917fbe70
UD
62502004-12-15 Ulrich Drepper <drepper@redhat.com>
6251
6252 * sysdeps/unix/sysv/linux/powerpc/powerpc32/clone.S: New file.
6253
1f9d7c27
UD
62542004-12-14 Ulrich Drepper <drepper@redhat.com>
6255
6256 * sysdeps/powerpc/tcb-offsets.sym: Add TID.
6257 * sysdeps/unix/sysv/linux/powerpc/powerpc64/clone.S: New file.
6258
6259 * tst-getpid1.c: If child crashes, report this first. Print which
6260 signal.
6261
bf7c04cd
UD
62622004-12-09 Ulrich Drepper <drepper@redhat.com>
6263
6264 * init.c (__pthread_initialize_minimal_internal): Also unblock
6265 SIGSETXID.
6266
62672004-12-01 Jakub Jelinek <jakub@redhat.com>
6268
6269 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_CPUTIME,
6270 _POSIX_THREAD_CPUTIME): Define to 0.
6271 * sysdeps/pthread/timer_create.c (timer_create): Remove unused code
6272 handling CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID.
6273 * sysdeps/pthread/timer_routines.c (__timer_signal_thread_pclk,
6274 __timer_signal_thread_tclk): Remove.
6275 (init_module): Remove their initialization.
6276 (thread_cleanup): Remove their cleanup assertions.
6277 * sysdeps/pthread/posix-timer.h (__timer_signal_thread_pclk,
6278 __timer_signal_thread_tclk): Remove.
6279 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Removed.
75df54b7 6280 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Removed.
bf7c04cd
UD
6281 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Removed.
6282
484cc801
UD
62832004-12-07 Jakub Jelinek <jakub@redhat.com>
6284
6285 * sysdeps/ia64/tcb-offsets.sym (TID): Add.
6286 * sysdeps/unix/sysv/linux/ia64/clone2.S: New file.
6287
6288 * Makefile (tests): Add tst-getpid2.
6289 * tst-getpid1.c (TEST_CLONE_FLAGS): Define.
6290 (do_test): Use it. Use __clone2 instead of clone on ia64.
6291 * tst-getpid2.c: New test.
6292
2da9a6a1
UD
62932004-12-07 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6294
6295 * sysdeps/unix/sysv/linux/sh/clone.S: New file.
6296
1ff241b8
UD
62972004-12-04 Ulrich Drepper <drepper@redhat.com>
6298
6299 * Makefile (tests): Add tst-getpid1.
6300 * tst-getpid1.c: New file.
6301 * sysdeps/unix/sysv/linux/i386/clone.S: New file.
6302 * sysdeps/unix/sysv/linux/x86_64/clone.S: New file.
6303
3f488b9c
RM
63042004-12-02 Roland McGrath <roland@redhat.com>
6305
6306 * Makefile (libpthread-nonshared): Variable removed.
6307 ($(objpfx)libpthread_nonshared.a): Target removed.
6308 ($(inst_libdir)/libpthread_nonshared.a): Likewise.
6309 These are now handled by generic magic from
6310 libpthread-static-only-routines being set.
6311
597ce09c
UD
63122004-11-27 Ulrich Drepper <drepper@redhat.com>
6313
6314 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_PRIORITIZED_IO,
6315 _POSIX2_CHAR_TERM, _POSIX_THREAD_PRIO_INHERIT,
6316 _POSIX_THREAD_PRIO_PROTECT): Define.
6317 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
6318 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
6319 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
6320
60e4523a
UD
63212004-11-26 Jakub Jelinek <jakub@redhat.com>
6322
6323 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_ADVISORY_INFO,
6324 _POSIX_SPORADIC_SERVER, _POSIX_THREAD_SPORADIC_SERVER, _POSIX_TRACE,
6325 _POSIX_TRACE_EVENT_FILTER, _POSIX_TRACE_INHERIT, _POSIX_TRACE_LOG,
6326 _POSIX_TYPED_MEMORY_OBJECTS, _POSIX_IPV6, _POSIX_RAW_SOCKETS): Define.
6327 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
6328 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
6329 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
6330
f1f2cafc
UD
63312004-11-24 Ulrich Drepper <drepper@redhat.com>
6332
bca2d208
UD
6333 * sysdeps/x86_64/Makefile [nptl]: Define CFLAGS-pthread_create.c.
6334
f1f2cafc
UD
6335 * Makefile (libpthread-routines): Add pthread_setschedprio.
6336 * Versions [libpthread, GLIBC_2.3.4]: Add pthread_setschedprio.
6337 * sysdeps/pthread/pthread.h: Declare pthread_setschedprio.
6338 * pthread_setschedprio.c: New file.
6339
b639d0c9
UD
63402004-11-20 Jakub Jelinek <jakub@redhat.com>
6341
ef2bb413
UD
6342 * pthread_create.c (pthread_cancel): Add PTHREAD_STATIC_FN_REQUIRE.
6343 * pthread_cancel.c (pthread_create): Likewise.
6344
b639d0c9
UD
6345 * Makefile (libpthread-routines): Add vars.
6346 * sysdeps/pthread/createthread.c (__pthread_multiple_threads): Remove.
6347 * init.c (__default_stacksize, __is_smp): Remove.
6348 * vars.c: New file.
6349 * pthreadP.h (__find_thread_by_id): If !SHARED, add weak_function
6350 and define a wrapper macro.
6351 (PTHREAD_STATIC_FN_REQUIRE): Define.
6352 * allocatestack.c (__find_thread_by_id): Undefine.
6353 * pthread_create (__pthread_keys): Remove.
6354 (pthread_mutex_lock, pthread_mutex_unlock, pthread_once,
6355 pthread_key_create, pthread_setspecific, pthread_getspecific): Add
6356 PTHREAD_STATIC_FN_REQUIRE.
6357
3defcff3
UD
63582004-11-18 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6359
6360 * sysdeps/sh/tls.h (DB_THREAD_SELF): Set the correct bias
6361 parameter to REGISTER macro.
6362
ec188f92
RM
63632004-11-17 Roland McGrath <roland@redhat.com>
6364
6365 * sysdeps/unix/sysv/linux/timer_routines.c (__start_helper_thread):
6366 Make sure SIGCANCEL is blocked as well.
6367
ccd8de9a
UD
63682004-11-10 Jakub Jelinek <jakub@redhat.com>
6369
6370 * sysdeps/pthread/setxid.h: New file.
6371 * sysdeps/pthread/pthread-functions.h (HAVE_PTR__NPTL_SETXID): Remove.
6372 (struct xid_command): Add forward decl.
6373 (struct pthread_functions): Change return type of __nptl_setxid hook
6374 to int.
6375 * pthreadP.h (__nptl_setxid): Change return type to int.
6376 * allocatestack.c (__nptl_setxid): Call INTERNAL_SYSCALL_NCS in the
6377 calling thread, return its return value and set errno on failure.
6378 * descr.h (struct xid_command): Change id type to long array.
6379
6380 * Makefile: Add rules to build and test tst-setuid1 and
6381 tst-setuid1-static.
6382 * tst-setuid1.c: New test.
6383 * tst-setuid1-static.c: New test.
6384
ed2ced8a
UD
63852004-11-10 Jakub Jelinek <jakub@redhat.com>
6386
6387 * Makefile (tests): Add tst-exit3.
6388 * tst-exit3.c: New test.
6389
948603ee
UD
63902004-11-09 Ulrich Drepper <drepper@redhat.com>
6391
6392 * Makefile (tests): Add tst-exit2.
6393 * tst-exit2.c: New file.
6394
ba5ffd2a
RM
63952004-11-09 Roland McGrath <roland@redhat.com>
6396
6397 [BZ #530]
6398 * sysdeps/pthread/createthread.c (do_clone): Increment __nptl_nthreads
6399 here, before calling clone.
6400 * pthread_create.c (start_thread): Don't do it here.
6401
c4d7bd39
RM
64022004-11-02 Jakub Jelinek <jakub@redhat.com>
6403
6404 * sysdeps/unix/sysv/linux/smp.h: Include <errno.h>.
6405
543fb0c8
UD
64062004-10-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6407
6408 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait):
6409 Set ETIMEDOUT to errno when time is up. Tweak to avoid
6410 assembler warning.
6411
a1fbd858
UD
64122004-10-28 Jakub Jelinek <jakub@redhat.com>
6413
6414 * pthread_create.c (__pthread_create_2_1): Avoid leaking stacks
6415 if sched_priority is not between minprio and maxprio.
6416
c2a4357a
UD
64172004-10-25 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6418
6419 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
6420 (__pthread_cond_timedwait): Use clock_gettime syscall if exists.
6421
6422 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
6423 (__lll_mutex_timedlock_wait): Fix a bad branch condition.
6424
78d8d211
UD
64252004-10-24 Ulrich Drepper <drepper@redhat.com>
6426
6427 * sysdeps/unix/sysv/linux/smp.h (is_smp_system): Use
6428 not-cancelable I/O functions.
6429
dd28590f
UD
64302004-10-21 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6431
6432 * sysdeps/unix/sysv/linux/sh/lowlevellock.S
6433 (__lll_mutex_timedlock_wait): If woken but cannot get the lock,
6434 make sure 2 is stored in the futex and we looked at the old value.
6435 Fix a few other problems to return the correct value.
6436
f8c97af7
RH
64372004-10-14 Richard Henderson <rth@redhat.com>
6438
6439 * sysdeps/alpha/tcb-offsets.sym (thread_offsetof): Redefine to
6440 make gcc4 happy.
6441
3feb8efa
UD
64422004-10-06 Jakub Jelinek <jakub@redhat.com>
6443
6444 * sysdeps/unix/sysv/linux/jmp-unwind.c: Include pthreadP.h instead
6445 of pthread-functions.h and pthreaddef.h.
6446 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Likewise.
6447
6448 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
6449 Change __data.__nwaiters from int to unsigned int.
6450
6451 * tst-clock2.c (do_test): Don't fail if _POSIX_THREAD_CPUTIME == 0 and
6452 sysconf (_SC_THREAD_CPUTIME) returns negative value.
6453
6454 * allocatestack.c (__find_thread_by_id): Move attribute_hidden
6455 before return type.
6456
6457 * sysdeps/s390/jmpbuf-unwind.h: Include bits/wordsize.h.
6458 (JMPBUF_CFA_UNWINDS_ADJ): Subtract 96 resp. 160 bytes from CFA.
6459
67060ef5
UD
64602004-10-06 Ulrich Drepper <drepper@redhat.com>
6461
6462 * tst-cancel4.c (tf_msgrcv): Check for failure in msgget. If the
6463 test fails, remove message queue.
6464 (tf_msgsnd): Likewise.
6465
f38a3086
UD
64662004-10-05 Jakub Jelinek <jakub@redhat.com>
6467
6468 * tst-clock1.c: Change #ifdef to #if defined.
6469 * tst-clock2.c: Likewise.
6470 * tst-cond11.c: Likewise.
6471
2c03b6db
UD
6472 * sysdeps/pthread/timer_create.c (timer_create): Use
6473 defined _POSIX_CPUTIME && _POSIX_CPUTIME >= 0 instead of
6474 defined CLOCK_PROCESS_CPUTIME_ID #ifs and similarly for
6475 THREAD_CPUTIME.
6476
6ab5f50d
UD
64772004-10-05 Jakub Jelinek <jakub@redhat.com>
6478
6479 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h (_POSIX_CPUTIME,
6480 _POSIX_THREAD_CPUTIME): Define to 0.
6481
e4bb4853
UD
64822004-10-04 Ulrich Drepper <drepper@redhat.com>
6483
6484 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Define _POSIX_CPUTIME
6485 and _POSIX_THREAD_CPUTIME to zero.
6486 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Likewise.
6487 * tst-barrier2.c: Fix testing for POSIX feature.
6488 * tst-clock1.c: Likewise.
6489 * tst-clock2.c: Likewise.
6490 * tst-cond11.c: Likewise.
6491 * tst-cond4.c: Likewise.
6492 * tst-cond6.c: Likewise.
6493 * tst-flock2.c: Likewise.
6494 * tst-mutex4.c: Likewise.
6495 * tst-mutex9.c: Likewise.
6496 * tst-rwlock12.c: Likewise.
6497 * tst-rwlock4.c: Likewise.
6498 * tst-signal1.c: Likewise.
6499 * tst-spin2.c: Likewise.
6500 * sysdeps/pthread/posix-timer.h: Likewise.
6501 * sysdeps/pthread/timer_create.c: Likewise.
6502 * sysdeps/pthread/timer_routines.c: Likewise.
6503
c1b48791
UD
65042004-10-01 Ulrich Drepper <drepper@redhat.com>
6505
927f0673
UD
6506 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
6507 (__lll_mutex_timedlock_wait): Address futex correctly.
6508
c1b48791 6509 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
b610fa2d 6510 (__lll_mutex_timedlock_wait): If woken but cannot get the lock,
c1b48791
UD
6511 make sure 2 is stored in the futex and we looked at the old value.
6512 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
6513 (__lll_mutex_timedlock_wait): Likewise. Fix a few other problems
6514 which might very well made the code not working at all before.
7b87aca6 6515 [BZ #417]
c1b48791 6516
e9f4e844
UD
65172004-09-28 Ulrich Drepper <drepper@redhat.com>
6518
4f21c95d
UD
6519 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): Don't
6520 allow SIGSETXID to be sent.
6521 * sysdeps/pthread/sigaction.c (__sigaction): Don't allow action
6522 for SIGSETXID to be defined.
6523 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Make sure
6524 SIGSETXID cannot be blocked.
6525
e9f4e844
UD
6526 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
6527 Add __extension__ to long long types.
6528 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
6529 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
6530 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
6531 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
6532 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Likewise.
6533 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
6534 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
6535
5f66b766
UD
65362004-09-25 Ulrich Drepper <drepper@redhat.com>
6537
6538 * descr.h (struct pthread): Add stopped_start field.
6539 * sysdeps/pthread/createthread.c (create_thread): Set
6540 start_stopped flag in descriptor for new thread appropriately.
6541 * pthread_create.c (start_thread): Only take lock to be stopped on
6542 startup if stopped_start flag says so.
6543
362038b0
UD
65442004-09-24 Ulrich Drepper <drepper@redhat.com>
6545
3f80a99b
UD
6546 * pthread_create.c (__pthread_create_2_1): Remember whether thread
6547 is created detached and if yes, do not try to free the stack in case
6548 the thread creation failed.
6549 * sysdeps/pthread/createthread.c (do_clone): Free stack here if clone
6550 call fails. Don't depend on INTERNAL_SYSCALL_ERRNO return zero in
6551 case there has been no error. [BZ #405]
6552
362038b0
UD
6553 * pthread_create.c (start_thread): Don't wait for scheduler data
6554 etc to be set at the beginning of the function. The cancellation
6555 infrastructure must have been set up. And enable async
6556 cancellation before potentially going to sleep. [BZ #401]
6557
65f0beb9
UD
65582004-09-20 Ulrich Drepper <drepper@redhat.com>
6559
3c12b91a 6560 * Versions: Remove exports for pthread_set*id_np functions.
65f0beb9
UD
6561 * sysdeps/pthread/pthread.h: Remove pthread_set*id_np prototypes
6562 for now.
6563 * Makefile: Don't build pthread_set*id code for now.
6564
2edb61e3
UD
65652004-09-19 Ulrich Drepper <drepper@redhat.com>
6566
6567 * sysdeps/unix/sysv/linux/allocrtsig.c: Allocate second signal for
6568 internal use.
6569 * allocatestack.c (__nptl_setxid): New function.
6570 * descr.h (struct xid_command): Define type.
6571 * init.c (pthread_functions): Add ptr__nptl_setxid initialization.
6572 (sighandler_setxid): New function.
6573 (__pthread_initialize_minimal): Register sighandler_setxid for
6574 SIGCANCEL.
6575 * pt-allocrtsig.c: Update comment.
6576 * pthreadP.h: Define SIGSETXID. Declare __xidcmd variable.
6577 Declare __nptl_setxid.
6578 * sysdeps/pthread/pthread-functions.h: Add ptr__nptl_setxid.
6579 * sysdeps/pthread/pthread.h: Declare pthread_setgid_np,
6580 pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
6581 pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
6582 and pthread_setresuid_np.
6583 * pthread_setgid_np.c: New file.
6584 * pthread_setuid_np.c: New file.
6585 * pthread_setegid_np.c: New file.
6586 * pthread_seteuid_np.c: New file.
6587 * pthread_setregid_np.c: New file.
6588 * pthread_setreuid_np.c: New file.
6589 * pthread_setresgid_np.c: New file.
6590 * pthread_setresuid_np.c: New file.
6591 * Versions [libpthread, GLIBC_2.3.4]: Add pthread_setgid_np,
6592 pthread_setuid_np, pthread_setegid_np, pthread_seteuid_np,
6593 pthread_setregid_np, pthread_setreuid_np, pthread_setresgid_np,
6594 and pthread_setresuid_np.
6595 * Makefile (libpthread-routines): Add pthread_setuid, pthread_seteuid,
6596 pthread_setreuid, pthread_setresuid, pthread_setgid, pthread_setegid,
6597 pthread_setregid, and pthread_setresgid.
6598
1ab1fa6f
UD
65992004-09-18 Ulrich Drepper <drepper@redhat.com>
6600
6601 * allocatestack.c (allocate_stack): Return EAGAIN instead of
6602 ENOMEM when out of memory.
6603
ae9e6b36
RM
66042004-09-10 Roland McGrath <roland@redhat.com>
6605
6606 [BZ #379]
6607 * allocatestack.c (allocate_stack): Remove [__ASSUME_CLONE_STOPPED]
6608 code, since we don't try to use the broken CLONE_STOPPED any more.
6609 * pthread_create.c (start_thread): Likewise.
6610
424bd2f8
RH
66112004-09-15 Richard Henderson <rth@redhat.com>
6612
6613 * sysdeps/unix/sysv/linux/alpha/vfork.S: Use libc_hidden_def.
6614
17b8a52d
UD
66152004-09-01 David Mosberger <davidm@hpl.hp.com>
6616
6617 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h
6618 (__libc_unwind_longjmp): Delete macro and declare as function.
6619 * sysdeps/unix/sysv/linux/ia64/Makefile (sysdep_routines): Mention
6620 __ia64_longjmp, sigstack_longjmp, and __sigstack_longjmp for
6621 nptl directory.
6622 * sysdeps/unix/sysv/linux/ia64/__ia64_longjmp.S: New file.
6623 * sysdeps/unix/sysv/linux/ia64/__sigstack_longjmp.c: New file.
6624 * sysdeps/unix/sysv/linux/ia64/unwind_longjmp.c: New file.
6625
ccc63b07
UD
66262004-09-12 Ulrich Drepper <drepper@redhat.com>
6627
6628 * sysdeps/pthread/pthread.h: Make rwlock prototypes available also
6629 for __USE_XOPEN2K.
6630 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Define rwlock
6631 types also for __USE_XOPEN2K.
6632 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
6633 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
6634 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
6635 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
6636 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
6637 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
6638 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
6639 [BZ #320]
6640
31f93b3b
UD
66412004-09-08 Ulrich Drepper <drepper@redhat.com>
6642
6643 * sysdeps/pthread/pthread.h
6644 (PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP): Make safe for C++.
6645 (PTHREAD_ERRORCHECK_MUTEX_INITIALIZER_NP): Likewise.
6646 (PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP): Likewise.
6647 (PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP): Likewise.
6648 [BZ #375]
6649
e0329987
UD
66502004-09-07 Ulrich Drepper <drepper@redhat.com>
6651
590b40f7
UD
6652 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Allow
6653 PSEUDO to be used with . prefix.
6654
67254a97
UD
6655 * sysdeps/unix/sysv/linux/alpha/pthread_once.c (__pthread_once):
6656 Use atomic_increment instead of atomic_exchange_and_add.
6657 * sysdeps/unix/sysv/linux/sparc/pthread_once.c (__pthread_once):
6658 Likewise.
6659 * sysdeps/unix/sysv/linux/ia64/pthread_once.c (__pthread_once):
6660 Likewise.
6661 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (__pthread_once):
6662 Likewise.
6663
6664 * allocatestack.c (allocate_stack): Use atomic_increment_val
6665 instead of atomic_exchange_and_add.
6666 * sysdeps/unix/sysv/linux/sem_post.c (__new_sem_post): Likewise.
6667 * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__new_sem_post):
6668 Likewise.
6669 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
6670 Likewise.
6671
e0329987
UD
6672 * sysdeps/pthread/pthread.h (pthread_once): Remove __THROW since
6673 the initialization function might throw.
6674
42d86dd6 66752005-09-05 Richard Henderson <rth@redhat.com>
e0329987 6676
42d86dd6
RH
6677 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
6678 Move definition inside libpthread, libc, librt check. Provide
6679 definition for rtld.
6680
73f7c32c
UD
66812004-09-02 Ulrich Drepper <drepper@redhat.com>
6682
f76c8499
UD
6683 * sysdeps/alpha/jmpbuf-unwind.h: Define __libc_unwind_longjmp.
6684 * sysdeps/i386/jmpbuf-unwind.h: Likewise
6685 * sysdeps/powerpc/jmpbuf-unwind.h: Likewise.
6686 * sysdeps/s390/jmpbuf-unwind.h: Likewise.
6687 * sysdeps/sh/jmpbuf-unwind.h: Likewise.
6688 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: Likewise.
6689 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Likewise.
6690 * sysdeps/x86_64/jmpbuf-unwind.h: Likewise.
6691 * unwind.c: Use it.
6692
73f7c32c
UD
6693 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
6694 Rename __data.__clock to __data.__nwaiters, make it unsigned int.
6695 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
6696 Likewise.
6697 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
6698 Decrement __nwaiters. If pthread_cond_destroy has been called and
6699 this is the last waiter, signal pthread_cond_destroy caller and
6700 avoid using the pthread_cond_t structure after unlock.
6701 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
6702 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
6703 Read clock type from the least significant bits of __nwaiters instead
6704 of __clock.
6705 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
6706 * sysdeps/unix/sysv/linux/internaltypes.h: Define COND_CLOCK_BITS.
6707
67082004-08-31 Jakub Jelinek <jakub@redhat.com>
6709
6710 [BZ #342]
6711 * Makefile (tests): Add tst-cond20 and tst-cond21.
6712 * tst-cond20.c: New test.
6713 * tst-cond21.c: New test.
6714 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h
6715 (pthread_cond_t): Rename __data.__clock to __data.__nwaiters, make
6716 it unsigned int.
6717 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
6718 Likewise.
6719 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
6720 (pthread_cond_t): Likewise.
6721 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_cond_t):
6722 Likewise.
6723 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
6724 Likewise.
6725 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_cond_t):
6726 Likewise.
6727 * sysdeps/unix/sysv/linux/lowlevelcond.sym (cond_clock): Remove.
6728 (cond_nwaiters): New.
6729 (clock_bits): New.
6730 * pthread_cond_destroy.c (__pthread_cond_destroy): Return EBUSY
6731 if there are waiters not signalled yet.
6732 Wait until all already signalled waiters wake up.
6733 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Decrement
6734 __nwaiters. If pthread_cond_destroy has been called and this is the
6735 last waiter, signal pthread_cond_destroy caller and avoid using
6736 the pthread_cond_t structure after unlock.
6737 (__pthread_cond_wait): Increment __nwaiters in the beginning,
6738 decrement it when leaving. If pthread_cond_destroy has been called
6739 and this is the last waiter, signal pthread_cond_destroy caller.
6740 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
6741 Likewise. Read clock type from the least significant bits of
6742 __nwaiters instead of __clock.
6743 * pthread_condattr_setclock.c (pthread_condattr_setclock): Check
6744 whether clock ID can be encoded in COND_CLOCK_BITS bits.
6745 * pthread_condattr_getclock.c (pthread_condattr_getclock): Decode
6746 clock type just from the last COND_CLOCK_BITS bits of value.
6747 * pthread_cond_init.c (__pthread_cond_init): Initialize __nwaiters
6748 instead of __clock, just from second bit of condattr's value.
6749
409f7493
UD
67502004-08-30 Jakub Jelinek <jakub@redhat.com>
6751
6752 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Include
6753 bits/wordsize.h. Make the header match i386 header when __WORDSIZE
6754 != 64.
6755 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
6756
92c6ccd1
RM
67572004-08-15 Roland McGrath <roland@frob.com>
6758
6759 * pthread_atfork.c: Update copyright terms including special exception
6760 for these trivial files, which are statically linked into executables
6761 that use dynamic linking for the significant library code.
6762
4d004cfb
UD
67632004-08-09 Jakub Jelinek <jakub@redhat.com>
6764
6765 * DESIGN-rwlock.txt: Add decreasing of nr_readers_queued to
6766 pthread_rwlock_rdlock.
6767 * sysdeps/pthread/pthread_rwlock_rdlock (__pthread_rwlock_rdlock):
6768 Decrease __nr_readers_queued after reacquiring lock.
6769 * sysdeps/pthread/pthread_rwlock_timedrdlock
6770 (pthread_rwlock_timedrdlock): Likewise.
6771 Reported by Bob Cook <bobcook47@hotmail.com>.
6772
90595fb6
RM
67732004-08-11 Jakub Jelinek <jakub@redhat.com>
6774
6775 * tst-rwlock14.c (tf): Read main thread handle from *ARG
6776 before pthread_barrier_wait.
6777
fa46f7ab
UD
67782004-08-07 Ulrich Drepper <drepper@redhat.com>
6779
6780 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
6781 Remove unnecessary exception handling data.
6782
15ef4b55
UD
67832004-07-23 Jakub Jelinek <jakub@redhat.com>
6784
6785 [BZ #284]
6786 * sysdeps/pthread/pthread.h (pthread_getcpuclockid): Use __clockid_t
6787 instead of clockid_t.
6788
4fb907b7
RM
67892004-07-21 Roland McGrath <roland@redhat.com>
6790
6791 * Makefile ($(objpfx)multidir.mk): Use $(make-target-directory).
6792
67932004-07-19 Roland McGrath <roland@redhat.com>
6794
6795 * tst-cancel4.c (tf_waitid): Use WEXITED flag bit if available.
6796
8f73811b
RM
67972004-07-02 Roland McGrath <roland@redhat.com>
6798
6799 * configure: Don't exit.
6800
290639c3
UD
68012004-07-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6802
6803 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
6804 (__pthread_cond_timedwait): Check for invalid nanosecond in
6805 timeout value.
6806
8e5aaad9
UD
68072004-07-07 Ulrich Drepper <drepper@redhat.com>
6808
6809 * Makefile: Add rules to build and run tst-fini1.
6810 * tst-fini1.c: New file.
6811 * tst-fini1mod.c: New file.
6812
ce6e047f
UD
68132004-07-05 Ulrich Drepper <drepper@redhat.com>
6814
6815 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define NO_CANCELLATION
6816 if no cancellation support is needed.
6817 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
6818 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
6819 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
6820 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
6821 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
6822 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
6823 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
6824 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: Likewise.
6825 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: Likewise.
6826
6827 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Define __NR_futex
6828 only if not already defined.
6829
9b9ef823
UD
68302004-07-05 Jakub Jelinek <jakub@redhat.com>
6831
2dd18ce2
UD
6832 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_unlock): Use
6833 constraint "m" instead of "0" for futex.
6834
9b9ef823
UD
6835 * shlib-versions: Add powerpc64-.*-linux.*.
6836
38205402
UD
68372004-07-04 Jakub Jelinek <jakub@redhat.com>
6838
6839 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S
6840 (pthread_rwlock_timedrdlock): Use cmpq instead of cmpl to check
6841 for valid tv_nsec.
6842 * tst-rwlock14.c (do_test): Test for invalid tv_nsec equal to
6843 1 billion and 64-bit tv_nsec which is valid when truncated to 32
6844 bits.
6845
78a9c837
RM
68462004-06-29 Roland McGrath <roland@redhat.com>
6847
6848 * Banner: NPTL no longer has its own version number.
6849 * Makefile (nptl-version): Variable removed.
6850 * sysdeps/pthread/Makefile (CFLAGS-confstr.c): Set LIBPTHREAD_VERSION
6851 using $(version), the glibc version number.
6852
d3d35527
UD
68532004-06-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6854
6855 * sysdeps/unix/sysv/linux/sh/pthread_once.S (__pthread_once):
6856 Fix branch offset for a PLT entry.
6857 * sysdeps/unix/sysv/linux/sh/sem_post.S (__new_sem_post):
6858 Likewise.
6859 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait):
6860 Likewise.
6861 * sysdeps/unix/sysv/linux/sh/sem_trywait.S (__new_sem_trywait):
6862 Likewise.
6863 * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait):
6864 Likewise.
6865
346f18ae
UD
68662004-06-28 Jakub Jelinek <jakub@redhat.com>
6867
6868 * sysdeps/alpha/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Define
6869 unconditionally.
6870
f3a19754
UD
68712004-06-28 Jakub Jelinek <jakub@redhat.com>
6872
6873 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
6874 (pthread_rwlock_timedwrlock): Return EINVAL if tv_nsec is negative,
6875 instead of tv_sec.
6876 * sysdeps/pthread/pthread_rwlock_timedrdlock.c
6877 (pthread_rwlock_timedrdlock): Likewise.
6878
539842a4
UD
68792004-06-22 Jakub Jelinek <jakub@redhat.com>
6880
6881 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue):
6882 Set __r7 to val, not mutex.
6883
46f4c578
UD
68842004-06-27 Ulrich Drepper <drepper@redhat.com>
6885
6886 * Makefile: Add rules to build tst-rwlock14.
6887 * tst-rwlock14.c: New file.
6888
68892004-06-24 Boris Hu <boris.hu@intel.com>
6890
6891 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Add timeout validation
6892 check.
6893 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
6894
9898e99c
AJ
68952004-06-19 Andreas Jaeger <aj@suse.de>
6896
6897 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Fix
6898 assembler in last patch.
6899
7c3164bc
UD
69002004-06-17 Ulrich Drepper <drepper@redhat.com>
6901
6902 * sysdeps/pthread/pthread_cond_timedwait.c
6903 (__pthread_cond_timedwait): Also check for negativ nanoseconds.
6904 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
6905 (__pthread_cond_timedwait): Check for invalid nanosecond in
6906 timeout value.
6907 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
6908 * tst-cond19.c: New file.
6909 * Makefile: Add rules to build and run tst-cond19.
6910
72e61500
UD
69112004-06-15 Steven Munroe <sjmunroe@us.ibm.com>
6912
6913 * tst-context1.c (GUARD_PATTERN): Defined.
6914 (tst_context_t): Define struct containing ucontext_t & guard words.
6915 (ctx): Declare as an array of tst_context_t.
6916 (fct): Verify uc_link & guard words are still valid.
6917 (tf): Initialize guard words in ctx. Adjust ctx refs for new struct.
6918
7c370086
UD
69192004-06-13 Kaz Kojima <kkojima@rr.iij4u.or.jp>
6920
6921 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
6922 Add __data.__futex field, reshuffle __data.__clock.
6923 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S
6924 (__pthread_cond_signal): Increment __futex at the same time as
6925 __wakeup_seq or __total_seq. Pass address of __futex instead of
6926 address of low 32-bits of __wakeup_seq to futex syscall.
6927 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S
6928 (__pthread_cond_wait): Likewise. Pass __futex value from before
6929 releasing internal lock to FUTEX_WAIT.
6930 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S
6931 (__pthread_cond_timedwait): Likewise.
6932 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
6933 (FUTEX_CMP_REQUEUE): Define.
6934 (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
6935 Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
6936 Pass __futex value from before the unlock and __futex address instead
6937 of address of low 32-bits of __wakeup_seq to futex syscall.
6938 Fallback to FUTEX_WAKE all on any errors.
6939
a9e526e7
RM
69402004-06-08 Jakub Jelinek <jakub@redhat.com>
6941
6942 * pthread_mutexattr_getpshared.c (pthread_mutex_getpshared): Fix
6943 comment typo.
6944 * pthread_mutexattr_gettype.c (pthread_mutexattr_gettype): Likewise.
6945 * pthread_mutexattr_init.c (__pthread_mutexattr_init): Likewise.
6946 * pthread_mutexattr_settype.c (__pthread_mutexattr_settype): Likewise.
6947 * pthread_mutexattr_setpshared.c (pthread_mutexattr_setpshared):
6948 Likewise. Reported by Bob Cook <bobcook47@hotmail.com>.
6949
f1847a84
RM
69502004-06-11 Martin Schwidefsky <schwidefsky@de.ibm.com>
6951
6952 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_compare_and_swap):
6953 Add memory clobber to inline assembly.
6954 (__lll_mutex_trylock): Likewise.
6955 (__lll_mutex_cond_trylock): Likewise.
6956
f7c81e1a
UD
69572004-06-07 Martin Schwidefsky <schwidefsky@de.ibm.com>
6958
6959 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue):
6960 Pass val argument as 6th system call argument in %r7.
6961
75fccede
UD
69622004-05-21 Jakub Jelinek <jakub@redhat.com>
6963
6964 * Makefile (tests): Add tst-cond16.
6965 * sysdeps/unix/sysv/linux/lowlevelcond.sym (cond_futex): Add.
6966 * pthread_cond_init.c (__pthread_cond_init): Clear __data.__futex.
6967 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
6968 Add __data.__futex field, reshuffle __data.__clock.
6969 * sysdeps/unix/sysv/linux/i386/pthread_cond_signal.S
6970 (__pthread_cond_signal): Increment __futex at the same time as
6971 __wakeup_seq or __total_seq. Pass address of __futex instead of
6972 address of low 32-bits of __wakeup_seq to futex syscall.
6973 * sysdeps/unix/sysv/linux/i386/pthread_cond_wait.S
6974 (__pthread_cond_wait): Likewise. Pass __futex value from before
6975 releasing internal lock to FUTEX_WAIT.
6976 * sysdeps/unix/sysv/linux/i386/pthread_cond_timedwait.S
6977 (__pthread_cond_timedwait): Likewise.
6978 * sysdeps/unix/sysv/linux/i386/pthread_cond_broadcast.S
6979 (FUTEX_CMP_REQUEUE): Define.
6980 (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
6981 Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
6982 Pass __futex value from before the unlock and __futex address instead
6983 of address of low 32-bits of __wakeup_seq to futex syscall.
6984 Fallback to FUTEX_WAKE all on any errors.
6985 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (FUTEX_CMP_REQUEUE):
6986 Define.
6987 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
6988 internally. Return non-zero if error, zero if success.
6989 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_cond_t):
6990 Add __data.__futex field, reshuffle __data.__clock.
6991 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_CMP_REQUEUE):
6992 Define.
6993 (lll_futex_requeue): Add val argument, return 1 unconditionally
6994 for the time being.
6995 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
6996 Add __data.__futex field, reshuffle __data.__clock.
6997 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_CMP_REQUEUE):
6998 Define.
6999 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
7000 internally. Return non-zero if error, zero if success.
7001 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
7002 (pthread_cond_t): Add __data.__futex field, reshuffle __data.__clock.
7003 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h (FUTEX_CMP_REQUEUE):
7004 Define.
7005 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
7006 internally. Return non-zero if error, zero if success.
7007 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h (pthread_cond_t):
7008 Add __data.__futex field, reshuffle __data.__clock.
7009 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (FUTEX_CMP_REQUEUE):
7010 Define.
7011 (lll_futex_requeue): Add val argument, use FUTEX_CMP_REQUEUE
7012 internally. Return non-zero if error, zero if success.
7013 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h (pthread_cond_t):
7014 Add __data.__futex field, reshuffle __data.__clock.
7015 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h (pthread_cond_t):
7016 Add __data.__futex field, reshuffle __data.__clock.
7017 * sysdeps/pthread/pthread_cond_signal.c (__pthread_cond_signal):
7018 Increment __futex at the same time as __wakeup_seq or __total_seq.
7019 Pass address of __futex instead of address of low 32-bits of
7020 __wakeup_seq to futex syscall.
7021 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
7022 Pass __futex value from before releasing internal lock
7023 to FUTEX_WAIT.
7024 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
7025 Likewise. Avoid unnecessary shadowing of variables.
7026 * sysdeps/pthread/pthread_cond_broadcast.c (__pthread_cond_broadcast):
7027 Set __futex to 2 * __total_seq. Pass __futex value from before the
7028 unlock and __futex address instead of address of low 32-bits of
7029 __wakeup_seq to futex_requeue macro, adjust for new return value
7030 meaning.
7031 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S
7032 (__pthread_cond_signal): Increment __futex at the same time as
7033 __wakeup_seq or __total_seq. Pass address of __futex instead of
7034 address of low 32-bits of __wakeup_seq to futex syscall.
7035 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
7036 (__pthread_cond_wait): Likewise. Pass __futex value from before
7037 releasing internal lock to FUTEX_WAIT.
7038 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
7039 (__pthread_cond_timedwait): Likewise.
7040 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
7041 (FUTEX_CMP_REQUEUE): Define.
7042 (__pthread_cond_broadcast): Set __futex to 2 * __total_seq.
7043 Use FUTEX_CMP_REQUEUE operation instead of FUTEX_REQUEUE.
7044 Pass __futex value from before the unlock and __futex address instead
7045 of address of low 32-bits of __wakeup_seq to futex syscall.
7046 Fallback to FUTEX_WAKE all on any errors.
7047
70482004-06-03 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7049
7050 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_mutex_lock):
7051 Add nop to align the end of critical section.
7052 (lll_mutex_cond_lock, lll_mutex_timedlock): Likewise.
7053
fbf86dda
UD
70542004-06-01 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7055
7056 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
7057 Add __broadcast_seq field.
7058 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Mark
7059 all waiters as woken with woken_seq and bump broadcast counter.
7060 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Use new
7061 __broadcast_seq. Increment __woken_seq correctly when cleanuped.
7062 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
7063 Comment typo fixes. Avoid returning -ETIMEDOUT.
7064
70652004-06-01 Ulrich Drepper <drepper@redhat.com>
7066
7067 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
7068 (__condvar_tw_cleanup): Fix access to saved broadcast_seq value.
7069 Reported by Kaz Kojima.
7070
ffdd5e50
UD
70712004-05-25 Jakub Jelinek <jakub@redhat.com>
7072
7073 * sysdeps/unix/sysv/linux/aio_misc.h: New file.
7074
3abc82c8
UD
70752004-05-21 Jakub Jelinek <jakub@redhat.com>
7076
7077 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Compare
7078 __broadcast_seq with bc_seq after acquiring internal lock instead of
7079 before it.
7080
893a3511
UD
70812004-05-18 Jakub Jelinek <jakub@redhat.com>
7082
7083 * Makefile (.NOTPARALLEL): Only serialize make check/xcheck, not
7084 compilation.
7085 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
7086 (__pthread_cond_timedwait): Avoid returning -ETIMEDOUT.
7087 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
7088 (pthread_cond_t): Add __data.__broadcast_seq field.
7089 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
7090 (FRAME_SIZE): Define.
7091 (__pthread_cond_timedwait): Use it. Store/check broadcast_seq.
7092 Comment typo fixes.
7093 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S (FRAME_SIZE):
7094 Define.
7095 (__pthread_cond_wait): Use it. Store/check broadcast_seq. Comment
7096 typo fixes.
7097 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
7098 (__pthread_cond_broadcast): Increment broadcast_seq. Comment typo
7099 fixes.
7100
71012004-05-18 Ulrich Drepper <drepper@redhat.com>
7102
7103 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Add broadcast_seq entry.
7104 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_cond_t):
7105 Add __broadcast_seq field.
7106 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
7107 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
7108 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
7109 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
7110 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
7111 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Mark
7112 all waiters as woken with woken_seq and bump broadcast counter.
7113 * sysdeps/pthread/pthread_cond_broadcast.c: Likewise.
7114 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Use new
7115 __broadcast_seq field.
7116 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
7117 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
7118 * sysdeps/pthread/pthread_cond_timedwait.c: Likewise.
7119 * pthread_cond_init.c: Initialize __broadcast_seq field.
7120 * Makefile (tests): Add tst-cond17 and tst-cond18.
7121 Add .NOTPARALLEL goal.
7122 * tst-cond16.c: New file. From Jakub.
7123 * tst-cond17.c: New file. From Jakub.
7124 * tst-cond18.c: New file. From Jakub.
7125
4123718e
UD
71262004-05-16 Ulrich Drepper <drepper@redhat.com>
7127
7128 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Correct some
7129 unwind info.
7130
7131 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S:
7132 Parametrize frame size. Correct some unwind info.
7133 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
7134
2d7ae210
UD
71352004-05-04 Jakub Jelinek <jakub@redhat.com>
7136
7137 * tst-stack3.c: Note testing functionality beyond POSIX.
7138
50c2b6d7
UD
71392004-05-04 Jakub Jelinek <jakub@redhat.com>
7140
7141 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (USE___THREAD):
7142 Change conditional from ifdef to if.
7143
27b02589
UD
71442004-04-23 Jakub Jelinek <jakub@redhat.com>
7145
7146 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SYSDEP_CANCEL_ERRNO,
7147 SYSDEP_CANCEL_ERROR): Define.
7148 (PSEUDO): Use it.
7149
4bb8fc33
UD
71502004-05-01 Jakub Jelinek <jakub@redhat.com>
7151
7152 * Versions (libpthread): Remove __pthread_cleanup_upto@@GLIBC_PRIVATE.
7153
f9a06dc1
UD
71542004-04-20 Jakub Jelinek <jakub@redhat.com>
7155
7156 * sem_unlink.c (sem_unlink): Change EPERM into EACCES.
7157
d3b52028
UD
71582004-04-19 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7159
7160 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Add frame info.
7161 Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
7162 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Remove unneeded frame
7163 info. Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
7164
a5dd0a6c
UD
71652004-04-19 Ulrich Drepper <drepper@redhat.com>
7166
7167 * sysdeps/unix/sysv/linux/timer_routines.c: Make sure helper
7168 thread has all signals blocked.
7169
620c3354
AJ
71702004-04-18 Andreas Jaeger <aj@suse.de>
7171
7172 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h
7173 (SEM_VALUE_MAX): Add missing brace.
7174
1683daeb
UD
71752004-04-17 Jakub Jelinek <jakub@redhat.com>
7176
7177 * sysdeps/pthread/Makefile (tests): Add tst-mqueue8x
7178 in rt subdir.
7179 (CFLAGS-tst-mqueue8x.c): Add -fexceptions.
7180 * sysdeps/pthread/tst-mqueue8x.c: New test.
7181 * tst-cancel4.c: Update comment about message queues.
7182
7183 * sysdeps/pthread/timer_gettime.c (timer_gettime): For expired timer
7184 return it_value { 0, 0 }.
7185 * sysdeps/pthread/timer_create.c (timer_create): Handle SIGEV_NONE
7186 like SIGEV_SIGNAL.
7187 * sysdeps/pthread/timer_routines.c (thread_expire_timer): Remove
7188 assertion for SIGEV_NONE.
7189 (thread_attr_compare): Compare all attributes, not just a partial
7190 subset.
7191
71922004-04-17 Jakub Jelinek <jakub@redhat.com>
7193
7194 * sysdeps/unix/sysv/linux/mq_notify.c: Include stdlib.h.
7195
f532641d
UD
71962004-04-17 Ulrich Drepper <drepper@redhat.com>
7197
7198 * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h (SEM_VALUE_MAX):
7199 Just use a plain number.
7200 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h: Likewise.
7201 * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: Likewise.
7202 * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: Likewise.
7203 * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: Likewise.
7204 * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: Likewise.
7205 * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: Likewise.
7206 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: Likewise.
7207
7eb7fdda
UD
72082004-04-16 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7209
53392906
UD
7210 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Remove unneeded
7211 frame info.
7212 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
7eb7fdda 7213
d7ba1313
UD
72142004-04-15 Jakub Jelinek <jakub@redhat.com>
7215
7216 * sysdeps/unix/sysv/linux/timer_routines.c: Include errno.h.
7217 (timer_helper_thread): Use inline rt_sigtimedwait syscall instead
7218 of calling sigwaitinfo.
7219
5adac0e4
UD
72202004-04-16 Ulrich Drepper <drepper@redhat.com>
7221
7222 * allocatestack.c (allocate_stack): Set reported_guardsize
7223 unconditionally.
7224 * pthread_getattr_np.c (pthread_getattr_np): Use
7225 reported_guardsize instead of guardsize.
7226 * descr.h (struct pthread): Add reported_guardsize field.
7227
f93fa7d4
UD
72282004-04-13 Jakub Jelinek <jakub@redhat.com>
7229
7230 * sysdeps/unix/sysv/linux/mq_notify.c: Shut up GCC warning.
7231
1b82c6c7
UD
72322004-04-12 Ulrich Drepper <drepper@redhat.com>
7233
7234 * sysdeps/unix/sysv/linux/mq-notify.c: New file.
7235
72362004-04-08 Jakub Jelinek <jakub@redhat.com>
7237
7238 * sysdeps/unix/sysv/linux/bits/local_lim.h (MQ_PRIO_MAX): Define.
7239 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h (MQ_PRIO_MAX): Define.
7240 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h (MQ_PRIO_MAX): Define.
7241 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h (MQ_PRIO_MAX): Define.
7242 * sysdeps/unix/sysv/linux/bits/posix_opt.h (_POSIX_MESSAGE_PASSING):
7243 Define.
7244 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h
7245 (_POSIX_MESSAGE_PASSING): Define.
7246 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h
7247 (_POSIX_MESSAGE_PASSING): Define.
7248 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h
7249 (_POSIX_MESSAGE_PASSING): Define.
7250
e6eb894e
UD
72512004-04-04 Ulrich Drepper <drepper@redhat.com>
7252
7253 * tst-context1.c (fct): Check whether correct stack is used.
7254
1e084487
UD
72552004-04-03 Ulrich Drepper <drepper@redhat.com>
7256
4e73e115
UD
7257 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Never use
7258 matching constraints for asm mem parameters.
7259
1e084487
UD
7260 * tst-clock2.c (tf): Don't define unless needed.
7261
feca5e0b
UD
72622004-03-30 H.J. Lu <hongjiu.lu@intel.com>
7263
7264 * Makefile (link-libc-static): Use $(static-gnulib) instead of
7265 $(gnulib).
7266
3fa21fd8
UD
72672004-03-30 Ulrich Drepper <drepper@redhat.com>
7268
7269 * sysdeps/pthread/pthread-functions.h: Add ptr__nptl_deallocate_tsd.
7270 * init.c (pthread_functions): Add ptr__nptl_deallocate_tsd.
7271 * pthreadP.h: Declare __nptl_deallocate_tsd.
7272 * pthread_create.c (deallocate_tsd): Remove to __nptl_deallocate_tsd.
7273 Adjust caller.
7274
7275 * Makefile (tests): Add tst-tsd5.
7276 * tst-tsd5.c: New file.
7277
8e32efa6
UD
72782004-03-29 Ulrich Drepper <drepper@redhat.com>
7279
7280 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
7281 (__pthread_attr_setaffinity_old): Prepend GLIBC_ to version names
7282 is SHLIB_COMPAT check.
7283 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c
7284 (__pthread_attr_getaffinity_old): Likewise.
7285 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
7286 (__pthread_getaffinity_old): Likewise.
7287 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
7288 (__pthread_setaffinity_old): Likewise.
7289
eec8b6ca
UD
72902004-03-26 Ulrich Drepper <drepper@redhat.com>
7291
7292 * allocatestack.c (_make_stacks_executable): Call
7293 _dl_make_stack_executable first.
7294
db2f05ba
RM
72952004-03-24 Roland McGrath <roland@redhat.com>
7296
7297 * sysdeps/i386/pthread_spin_lock.c (pthread_spin_lock): Use "m"
7298 constraint instead of "0".
7299
6abbc501
UD
73002004-03-24 Ulrich Drepper <drepper@redhat.com>
7301
68dc4dcb
UD
7302 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
7303 (lll_mutex_cond_trylock): Define as wrapper around __lll_cond_trylock.
7304
6abbc501
UD
7305 * sysdeps/unix/sysv/linux/getpid.c (really_getpid): Reorganize
7306 code to avoid warning.
7307
865e14d9
AJ
73082004-03-24 Andreas Jaeger <aj@suse.de>
7309
7310 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
7311 (__pthread_attr_setaffinity_old): Remove const.
7312
16b06b70
UD
73132004-03-23 Ulrich Drepper <drepper@redhat.com>
7314
2c0b891a
UD
7315 * sysdeps/unix/sysv/linux/smp.h: New file.
7316 * sysdeps/unix/sysv/linux/sh/smp.h: New file.
7317 * init.c: Define __is_smp.
7318 (__pthread_initialize_minimal_internal): Call is_smp_system to
7319 initialize __is_smp.
7320 * pthreadP.h: Declare __is_smp.
7321 Define MAX_ADAPTIVE_COUNT is necessary.
7322 * pthread_mutex_init.c: Add comment regarding __spins field.
7323 * pthread_mutex_lock.c: Implement adaptive mutex type.
7324 * pthread_mutex_timedlock.c: Likewise.
7325 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Likewise.
7326 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h (pthread_mutex_t):
7327 Add __spins field.
7328 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
7329 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
7330 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
7331 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
7332 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
7333 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
7334 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
7335 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Define
7336 lll_mutex_cond_trylock.
7337 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
7338 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
7339 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
7340 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
7341 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
7342 Define BUSY_WAIT_NOP.
7343 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
7344 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
7345
7346 * tst-mutex5.c: Add support for testing adaptive mutexes.
7347 * tst-mutex7.c: Likewise.
7348 * tst-mutex5a.c: New file.
7349 * tst-mutex7a.c: New file.
7350 * Makefile (tests): Add tst-mutex5a and tst-mutex7a.
7351
565699e4
UD
7352 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
7353 (__lll_mutex_timedlock_wait): Preserve r8 and r9 since the
6abbc501 7354 vgettimeofday call might destroy the content.
565699e4 7355
7fe1586f
UD
7356 * sysdeps/ia64/pthread_spin_lock.c (pthread_spin_lock): Use hint
7357 @pause in the loop.
7358
e408880b
UD
7359 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_mutex_trylock):
7360 No need to restrict type of ret. Make it int. Add comment.
7361
16b06b70
UD
7362 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_mutex_trylock):
7363 Remove unnecessary setne instruction.
7364
61645263
UD
73652004-03-22 Jakub Jelinek <jakub@redhat.com>
7366
7367 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
7368 (__pthread_getaffinity_new): Use INT_MAX instead of UINT_MAX.
7369 * pthread_getattr_np.c (pthread_getattr_np): Double size every cycle.
7370 If realloc fails, break out of the loop.
7371
e3d4c585
AJ
73722004-03-20 Andreas Jaeger <aj@suse.de>
7373
7374 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
7375 (__pthread_setaffinity_old): Fix interface.
7376 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
7377 (__pthread_getaffinity_old): Likewise.
7378
7379 * sysdeps/unix/sysv/linux/pthread_setaffinity.c
7380 (__pthread_setaffinity_new): Remove duplicate declaration.
7381
3abb1ff7
UD
73822004-03-20 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7383
7384 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (CENABLE): Save
7385 the return value to a safe register.
7386 (CDISABLE): Set the function argument correctly.
7387
07bd2a3f
UD
73882004-03-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7389
7390 * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h (XCHG): Define.
7391 * sysdeps/unix/sysv/linux/sh/lowlevellock.S (__lll_mutex_lock_wait):
7392 Rewrite so that only one locked memory operation per round is needed.
7393 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S
7394 (pthread_barrier_wait): After wakeup, release lock only when the
7395 last thread stopped using the barrier object.
7396 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S
7397 (__pthread_cond_wait): Don't store mutex address if the current
7398 value is ~0l. Add correct cleanup support and unwind info.
7399 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
7400 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S
7401 (__pthread_cond_broadcast): Don't use requeue for pshared condvars.
7402 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Update comment.
7403 * sysdeps/unix/sysv/linux/sh/pthread_once.S (__pthread_once):
7404 Add correct cleanup support and unwind info.
7405 * sysdeps/unix/sysv/linux/sh/sem_wait.S (__new_sem_wait): Likewise.
7406 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Add unwind
7407 information for syscall wrappers.
7408
14c35863
UD
74092004-03-18 Ulrich Drepper <drepper@redhat.com>
7410
7411 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_attr): Add
7412 cpusetsize field, remove next.
7413 * sysdeps/pthread/pthread.h (pthread_getaffinity_np): Add new second
7414 parameter for size of the CPU set.
7415 (pthread_setaffinity_np): Likewise.
7416 (pthread_attr_getaffinity_np): Likewise.
7417 (pthread_attr_setaffinity_np): Likewise.
7418 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c: Implement
7419 interface change, keep compatibility code.
7420 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: Likewise.
7421 * sysdeps/unix/sysv/linux/pthread_getaffinity.c: Likewise.
7422 * sysdeps/unix/sysv/linux/pthread_setaffinity.c: Likewise.
7423 * pthreadP.h: Remove hidden_proto for pthread_getaffinity_np. Declare
7424 __pthread_getaffinity_np.
7425 * Versions: Add version for changed interfaces.
7426 * tst-attr3.c: Adjust test for interface change.
7427 * pthread_getattr_np.c: Query the kernel about the affinity mask with
7428 increasing buffer sizes.
7429 * pthread_attr_destroy.c: Remove unused list handling.
7430 * pthread_attr_init.c: Likewise.
7431
8e115d80
RM
74322004-03-17 Roland McGrath <roland@redhat.com>
7433
7434 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Pass missing
7435 first argument to clock_getres so we ever enable kernel timers.
7436
e3b22ad3
UD
74372004-03-15 Ulrich Weigand <uweigand@de.ibm.com>
7438
7439 * init.c (nptl_version): Add __attribute_used__ to nptl_version.
7440
841153fa
RH
74412004-03-12 Richard Henderson <rth@redhat.com>
7442
e3b22ad3
UD
7443 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: Propagate
7444 oldvalue from CENABLE to CDISABLE.
841153fa 7445
932dfea7
UD
74462004-03-12 Ulrich Drepper <drepper@redhat.com>
7447
7448 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define HOST_NAME_MAX.
7449 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: Likewise.
7450 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: Likewise.
7451 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: Likewise.
7452
9852f6dc
RH
74532004-03-11 Richard Henderson <rth@redhat.com>
7454
7455 * sysdeps/alpha/tcb-offsets.sym (PID_OFFSET): New.
7456 * sysdeps/unix/sysv/linux/alpha/pt-vfork.S: Save/restore PID.
7457 * sysdeps/unix/sysv/linux/alpha/vfork.S: New file.
7458
43513fb7
UD
74592004-03-11 Jakub Jelinek <jakub@redhat.com>
7460
7461 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Use jgnl
7462 instead of jnl instruction to jump to SYSCALL_ERROR_LABEL.
7463 * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S (__vfork): Likewise.
7464
74652004-03-11 Jakub Jelinek <jakub@redhat.com>
7466
7467 * forward.c (__pthread_cond_broadcast_2_0,
7468 __pthread_cond_destroy_2_0, __pthread_cond_init_2_0,
7469 __pthread_cond_signal_2_0, __pthread_cond_wait_2_0,
7470 __pthread_cond_timedwait_2_0): Use return 0 as defaction instead of 0.
7471
8a3e10e0
UD
74722004-03-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7473
7474 * sysdeps/sh/tcb-offsets.sym: Add PID.
7475 * sysdeps/unix/sysv/linux/sh/pt-vfork.S: Properly handle PID cache.
7476 * sysdeps/unix/sysv/linux/sh/vfork.S: New file.
7477
6d3a2bec
UD
74782004-03-10 Ulrich Drepper <drepper@redhat.com>
7479
7480 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: No need to
7481 include <sysdep-cancel.h>, vfork is no cancellation point.
7482 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: Likewise.
7483 * sysdeps/unix/sysv/linux/powerpc/powerpc64/pt-vfork.S: Likewise.
7484 * sysdeps/unix/sysv/linux/powerpc/powerpc32/pt-vfork.S: Likewise.
7485
d3a4a571
UD
74862004-03-10 Jakub Jelinek <jakub@redhat.com>
7487
73b4ce64
UD
7488 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S (__vfork): Add
7489 libc_hidden_def.
7490 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S (__vfork): Likewise.
7491 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S (__vfork):
7492 Likewise.
7493 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S (__vfork):
7494 Likewise.
7495 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S (__vfork): Likewise.
7496 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S (__vfork): Likewise.
7497 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Include tcb-offsets.h.
7498 * sysdeps/unix/sysv/linux/ia64/vfork.S (__vfork): Use DO_CALL instead
7499 of DO_CALL_VIA_BREAK. Work around a gas problem.
7500
d682a515
UD
7501 * sysdeps/unix/sysv/linux/powerpc/pt-vfork.S: Remove.
7502 * sysdeps/unix/sysv/linux/powerpc/powerpc32/vfork.S: New file.
7503 * sysdeps/unix/sysv/linux/powerpc/powerpc32/pt-vfork.S: New file.
7504 * sysdeps/unix/sysv/linux/powerpc/powerpc64/vfork.S: New file.
7505 * sysdeps/unix/sysv/linux/powerpc/powerpc64/pt-vfork.S: New file.
7506 * sysdeps/powerpc/tcb-offsets.sym: Add PID.
7507
7508 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S (__vfork): Don't use
7509 a local register for saving old PID. Negate PID in parent upon exit.
7510
d3a4a571
UD
7511 * sysdeps/unix/sysv/linux/s390/s390-32/pt-vfork.S: Include
7512 tcb-offsets.h.
7513 (__vfork): Negate PID if non-zero and set to INT_MIN if zero
7514 before syscall, set to the old value in the parent afterwards.
7515 * sysdeps/unix/sysv/linux/s390/s390-32/vfork.S: New file.
7516 * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S: Include
7517 tcb-offsets.h.
7518 (__vfork): Negate PID if non-zero and set to INT_MIN if zero
7519 before syscall, set to the old value in the parent afterwards.
7520 * sysdeps/unix/sysv/linux/s390/s390-64/vfork.S: New file.
7521 * sysdeps/s390/tcb-offsets.sym: Add PID.
7522
7523 * sysdeps/unix/sysv/linux/sparc/pt-vfork.S: Remove.
7524 * sysdeps/unix/sysv/linux/sparc/sparc32/vfork.S: New file.
7525 * sysdeps/unix/sysv/linux/sparc/sparc32/pt-vfork.S: New file.
7526 * sysdeps/unix/sysv/linux/sparc/sparc64/vfork.S: New file.
7527 * sysdeps/unix/sysv/linux/sparc/sparc64/pt-vfork.S: New file.
7528 * sysdeps/sparc/tcb-offsets.sym: Add PID.
7529
75302004-03-10 Andreas Schwab <schwab@suse.de>
7531
7532 * sysdeps/ia64/tcb-offsets.sym: Add PID.
7533 * sysdeps/unix/sysv/linux/ia64/vfork.S: New file.
7534 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Properly handle PID cache.
7535
3f2fb223 75362004-03-09 Jakub Jelinek <jakub@redhat.com>
f4c024d1 7537
3f2fb223
UD
7538 * tst-cancel20.c (do_one_test): Clear in_sh_body first.
7539 * tst-cancel21.c (do_one_test): Likewise.
7540 Reported by Gordon Jin <gordon.jin@intel.com>.
f4c024d1 7541
8b9d6054
UD
75422004-02-09 Jakub Jelinek <jakub@redhat.com>
7543
7544 * sysdeps/unix/sysv/linux/i386/vfork.S (SAVE_PID): Negate PID
7545 if non-zero and set to INT_MIN if zero.
7546 * sysdeps/unix/sysv/linux/x86_64/vfork.S (SAVE_PID): Likewise.
7547 * sysdeps/unix/sysv/linux/i386/pt-vfork.S: Include tcb-offsets.h.
7548 (SAVE_PID, RESTORE_PID): Define.
7549 (__vfork): Use it.
7550 * sysdeps/unix/sysv/linux/x86_64/pt-vfork.S: Include tcb-offsets.h.
7551 Use relative path to avoid including NPTL i386/vfork.S.
7552 (SAVE_PID, RESTORE_PID): Define.
7553 * sysdeps/unix/sysv/linux/raise.c: Include limits.h.
7554 (raise): Handle THREAD_SELF->pid INT_MIN the same as 0.
7555 * Makefile (tests): Add tst-vfork1, tst-vfork2, tst-vfork1x and
7556 tst-vfork2x.
7557 (tests-reverse): Add tst-vfork1x and tst-vfork2x.
7558 * tst-vfork1.c: New test.
7559 * tst-vfork2.c: New test.
7560 * tst-vfork1x.c: New test.
7561 * tst-vfork2x.c: New test.
7562
02287d05
UD
75632004-03-08 Ulrich Drepper <drepper@redhat.com>
7564
c072ef6d 7565 * sysdeps/i386/tcb-offsets.sym: Add PID.
6fadea9f 7566 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
c072ef6d 7567 * sysdeps/unix/sysv/linux/i386/vfork.S: New file.
6fadea9f 7568 * sysdeps/unix/sysv/linux/x86_64/vfork.S: New file.
02287d05 7569
d4acd24b
UD
75702004-03-08 Steven Munroe <sjmunroe@us.ibm.com>
7571
7572 * sysdeps/unix/sysv/linux/powerpc/Versions: Remove leading tabs.
7573
8acb4b81
UD
75742004-03-08 H.J. Lu <hongjiu.lu@intel.com>
7575
7576 * sysdeps/s390/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
7577 _rtld_global_ro.
7578
4d1a02ef
UD
75792004-03-07 Ulrich Drepper <drepper@redhat.com>
7580
001836c8 7581 * sysdeps/ia64/tls.h (INIT_SYSINFO): _dl_sysinfo is now in
8acb4b81 7582 _rtld_global_ro.
001836c8 7583
4d1a02ef
UD
7584 * tst-once4.c: Remove unnecessary macro definition.
7585
7586 * tst-mutex7.c (do_test): Limit thread stack size.
7587 * tst-once2.c (do_test): Likewise.
7588 * tst-tls3.c (do_test): Likewise.
7589 * tst-tls1.c (do_test): Likewise.
7590 * tst-signal3.c (do_test): Likewise.
7591 * tst-kill6.c (do_test): Likewise.
7592 * tst-key4.c (do_test): Likewise.
7593 * tst-join4.c (do_test): Likewise.
7594 * tst-fork1.c (do_test): Likewise.
7595 * tst-context1.c (do_test): Likewise.
7596 * tst-cond2.c (do_test): Likewise.
7597 * tst-cond10.c (do_test): Likewise.
7598 * tst-clock2.c (do_test): Likewise.
7599 * tst-cancel10.c (do_test): Likewise.
7600 * tst-basic2.c (do_test): Likewise.
7601 * tst-barrier4.c (do_test): Likewise.
7602
aa420660
UD
76032004-03-05 Ulrich Drepper <drepper@redhat.com>
7604
7605 * sysdeps/i386/tls.h: Use GLRO instead of GL where appropriate.
7606
cff08c81
UD
76072004-03-01 Ulrich Drepper <drepper@redhat.com>
7608
7609 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
7610 (__pthread_cond_timedwait): Optimize wakeup test.
7611 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
7612 (__pthread_cond_wait): Likewise.
7613 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
7614 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
7615 Likewise.
7616
b7fe377c
UD
76172004-02-29 Ulrich Drepper <drepper@redhat.com>
7618
7619 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
7620 (__lll_mutex_lock_wait): Optimize a bit more. Just one copy of
7621 the atomic instruction needed.
7622 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
7623 (__lll_mutex_lock_wait): Likewise.
7624
4c771a3b
UD
76252004-02-28 Ulrich Drepper <drepper@redhat.com>
7626
7627 * Makefile (tests): Add tst-cond14 and tst-cond15.
7628 * tst-cond14.c: New file.
7629 * tst-cond15.c: New file.
7630
a2c33d5a
UD
76312004-02-27 Ulrich Drepper <drepper@redhat.com>
7632
7633 * sysdeps/pthread/createthread.c (create_thread): Remove use of
7634 CLONE_STOPPED. We cannot use SIGCONT which means CLONE_STOPPED
7635 needs to be implemented differently to be useful.
7636
261eada2
UD
76372004-02-26 Ulrich Drepper <drepper@redhat.com>
7638
14ffbc83
UD
7639 * pthread_attr_setschedparam.c: Don't test priority against limits
7640 here. Set ATTR_FLAG_SCHED_SET flag.
7641 * pthread_attr_setschedpolicy.c: Set ATTR_FLAG_POLICY_SET flag.
7642 * pthread_create.c (__pthread_create_2_1): Copy scheduling attributes
7643 from parent thread to child. If attribute is used and scheduling
7644 parameters are not inherited, copy parameters from attribute or
7645 compute them. Check priority value.
7646 * pthread_getschedparam.c: If the parameters aren't known yet get
7647 them from the kernel.
7648 * pthread_setschedparam.c: Set ATTR_FLAG_SCHED_SET and
7649 ATTR_FLAG_POLICY_SET flag for thread.
7650 * sysdeps/unix/sysv/linux/internaltypes.h: Define ATTR_FLAG_SCHED_SET
7651 and ATTR_FLAG_POLICY_SET.
7652
7653 * sysdeps/pthread/createthread.c: Use tgkill if possible.
7654
261eada2
UD
7655 * pthread_attr_getstackaddr.c (__pthread_attr_getstackaddr): Don't
7656 fail if stack address hasn't been set. Just return 0.
7657
701d185c
UD
76582004-02-25 Ulrich Drepper <drepper@redhat.com>
7659
25b8e63c
UD
7660 * Makefile (tests-nolibpthread): Add tst-unload. Don't link with
7661 libpthread for the files in this list.
7662 (CFLAGS-tst-unload): Removed.
7663 * tst-unload.c (do_test): Don't use complete path for
7664 LIBPHREAD_SO.
7665
701d185c
UD
7666 * Makefile: Define sonames for tst-tls5mod, tst-_res1mod1, and
7667 tst-_res1mod2.
7668
a8fd5a02
UD
76692004-02-22 Ulrich Drepper <drepper@redhat.com>
7670
7671 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
7672 (__lll_mutex_lock_wait): Rewrite so that only one locked memory
7673 operation per round is needed.
7674 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S
7675 (__lll_mutex_lock_wait): Likewise.
7676
dd0b7b19
UD
76772004-02-20 Ulrich Drepper <drepper@redhat.com>
7678
7679 * tst-cancel9.c (cleanup): Don't print to stderr.
7680
5990e1fe
UD
76812004-02-20 Kaz Kojima <kkojima@rr.iij4u.or.jp>
7682
7683 * sysdeps/sh/jmpbuf-unwind.h (_JMPBUF_UNWINDS_ADJ): Fix variable name.
7684
33ab3b66
UD
76852004-02-20 Jakub Jelinek <jakub@redhat.com>
7686
1be3130e
UD
7687 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h
7688 (__syscall_error_handler2): Call CDISABLE.
7689 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h
7690 (__syscall_error_handler2): Call CDISABLE.
7691
8ba5025a
UD
7692 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
7693 Release lock before the loop, don't reacquire it.
8ba5025a 7694
33ab3b66
UD
7695 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h (DL_ARGV_NOT_RELRO): Define.
7696
11986c68
UD
76972004-02-19 Andreas Schwab <schwab@suse.de>
7698
7699 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
7700 Fix last change.
7701
dc391246
UD
77022004-02-18 Ulrich Drepper <drepper@redhat.com>
7703
37c054c7
UD
7704 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
7705 (pthread_barrier_wait): After wakeup, release lock only when the
7706 last thread stopped using the barrier object.
7707 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S
7708 (pthread_barrier_wait): Likewise.
7709 * sysdeps/pthread/pthread_barrier_wait.c (pthread_barrier_wait):
7710 Likewise.
7711 * Makefile (tests): Add tst-barrier4.
7712 * tst-barrier4.c: New file.
dc391246
UD
7713
7714 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
7715 (__pthread_cond_timedwait): Perform timeout test while holding
7716 internal lock to prevent wakeup race.
7717 Patch by Dinakar Guniguntala <dgunigun@in.ibm.com>.
7718 * sysdeps/pthread/pthread_cond_timedwait.c
7719 (__pthread_cond_timedwait): Likewise.
7720 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
7721 (__pthread_cond_timedwait): Likewise.
7722
4a08113c
UD
77232004-02-18 Jakub Jelinek <jakub@redhat.com>
7724
7725 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S
7726 (__pthread_rwlock_unlock): Access WRITER as 32-bit value.
7727 * Makefile (tests): Add tst-rwlock13.
7728 * tst-rwlock13.c: New test.
7729
71b1675e
UD
77302004-02-16 Ulrich Drepper <drepper@redhat.com>
7731
7732 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
7733 (__condvar_tw_cleanup): Little optimization.
7734 Patch by Dinakar Guniguntala <dgunigun@in.ibm.com>.
7735
cd9fdc72
UD
77362004-02-16 Steven Munroe <sjmunroe@us.ibm.com>
7737
7738 * sysdeps/unix/sysv/linux/powerpc/pt-longjmp.c: Replace libc with
7739 libpthread as "lib" parameter to SHLIB_COMPAT.
7740 (__novmx_siglongjmp): Fix typo in function name.
7741 (__novmx_longjmp): Fix typo in function name.
7742
82038750
UD
77432004-02-13 Ulrich Drepper <drepper@redhat.com>
7744
b078c591
UD
7745 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Add a
7746 __builtin_expect.
7747
82038750
UD
7748 * sysdeps/generic/pt-longjmp.c: Moved to...
7749 * sysdeps/pthread/pt-longjmp.c: ...here. New file.
7750
e2982bf0
UD
77512004-01-29 Steven Munroe <sjmunroe@us.ibm.com>
7752
7753 * Makefile (libpthread-routines): Add pt-cleanup.
7754 * pt-longjmp.c: Removed.
7755 * pt-cleanup.c: Copied __pthread_cleanup_upto to here. New file.
7756 * sysdeps/generic/pt-longjmp.c: Copied longjmp to here. New file.
7757 * sysdeps/unix/sysv/linux/powerpc/Versions: New file.
7758 Version longjmp, siglongjmp for GLIBC_2.3.4.
7759 * sysdeps/unix/sysv/linux/powerpc/pt-longjmp.c: New File.
7760
3730d95c
UD
77612004-02-13 Ulrich Drepper <drepper@redhat.com>
7762
219304ec
UD
7763 * sysdeps/pthread/pthread_cond_timedwait.c
7764 (__pthread_cond_timedwait): Optimize. Drop internal lock earlier.
7765 Reuse code. Add __builtin_expects.
7766
3730d95c
UD
7767 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
7768 (__pthread_cond_timedwait): Get internal lock in case timeout has
7769 passed before the futex syscall.
7770 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
7771
5673ccc1
UD
77722004-01-20 Ulrich Drepper <drepper@redhat.com>
7773
debddf64
UD
7774 * allocatestack.c: Pretty printing.
7775
5673ccc1
UD
7776 * sysdeps/pthread/createthread.c (create_thread): Don't add
7777 CLONE_DETACHED bit if it is not necessary.
7778
6bae8725
UD
77792004-01-16 Ulrich Drepper <drepper@redhat.com>
7780
7781 * pthread_getattr_np.c: Include ldsodefs.h.
7782
ff151400
RH
77832004-01-16 Richard Henderson <rth@redhat.com>
7784
6bae8725
UD
7785 * allocatestack.c: Don't declare __libc_stack_end.
7786 * init.c (__pthread_initialize_minimal_internal): Likewise.
7787 * pthread_getattr_np.c (pthread_getattr_np): Likewise.
ff151400 7788
ba683832
RH
77892004-01-15 Richard Henderson <rth@redhat.com>
7790
7791 * sysdeps/alpha/tls.h (tcbhead_t): Add private.
7792 (TLS_INIT_TCB_SIZE, TLS_INIT_TCB_ALIGN, TLS_TCB_SIZE,
7793 TLS_PRE_TCB_SIZE, TLS_TCB_ALIGN, INSTALL_DTV, INSTALL_NEW_DTV,
7794 GET_DTV, THREAD_DTV, THREAD_SELF, DB_THREAD_SELF): Match ia64.
7795 (TLS_TCB_OFFSET, THREAD_ID, NO_TLS_OFFSET): Remove.
7796 (THREAD_GETMEM, THREAD_GETMEM_NC): Simplify.
7797 (THREAD_SETMEM, THREAD_SETMEM_NC): Likewise.
7798 * sysdeps/unix/sysv/linux/alpha/createthread.c (TLS_VALUE): Match ia64.
7799
630d93a7
UD
78002004-01-14 Ulrich Drepper <drepper@redhat.com>
7801
219304ec 7802 * init.c (pthread_functions): Make array const.
630d93a7 7803
d1fc817e
UD
78042004-01-13 Ulrich Drepper <drepper@redhat.com>
7805
7806 * allocatestack.c (__make_stacks_executable): Change interface.
7807 Check parameters. Pass parameter on to libc counterpart.
7808 * pthreadP.h: Change declaration.
7809
dc927809
RH
78102004-01-13 Richard Henderson <rth@redhat.com>
7811
10677727
UD
7812 * pthread_attr_setstack.c (__old_pthread_attr_setstack): Use
7813 prototype form.
7814 * pthread_attr_setstacksize.c (__old_pthread_attr_setstacksize):
7815 Likewise.
7816
d1fc817e
UD
7817 * sysdeps/alpha/Makefile: New file.
7818 * sysdeps/alpha/tcb-offsets.sym: New file.
7819 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h (SINGLE_THREAD_P):
7820 Use MULTIPLE_THREADS_OFFSET to implement !libpthread !libc version.
dc927809 7821
d1fc817e
UD
7822 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: Rewrite based
7823 on powerpc version.
dc927809 7824
249a3d0c
UD
78252004-01-08 Jakub Jelinek <jakub@redhat.com>
7826
7827 * Makefile (tests): Add tst-backtrace1.
7828 * tst-backtrace1.c: New test.
7829
763c0490
RM
78302003-12-11 Ulrich Weigand <uweigand@de.ibm.com>
7831
7832 * sysdeps/alpha/tls.h (DB_THREAD_SELF): Pass bit size of thread
7833 register as second parameter to the REGISTER macro.
7834 * sysdeps/ia64/tls.h (DB_THREAD_SELF): Likewise.
7835 * sysdeps/powerpc/tls.h (DB_THREAD_SELF): Likewise.
7836 * sysdeps/sh/tls.h (DB_THREAD_SELF): Likewise.
7837 * sysdeps/sparc/tls.h (DB_THREAD_SELF): Likewise.
7838 * sysdeps/s390/tls.h (DB_THREAD_SELF): Pass __WORDSIZE as bit size
7839 of thread register as second parameter to REGISTER macro in 64 case.
7840
c7baafd5
UD
78412004-01-03 Ulrich Drepper <drepper@redhat.com>
7842
7843 * sysdeps/unix/sysv/linux/Makefile (CFLAGS-getpid.c): Removed.
7844 (CFLAGS-getpid.o): Defined.
7845 (CFLAGS-getpid.os): Defined.
7846
25ac0258
UD
78472003-12-31 Ulrich Drepper <drepper@redhat.com>
7848
7849 * pthread_getattr_np.c (pthread_getattr_np): Make sure stack info
7850 returned for main thread does not overlap with any other VMA.
7851 Patch by Jakub Jelinek.
7852
795985e4
UD
78532003-12-29 Jakub Jelinek <jakub@redhat.com>
7854
7855 * tst-raise1.c: Include stdio.h.
7856
cb5b9388
UD
78572003-12-23 Jakub Jelinek <jakub@redhat.com>
7858
7859 * sysdeps/unix/sysv/linux/raise.c (raise): Protect pid = selftid
7860 setting with __ASSUME_TGKILL || defined __NR_tgkill.
7861 If pid is 0, set it to selftid.
7862 * sysdeps/unix/sysv/linux/getpid.c (really_getpid): Make inline.
7863 Don't set self->pid but self->tid. If self->pid == 0 and self->tid
7864 != 0, return self->tid without doing a syscall.
7865 * descr.h (struct pthread): Move pid field after tid.
7866
7867 * Makefile (tests): Add tst-raise1.
7868 * tst-raise1.c: New file.
7869
432aaf5b
RM
78702003-12-23 Roland McGrath <roland@redhat.com>
7871
7872 * tst-oddstacklimit.c: New file.
7873 * Makefile (tests): Add it.
7874 (tst-oddstacklimit-ENV): New variable.
7875
7876 * init.c (__pthread_initialize_minimal_internal): Round stack rlimit
7877 value up to page size for __default_stacksize.
7878
33ebea17
UD
78792003-12-21 Ulrich Drepper <drepper@redhat.com>
7880
7881 * Makefile (tests): Add tst-eintr5.
7882 * tst-eintr5.c: New file.
7883
7884 * eintr.c (eintr_source): Prevent sending signal to self.
7885
7886 * tst-eintr2.c (tf1): Improve error message.
7887
bbe35eb5
UD
78882003-12-20 Ulrich Drepper <drepper@redhat.com>
7889
7890 * sysdeps/unix/sysv/linux/Makefile (CFLAGS-getpid.c): Define.
7891 * sysdeps/unix/sysv/linux/getpid.c: New file.
c0ecb80a
UD
7892 * pthread_cancel.c: Add comment explaining use of PID field.
7893 * sysdeps/unix/sysv/linux/pthread_kill.c: Likewise.
7894 * pthread_getattr_np.c: Use abs() when comparing PID and TID fields.
7895 * sysdeps/unix/sysv/linux/fork.c: Negate PID field of parent
7896 temporarily to signal the field must not be relied on and updated
7897 by getpid().
7898 * sysdeps/unix/sysv/linux/pt-raise.c: Handle case where PID is
7899 temporarily negative.
7900 * sysdeps/unix/sysv/linux/raise.c: Likewise.
bbe35eb5 7901
4efdd8d3
UD
79022003-12-19 Ulrich Drepper <drepper@redhat.com>
7903
7904 * eintr.c (setup_eintr): Add new parameter. Pass to thread function.
7905 (eintr_source): If ARG != NULL, use pthread_kill.
7906 * tst-eintr1.c: Adjust for this change.
7907 * tst-eintr2.c: Likewise.
7908 * Makefile (tests): Add tst-eintr3 and tst-eintr4.
7909 * tst-eintr3.c: New file.
7910 * tst-eintr4.c: New file.
7911
79122003-12-19 Jakub Jelinek <jakub@redhat.com>
7913
7914 * libc-cancellation.c (__libc_enable_asynccancel): Don't cancel
7915 if CANCELSTATE_BITMASK is set.
7916 * sysdeps/pthread/librt-cancellation.c (__librt_enable_asynccancel):
7917 Likewise.
7918
7919 * Makefile (tests): Add tst-cancel22 and tst-cancel23.
7920 (tests-reverse): Add tst-cancel23.
7921 * tst-cancel22.c: New test.
7922 * tst-cancel23.c: New test.
7923
675620f7
UD
79242003-12-18 Ulrich Drepper <drepper@redhat.com>
7925
7926 * tst-eintr1.c: Better error messages.
7927
7928 * Makefile (tests): Add tst-eintr2.
7929 * tst-eintr2.c: New file.
7930
79312003-12-18 Jakub Jelinek <jakub@redhat.com>
7932
7933 * Makefile (tests): Add tst-cancel21 and tst-cancelx21.
7934 (CFLAGS-tst-cancelx21.c): Set.
7935 * tst-cancel21.c: New test.
7936 * tst-cancelx21.c: New test.
7937
7938 * unwind.c (FRAME_LEFT): Add adj argument. Subtract it from each
7939 comparison operand.
7940 (unwind_stop): Use _JMPBUF_CFA_UNWINDS_ADJ macro instead of
7941 _JMPBUF_CFA_UNWINDS. Adjust FRAME_LEFT invocations.
7942 * pt-longjmp.c: Include jmpbuf-unwind.h.
7943 (__pthread_cleanup_upto): Use _JMPBUF_UNWINDS_ADJ macro instead of
7944 _JMPBUF_UNWINDS. Adjust compared pointers.
7945 * init.c (__pthread_initialize_minimal_internal): Initialize
7946 pd->stackblock_size.
7947 * sysdeps/pthread/jmpbuf-unwind.h: Removed.
7948 * sysdeps/alpha/jmpbuf-unwind.h: New file.
7949 * sysdeps/i386/jmpbuf-unwind.h: New file.
7950 * sysdeps/powerpc/jmpbuf-unwind.h: New file.
7951 * sysdeps/s390/jmpbuf-unwind.h: New file.
7952 * sysdeps/sh/jmpbuf-unwind.h: New file.
7953 * sysdeps/sparc/sparc32/jmpbuf-unwind.h: New file.
7954 * sysdeps/x86_64/jmpbuf-unwind.h: New file.
2e5e031d 7955 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: Include stdint.h.
675620f7
UD
7956 (_JMPBUF_CFA_UNWINDS): Remove.
7957 (_JMPBUF_CFA_UNWINDS_ADJ, _JMPBUF_UNWINDS_ADJ): Define.
7958
79592003-12-12 Jakub Jelinek <jakub@redhat.com>
7960
7961 * Makefile (tests): Add tst-cancel20 and tst-cancelx20.
7962 (CFLAGS-tst-cancelx20.c): Set.
7963 * tst-cancel20.c: New test.
7964 * tst-cancelx20.c: New test.
7965
2d951ab6
UD
79662003-12-17 Ulrich Drepper <drepper@redhat.com>
7967
7968 * init.c (__pthread_initialize_minimal_internal): Don't treat
7969 architectures with separate register stack special here when
7970 computing default stack size.
7971
f8a3a2e7
RM
79722003-12-17 Roland McGrath <roland@redhat.com>
7973
7974 * Makefile (tst-cancelx7-ARGS): New variable.
7975 Reportd by Greg Schafer <gschafer@zip.com.au>.
7976
e796f92f
UD
79772003-12-17 Jakub Jelinek <jakub@redhat.com>
7978
7979 * Makefile (tests): Add tst-stack3. Depend on $(objpfx)tst-stack3-mem.
7980 (generated): Add tst-stack3.mtrace and tst-stack3-mem.
7981 (tst-stack3-ENV): Set.
7982 ($(objpfx)tst-stack3-mem): New.
7983 * tst-stack3.c: New test.
7984
092eb73c
UD
79852003-12-10 David Mosberger <davidm@hpl.hp.com>
7986
7987 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c (_init_EPILOG_BEGINS):
7988 Add unwind directives. Drop unused .regstk directive.
7989 (_fini_EPILOG_BEGINS): Add unwind directives.
7990
ff48874d
UD
79912003-12-11 Ulrich Drepper <drepper@redhat.com>
7992
7993 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_futex_wait):
7994 Assume parameter is a pointer.
7995 (lll_futex_wake): Likewise.
20945457
UD
7996 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_futex_wait):
7997 Likewise.
7998 (lll_futex_wake): Likewise.
ff48874d
UD
7999 Reported by Boris Hu.
8000 * sysdeps/unix/sysv/linux/unregister-atfork.c
8001 (__unregister_atfork): Pass pointer to refcntr to lll_futex_wait.
8002
8003 * sysdeps/unix/sysv/linux/sem_wait.c (__new_sem_wait): Simplify a bit.
8004
1d9d0b80
UD
80052003-12-10 Ulrich Drepper <drepper@redhat.com>
8006
8007 * sysdeps/pthread/bits/libc-lock.h (__rtld_lock_initialize): Define.
8008 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Call
8009 __rtld_lock_initialize for ld.so lock.
8010 Patch in part by Adam Li <adam.li@intel.com>.
8011
c776b3d7
UD
80122003-12-02 David Mosberger <davidm@hpl.hp.com>
8013
8014 * Makefile (link-libc-static): Remove -lgcc_eh---it's already mentioned
8015 in $(gnulib). Also, remove stale comment.
8016
80172003-11-12 David Mosberger <davidm@hpl.hp.com>
8018
8019 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO): Take
8020 advantage of new syscall stub and optimize accordingly.
8021
8022 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__NR_futex): Rename
8023 from SYS_futex, to match expectations of
8024 sysdep.h:DO_INLINE_SYSCALL.
8025 (lll_futex_clobbers): Remove.
8026 (lll_futex_timed_wait): Rewrite in terms of DO_INLINE_SYSCALL.
8027 (lll_futex_wake): Likewise.
8028 (lll_futex_requeue): Likewise.
8029 (__lll_mutex_trylock): Rewrite to a macro, so we can include this
8030 file before DO_INLINE_SYSCALL is defined (proposed by Jakub
8031 Jelinek).
8032 (__lll_mutex_lock): Likewise.
8033 (__lll_mutex_cond_lock): Likewise.
8034 (__lll_mutex_timed_lock): Likewise.
8035 (__lll_mutex_unlock): Likewise.
8036 (__lll_mutex_unlock_force): Likewise.
8037
8038 * sysdeps/ia64/tls.h: Move declaration of __thread_self up so it
8039 comes before the include of <sysdep.h>.
8040 (THREAD_SELF_SYSINFO): New macro.
8041 (THREAD_SYSINFO): Likewise.
8042 (INIT_SYSINFO): New macro.
8043 (TLS_INIT_TP): Call INIT_SYSINFO.
8044
8045 * sysdeps/ia64/tcb-offsets.sym: Add SYSINFO_OFFSET.
8046
8047 * sysdeps/pthread/createthread.c (create_thread): Use
8048 THREAD_SELF_SYSINFO and THREAD_SYSINFO instead of open code.
8049 * allocatestack.c (allocate_stack): Use THREAD_SYSINFO and
8050 THREAD_SELF_SYSINFO instead of open code.
8051 * sysdeps/i386/tls.h (THREAD_SELF_SYSINFO): New macro.
8052 (THREAD_SYSINFO): Likewise.
8053
8054 * sysdeps/unix/sysv/linux/ia64/dl-sysdep.h: New file.
8055
8056 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: Work around gas problem.
8057
57d20ee7
UD
80582003-12-06 Ulrich Drepper <drepper@redhat.com>
8059
8060 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: Use .init_array
8061 instead of .init. Patch by David Mosberger.
8062
67aeab2a
AJ
80632003-11-30 Thorsten Kukuk <kukuk@suse.de>
8064
8065 * sysdeps/pthread/configure.in: Remove broken declaration in C
8066 cleanup handling check.
8067
8ca203e6
AJ
80682003-11-30 Andreas Jaeger <aj@suse.de>
8069
8070 * Makefile (CFLAGS-pt-initfini.s): Add $(fno_unit_at_a_time).
8071 * sysdeps/unix/sysv/linux/x86_64/Makefile (CFLAGS-pt-initfini.s):
8072 Likewise.
8073
46bf9de7
UD
80742003-11-27 Jakub Jelinek <jakub@redhat.com>
8075
8076 * sysdeps/unix/sysv/linux/internaltypes.h (ATTR_FLAG_OLDATTR): Define.
8077 * pthread_attr_destroy.c: Include shlib-compat.h.
8078 (__pthread_attr_destroy): Return immediately if ATTR_FLAG_OLDATTR
8079 is set in iattr->flags.
8080 * pthread_attr_init.c (__pthread_attr_init_2_0): Set ATTR_FLAG_OLDATTR.
8081
1d9b73ab
UD
80822003-11-21 Jakub Jelinek <jakub@redhat.com>
8083
8084 * Makefile (distribute): Add tst-cleanup4aux.c.
8085
8086 * tst-cond12.c (prepare): Add prototype. Move after test-skeleton.c
8087 include.
8088
53f9084e
UD
80892003-11-21 Ulrich Drepper <drepper@redhat.com>
8090
1d9b73ab
UD
8091 * tst-cond12.c (do_test): If USE_COND_SIGNAL is defined, use
8092 pthread_cond_signal.
8093
e42a990e
UD
8094 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Don't
8095 store mutex address if the current value is ~0l.
8096 * sysdeps/pthread/pthread_cond_timedwait.c
8097 (__pthread_cond_timedwait): Likewise.
8098 * sysdeps/pthread/pthread_cond_broadcast.c
8099 (__pthread_cond_broadcast): Don't use requeue for pshared
8100 condvars.
8101
8102 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
8103 (__pthread_cond_wait): Don't store mutex address if the current
8104 value is ~0l.
8105 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S
8106 (__pthread_cond_timedwait): Likewise.
8107 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S
8108 (__pthread_cond_broadcast): Don't use requeue for pshared
8109 condvars.
8110
8111 * pthread_cond_init.c (__pthread_cond_init): Initialize __mutex
8112 element with ~0l for pshared condvars, with NULL otherwise.
8113
8114 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
8115 (__pthread_cond_wait): Don't store mutex address if the current
8116 value is ~0l.
8117 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
8118 (__pthread_cond_timedwait): Likewise.
8119 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
8120 (__pthread_cond_broadcast): Don't use requeue for pshared
8121 condvars.
8122
bf68b236 8123 * Makefile: Add rules to build and run tst-cond12 and tst-cond13.
53f9084e 8124 * tst-cond12.c: New file.
bf68b236 8125 * tst-cond13.c: New file.
53f9084e 8126
9780c971
UD
81272003-11-17 Ulrich Drepper <drepper@redhat.com>
8128
8129 * sysdeps/pthread/configure.in: Make missing forced unwind support
8130 fatal.
8131
74e12fbc
UD
81322003-11-11 Ulrich Drepper <drepper@redhat.com>
8133
8134 * pthreadP.h: Don't declare __pthread_unwind as weak inside libpthread.
8135
c685b2b0
UD
81362003-11-06 Ulrich Drepper <drepper@redhat.com>
8137
8138 * Makefile: Add magic to clean up correctly.
8139
44e94149
UD
81402003-11-05 Jakub Jelinek <jakub@redhat.com>
8141
8142 * unwind.c (FRAME_LEFT): Define.
8143 (unwind_stop): Handle old style cleanups here.
8144 (__pthread_unwind): Handle old style cleanups only if
8145 !HAVE_FORCED_UNWIND.
8146 * Makefile (tests): Add tst-cleanup4 and tst-cleanupx4.
8147 (CFLAGS-tst-cleanupx4.c): Add -fexceptions.
8148 ($(objpfx)tst-cleanup4): Depend on $(objpfx)tst-cleanup4aux.o.
8149 ($(objpfx)tst-cleanupx4): Likewise.
8150 * tst-cleanup4.c: New test.
8151 * tst-cleanup4aux.c: New.
8152 * tst-cleanupx4.c: New test.
8153
c28422b5
UD
81542003-11-04 Ulrich Drepper <drepper@redhat.com>
8155
8156 * sysdeps/pthread/bits/stdio-lock.h: Use lll_*lock instead of
8157 lll_mutex_*lock macros to skip atomic operations on some archs.
8158
27176677
UD
81592003-11-03 Ulrich Drepper <drepper@redhat.com>
8160
8161 * sysdeps/pthread/tst-timer.c (main): Initialize
8162 sigev2.sigev_value as well.
8163
026395a2
RM
81642003-10-15 Roland McGrath <roland@redhat.com>
8165
8166 * sysdeps/pthread/configure.in: Barf if visibility attribute support
8167 is missing.
8168 * sysdeps/pthread/configure: Regenerated.
8169
fa3cbe3d
UD
81702003-10-09 Kaz Kojima <kkojima@rr.iij4u.or.jp>
8171
8172 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Completely revamp the
8173 locking macros. No distinction between normal and mutex locking
8174 anymore.
8175 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Rewrite mutex locking.
8176 Merge bits from lowlevelmutex.S we still need.
8177 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: Remove.
8178 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Likewise.
8179 * sysdeps/unix/sysv/linux/sh/not-cancel.h: New file.
8180 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Adjust for
8181 new mutex implementation.
8182 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Likewise.
8183 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Likewise.
8184 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
8185 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Likewise.
8186 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
8187 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
8188 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
8189 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
8190 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
8191 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h (PSEUDO): Also defined
8192 symbol for entry point to avoid cancellation.
8193
e700a908
UD
81942003-10-07 Jakub Jelinek <jakub@redhat.com>
8195
8196 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Backout 2003-10-02
8197 changes.
8198 (SAVE_OLDTYPE_0): Fix a typo.
8199
c70a86b6
UD
82002003-10-03 Ulrich Drepper <drepper@redhat.com>
8201
8202 * sysdeps/unix/sysv/linux/i386/pthread_once.S (__pthread_once):
8203 Check __sigsetjmp return value. Reported by Daniel Jacobowitz.
8204
134abcb5
UD
82052003-10-02 Ulrich Drepper <drepper@redhat.com>
8206
8207 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (DOCARGS_1): Use
8208 correct offset.
8209
b77ca0e8
UD
82102003-10-02 Jakub Jelinek <jakub@redhat.com>
8211
8212 * Makefile (tests): Add tst-cancel19.
8213 * tst-cancel19.c: New test.
8214
4d961dc7
UD
82152003-10-02 Ulrich Drepper <drepper@redhat.com>
8216
8217 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Fix saving and
8218 restoring of the old cancellation type.
8219
1d5b20ad 82202003-09-30 Jakub Jelinek <jakub@redhat.com>
94ae6d75 8221
1d5b20ad
UD
8222 * sysdeps/pthread/malloc-machine.h: Remove misleading comment.
8223
4106a403
RM
82242003-09-27 Wolfram Gloger <wg@malloc.de>
8225
4d961dc7 8226 * sysdeps/pthread/malloc-machine.h: New file
94ae6d75 8227
fca9d8e4
RM
82282003-09-24 Roland McGrath <roland@redhat.com>
8229
8230 * allocatestack.c (__make_stacks_executable): Don't ignore return
8231 value from _dl_make_stack_executable.
8232
c9c60884
UD
82332003-09-24 Ulrich Drepper <drepper@redhat.com>
8234
69c9fa04
UD
8235 * allocatestack.c (__make_stacks_executable): Also change
8236 permission of the currently unused stacks.
8237
279f1143
UD
8238 * allocatestack.c (change_stack_perm): Split out from
8239 __make_stacks_executable.
8240 (allocate_stack): If the required permission changed between the time
8241 we started preparing the stack and queueing it, change the permission.
8242 (__make_stacks_executable): Call change_stack_perm.
8243
c9c60884
UD
8244 * Makefile: Build tst-execstack-mod locally.
8245 * tst-execstack-mod.c: New file.
8246
54ee14b3
UD
82472003-09-23 Jakub Jelinek <jakub@redhat.com>
8248
8249 * Makefile (tests): Only add tst-execstack if have-z-execstack is yes.
8250
82512003-09-23 Roland McGrath <roland@redhat.com>
8252
8253 * tst-execstack.c: New file.
8254 * Makefile (tests): Add it.
8255 ($(objpfx)tst-execstack, $(objpfx)tst-execstack.out): New targets.
8256 (LDFLAGS-tst-execstack): New variable.
8257
8258 * allocatestack.c (allocate_stack): Use GL(dl_stack_flags) to decide
8259 whether to use PROT_EXEC for stack mmap.
8260 (__make_stacks_executable): New function.
8261 * pthreadP.h: Declare it.
8262 * init.c (__pthread_initialize_minimal_internal): Set
8263 GL(dl_make_stack_executable_hook) to that.
8264
365b1602
UD
82652003-09-22 Ulrich Drepper <drepper@redhat.com>
8266
8267 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Adjust for latest
8268 recommendation from AMD re avoidance of lock prefix.
8269
39358e8b
UD
82702003-09-22 Jakub Jelinek <jakub@redhat.com>
8271
8272 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait): Use
8273 lll_futex_timed_wait instead of lll_futex_wait.
8274 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Removed.
8275 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c: Removed.
8276 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: Removed.
8277 * sysdeps/unix/sysv/linux/s390/libc-lowlevelmutex.c: Removed.
8278 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Removed.
8279 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Removed.
8280 * sysdeps/unix/sysv/linux/s390/sem_post.c: Removed.
8281 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Removed.
8282 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Include atomic.h.
8283 Completely revamp the locking macros. No distinction between
8284 normal and mutex locking anymore.
8285 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: Likewise.
8286 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_lock_wait,
8287 __lll_lock_timedwait): Fix prototypes.
8288 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (__lll_lock_wait,
8289 __lll_lock_timedwait): Likewise.
8290 (lll_mutex_lock, lll_mutex_cond_lock): Use _val instead of _bool
8291 macros, add __builtin_expect.
8292 (lll_mutex_timedlock): Likewise. Fix return value.
8293 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Removed.
8294 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevelmutex.S: Removed.
8295 * sysdeps/unix/sysv/linux/i386/i586/lowlevelmutex.S: Removed.
8296 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevelmutex.S: Removed.
8297 * sysdeps/unix/sysv/linux/i386/i686/lowlevelmutex.S: Removed.
8298 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevelmutex.S: Removed.
8299 * sysdeps/unix/sysv/linux/lowlevelmutex.c: Removed.
8300 * sysdeps/unix/sysv/linux/libc-lowlevelmutex.c: Removed.
8301
9d08fbbb
UD
83022003-09-22 Ulrich Drepper <drepper@redhat.com>
8303
c0df57e1
UD
8304 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
8305 (__lll_mutex_lock_wait): Minor optimization to avoid one atomic
8306 operation if possible.
8307
9d08fbbb
UD
8308 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Don't play tricks
8309 like jumping over the lock prefix.
8310
71451de2
UD
83112003-09-21 Ulrich Drepper <drepper@redhat.com>
8312
8313 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Completely revamp the
8314 locking macros. No distinction between normal and mutex locking
8315 anymore.
3a226d33 8316 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
bc1989aa
UD
8317 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
8318 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
71451de2
UD
8319 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Rewrite mutex
8320 locking. Merge bits from lowlevelmutex.S we still need.
3a226d33 8321 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
bc1989aa 8322 * sysdeps/unix/sysv/linux/lowlevellock.c: Likewise.
71451de2 8323 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Removed.
3a226d33 8324 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Removed.
71451de2
UD
8325 * Makefile (routines): Remove libc-lowlevelmutex.
8326 (libpthread-rountines): Remove lowlevelmutex.
3a226d33
UD
8327 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Adjust
8328 for new mutex implementation.
8329 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
8330 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
8331 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
8332 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
8333 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
8334 Likewise.
8335 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
8336 Likewise.
8337 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
8338 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
8339 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: Likewise
8340 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
8341 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
8342 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
8343 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
8344 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
8345 Likewise.
8346 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
8347 Likewise.
8348 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: Likewise.
8349 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
8350 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
8351 Don't use requeue.
8352 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
bc1989aa 8353 * sysdeps/pthread/pthread_cond_signal.c: Don't use requeue.
71451de2 8354
8f31c0ef
UD
83552003-09-20 Ulrich Drepper <drepper@redhat.com>
8356
56a4aa98
UD
8357 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Don't match memory
8358 in parameters of asm with output parameters.
8359
8f31c0ef
UD
8360 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Change
8361 type of DECR parameter to int.
8362 * pthreadP.h: Adjust prototype of __pthread_mutex_unlock_usercnt.
8363
8b8074da
UD
83642003-09-18 Jakub Jelinek <jakub@redhat.com>
8365
8366 * tst-attr3.c (tf, do_test): Print stack start/end/size and
8367 guardsize for each thread.
8368
65af7e61
UD
83692003-09-17 Jakub Jelinek <jakub@redhat.com>
8370
9ba96eda
UD
8371 * sysdeps/pthread/pthread.h (pthread_getattr_np): Clarify usage.
8372 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c
8373 (pthread_attr_setaffinity_np): Handle cpuset == NULL.
8374
06f6ca90
UD
8375 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c
8376 (pthread_attr_getaffinity_np): Don't segfault if iattr->cpuset is
8377 NULL.
8378 * pthread_getattr_np.c: Set cpuset using pthread_getaffinity_np.
8379 * pthreadP.h (pthread_getaffinity_np): Add hidden_proto.
8380 * sysdeps/unix/sysv/linux/pthread_getaffinity.c
8381 (pthread_getaffinity_np): Add hidden_def.
8382
8383 * Makefile (tests): Add tst-attr3.
8384 * tst-attr3.c: New test.
8385
65af7e61
UD
8386 * sysdeps/i386/Makefile (CFLAGS-tst-align.c): Remove.
8387
3402852c
UD
83882003-09-15 Jakub Jelinek <jakub@redhat.com>
8389
8390 * sysdeps/i386/Makefile (CFLAGS-pthread_create.c,
8391 CFLAGS-tst-align.c): Add -mpreferred-stack-boundary=4.
8392
a4db3439
UD
83932003-09-17 Jakub Jelinek <jakub@redhat.com>
8394
8395 * Makefile (CFLAGS-tst-align.c): Add $(stack-align-test-flags).
8396 * tst-align.c: Include tst-stack-align.h.
8397 (tf, do_test): Use TEST_STACK_ALIGN macro.
8398
83992003-09-17 Ulrich Drepper <drepper@redhat.com>
8400
8401 * pthread_attr_init.c (__pthread_attr_init_2_0): Remove unused
8402 variable.
8403
92ce4676
UD
84042003-09-16 Ulrich Drepper <drepper@redhat.com>
8405
8406 * pthread_getattr_np.c (pthread_getattr_np): Correctly fill in the
8407 stack-related values for the initial thread.
8408
e07bb02a
UD
84092003-09-15 Jakub Jelinek <jakub@redhat.com>
8410
8411 * Makefile (CFLAGS-pthread_once.c): Add $(uses-callbacks).
8412
d087b5dc
UD
84132003-09-11 Ulrich Drepper <drepper@redhat.com>
8414
8415 * pthread_mutex_lock.c: Minor code rearrangements.
8416
7f08f55a
RM
84172003-09-05 Roland McGrath <roland@redhat.com>
8418
8419 * pthread_create.c (__pthread_pthread_sizeof_descr): Removed.
8420 Instead, include ../nptl_db/db_info.c to do its magic.
8421 * pthread_key_create.c (__pthread_pthread_keys_max): Removed.
8422 (__pthread_pthread_key_2ndlevel_size): Likewise.
8423 * sysdeps/alpha/tls.h (DB_THREAD_SELF): New macro.
8424 * sysdeps/i386/tls.h (DB_THREAD_SELF): New macro.
8425 * sysdeps/ia64/tls.h (DB_THREAD_SELF): New macro.
8426 * sysdeps/powerpc/tls.h (DB_THREAD_SELF): New macro.
8427 * sysdeps/s390/tls.h (DB_THREAD_SELF): New macro.
8428 * sysdeps/sh/tls.h (DB_THREAD_SELF): New macro.
8429 * sysdeps/sparc/tls.h (DB_THREAD_SELF): New macro.
8430 * sysdeps/x86_64/tls.h (DB_THREAD_SELF): New macro.
8431 * sysdeps/alpha/td_ta_map_lwp2thr.c: File removed.
8432 * sysdeps/generic/td_ta_map_lwp2thr.c: File removed.
8433 * sysdeps/i386/td_ta_map_lwp2thr.c: File removed.
8434 * sysdeps/ia64/td_ta_map_lwp2thr.c: File removed.
8435 * sysdeps/powerpc/td_ta_map_lwp2thr.c: File removed.
8436 * sysdeps/s390/td_ta_map_lwp2thr.c: File removed.
8437 * sysdeps/sh/td_ta_map_lwp2thr.c: File removed.
8438 * sysdeps/sparc/td_ta_map_lwp2thr.c: File removed.
8439 * sysdeps/x86_64/td_ta_map_lwp2thr.c: File removed.
8440
806e4a4a
UD
84412003-09-08 Ulrich Drepper <drepper@redhat.com>
8442
8443 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Change type
8444 of pthread_t to be compatible with LT.
8445 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: Likewise.
8446 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
8447 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
8448 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
8449 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: Likewise.
8450 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
8451 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Likewise.
8452
17f83e56
UD
84532003-09-04 Ulrich Drepper <drepper@redhat.com>
8454
8455 * sysdeps/unix/sysv/linux/i386/not-cancel.h (fcntl_not_cancel): Define.
8456
58e8ec84
UD
84572003-09-04 Jakub Jelinek <jakub@redhat.com>
8458
8459 * unwind-forcedunwind.c: Move to...
8460 * sysdeps/pthread/unwind-forcedunwind.c: ...here.
8461 (pthread_cancel_init): Use ARCH_CANCEL_INIT if defined.
8462 * sysdeps/pthread/jmpbuf-unwind.h: New file.
8463 * sysdeps/unix/sysv/linux/ia64/unwind-forcedunwind.c: New file.
8464 * sysdeps/unix/sysv/linux/ia64/jmpbuf-unwind.h: New file.
8465 * unwind.c: Include jmpbuf-unwind.h.
8466 (unwind_stop): Use _JMPBUF_CFA_UNWINDS macro.
8467
abf1cf21
JJ
84682003-09-02 Jakub Jelinek <jakub@redhat.com>
8469
4a244f0d
UD
8470 * sysdeps/unix/sysv/linux/ia64/bits/local_lim.h: New file.
8471 * sysdeps/unix/sysv/linux/ia64/Versions (libpthread): Export
8472 pthread_attr_setstack and pthread_attr_setstacksize @@GLIBC_2.3.3.
8473 * sysdeps/unix/sysv/linux/alpha/bits/local_lim.h: New file.
8474 * sysdeps/unix/sysv/linux/alpha/Versions: New file.
8475 * sysdeps/unix/sysv/linux/sparc/bits/local_lim.h: New file.
8476 * sysdeps/unix/sysv/linux/sparc/Versions: New file.
8477 * pthread_attr_setstack.c (__old_pthread_attr_setstack): New function.
8478 (pthread_attr_setstack): If PTHREAD_STACK_MIN != 16384, export
8479 as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.2.
8480 * pthread_attr_setstacksize.c (__old_pthread_attr_setstacksize): New
8481 function.
8482 (pthread_attr_setstacksize): If PTHREAD_STACK_MIN != 16384, export
8483 as @@GLIBC_2.3.2 and also export compatibility @GLIBC_2.1.
8484 * Makefile (tests): Add tst-stack2.
8485 * tst-stack2.c: New test.
8486 * tst-stack1.c: Include limits.h and sys/param.h.
8487 (do_test): Set size to MAX (4 * getpagesize (), PTHREAD_STACK_MIN).
8488
e29ef647
UD
8489 * pthread_condattr_setpshared.c: Include errno.h.
8490 (pthread_condattr_setpshared): Return EINVAL if pshared
8491 is neither PTHREAD_PROCESS_PRIVATE nor PTHREAD_PROCESS_SHARED.
8492
5777d565
UD
8493 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO): Also
8494 defined symbol for entry point to avoid cancellation.
8495 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
8496 Likewise.
8497 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (PSEUDO):
8498 Likewise.
8499 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h (PSEUDO):
8500 Likewise.
8501 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h (PSEUDO):
8502 Likewise.
8503 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h (PSEUDO):
8504 Likewise.
8505 * sysdeps/unix/sysv/linux/i386/not-cancel.h (__open_nocancel,
8506 __close_nocancel, __read_nocancel, __write_nocancel,
8507 __waitpid_nocancel): Add attribute_hidden. If not in libc.so,
8508 libpthread.so or librt.so, define to corresponding function
8509 without _nocancel suffix.
8510 * sysdeps/unix/sysv/linux/s390/not-cancel.h: New file.
8511 * sysdeps/unix/sysv/linux/powerpc/not-cancel.h: New file.
8512 * sysdeps/unix/sysv/linux/sparc/not-cancel.h: New file.
8513
abf1cf21
JJ
8514 * sysdeps/unix/sysv/linux/x86_64/not-cancel.h: Fix a typo.
8515
8348dcc8
UD
85162003-09-02 Ulrich Drepper <drepper@redhat.com>
8517
8518 * sysdeps/unix/sysv/linux/i386/not-cancel.h: New file.
1e03e0af 8519 * sysdeps/unix/sysv/linux/x86_64/not-cancel.h: New file.
8348dcc8
UD
8520
8521 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Make sure the code
8522 in subsections has a symbol associated with it.
8523
8524 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (PSEUDO): Also
8525 defined symbol for entry point to avoid cancellation.
8526 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (PSEUDO): Likewise.
8527
c874a32e
UD
85282003-09-01 Jakub Jelinek <jakub@redhat.com>
8529
8530 * Makefile (tests): Add tst-tls5.
8531 (module-names): Add tst-tls5mod{,a,b,c,d,e,f}.
8532 ($(objpfx)tst-tls5mod{,a,b,c,d,e,f}.so-no-z-defs): Set to yes.
8533 ($(objpfx)tst-tls5): New.
8534 ($(objpfx)tst-tls6.out): Likewise.
8535 (tests): Depend on $(objpfx)tst-tls6.out.
8536 * tst-tls3.c: Include stdint.h and pthreaddef.h.
8537 (do_test): Check pthread_self () return value alignment.
8538 * tst-tls3mod.c: Include stdint.h and pthreaddef.h.
8539 (tf): Check pthread_self () return value alignment.
8540 * tst-tls5.c: New test.
8541 * tst-tls5.h: New.
8542 * tst-tls5mod.c: New.
8543 * tst-tls5moda.c: New.
8544 * tst-tls5modb.c: New.
8545 * tst-tls5modc.c: New.
8546 * tst-tls5modd.c: New.
8547 * tst-tls5mode.c: New.
8548 * tst-tls5modf.c: New.
8549 * tst-tls6.sh: New test.
8550
c503d3dc
UD
8551 * sysdeps/pthread/pthread-functions.h (struct pthread_functions): Add
8552 ptr___pthread_cond_timedwait and ptr___pthread_cond_timedwait_2_0.
8553 * init.c (pthread_functions): Initialize them.
8554 * forward.c (pthread_cond_timedwait@GLIBC_2.0,
8555 pthread_cond_timedwait@@GLIBC_2.3.2): New forwards.
8556 * Versions (libc): Export pthread_cond_timedwait@GLIBC_2.0,
8557 pthread_cond_timedwait@@GLIBC_2.3.2.
8558
48614753
JJ
85592003-09-01 Jakub Jelinek <jakub@redhat.com>
8560
56a1b877
JJ
8561 * sysdeps/unix/sysv/linux/alpha/timer_create.c: New file.
8562 * sysdeps/unix/sysv/linux/alpha/timer_delete.c: New file.
8563 * sysdeps/unix/sysv/linux/alpha/timer_getoverr.c: New file.
8564 * sysdeps/unix/sysv/linux/alpha/timer_gettime.c: New file.
8565 * sysdeps/unix/sysv/linux/alpha/timer_settime.c: New file.
8566 * sysdeps/unix/sysv/linux/alpha/Versions: New file.
8567
8568 * sysdeps/unix/sysv/linux/alpha/aio_cancel.c: New file.
8569
48614753
JJ
8570 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: Define
8571 _POSIX_THREAD_PRIORITY_SCHEDULING.
8572 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: Likewise.
8573
28c97261
UD
85742003-08-31 Ulrich Drepper <drepper@redhat.com>
8575
eef80cf8
UD
8576 * sysdeps/pthread/bits/stdio-lock.h (_IO_acquire_lock): Avoid
8577 nested function, use static inline function from libio.h.
8578 Code by Richard Henderson.
8579
28c97261
UD
8580 * sysdeps/pthread/bits/libc-lock.h: Mark pthread_setcancelstate as
8581 weak.
8582
cd2fbe58
UD
85832003-08-30 Jakub Jelinek <jakub@redhat.com>
8584
8585 * sysdeps/unix/sysv/linux/sparc/sparc64/Versions: New file.
8586 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_create.c: New file.
8587 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_delete.c: New file.
8588 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_getoverr.c: New file.
8589 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_gettime.c: New file.
8590 * sysdeps/unix/sysv/linux/sparc/sparc64/timer_settime.c: New file.
8591 * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep-cancel.h: New file.
8592 * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep-cancel.h: New file.
8593 * sysdeps/unix/sysv/linux/sparc/bits/pthreadtypes.h: New file.
8594 * sysdeps/unix/sysv/linux/sparc/bits/semaphore.h: New file.
8595 * sysdeps/unix/sysv/linux/sparc/lowlevellock.h: New file.
8596 * sysdeps/unix/sysv/linux/sparc/pthread_once.c: New file.
8597 * sysdeps/unix/sysv/linux/sparc/pt-vfork.S: New file.
8598 * sysdeps/unix/sysv/linux/sparc/fork.c: New file.
8599 * sysdeps/unix/sysv/linux/sparc/aio_cancel.c: New file.
8600 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_lock.c: New file.
8601 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_trylock.c: New file.
8602 * sysdeps/sparc/sparc32/sparcv9/pthread_spin_unlock.c: New file.
8603 * sysdeps/sparc/sparc32/pthread_spin_lock.c: New file.
8604 * sysdeps/sparc/sparc32/pthread_spin_trylock.c: New file.
8605 * sysdeps/sparc/sparc32/pthreaddef.h: New file.
8606 * sysdeps/sparc/sparc64/pthread_spin_lock.c: New file.
8607 * sysdeps/sparc/sparc64/pthread_spin_trylock.c: New file.
8608 * sysdeps/sparc/sparc64/pthread_spin_unlock.c: New file.
8609 * sysdeps/sparc/sparc64/pthreaddef.h: New file.
8610 * sysdeps/sparc/tls.h: New file.
8611 * sysdeps/sparc/tcb-offsets.sym: New file.
8612 * sysdeps/sparc/Makefile: New file.
8613 * sysdeps/sparc/td_ta_map_lwp2thr.c: New file.
8614 * init.c [__sparc__] (__NR_set_tid_address): Define.
8615
feda52c0
UD
86162003-08-29 Jakub Jelinek <jakub@redhat.com>
8617
8618 * sysdeps/pthread/bits/stdio-lock.h (_IO_acquire_lock,
8619 _IO_release_lock): Define.
8620
7c868816
JJ
86212003-08-29 Jakub Jelinek <jakuB@redhat.com>
8622
0261d33f 8623 * tst-cancel4.c (tf_sigwait, tf_sigwaitinfo, tf_sigtimedwait): Add
7c868816
JJ
8624 sigemptyset before sigaddset. Reported by jreiser@BitWagon.com.
8625
68b9e1ae
UD
86262003-08-27 Ulrich Drepper <drepper@redhat.com>
8627
8628 * sysdeps/pthread/pthread.h (pthread_exit): Remove __THROW.
8629 (__pthread_cleanup_class): Add missing return types of member
8630 functions.
8631
13b3edfc
UD
86322003-08-26 Steven Munroe <sjmunroe@us.ibm.com>
8633
8634 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
8635 (lll_mutex_unlock_force): Add memory barrier between store and futex
8636 syscall.
8637
bb606fbe
UD
86382003-08-25 Ulrich Drepper <drepper@redhat.com>
8639
8640 * tst-cancel4.c (do_test): Also unlink tempfname and remove
8641 tempmsg in first loop.
8642
ee4e5a3d
UD
86432003-08-18 Ulrich Drepper <drepper@redhat.com>
8644
8645 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
8646 _POSIX_THREAD_PRIORITY_SCHEDULING.
8647 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
8648
334fcf2a
UD
86492003-08-07 Jakub Jelinek <jakub@redhat.com>
8650
8651 * sysdeps/pthread/bits/libc-lock.h [_LIBC && SHARED]
8652 (__rtld_lock_default_lock_recursive,
8653 __rtld_lock_default_unlock_recursive): Define.
8654 [_LIBC && SHARED] (__rtld_lock_lock_recursive,
8655 __rtld_lock_unlock_recursive): Define using
8656 GL(_dl_rtld_*lock_recursive).
8657 * init.c (__pthread_initialize_minimal_internal): Initialize
8658 _dl_rtld_lock_recursive and _dl_rtld_unlock_recursive.
8659 Lock GL(_dl_load_lock) the same number of times as
8660 GL(_dl_load_lock) using non-mt implementation was nested.
8661
8662 * pthreadP.h (__pthread_cleanup_upto): Add hidden_proto.
8663 * pt-longjmp.c (__pthread_cleanup_upto): Add hidden_def.
8664
a30fb2df
UD
86652003-08-06 Jakub Jelinek <jakub@redhat.com>
8666
8667 * tst-cancel17.c (do_test): Make len2 maximum of page size and
8668 PIPE_BUF.
8669
ce0d30a0
JJ
86702003-08-07 Jakub Jelinek <jakub@redhat.com>
8671
8672 * pthread_create.c (__pthread_create_2_0): Clear new_attr.cpuset.
8673
9c988b83
UD
86742003-08-03 Jakub Jelinek <jakub@redhat.com>
8675
8676 * sysdeps/pthread/createthread.c (do_clone): Move error handling
8677 to first syscall error check. Move syscall error check for tkill
8678 into __ASSUME_CLONE_STOPPED #ifdef.
8679
5c5252bd
UD
86802003-08-02 Ulrich Drepper <drepper@redhat.com>
8681
f1205aa7
UD
8682 * sysdeps/pthread/createthread.c (do_clone): If __ASSUME_CLONE_STOPPED
8683 is not defined, do explicit synchronization.
8684 (create_thread): Do not lock pd->lock here. If __ASSUME_CLONE_STOPPED
8685 is not defined also unlock pd->lock for non-debugging case in case
8686 it is necessary.
8687 * pthread_create.c (start_thread): Always get and release pd->lock
8688 if __ASSUME_CLONE_STOPPED is not defined.
8689 (start_thread_debug): Removed. Adjust users.
8690 * allocatestack.c (allocate_stack): Always initialize lock if
8691 __ASSUME_CLONE_STOPPED is not defined.
8692 * Makefile (tests): Add tst-sched1.
8693 * tst-sched1.c: New file.
8694
5c5252bd
UD
8695 * sysdeps/pthread/createthread.c (do_clone): Only use
8696 sched_setschduler and pass correct parameters.
8697
973d66e4
UD
86982003-07-31 Jakub Jelinek <jakub@redhat.com>
8699
8700 * sysdeps/pthread/pthread.h (pthread_attr_setstackaddr,
8701 pthread_attr_setstacksize): Change PTHREAD_STACK_SIZE to
8702 PTHREAD_STACK_MIN in comments.
8703
d347a4ab
UD
87042003-07-31 Jakub Jelinek <jakub@redhat.com>
8705
8706 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
8707 Shut up warnings if INTERNAL_SYSCALL_ERROR_P does not use its first
8708 argument.
8709 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Likewise.
8710 * pthread_condattr_setclock.c (pthread_condattr_setclock): Likewise.
8711 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: Include pthreaddef.h.
8712 (__pthread_cleanup_upto): Fix prototype.
8713 (_longjmp_unwind): Adjust caller.
8714 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (__lll_mutex_timedlock):
8715 Change second argument to const struct pointer.
8716 * tst-sem8.c (main): Remove unused s2 and s3 variables.
8717 * tst-sem9.c (main): Likewise.
8718 * unwind.c: Include string.h for strlen prototype.
8719
1b26e9a5
UD
87202003-07-31 Ulrich Drepper <drepper@redhat.com>
8721
8722 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
8723 (__pthread_cond_timedwait): Don't use cmov unless HAVE_CMOV is defined.
8724 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_timedwait.S:
8725 Define HAVE_CMOV.
8726 Patch by Nicholas Miell <nmiell@attbi.com>.
8727
adc12574
UD
87282003-07-30 Jakub Jelinek <jakub@redhat.com>
8729
8730 * init.c (__pthread_initialize_minimal_internal): Initialize
8731 GL(dl_init_static_tls).
8732 * pthreadP.h (__pthread_init_static_tls): New prototype.
8733 * allocatestack.c (init_one_static_tls, __pthread_init_static_tls):
8734 New functions.
8735 * Makefile (tests): Add tst-tls4.
8736 (modules-names): Add tst-tls4moda and tst-tls4modb.
8737 ($(objpfx)tst-tls4): Link against libdl and libpthread.
8738 ($(objpfx)tst-tls4.out): Depend on tst-tls4moda.so and
8739 tst-tls4modb.so.
8740 * tst-tls4.c: New file.
8741 * tst-tls4moda.c: New file.
8742 * tst-tls4modb.c: New file.
8743
a7f6c66e
RM
87442003-06-19 Daniel Jacobowitz <drow@mvista.com>
8745
8746 * sysdeps/pthread/timer_create.c (timer_create): Call timer_delref
8747 before __timer_dealloc.
8748 * sysdeps/pthread/timer_routines.c (__timer_thread_find_matching):
8749 Don't call list_unlink.
8750
172ce013
RM
87512003-07-29 Roland McGrath <roland@redhat.com>
8752
8753 * Makefile [$(build-shared) = yes] (tests): Depend on $(test-modules).
8754
7b787f85
UD
87552003-07-25 Jakub Jelinek <jakub@redhat.com>
8756
8757 * tst-cancel17.c (do_test): Check if aio_cancel failed.
8758 Don't reuse struct aiocb A if it failed.
8759 Write fpathconf (fds[1], _PC_PIPE_BUF) + 2 bytes using aio_write,
8760 not just one byte, as that does not block.
8761
0e9d6240
UD
87622003-07-22 Jakub Jelinek <jakub@redhat.com>
8763
9d79e037
UD
8764 * sysdeps/pthread/unwind-resume.c: New file.
8765 * sysdeps/pthread/Makefile (routines, shared-only-routines): Add
8766 unwind-resume in csu subdir.
8767 (CFLAGS-unwind-resume.c, CFLAGS-rt-unwind-resume.c): Compile with
8768 exceptions.
8769 (librt-sysdep_routines, librt-shared-only-routines): Add
8770 rt-unwind-resume.
8771 * sysdeps/pthread/rt-unwind-resume.c: New file.
8772 * unwind-forcedunwind.c: New file.
8773 * Makefile (libpthread-routines): Add unwind-forcedunwind.
8774 (libpthread-shared-only-routines): Likewise.
8775 (CFLAGS-unwind-forcedunwind.c): Compile with exceptions.
8776 * pthreadP.h (pthread_cancel_init): New prototype.
8777 * pthread_cancel.c (pthread_cancel): Call pthread_cancel_init.
8778
8779 * sysdeps/pthread/createthread.c (do_thread, create_thread): Make
8780 attr argument const struct pthread_attr *.
8781
0e9d6240
UD
8782 * res.c (__res_state): Return __resp.
8783 * descr.h: Include resolv.h.
8784 (struct pthread): Add res field.
8785 * pthread_create.c: Include resolv.h.
8786 (start_thread): Initialize __resp.
8787 * Makefile (tests): Add tst-_res1.
8788 (module-names): Add tst-_res1mod1, tst-_res1mod2.
8789 ($(objpfx)tst-_res1mod2.so): Depend on $(objpfx)tst-_res1mod1.so.
8790 ($(objpfx)tst-_res1): Depend on $(objpfx)tst-_res1mod2.so and
8791 libpthread.
8792 * tst-_res1.c: New file.
8793 * tst-_res1mod1.c: New file.
8794 * tst-_res1mod2.c: New file.
8795
1a379ea0
UD
87962003-07-21 Ulrich Drepper <drepper@redhat.com>
8797
7e939b21
UD
8798 * sysdeps/pthread/createthread.c: Don't define CLONE_STOPPED.
8799
1a379ea0
UD
8800 * Makefile: Define various *-no-z-defs variables for test DSOs
8801 which has undefined symbols.
8802
ca86a763
UD
88032003-07-21 Steven Munroe <sjmunroe@us.ibm.com>
8804
8805 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c (__pthread_once):
8806 Retry if the stwcx fails to store once_control.
8807
80f536db
UD
88082003-07-20 Ulrich Drepper <drepper@redhat.com>
8809
8810 * Makefile (libpthread-routines): Add pthread_attr_getaffinity and
8811 pthread_attr_setaffinity.
8812 * Versions [libpthread] (GLIBC_2.3.3): Likewise.
8813 * sysdeps/unix/sysv/linux/pthread_attr_getaffinity.c: New file.
8814 * sysdeps/unix/sysv/linux/pthread_attr_setaffinity.c: New file.
8815 * pthread_attr_destroy.c: Free cpuset element if allocated.
8816 * pthread_create.c: Pass iattr as additional parameter to
8817 create_thread.
8818 * sysdeps/pthread/createthread.c: If attribute is provided and
8819 a new thread is created with affinity set or scheduling parameters,
8820 start thread with CLONE_STOPPED.
8821 * sysdeps/pthread/pthread.h: Declare pthread_attr_getaffinity and
8822 pthread_attr_setaffinity.
8823 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_attr): Add
8824 cpuset element.
8825
73299943
UD
88262003-07-15 Ulrich Drepper <drepper@redhat.com>
8827
8828 * tst-tcancel-wrappers.sh: lseek and llseek are not cancelation points.
8829
da35d15e
UD
88302003-07-14 Ulrich Drepper <drepper@redhat.com>
8831
8832 * sysdeps/pthread/configure.in: Require CFI directives also for
8833 ppc and s390.
8834
75540d8a
UD
88352003-07-15 Jakub Jelinek <jakub@redhat.com>
8836
8837 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h (PSEUDO):
8838 Add cfi directives.
8839
4a17085f
UD
88402003-07-12 Kaz Kojima <kkojima@rr.iij4u.or.jp>
8841
8842 * sysdeps/sh/tcb-offsets.sym: Add RESULT, TID, CANCELHANDLING and
8843 CLEANUP_JMP_BUF.
8844 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Use more
8845 registers as variables. Call __pthread_mutex_unlock_usercnt.
8846 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
8847 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Store TID
8848 not self pointer in __writer. Compare with TID to determine
8849 deadlocks.
8850 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
8851 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S:
8852 Likewise.
8853 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S:
8854 Likewise.
8855 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Add cancellation support.
8856 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
8857 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Define all the nice
8858 macros also when compiling librt.
8859
6080ecdf
UD
88602003-07-11 Jakub Jelinek <jakub@redhat.com>
8861
8862 * Makefile (CFLAGS-pthread_once.c): Add -fexceptions
8863 -fasynchronous-unwind-tables.
8864 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h
8865 (PSEUDO): Add cfi directives.
8866 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (PSEUDO):
8867 Likewise.
8868 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (PSEUDO):
8869 Likewise.
8870
da0c02ee
UD
88712003-07-08 Jakub Jelinek <jakub@redhat.com>
8872
8873 * pthreadP.h (__pthread_unwind_next, __pthread_register_cancel,
8874 __pthread_unregister_cancel): Add prototypes and hidden_proto.
8875 * unwind.c (__pthread_unwind_next): Add hidden_def.
8876 * cleanup.c (__pthread_register_cancel, __pthread_unregister_cancel):
8877 Likewise.
8878 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S (__new_sem_wait):
8879 Use HIDDEN_JUMPTARGET to jump to __pthread_unwind.
8880 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S (sem_timedwait):
8881 Likewise.
8882 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S (sem_wait): Likewise.
8883 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S (sem_timedwait):
8884 Likewise.
8885 * sysdeps/unix/sysv/linux/i386/pthread_once.S (__pthread_once): Use
8886 HIDDEN_JUMPTARGET to call __pthread_register_cancel,
8887 __pthread_unregister_cancel and __pthread_unwind_next.
8888
57a5ea02
UD
88892003-07-04 Jakub Jelinek <jakub@redhat.com>
8890
8891 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (PSEUDO): Use
8892 different symbol for the cancellation syscall wrapper and
8893 non-cancellation syscall wrapper.
8894 (PSEUDO_END): Define.
8895
d810b358
UD
88962003-07-05 Richard Henderson <rth@redhat.com>
8897
8898 * sysdeps/alpha/elf/pt-initfini.c: Avoid .ent/.end.
8899 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h (lll_futex_wait,
42d86dd6
RH
8900 lll_futex_timed_wait, lll_futex_wake, lll_futex_requeue): On success
8901 return actual return value from the syscall, not 0.
d810b358 8902
db54f488
UD
89032003-07-07 Ulrich Drepper <drepper@redhat.com>
8904
8905 * descr.h (struct pthread): Add pid field.
8906 * allocatestack.c (allocate_stack): Initialize pid field in descriptor.
8907 (__reclaim_stacks): Likewise.
8908 * init.c (sigcancel_handler): If __ASSUME_CORRECT_SI_PID is defined
8909 also check for PID of the signal source.
8910 (__pthread_initialize_minimal_internal): Also initialize pid field
8911 of initial thread's descriptor.
8912 * pthread_cancel.c: Use tgkill instead of tkill if possible.
8913 * sysdeps/unix/sysv/linux/fork.c: Likewise.
8914 * sysdeps/unix/sysv/linux/pt-raise.c: Likewise.
8915 * sysdeps/unix/sysv/linux/pthread_kill.c: Likewise.
8916 * sysdeps/unix/sysv/linux/raise.c: Likewise.
8917
5e497a41
UD
89182003-07-05 Ulrich Drepper <drepper@redhat.com>
8919
8920 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_push): Renamed.
8921 Fix use of parameter.
8922 (__libc_cleanup_pop): Likewise.
8923
86a0c4fa
UD
89242003-07-04 Ulrich Drepper <drepper@redhat.com>
8925
8926 * init.c (sigcancel_handler): Change parameters to match handler
8927 for SA_SIGACTION. Check signal number and code to recognize
8928 invalid invocations.
8929
bdbecaa3
RM
89302003-07-03 Roland McGrath <roland@redhat.com>
8931
8932 * sysdeps/ia64/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr):
8933 Apply sizeof (struct pthread) bias to r13 value.
8934
56421b23
UD
89352003-07-03 Ulrich Drepper <drepper@redhat.com>
8936
fbd90f6c
UD
8937 * sysdeps/pthread/configure.in: Require CFI directives.
8938
56421b23
UD
8939 * sysdeps/pthread/librt-cancellation.c (__pthread_unwind): Remove
8940 definition.
8941 * pthreadP.h (__pthread_unwind): Add hidden_proto if used in
8942 libpthread compilation.
8943 * unwind.c (__pthread_unwind): Add hidden_def.
8944 * Versions (libpthread) [GLIBC_PRIVATE]: Add __pthread_unwind.
8945
ca2b4cd7
UD
89462003-07-01 Ulrich Drepper <drepper@redhat.com>
8947
8948 * libc-cancellation.c (__libc_cleanup_routine): Define.
8949 * sysdeps/pthread/bits/libc-lock.h (__pthread_cleanup_push): Define.
8950 (__pthread_cleanup_pop): Define.
8951
f036e569
UD
89522003-07-01 Richard Henderson <rth@redhat.com>
8953
8954 * sysdeps/alpha/elf/pt-initfini.c: New file.
8955 * sysdeps/alpha/pthread_spin_lock.S: New file.
8956 * sysdeps/alpha/pthread_spin_trylock.S: New file.
8957 * sysdeps/alpha/pthreaddef.h: New file.
8958 * sysdeps/alpha/td_ta_map_lwp2thr.c: New file.
8959 * sysdeps/alpha/tls.h: New file.
8960 * sysdeps/unix/sysv/linux/alpha/Makefile: New file.
8961 * sysdeps/unix/sysv/linux/alpha/bits/pthreadtypes.h: New file.
8962 * sysdeps/unix/sysv/linux/alpha/bits/semaphore.h: New file.
8963 * sysdeps/unix/sysv/linux/alpha/createthread.c: New file.
8964 * sysdeps/unix/sysv/linux/alpha/fork.c: New file.
8965 * sysdeps/unix/sysv/linux/alpha/lowlevellock.h: New file.
8966 * sysdeps/unix/sysv/linux/alpha/pt-vfork.S: New file.
8967 * sysdeps/unix/sysv/linux/alpha/pthread_once.c: New file.
8968 * sysdeps/unix/sysv/linux/alpha/sem_post.c: New file.
8969 * sysdeps/unix/sysv/linux/alpha/sysdep-cancel.h: New file.
8970
3b985826
UD
89712003-07-01 Ulrich Drepper <drepper@redhat.com>
8972
8973 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Add correct
8974 cleanup support and unwind info.
8975
3a4d1e1e
UD
89762003-06-30 Ulrich Drepper <drepper@redhat.com>
8977
8978 * sysdeps/unix/sysv/linux/i386/pthread_once.S (__pthread_once):
8979 Use correct cleanup handler registration. Add unwind info.
96c814d3
UD
8980 * sysdeps/unix/sysv/linux/unwindbuf.sym: New file.
8981 * sysdeps/unix/sysv/linux/Makefile: Add rule to build unwindbuf.h.
3a4d1e1e
UD
8982 * tst-once3.c: Add cleanup handler and check it is called.
8983 * tst-once4.c: Likewise.
8984 * tst-oncex3.c: New file.
8985 * tst-oncex4.c: New file.
8986 * Makefile: Add rules to build and run tst-oncex3 and tst-oncex4.
8987
e479cc8e
UD
89882003-06-29 Ulrich Drepper <drepper@redhat.com>
8989
8990 * sysdeps/pthread/configure.in: Check for C cleanup handling in gcc.
8991
7d7ff54c
UD
89922003-06-27 Ulrich Drepper <drepper@redhat.com>
8993
483e95d0
UD
8994 * tst-cancel4.c (tf_msgrcv): Use IPC_PRIVATE in msgget call.
8995 (tf_msgsnd): Likewise.
8996
7d7ff54c
UD
8997 * tst-cancel4.c (tf_msgrcv): Strengthen test against valid
8998 premature returns a bit more.
8999
7539c7ec
UD
90002003-06-26 Ulrich Drepper <drepper@redhat.com>
9001
9002 * sysdeps/pthread/librt-cancellation.c: Move __pthread_unwind
9003 definition to the front.
9004
9005 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Rename
9006 the cleanup functions to make the names unique. Fix dwarf opcode
9007 un unwind table.
9008 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Rename cleanup
9009 functions to make the names unique. Fix CFA offset for two blocks.
9010
0af6a1d9
UD
90112003-06-25 Ulrich Drepper <drepper@redhat.com>
9012
9013 * sysdeps/pthread/pthread.h (class __pthread_cleanup_class): Add
9014 missing closing braces.
9015 Patch by Christophe Saout <christophe@saout.de>.
9016
eef4a9f3
RM
90172003-06-24 Roland McGrath <roland@redhat.com>
9018
9019 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Typo fix.
9020
4165d44d
UD
90212003-06-24 Ulrich Drepper <drepper@redhat.com>
9022
7f8f7b9d
UD
9023 * sysdeps/unix/sysv/linux/ia64/bits/posix_opt.h: New file.
9024 * sysdeps/unix/sysv/linux/x86_64/bits/posix_opt.h: New file.
9025
4165d44d
UD
9026 * pthreadP.h: Declare __find_thread_by_id.
9027 * allocatestack.c [HP_TIMING_AVAIL]: Define __find_thread_by_id.
9028 * pthread_clock_gettime.c: Allow using other thread's clock.
9029 * pthread_clock_settime.c: Likewise.
9030 * sysdeps/pthread/pthread_getcpuclockid.c: Likewise.
9031 * Makefile: Add rules to build and run tst-clock2.
9032 * tst-clock2.c: New file.
9033
67b78ef9
UD
90342003-06-23 Ulrich Drepper <drepper@redhat.com>
9035
9036 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Rewrite
9037 to use exception-based cleanup handler.
9038 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
9039
9040 * tst-cond8.c (ch): Announce that we are done.
9041
9042 * pthreadP.h (__pthread_mutex_cond_lock): Mark with internal_function.
9043
9044 * tst-cancel17.c (tf): Retry aio_suspend in case of EINTR.
9045 Also test aio_suspend with timeout value.
9046
61623643
UD
90472003-06-22 Ulrich Drepper <drepper@redhat.com>
9048
3a4f2043
UD
9049 * pthreadP.h: Mark __pthread_mutex_unlock_usercnt also hidden.
9050 * pthread_mutex_unlock.c (__pthread_mutex_unlock_usercnt): Add
9051 attribute_hidden.
9052
61623643
UD
9053 * pthreadP.h (__pthread_mutex_init_internal): Mark hidden.
9054 (__pthread_mutex_lock_internal): Likewise.
9055 (__pthread_mutex_unlock_internal): Likewise.
9056 (__pthread_mutex_unlock_usercnt): Declare.
9057 * pthread_mutex_destroy.c: Always fail if used in any way.
9058 * pthread_mutex_init.c: Update comment.
9059 * pthread_mutex_lock.c: If NO_INCR is not defined adjust __nusers.
9060 * pthread_mutex_timedlock.c: Adjust __nusers.
9061 * pthread_mutex_trylock.c: Adjust __nusers.
9062 * pthread_mutex_unlock.c: Old code is in __pthread_mutex_unlock_usercnt
9063 and public interfaces are wrapper with pass additional parameter.
9064 __pthread_mutex_unlock_usercnt does not adjust __nusers if second
9065 parameter zero.
9066 * tst-mutex8.c: New file.
9067 * Makefile (tests): Add tst-mutex8.
9068 * sysdeps/pthread/pthread_cond_timedwait.c: Call
9069 __pthread_mutex_unlock_usercnt.
9070 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
9071 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9072 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
9073 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
9074 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
9075 * sysdeps/unix/sysv/linux/pthread_mutex_cond_lock.c: Define NO_INCR.
9076 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
9077 Add __nusers.
9078 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
9079 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
9080 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
9081 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
9082 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
9083
9084 * pthread_mutex_lock.c: Don't store THREAD_ID in __owner, use TID.
9085 * pthread_mutex_timedlock.c: Likewise.
9086 * pthread_mutex_trylock.c: Adjust __nusers.
9087 * pthread_mutex_unlock.c: Compare with TID not THREAD_ID.
9088 * tst-mutex9.c: New file.
9089 * Makefile (tests): Add tst-mutex9.
9090 * sysdeps/i386/tls.h: Remove THREAD_ID definition.
9091 * sysdeps/ia64/tls.h: Likewise.
9092 * sysdeps/powerpc/tls.h: Likewise.
9093 * sysdeps/s390/tls.h: Likewise.
9094 * sysdeps/sh/tls.h: Likewise.
9095 * sysdeps/x86_64/tls.h: Likewise.
9096 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_mutex_t):
9097 Change type of __owner.
9098 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
9099 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
9100 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
9101 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
9102 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
9103
9bdabb94
UD
91042003-06-19 Jakub Jelinek <jakub@redhat.com>
9105
9106 * sysdeps/unix/sysv/linux/ia64/sem_post.c: Move to...
9107 * sysdeps/unix/sysv/linux/sem_post.c: ...here.
9108
9109 * sysdeps/unix/sysv/linux/sem_post.c: Move to...
9110 * sysdeps/unix/sysv/linux/powerpc/sem_post.c: ... here. Pass nr + 1
9111 instead of nr to lll_futex_wake. Only set errno and return -1
9112 if err < 0.
9113
9114 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (lll_futex_wait,
9115 lll_futex_timed_wait, lll_futex_wake, lll_futex_requeue): On success
9116 return actual return value from the syscall, not 0.
9117
f6c93bd9
UD
91182003-06-18 Ulrich Drepper <drepper@redhat.com>
9119
ca343e73
UD
9120 * tst-cancel4.c (tf_msgsnd): Don't always use 100 as the type,
9121 find a random value.
9122 (tf_msgrcv): Likewise. Also don't report msgrcv returns if
9123 errno==EIDRM.
9124
50441a98
UD
9125 * sysdeps/unix/sysv/linux/timer_settime.c: Add prototype for
9126 compat_timer_settime.
9127 * sysdeps/unix/sysv/linux/timer_gettime.c: Add prototype for
9128 compat_timer_gettime.
9129 * sysdeps/unix/sysv/linux/timer_getoverr.c: Add prototype for
9bdabb94 9130 compat_timer_getoverrun.
50441a98
UD
9131 * sysdeps/unix/sysv/linux/timer_delete.c: Add prototype for
9132 compat_timer_delete.
9133
f6c93bd9
UD
9134 * pthread_mutex_destroy.c (__pthread_mutex_destroy): For
9135 error-checking mutex detect busy mutexes.
9136
047aec8f
UD
91372003-06-17 Ulrich Drepper <drepper@redhat.com>
9138
1d53508d
UD
9139 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_mutex_lock):
9140 Add ax to clobber list.
9141 (lll_mutex_cond_lock): Likewise.
9142 (lll_mutex_unlock): Likewise.
9143 (lll_lock): Likewise.
9144 (lll_unlock): Likewise.
9145
f23b30e2
UD
9146 * Makefile: Add rules to build and run tst-cancel18 and tst-cancelx18.
9147 * tst-cancel18.c: New file.
9148 * tst-cancelx18.c: New file.
9149
9150 * tst-cancel4.c: Test connect, creat, msgrcv, msgsnd, sendmsg, sendto,
9151 and tcdrain.
9152
9153 * Makefile: Add rules to build and run tst-cancel17 and tst-cancel17x.
9154 * tst-cancel17.c: New file.
9155 * tst-cancelx17.c: New file.
9156
9157 * sysdeps/unix/sysv/linux/sigtimedwait.c: New file.
9158 * sysdeps/unix/sysv/linux/sigwait.c: New file.
9159 * sysdeps/unix/sysv/linux/sigwaitinfo.c: New file.
9160
047aec8f
UD
9161 * tst-cancel4.c: Test open, close, pread, pwrite, fsync, and msync.
9162
bbde8527
UD
91632003-06-16 Jakub Jelinek <jakub@redhat.com>
9164
9165 * sysdeps/pthread/createthread.c (create_thread): Set
9166 header.multiple_threads unconditionally.
9167 * allocatestack.c (allocate_stack): Likewise.
9168 * descr.h (struct pthread): Add header.multiple_threads
9169 unconditionally.
9170 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (CENABLE, CDISABLE):
9171 Define for librt. #error if neither libpthread, libc nor librt.
9172 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (CENABLE, CDISABLE):
9173 Likewise.
9174 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h (CENABLE,
9175 CDISABLE): Likewise.
9176 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h (CENABLE,
9177 CDISABLE): Likewise.
9178 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h (CENABLE,
9179 CDISABLE): Likewise.
9180 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h (CENABLE,
9181 CDISABLE): Likewise. Access header.multiple_threads outside of
9182 libc and libpthread.
9183 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h (CENABLE, CDISABLE):
9184 Likewise.
9185 * sysdeps/x86_64/tls.h (tcbhead_t): Add multiple_threads.
9186 * sysdeps/x86_64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Define.
9187
26676450
UD
91882003-06-17 Ulrich Drepper <drepper@redhat.com>
9189
9190 * tst-cancel4.c: Add tests for the socket and signal functions, pause.
9191 Also test early cancellation before the thread reaches the cancellation
9192 point.
9193
9194 * Makefile: Compile forward.c with exceptions.
9195
9196 * sysdeps/unix/sysv/linux/sleep.c: New file.
9197
301a6724
UD
91982003-06-16 Ulrich Drepper <drepper@redhat.com>
9199
0e0deb03
UD
9200 * Makefile: Add CFLAGS definition to compile function wrappers
9201 duplicated from libc with exceptions.
9202 * tst-cancel4.c: Also check cancellation handlers.
9203
301a6724
UD
9204 * Makefile: Add rules to build and run tst-cancel16 and
9205 tst-cancelx16. Add missing CFLAGS definitions.
9206 * tst-cancel16.c: New file.
9207 * tst-cancelx16.c: New file.
9208
7a114794
UD
92092003-06-15 Ulrich Drepper <drepper@redhat.com>
9210
452aea84
UD
9211 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
9212 (DL_SYSINFO_IMPLEMENTATION): Use CFI opcodes.
9213 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h
9214 (DL_SYSINFO_IMPLEMENTATION): Likewise.
9215
7a114794
UD
9216 * pthreadP.h (LIBC_CANCEL_ASYNC): Also define for librt.
9217 (LIBC_CANCEL_RESET): Likewise.
9218 Declare __librt_enable_asynccancel and __librt_disable_asynccancel.
9219 * sysdeps/pthread/Makefile (librt-sysdep_routines): Add
9220 librt-cancellation.
9221 (CFLAGS-libcrt-cancellation.c): Define.
9222 * sysdeps/pthread/librt-cancellation.c: New file.
9223 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define all the nice
9224 macros also when compiling librt.
9225 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: Likewise.
9226 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: Likewise.
9227 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: Likewise.
9228 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: Likewise.
9229 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: Likewise.
9230 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: Likewise.
9231 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
9232
9233 * sysdeps/unix/sysv/linux/timer_create.c: Add prototype for
9234 compat_timer_create.
9235
8ba1d429
UD
92362003-06-14 Ulrich Drepper <drepper@redhat.com>
9237
cc8fb6f3
UD
9238 * sysdeps/pthread/posix-timer.h (timespec_compare): Always inline.
9239
8ba1d429
UD
9240 * sysdeps/unix/sysv/linux/fork.h: Add libc_hidden_proto for
9241 __register_atfork.
9242 * sysdeps/unix/sysv/linux/register-atfork.c (__register_atfork):
9243 Add libc_hidden_def.
9244
d4f100e2
RM
92452003-06-13 Roland McGrath <roland@redhat.com>
9246
9247 * sysdeps/x86_64/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Pass FS
9248 constant from <sys/reg.h> to ps_get_thread_area, not register contents.
9249
dd9423a6
UD
92502003-06-11 Ulrich Drepper <drepper@redhat.com>
9251
9252 * allocatestack.c (queue_stack): Always inline.
9253 * ptreadhP.h (__do_cancel): Likewise.
9254
ed24330d
JJ
92552003-06-10 Jakub Jelinek <jakub@redhat.com>
9256
9257 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c (sem_timedwait): Fix
9258 a typo.
9259
06120d79
UD
92602003-06-10 Ulrich Drepper <drepper@redhat.com>
9261
9262 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
9263 (__pthread_cond_signal): Remove incorrect second addition for
9264 cond_lock!=0.
9265
b1720346
UD
92662003-06-09 Ulrich Drepper <drepper@redhat.com>
9267
5b318f85
UD
9268 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
9269 (__pthread_cond_signal): Use correct futex pointer in
9270 __lll_mutex_lock_wait call.
9271
b1720346
UD
9272 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
9273 (__pthread_cond_signal): Some more tweaks to handle cond_lock!=0.
9274
3e36c37d
UD
92752003-06-08 Ulrich Drepper <drepper@redhat.com>
9276
ecf7955d
UD
9277 * sysdeps/unix/sysv/linux/s390/sem_wait.c (__new_sem_wait): Make
9278 cancelable.
ed24330d 9279 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c (sem_timedwait):
ecf7955d
UD
9280 Likewise.
9281
3e36c37d
UD
9282 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Remove
9283 hand-written CFI generation code. Since ENTRY/END also initiated
9284 CFI frames this caused two CFI sets to be generated.
9285
7726edc2
UD
92862003-06-07 Ulrich Drepper <drepper@redhat.com>
9287
9288 * cleanup_routine.c: New file.
9289 * Versions (libpthread) [GLIBC_2.3.3]: Add __pthread_cleanup_routine.
9290 * sysdeps/pthread/pthread.h: Add support for fully exception-based
9291 cleanup handling.
9292 * Makefile (libpthread-routines): Add cleanup_routine.
9293 Add more CFLAGS variables to compile with exceptions. Add comments
9294 why which file needs unwind tables.
9295 (tests) [have-forced-unwind==yes]: Add tst-cancelx* and tst-cleanupx*
9296 tests.
9297 * tst-cancelx1.c: New file.
9298 * tst-cancelx2.c: New file.
9299 * tst-cancelx3.c: New file.
9300 * tst-cancelx4.c: New file.
9301 * tst-cancelx5.c: New file.
9302 * tst-cancelx6.c: New file.
9303 * tst-cancelx7.c: New file.
9304 * tst-cancelx8.c: New file.
9305 * tst-cancelx9.c: New file.
9306 * tst-cancelx10.c: New file.
9307 * tst-cancelx11.c: New file.
9308 * tst-cancelx12.c: New file.
9309 * tst-cancelx13.c: New file.
9310 * tst-cancelx14.c: New file.
9311 * tst-cancelx15.c: New file.
9312 * tst-cleanupx0.c: New file.
9313 * tst-cleanupx0.expect: New file.
9314 * tst-cleanupx1.c: New file.
9315 * tst-cleanupx2.c: New file.
9316 * tst-cleanupx3.c: New file.
9317
9318 * tst-cleanup0.c: Make standard compliant.
9319 * tst-cleanup1.c: Likewise.
9320
9321 * sysdeps/unix/sysv/linux/sem_timedwait.c: Add cancellation support.
9322 * sysdeps/unix/sysv/linux/sem_wait.c: Likewise.
9323 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
9324 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
9325 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
9326 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
9327 * sysdeps/i386/tcb-offsets.sym: Add RESULT, CANCELHANDLING, and
9328 CLEANUP_JMP_BUF.
9329 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
9330 * tst-cancel12.c: New file.
9331 * tst-cancel13.c: New file.
9332 * tst-cancel14.c: New file.
9333 * tst-cancel15.c: New file.
9334 * Makefile (tests): Add tst-cancel12, tst-cancel13, tst-cancel14,
9335 and tst-cancel15.
9336
9337 * tst-cancel1.c: Add some comments.
9338
9339 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Compute relative
9340 timeout correctly.
9341
7a8a8e21
UD
93422003-06-06 Ulrich Drepper <drepper@redhat.com>
9343
9344 * Makefile (CFLAGS-pthread_cancel.c): Define.
9345
4ad0bbf4
UD
93462003-06-05 Ulrich Drepper <drepper@redhat.com>
9347
9348 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_rwlock_t):
9349 Change type of __writer element to int.
9350 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
9351 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
9352 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
9353 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
9354 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
9355 * sysdeps/i386/tcb-offsets.sym: Replace SELF entry with TID entry.
9356 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
9357 * pthread_rwlock_trywrlock.c: Store TID not self pointer in __writer.
9358 Compare with TID to determine deadlocks.
9359 * sysdeps/pthread/pthread_rwlock_rdlock.c: Likewise.
9360 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Likewise.
9361 * sysdeps/pthread/pthread_rwlock_timedwrlock.: Likewise.
9362 * sysdeps/pthread/pthread_rwlock_wrlock.c: Likewise.
9363 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
9364 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
9365 Likewise.
9366 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
9367 Likewise.
9368 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
9369 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
9370 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S:
9371 Likewise.
9372 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S:
9373 Likewise.
9374 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
9375 * Makefile (tests): Add tst-rwlock12.
9376 * tst-rwlock12.c: New file.
9377
332faa96
JJ
93782003-06-05 Jakub Jelinek <jakub@redhat.com>
9379
9380 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait,
9381 __lll_timedlock_wait, lll_unlock_wake_cb, __lll_timedwait_tid):
9382 Remove bogus hidden_proto.
9383 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c (___lll_lock):
9384 Likewise.
9385 * sysdeps/unix/sysv/linux/s390/lowlevellock.c (___lll_lock,
9386 lll_unlock_wake_cb, ___lll_timedwait_tid): Likewise.
9387 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c (___lll_mutex_lock,
9388 ___lll_mutex_timedlock): Likewise.
9389
29d9e2fd
UD
93902003-06-04 Ulrich Drepper <drepper@redhat.com>
9391
9392 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
9393 (__pthread_cond_signal): Add some code to eventually handle
9394 cond_lock!=0.
9395
6f1acb30
UD
93962003-06-01 Ulrich Drepper <drepper@redhat.com>
9397
9398 * Makefile (tests): Add tst-exec4.
9399 (tst-exec4-ARGS): Define.
9400 * tst-exec4.c: New file.
9401
49b65043
UD
94022003-05-31 Ulrich Drepper <drepper@redhat.com>
9403
31195be2
UD
9404 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait):
9405 Also fail if tv_nsec < 0.
9406 (__lll_timedwait_tid): Likewise.
9407 * sysdeps/unix/sysv/linux/sem_timedwait.c (sem_timedwait): Likewise.
9408 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_timedwait_tid):
9409 Likewise.
9410 * sysdeps/unix/sysv/linux/s390/lowlevellock.c (___lll_timedwait_tid):
9411 Likewise.
9412 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c (__lll_mutex_timedlock):
9413 Likewise.
9414 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c (sem_timedwait):
9415 Likewise.
80b54217
UD
9416 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_timedwait_tid):
9417 Likewise.
9418 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (lll_timedwait_tid):
9419 Likewise.
31195be2 9420
dcfc8224
UD
9421 * Makefile (tests): Add tst-sem8 and tst-sem9.
9422 * tst-sem8.c: New file.
9423 * tst-sem9.c: New file.
9424 * sem_open.c: Fix creation of in_use record if the file exists but
9425 no internal record.
9426
49b65043
UD
9427 * posix-timer.h: Remove old, unused timer_id2ptr and timer_ptr2id
9428 definitions.
9429
9430 * sysdeps/pthread/timer_create.c (timer_create): In case
9431 evp==NULL, assign timer ID to sival_ptr.
9432
9433 * descr.h (struct pthread_unwind_buf): Change type of prev element to
9434 struct pthread_unwind_buf *.
9435 (struct pthread): Likewise for cleanup_jmp_buf element.
9436
9437 * cleanup.c (__pthread_register_cancel): Add cast to avoid warning.
9438 * cleanup_defer.c (__pthread_register_cancel_defer): Likewise.
9439 * unwind.c (__pthread_unwind_next): Likewise.
9440
50794a45
UD
94412003-05-30 Ulrich Drepper <drepper@redhat.com>
9442
5d4f57bd
UD
9443 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
9444 (lll_futex_timed_wait): Use int for futex value parameter.
9445 (lll_futex_wake): Likewise.
9446 (lll_futex_requeue): Likewise.
9447
9448 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait):
9449 Replace one memory operation with one register operation.
9450
9451 * tst-join4.c (do_test): Fix error message.
9452
7ab7ea33
UD
9453 * tst-rwlock6.c (do_test): Use correct format specifier.
9454
9455 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S
9456 (__lll_mutex_lock_wait): Replace one memory operation with one
9457 register operation.
9458 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S
9459 (__lll_mutex_lock_wait): Likewise.
9460
50794a45
UD
9461 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
9462 (__lll_mutex_cond_lock): Add one to value parameter of
9463 __lll_lock_wait to reflect reality in the futex syscall.
9464 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
9465 (lll_mutex_cond_lock): Likewise.
9466
5a70784e
JJ
94672003-05-30 Jakub Jelinek <jakub@redhat.com>
9468
9469 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (__lll_mutex_cond_lock):
9470 New function.
9471 (lll_mutex_cond_lock): Define.
9472
e7c5ac68
UD
94732003-05-29 Ulrich Drepper <drepper@redhat.com>
9474
586d1748
UD
9475 * Makefile (tests): Add tst-signal6.
9476 * tst-signal6.c: New file.
9477
b8ba4a27
UD
9478 * sysdeps/unix/sysv/linux/s390/lowlevellock.h
9479 (__lll_mutex_unlock_force): New function
9480 (lll_mutex_unlock_force): Use __lll_mutex_unlock_force.
9481
65d46efe
UD
9482 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
9483 (__lll_mutex_unlock_force): New function.
9484 (lll_mutex_unlock_force): Use __lll_mutex_unlock_force.
9485
9486 * tst-rwlock7.c (do_test): Use correct format specifier.
9487
e7c5ac68
UD
9488 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_requeue):
9489 Find break parameter in correct asm argument.
9490
284bdc42
UD
94912003-05-27 Jakub Jelinek <jakub@redhat.com>
9492
9493 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_clobbers):
9494 Remove out4.
9495 (lll_futex_requeue): Fix __o3 constraint, return negative errno if
9496 error occured.
9497 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
9498 Add __mutex.
9499 * sysdeps/unix/sysv/linux/s390/lowlevellock.h (FUTEX_REQUEUE,
9500 lll_futex_requeue, lll_mutex_unlock_force): Define.
9501
e7c5ac68
UD
95022003-05-30 Jakub Jelinek <jakub@redhat.com>
9503
9504 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
9505 (pthread_cond_t): Add __mutex.
9506 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (FUTEX_REQUEUE,
9507 lll_futex_requeue, lll_mutex_unlock_force): Define.
9508
ea2630c6
UD
95092003-05-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
9510
9511 * sysdeps/sh/tcb-offsets.sym: Define MUTEX_FUTEX.
9512 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h (pthread_cond_t):
42d86dd6 9513 Add __mutex field.
ea2630c6
UD
9514 * sysdeps/unix/sysv/linux/sh/lowlevellock.h (SYSCALL_WITH_INST_PAD):
9515 Define.
9516 (lll_futex_wait, lll_futex_wake): Define.
9517 * sysdeps/unix/sysv/linux/sh/sh4/lowlevellock.h: New file.
9518 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: Try using
9519 FUTEX_REQUEUE instead of FUTEX_WAIT.
9520 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: Likewise.
9521 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Remember
9522 mutex which was used in condvar structure. Call
9523 __pthread_mutex_cond_lock instead of __pthread_mutex_lock_internal.
9524 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Likewise.
9525
9526 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Don't
9527 include tcb-offsets.h. Read wakeup value in locked region.
9528 Use the value of gbr register as THREAD_ID.
9529 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
9530 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
9531 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
9532
9533 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Remove futex related
9534 macros.
9535
5a77f150
UD
95362003-05-28 Ulrich Drepper <drepper@redhat.com>
9537
9538 * sysdeps/pthread/pthread_cond_broadcast.c
9539 (__pthread_cond_broadcast): Fix typo: MAX_INT -> INT_MAX.
9540
7661d9f7
UD
95412003-05-26 Ulrich Drepper <drepper@redhat.com>
9542
9543 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Fix
9544 typo in register name.
9545 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Use parameters
9546 correctly. Actually use requeue. Little optimization.
9547 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Store
9548 mutex address early. Handle cancellation state as 32-bit value.
9549 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
9550 Remove unnecessary label.
9551
69431c9a
UD
95522003-05-25 Ulrich Drepper <drepper@redhat.com>
9553
9554 * sysdeps/pthread/pthread_cond_broadcast.c: Try using FUTEX_REQUEUE
9555 instead of FUTEX_WAIT.
9556 * sysdeps/pthread/pthread_cond_signal.c: Likewise.
9557 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
9558 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
9559 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: Likewise.
9560 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
9561 * sysdeps/pthread/pthread_cond_timedwait.c: Remember mutex which was
9562 used in condvar structure. Call __pthread_mutex_cond_lock instead
9563 of __pthread_mutex_lock_internal.
9564 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9565 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
9566 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
9567 (__condvar_cleanup): Always call __pthread_mutex_cond_lock.
9568 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
9569 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
9570 * sysdeps/unix/sysv/linux/Makefile (libpthread-sysdep_routines):
9571 Add pthread_mutex_cond_lock.
9572 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Add dep_mutex.
9573 * sysdeps/unix/sysv/linux/pthread_cond_mutex_lock.c: New file.
9574 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define
9575 lll_mutex_cond_lock.
9576 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Likewise.
9577 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
248a3490 9578 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
69431c9a 9579 Add __mutex field.
248a3490 9580 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
69431c9a
UD
9581 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
9582
9583 * sysdeps/i386/tcb-offsets.sym: Define MUTEX_FUTEX.
9584 * sysdeps/x86_64/tcb-offsets.sym: Likewise.
9585
9586 * pthreadP.h: Declare __pthread_mutex_cond_lock.
9587 * pthread_mutex_lock.c: Define LLL_MUTEX_LOCK if not already defined.
9588 Use it instead of lll_mutex_lock. If __pthread_mutex_lock is a
9589 macro don't define aliases.
9590
9591 * cancellation.c: Remove __pthread_enable_asynccancel_2.
9592 * pthreadP.h: Remove declaration of __pthread_enable_asynccancel_2.
9593 * sysdeps/pthread/pthread_cond_timedwait.c: Use
9594 __pthread_enable_asynccancel instead of __pthread_enable_asynccancel_2.
9595 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9596 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
9597 * sysdeps/pthread/pthread_cond_wait.c: Likewise.
9598 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
9599 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
9600
fddfebbd
UD
96012003-05-17 Ulrich Drepper <drepper@redhat.com>
9602
9603 * sem_open.c: Fix one endless loop. Implement correct semantics
9604 wrt opening the same semaphore more then once.
9605 * sem_close.c: Adjust for sem_open change.
9606 * semaphoreP.h: Include <semaphore.h>. Define struct inuse_sem.
9607 Declare __sem_mappings, __sem_mappings_lock, __sem_search.
9608 * Makefile (tests): Add tst-sem7.
9609 * tst-sem7.c: New file.
9610
1eefffb0
RM
96112003-05-16 Roland McGrath <roland@redhat.com>
9612
9613 * sysdeps/unix/sysv/linux/register-atfork.c (libc_freeres_fn): Fix
9614 uninitialized variable braino.
9615
6e66dc78
UD
96162003-05-16 Ulrich Drepper <drepper@redhat.com>
9617
23ae6451
UD
9618 * sysdeps/unix/sysv/linux/timer_gettime.c (timer_gettime): Correct
9619 test for syscall availability.
9620
9621 * sysdeps/unix/sysv/linux/timer_settime.c (timer_settime): Set
9622 __no_posix_timers to -1 if the syscalls don't exist.
9623
7ac5b8e2
UD
9624 * pthread_join.c (pthread_join): Set tid field of the joined
9625 thread to -1. This isn't necessary but helps to recognize some
9626 error conditions with almost no cost.
9627
9628 * allocatestack.c (FREE_P): Also negative values indicate an
9629 unused stack.
9630
6e66dc78
UD
9631 * unwind.c: Include <unistd.h>.
9632
855dba3c
UD
96332003-05-14 Ulrich Drepper <drepper@redhat.com>
9634
9635 * Makefile ($(objpfx)$(multidir)): Add rule to create the directory.
9636
81f3ac4c
UD
96372003-05-14 Jakub Jelinek <jakub@redhat.com>
9638
9639 * Makefile (crti-objs, crtn-objs): New variables.
9640 (omit-deps, extra-objs): Add crtn.
9641 ($(objpfx)libpthread.so): Depend on both crti and crtn
9642 and links to them in multidir.
9643 ($(objpfx)crtn.S, $(objpfx)crtn.o): New rules.
9644
7158eae4
UD
96452003-05-12 Steven Munroe <sjmunroe@us.ibm.com>
9646
9647 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h
9648 (lll_mutex_unlock): Use atomic_exchange_rel.
9649
edf205d5
UD
96502003-05-11 Ulrich Drepper <drepper@redhat.com>
9651
9652 * cond-perf.c (cons): Add missing locking around setting of alldone.
9653
a3f979a7
UD
96542003-05-10 Ulrich Drepper <drepper@redhat.com>
9655
9656 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Remove futex
9657 related macros.
9658 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
9659
880867a4
UD
96602003-05-09 Ulrich Drepper <drepper@redhat.com>
9661
949ec764
UD
9662 * tst-sem6.c: New file.
9663 * Makefile (tests): Add tst-sem6.
9664
9665 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (___lll_mutex_unlock):
9666 Use atomic_exchange_rel instead of atomic_exchange.
9667 * sysdeps/unix/sysv/linux/lowlevellock.c (lll_unlock_wake_cb):
9668 Likewise.
9669
9670 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Improve quality of
9671 code for lll_futex_wait and lll_futex_wake in static apps. Use
9672 vsyscall is possible.
9673
9674 * sysdeps/unix/sysv/linux/pthread_getaffinity.c: New file.
9675 * sysdeps/unix/sysv/linux/pthread_setaffinity.c: New file.
9676 * sysdeps/pthread/pthread.h: Declare pthread_getaffinity_np and
9677 pthread_setaffinity_np.
9678 * Versions [libpthread] (GLIBC_2.3.3): Add pthread_getaffinity_np
9679 and pthread_setaffinity_np.
9680 * Makefile (libpthread-routines): Add pthread_getaffinity and
9681 pthread_setaffinity.
9682
880867a4
UD
9683 * allocatestack.c (allocate_stack): If ARCH_RETRY_MMAP is defined,
9684 use it in case mmap to allocate the stack fails.
9685 * sysdeps/unix/sysv/linux/x86_64/Makefile: Don't define
9686 ARCH_MAP_FLAGS here.
9687 * sysdeps/x86_64/pthreaddef.h: Define ARCH_MAP_FLAGS and
9688 ARCH_RETRY_MMAP.
9689
92d83c72
UD
96902003-05-08 Ulrich Drepper <drepper@redhat.com>
9691
9692 * sysdeps/unix/sysv/linux/fork.c: Complete rewrite of the atfork
9693 handler implementation. It is now lockless in fork().
9694 * sysdeps/unix/sysv/linux/register-atfork.c: Likewise.
9695 * sysdeps/unix/sysv/linux/unregister-atfork.c: Likewise.
9696 * sysdeps/unix/sysv/linux/fork.h: Don't include <link.h>. Don't
9697 declare the __fork_*_lists.
9698 (struct fork_handler): Include pointers to all three functions.
9699 Add next, refcntr and need_signal elements.
9700 (__fork_handlers): New declaration.
9701 (__register_atfork_malloc): Remove declaration.
9702 (HAVE_register_atfork_malloc): Remove definition.
9703 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Remove
9704 __pthread_child_handler variable.
9705 (__libc_pthread_init): Use __register_atfork instead of explicitly
9706 adding to the list.
9707 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Define lll_futex_wait
9708 and lll_futex_wake.
9709 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
9710
9711 * unwind.c (unwind_cleanup): Print error message and then abort. This
9712 function must never be reached.
9713
9714 * cond-perf.c: New file.
9715
be4d8038
UD
97162003-05-05 Ulrich Drepper <drepper@redhat.com>
9717
9718 * sysdeps/i386/tls.h (TLS_INIT_TP): Include \n in error message.
9719
c6696b79
RM
97202003-05-04 Roland McGrath <roland@redhat.com>
9721
9722 * Makefile ($(objpfx)../libc.so): New target.
9723
7da168bf
UD
97242003-05-02 Ulrich Drepper <drepper@redhat.com>
9725
9726 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
9727 (pthread_condattr_t): Size is only an int, don't use long for
9728 alignment.
9729 (pthread_mutexattr_t): Likewise.
7da168bf
UD
9730 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
9731 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
9732 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
9733
9a7178d6
UD
97342003-05-01 Ulrich Drepper <drepper@redhat.com>
9735
9736 * sysdeps/i386/tls.h: Define THREAD_ID.
9737 * sysdeps/ia64/tls.h: Likewise.
9738 * sysdeps/powerpc/tls.h: Likewise.
9739 * sysdeps/s390/tls.h: Likewise.
9740 * sysdeps/sh/tls.h: Likewise.
9741 * sysdeps/x86_64/tls.h: Likewise.
9742 * pthread_mutex_lock.c: Use THREAD_ID instead of THREAD_SELF to
9743 record ownership.
9744 * pthread_mutex_timedlock.c: Likewise.
9745 * pthread_mutex_trylock.c: Likewise.
9746 * pthread_mutex_unlock.c: Likewise.
9747 * pthread_rwlock_trywrlock.c: Likewise.
9748 * sysdeps/pthread/pthread_rwlocklock_rdlock.c: Likewise.
9749 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Likewise.
9750 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
9751 * sysdeps/pthread/pthread_rwlock_wrlock.c: Likewise.
9752
9753 * sysdeps/pthread/createthread.c (create_thread): Use CLONE_SYSVSEM
9754 flag.
9755
a234e27d
UD
97562003-04-29 Jakub Jelinek <jakub@redhat.com>
9757
9758 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
9759 (__SIZEOF_PTHREAD_COND_T): Define to 48.
9760 (pthread_rwlock_t): Add 16 bytes of pad instead of 8 before __flags.
9761 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h (pthread_cond_t):
9762 Make __align long long instead of long.
9763 (pthread_rwlock_t): Formatting.
9764 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h
9765 (pthread_rwlock_t): Formatting.
9766 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h
9767 (pthread_cond_t): Make __align long long instead of long.
9768 (pthread_rwlock_t): Move __flags field to the same position as in
9769 linuxthreads.
9770
f025c136
UD
97712003-04-30 Ulrich Drepper <drepper@redhat.com>
9772
9773 * tst-rwlock6.c (do_test): Use correct printf format specifiers.
9774 * tst-rwlock7.c (do_test): Likewise.
9775
7531ab9e
RM
97762003-04-26 Roland McGrath <roland@redhat.com>
9777
9778 * Makefile ($(test-modules)): Depend on $(common-objpfx)shlib.lds.
9779
299601a1
UD
97802003-04-22 Jakub Jelinek <jakub@redhat.com>
9781
299601a1
UD
9782 * allocatestack.c (TLS_TPADJ): Add TLS_PRE_TCB_SIZE instead of
9783 sizeof (struct pthread).
9784 (allocate_stack): Subtract TLS_PRE_TCB_SIZE bytes instead of
468777e1 9785 1 struct pthread.
299601a1
UD
9786 * sysdeps/powerpc/tls.h (TLS_INIT_TCB_SIZE, TLS_TCB_SIZE): Define
9787 to 0.
9788 (TLS_INIT_TCB_ALIGN, TLS_TCB_ALIGN): Define to alignment of
9789 struct pthread.
9790 (TLS_PRE_TCB_SIZE): Increase to cover tcbhead_t preceeded by pad
9791 to 32-bit bytes.
9792 (INSTALL_DTV, GET_DTV, THREAD_DTV): tcbhead_t is immediately before
9793 tcbp.
9794 (TLS_INIT_TP, THREAD_SELF, INIT_THREAD_SELF): Don't add TLS_TCB_SIZE
9795 unneccessarily.
9796 (NO_TLS_OFFSET): Define.
299601a1
UD
9797 * sysdeps/unix/sysv/linux/powerpc/createthread.c (TLS_VALUE): Don't
9798 add TLS_TCB_SIZE unnecessarily.
299601a1 9799
950094f8
RM
98002003-04-22 Roland McGrath <roland@redhat.com>
9801
9802 * Makeconfig (shared-thread-library): Reverse link order to work
9803 around linker bug.
9804
dc2f6455
UD
98052003-04-22 Ulrich Drepper <drepper@redhat.com>
9806
9807 * semaphore.h: Fix typo in comment.
9808
e7608d77
UD
98092003-04-21 Ulrich Drepper <drepper@redhat.com>
9810
6a87ee19
UD
9811 * sysdeps/pthread/sigfillset.c: New file.
9812
e7608d77
UD
9813 * init.c (__pthread_initialize_minimal): Don't block SIGTIMER.
9814 * pthreadP.h: Make SIGTIMER and SIGCANCEL the same.
9815 * sysdeps/pthread/pthread_sigmask.c: Remove handling of SIGTIMER.
9816 * sysdeps/pthread/sigaction.c: Likewise.
9817 * sysdeps/pthread/sigprocmask.c: New file.
9818 * sysdeps/unix/sysv/linux/allocrtsig.c (current_rtmin): Define as
9819 __SIGRTMIN+1.
9820 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
9821 Block SIGTIMER. Also handle SI_TKILL events and terminate thread
9822 in this case.
9823
0b3df49e
UD
98242003-04-19 Ulrich Drepper <drepper@redhat.com>
9825
58a7a325
UD
9826 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
9827 (DL_SYSINFO_IMPLEMENTATION): Add .eh_frame information.
9828
0b3df49e
UD
9829 * sysdeps/unix/sysv/linux/unregister-atfork.c
9830 (__unregister_atfork): Don't free memory not allocated dynamically.
9831
9832 * semaphore.h: Remove __THROW marker from cancellation points.
9833 * nptl/sysdeps/pthread/pthread.h: Likewise.
9834
7d74651e
UD
98352003-04-18 Ulrich Drepper <drepper@redhat.com>
9836
76a67697
UD
9837 * sysdeps/pthread/pthread.h: Don't mark pthread_testcancel,
9838 pthread_cancel, pthread_setcancelstate, and pthread_setcanceltype with
7d74651e
UD
9839 __THROW.
9840
dd9d6538
JJ
98412003-04-16 Jakub Jelinek <jakub@redhat.com>
9842
9843 * tst-cancel4.c (do_test): Use %zd instead of %d when printing cnt.
9844
4ab6f47c
RM
98452003-04-15 Roland McGrath <roland@redhat.com>
9846
9847 * forward.c (__pthread_unwind): Tweak to avoid warning.
9848
162434a6
UD
98492003-04-15 Ulrich Drepper <drepper@redhat.com>
9850
9851 * pthreadP.h: Move THREAD_ATOMIC_* replacements to the top.
9852
35909161
UD
98532003-04-14 Ulrich Drepper <drepper@redhat.com>
9854
18ddd3aa 9855 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Don't
35909161
UD
9856 overflow CFA advance instructions.
9857 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
9858
18a8e730
UD
98592003-04-14 Jakub Jelinek <jakub@redhat.com>
9860
bd4f43b4
UD
9861 * sysdeps/i386/tls.h: Rename LOCK to LOCK_PREFIX.
9862 * sysdeps/i386/pthread_spin_lock.c: Likewise.
9863 * sysdeps/x86_64/tls.h: Likewise. Define LOCK_PREFIX if not already
9864 defined.
9865
18a8e730
UD
9866 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Use
9867 DW_CFA_advance_loc2 for .Laddl-.Lsubl.
9868 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Use
9869 DW_CFA_advance_loc for .Laddl-.Lsubl.
9870
08c765fa
UD
98712003-04-13 Ulrich Drepper <drepper@redhat.com>
9872
18a8e730
UD
9873 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Don't use
9874 position-independent unwind data for static libraries.
9875 Add missing unwind info. Add comments.
9876
ad2be852
UD
9877 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Add unwind info.
9878 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
9879 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
08c765fa
UD
9880 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
9881
177d1ad3
UD
98822003-04-12 Ulrich Drepper <drepper@redhat.com>
9883
08c765fa
UD
9884 * Makefile: Make sure all cancellation points are compiled with
9885 exception and asynchronous unwind tables.
9886
177d1ad3
UD
9887 * sysdeps/x86_64/tls.h (THREAD_SETMEM): Word around compiler bug
9888 which mishandles loading of global object addresses in PIC.
9889 (THREAD_SETMEM_NC): Likewise.
9890
09d65ff3
UD
98912003-04-11 Ulrich Drepper <drepper@redhat.com>
9892
9893 * pthread.h: Define new data structure for cleanup buffer. Declare
9894 new cleanup handler interfaces.
9895 * descr.h: Include <unwind.h> if necessary. Define pthread_unwind_buf.
9896 (struct pthread): Add cleanup_jmp_buf pointer. Define
9897 HAVE_CLEANUP_JMP_BUF and not HAVE_CANCELBUF.
9898 * pthreadP.h: Declare __pthread_unwind. Define __do_cancel to use
9899 it. Declare old cleanup handler installation functions.
9900 * cleanup.c: Rewrite. Install handler for unwind-based cleanup
9901 handling.
9902 * cleanup_defer.c: Likewise.
9903 * cleanup_compat.c: New file. Old cleanup code.
9904 * cleanup_def_compat.c: New file. Old cleanup code.
9905 * pthread_create.c (start_thread): Initialize cleanup_jmp_buf element
9906 if own thread descriptor.
9907 * unwind.c: New file.
9908 * forward.c: Add __pthread_unwind.
9909 * init.c (pthread_functions): Add __pthread_unwind.
9910 * sysdeps/pthread/pthread-functions.s (struct pthread_functions):
9911 Add ptr___pthread_unwind.
9912 * Versions [GLIBC_2.3.3] (libpthread): Export new cleanup handling
9913 and unwind function.
9914 * Makefile (libpthread-routines): Add cleanup_compat,
9915 cleanup_def_compat, and unwind. Define CFLAGS to enable unwind
9916 table generation if necessary.
9917 * version.c: Record whether unwind support is compiled in.
9918 * sysdeps/pthread/configure.in: Add checks for unwind unterfaces.
9919 * sysdeps/pthread/bits/libc-lock.h: Add prototypes of the old cleanup
9920 handler interfaces.
9921 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Add quite a bit of
9922 complication to generate unwind information for syscall wrappers.
68107ec0 9923 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: Likewise.
09d65ff3
UD
9924 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Define
9925 __cleanup_fct_attribute.
9926
9927 * Makefile: Add rules to build and run tst-cleanup0.
9928 * tst-cleanup0.c: New file.
9929 * tst-cleanup0.expect: New file.
9930
9931 * pthread_create.c (deallocate_tsd): Don't take parameter. Adjust
9932 caller. Optimize to avoid often unecessary local variable.
9933
0dc44b51
RM
99342003-04-11 Roland McGrath <roland@redhat.com>
9935
9936 * Makefile ($(objpfx)multidir.mk): New target, generated makefile that
9937 sets variable `multidir'; include that.
9938 (generated): Add it.
9939 ($(objpfx)$(multidir)/crti.o): New target.
9940 [$(multidir) != .] (generated-dirs, extra-objs, omit-deps): Add it.
9941
84a80719
UD
99422003-04-11 Ulrich Drepper <drepper@redhat.com>
9943
9944 * tst-attr2.c (do_test): Add cast to avoid warning.
9945 * tst-mutex4.c (do_test): Likewise.
9946
88ff4759
UD
99472003-04-10 Ulrich Drepper <drepper@redhat.com>
9948
9949 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Reset CPU clocks
9950 in child.
9951
b2041097
UD
99522003-04-09 Ulrich Drepper <drepper@redhat.com>
9953
9954 * Makefile (tests): Add tst-detach1.
9955 * tst-detach1.c: New file.
9956
f9657e88
UD
99572003-04-08 Ulrich Drepper <drepper@redhat.com>
9958
9afe4964
UD
9959 * sysdeps/pthread/pthread.h: Remove duplicate
9960 pthread_cleanup_{push,pop} definitions.
9961
f9657e88
UD
9962 * tst-barrier2.c: Eliminate warnings.
9963 * tst-cancel4.c: Likewise.
9964 * tst-cond4.c: Likewise.
9965 * tst-cond6.c: Likewise.
9966 * tst-detach1.c: Likewise.
9967 * tst-rwlock4.c: Likewise.
9968 * tst-rwlock6.c: Likewise.
9969 * tst-rwlock7.c: Likewise.
9970 * tst-sem3.c: Likewise.
9971 * tst-spin2.c: Likewise.
9972 * tst-umask1.c: Likewise.
9973
69b35e86
UD
99742003-04-07 Ulrich Drepper <drepper@redhat.com>
9975
9976 * pthread_detach.c (pthread_detach): Fix test for invalid TID.
9977
c70ad7d7
UD
99782003-04-06 Ulrich Drepper <drepper@redhat.com>
9979
9980 * descr.h (struct pthread): Move cancelhandling member to the front.
9981
54e0138f
UD
99822003-04-05 Ulrich Drepper <drepper@redhat.com>
9983
9984 * sysdeps/unix/sysv/linux/register-atfork.c: Define malloc_prepare,
9985 malloc_parent, and malloc_child statically.
9986 (__register_atfork_malloc): New function.
9987 (free_mem): Don't free any of the malloc_* variables on the list.
9988 * sysdeps/unix/sysv/linux/fork.h: Declare __register_atfork_malloc.
9989 Define HAVE_register_atfork_malloc.
9990
b22d701b
UD
99912003-04-04 Ulrich Drepper <drepper@redhat.com>
9992
9993 * sysdeps/pthread/createthread.c (create_thread): Add some more
9994 comments explaining when to set multiple_threads and when not.
9995
9996 * pthreadP.h: Define THREAD_ATOMIC_CMPXCHG_VAL and
9997 THREAD_ATOMIC_BIT_SET if not already defined.
9998 * sysdeps/i386/tls.h: Define THREAD_ATOMIC_CMPXCHG_VAL and
9999 THREAD_ATOMIC_BIT_SET:
10000 * sysdeps/x86_64/tls.h: Likewise.
10001 * cleanup_defer.c (_pthread_cleanup_push_defer): Rewrite to use
10002 THREAD_ATOMIC_CMPXCHG_VAL.
10003 (_pthread_cleanup_pop_restore): Likewise.
10004 * cancellation.c (__pthread_enable_asynccancel): Likewise.
10005 (__pthread_enable_asynccancel_2): Likewise.
10006 (__pthread_disable_asynccancel): Likewise.
10007 * libc-cancellation.c (__libc_enable_asynccancel): Likewise.
10008 (__libc_disable_asynccancel): Likewise.
10009 * init.c (sigcancel_handler): Likewise.
10010 * pthread_setcancelstate.c (__pthread_setcancelstate): Likewise.
10011 * pthread_setcanceltype.c (__pthread_setcanceltype): Likewise.
10012
86246935
UD
100132003-04-03 Ulrich Drepper <drepper@redhat.com>
10014
10015 * init.c (sigcancel_handler): Don't set EXITING_BIT here.
10016 * libc-cancellation.c (__libc_enable_asynccancel): Likewise.
10017 * pthreadP.h (__do_cancel): Set EXITING_BIT here.
10018 * Makefile (tests): Add tst-cancel11.
10019 * tst-cancel11.c: New file.
10020
6b4686a5
UD
100212003-04-01 Ulrich Drepper <drepper@redhat.com>
10022
10023 * pthread_create.c (deallocate_tsd): Clear/free memory after the last
10024 round, not the first. Use specific_used flag instead of local
10025 found_nonzero variable. Use THREAD_[SG]ETMEM where possible.
10026 (__free_tcb): Don't call deallocate_tsd here.
10027 (start_thread): Call deallocate_tsd here.
10028 * pthread_setspecific.c: Set specific_used flag really only when
10029 needed.
0d73a73b 10030 * Makefile (tests): Add tst-tsd3.c and tst-tsd4.
6b4686a5 10031 * tst-tsd3.c: New file.
0d73a73b 10032 * tst-tsd4.c: New file.
6b4686a5 10033
42b2395d
UD
100342003-03-31 Ulrich Drepper <drepper@redhat.com>
10035
211d90c5
UD
10036 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_mutex_lock):
10037 Use atomic_exchange_and_add instead of __lll_add.
10038 (__lll_mutex_timedlock): Likewise.
10039 Patch by Ian Wienand.
10040
100412003-03-24 Steven Munroe <sjmunroe@us.ibm.com>
10042
10043 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
10044 (SINGLE_THREAD_P): Fix typo.
10045 * tst-cancel-wrappers.sh: Handle '.'ed symbols.
10046
100472003-03-31 Ulrich Drepper <drepper@redhat.com>
10048
10049 * Makefile (tests): Add tst-align.
10050 * tst-align.c: New file.
10051 * sysdeps/i386/Makefile: Define CFLAGS-tst-align.
211d90c5 10052
42b2395d
UD
10053 * sysdeps/i386/tls.h (CALL_THREAD_FCT): Align stack of called
10054 function correctly.
10055
211d90c5
UD
10056 * tst-tsd2.c: Add casts to avoid warnings.
10057
163b180f
UD
100582003-03-30 Ulrich Drepper <drepper@redhat.com>
10059
10060 * descr.h (struct pthread): Move most often used elements to the front.
10061
ea473bad
UD
100622003-03-29 Ulrich Drepper <drepper@redhat.com>
10063
10064 * Makefile (libpthread-routines): Add pthread_atfork.
10065 (libpthread-static-only-routines): Add pthread_atfork.
10066
dd731d53
UD
100672003-03-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
10068
10069 * sysdeps/sh/tls.h: Include nptl/descr.h after the definition
10070 of TLS_DTV_AT_TP.
10071 (INSTALL_DTV): Add parens.
10072 (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM, THREAD_SETMEM_NC):
10073 Use passed descr instead of THREAD_SELF.
10074 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S
10075 (__lll_mutex_timedlock_wait): Correct expected value after
10076 spurious wakeup.
10077 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S:
10078 Release lock before waking up the waiters.
10079 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: Correct exit
10080 criteria. Reorderstruct passed to cleanup handler. Fix
10081 handling of cancellation and failung pthread_mutex_unlock call.
10082 Use __pthread_enable_asynccancel_2 instead of
10083 __pthread_enable_asynccancel.
10084 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
10085 Return result of lock re-get if it fails.
10086 * sysdeps/unix/sysv/linux/sh/pthread_once.S: Fix wrong argument
10087 for __pthread_cleanup_push.
10088 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Fix
10089 completely broken rwlock implementation.
10090 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
10091 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
10092 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
10093 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: Likewise.
10094 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
10095 * sysdeps/unix/sysv/linux/sh/sem_post.S: Fix error value. Use
10096 versioned_symbol macro.
10097 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Use versioned_symbol macro.
10098 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Likewise.
10099
c75d02f0
UD
101002003-03-27 Ulrich Drepper <drepper@redhat.com>
10101
5f5004df
UD
10102 * sysdeps/unix/sysv/linux/kernel-posix-timers.h: Don't declare
10103 __timer_helper_thread. Declare __start_helper_thread, __helper_once,
10104 and __helper_tid.
10105 (struct timer): Remove th and bar field.
10106 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): Remove
10107 debugging code. Create only one helper thread.
10108 * sysdeps/unix/sysv/linux/timer_delete.c (timer_delete): Don't kill
10109 helper thread.
10110 * sysdeps/unix/sysv/linux/timer_routines.c (timer_helper_thread):
10111 Renamed. Define statically. Use thread info from siginfo.
10112 (__helper_once): New variable.
10113 (__helper_tid): New variable.
10114 (__reset_helper_control): New function.
10115 (__start_helper_thread): New function.
10116
18d009ca
UD
10117 * pthread_create.c (start_thread): Don't use setjmp inside
10118 __builtin_expect to work around gcc bug.
10119
c75d02f0
UD
10120 * sysdeps/unix/sysv/linux/timer_delete.c (timer_delete): Even if
10121 timer_delete syscall fails, but not with ENOSYS, set
10122 __no_posix_timers.
10123
10124 * sysdeps/unix/sysv/linux/timer_settime.c [!__ASSUME_POSIX_TIMERS]
10125 (timer_settime): Fix typo.
28cf3058
UD
10126 * sysdeps/unix/sysv/linux/timer_getoverr.c
10127 [!__ASSUME_POSIX_TIMERS] (timer_getoverrun): Likewise.
c75d02f0 10128
049ac259
JJ
101292003-03-27 Jakub Jelinek <jakub@redhat.com>
10130
10131 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Fix
10132 offset of cleanupbuf.__prev.
10133
f93d39dd
JJ
101342003-03-26 Jakub Jelinek <jakub@redhat.com>
10135
10136 * sysdeps/unix/sysv/linux/timer_getoverr.c: Fix typo in name
10137 of included file.
10138
f064e4c5
UD
101392003-03-26 Ulrich Drepper <drepper@redhat.com>
10140
10141 * sysdeps/unix/sysv/linux/timer_create.c (timer_create): If EVP ==
10142 NULL provide default definition to syscall.
10143
83e886a3
RM
101442003-03-25 Roland McGrath <roland@redhat.com>
10145
10146 * sysdeps/pthread/posix-timer.h (TIMER_MAX): Define if not defined.
10147 (timer_id2ptr): Fix typo.
10148
09402f5b
UD
101492003-03-25 Ulrich Drepper <drepper@redhat.com>
10150
10151 * pthreadP.h: Define SIGCANCEL and SIGTIMER.
10152 * sysdeps/i386/pthreaddef.h: Remove SIGCANCEL definition.
10153 * sysdeps/ia64/pthreaddef.h: Likewise.
10154 * sysdeps/powerpc/pthreaddef.h: Likewise.
10155 * sysdeps/s390/pthreaddef.h: Likewise.
10156 * sysdeps/sh/pthreaddef.h: Likewise.
10157 * sysdeps/x86_64/pthreaddef.h: Likewise.
10158 * init.c (__pthread_initialize_minimal): Block SIGTIMER.
10159 * sysdeps/pthread/sigaction.c: Also prevent SIGTIMER handler from
10160 being changed.
10161 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Make sure
10162 SIGTIMER is not unblocked.
10163 * sysdeps/unix/sysv/linux/allocrtsig.c (current_rtmin): One more
10164 RT signal taken.
10165 * sysdeps/unix/sysv/linux/pthread_kill.c: Do not allow SIGTIMER to
10166 be send.
10167 * sysdeps/pthread/posix-timer.h (timer_id2ptr, timer_ptr2id): Just
10168 pass pointer through as ID.
10169 * sysdeps/unix/sysv/linux/bits/local_lim.h (TIMER_MAX): Removed.
10170 * sysdeps/unix/sysv/linux/kernel-posix-timers.h: New file.
10171 * sysdeps/unix/sysv/linux/timer_create.c: New file.
10172 * sysdeps/unix/sysv/linux/timer_delete.c: New file.
10173 * sysdeps/unix/sysv/linux/timer_getoverr.c: New file.
10174 * sysdeps/unix/sysv/linux/timer_gettime.c: New file.
10175 * sysdeps/unix/sysv/linux/timer_routines.c: New file.
10176 * sysdeps/unix/sysv/linux/timer_settime.c: New file.
10177 * sysdeps/unix/sysv/linux/ia64/Versions: New file.
10178 * sysdeps/unix/sysv/linux/ia64/timer_create.c: New file.
10179 * sysdeps/unix/sysv/linux/ia64/timer_delete.c: New file.
10180 * sysdeps/unix/sysv/linux/ia64/timer_getoverr.c: New file.
10181 * sysdeps/unix/sysv/linux/ia64/timer_gettime.c: New file.
10182 * sysdeps/unix/sysv/linux/ia64/timer_settime.c: New file.
10183 * sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions: New file.
10184 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_create.c: New file.
10185 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_delete.c: New file.
10186 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_getoverr.c: New file.
10187 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_gettime.c: New file.
10188 * sysdeps/unix/sysv/linux/powerpc/powerpc64/timer_settime.c: New file.
10189 * sysdeps/unix/sysv/linux/s390/s390-64/Versions: New file.
10190 * sysdeps/unix/sysv/linux/s390/s390-64/timer_create.c: New file.
10191 * sysdeps/unix/sysv/linux/s390/s390-64/timer_delete.c: New file.
10192 * sysdeps/unix/sysv/linux/s390/s390-64/timer_getoverr.c: New file.
10193 * sysdeps/unix/sysv/linux/s390/s390-64/timer_gettime.c: New file.
10194 * sysdeps/unix/sysv/linux/s390/s390-64/timer_settime.c: New file.
10195 * sysdeps/unix/sysv/linux/x86_64/Versions: New file.
10196 * sysdeps/unix/sysv/linux/x86_64/compat-timer.h: New file.
10197 * sysdeps/unix/sysv/linux/x86_64/timer_create.c: New file.
10198 * sysdeps/unix/sysv/linux/x86_64/timer_delete.c: New file.
10199 * sysdeps/unix/sysv/linux/x86_64/timer_getoverr.c: New file.
10200 * sysdeps/unix/sysv/linux/x86_64/timer_gettime.c: New file.
10201 * sysdeps/unix/sysv/linux/x86_64/timer_settime.c: New file.
10202
10203 * pthreadP.h: Remove FRAME_LEFT definition.
10204 * cleanup.c (_pthread_cleanup_push): Don't check for reference to
10205 already left frame. Programs which have this problem are not POSIX
10206 compliant.
10207 * cleanup_defer.c (_pthread_cleanup_push_defer): Likewise.
10208
5e826ab5
UD
102092003-03-24 Ulrich Drepper <drepper@redhat.com>
10210
10211 * sysdeps/pthread/tst-timer.c: Check return values of the
10212 functions we test.
10213
b910f788
RM
102142003-03-23 Roland McGrath <roland@redhat.com>
10215
3045a1fe
RM
10216 * tst-tls3.c (do_test) [! HAVE___THREAD]: Don't test anything.
10217 * tst-tls3mod.c: Likewise.
10218 * tst-tls1.c: Likewise.
10219 * tst-tls2.c: Likewise.
10220
85047fe3
RM
10221 * tst-mutex5.c (do_test): Unlock before destroy, otherwise we invoke
10222 undefined behavior.
10223
b910f788
RM
10224 * tst-join5.c (tf1, tf2): Add a cast.
10225
10226 * Makeconfig (includes): Append -I$(..)nptl to this variable.
10227
10228 * tst-barrier2.c (do_test) [! _POSIX_THREAD_PROCESS_SHARED]:
10229 Don't test anything.
10230 * tst-cond4.c: Likewise.
10231 * tst-cond6.c: Likewise.
10232 * tst-flock2.c: Likewise.
10233 * tst-mutex4.c: Likewise.
10234 * tst-rwlock4.c: Likewise.
10235 * tst-signal1.c: Likewise.
10236 * tst-spin2.c: Likewise.
10237 * tst-cond11.c [! _POSIX_CLOCK_SELECTION]: Likewise.
10238
10239 * tst-mutex4.c: Use test-skeleton.c.
10240 * tst-spin2.c: Likewise.
10241 * tst-sysconf.c: Likewise.
10242 * tst-barrier2.c: Likewise.
10243 * tst-cond4.c: Likewise.
10244 * tst-cond6.c: Likewise.
10245 * tst-rwlock4.c: Likewise.
10246 * tst-unload.c: Likewise.
10247 * tst-flock2.c (do_test): Use return instead of exit.
10248
4baa087a
RM
102492003-03-22 Jakub Jelinek <jakub@redhat.com>
10250
10251 * sysdeps/unix/sysv/linux/fork.c (__fork): Add libc_hidden_def.
10252
5a3ab2fc
UD
102532003-03-21 Ulrich Drepper <drepper@redhat.com>
10254
9f07eae2
UD
10255 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h
10256 (__lll_mutex_trylock): Use atomic_compare_and_exchange_val_acq
10257 instead of __lll_compare_and_swap.
10258 * sysdeps/unix/sysv/linux/ia64/pthread_once.c (__pthread_once):
10259 Likewise.
10260 Removed definition if __lll_compare_and_swap.
10261
5a3ab2fc
UD
10262 * cancellation.c: Adjust for new form of compare&exchange macros.
10263 * cleanup_defer.c: Likewise.
10264 * init.c: Likewise.
10265 * libc-cancellation.c: Likewise.
10266 * old_pthread_cond_broadcast.c: Likewise.
10267 * old_pthread_cond_signal.c: Likewise.
10268 * old_pthread_cond_timedwait.c: Likewise.
10269 * old_pthread_cond_wait.c: Likewise.
10270 * pthread_cancel.c: Likewise.
10271 * pthread_create.c: Likewise.
10272 * pthread_detach.c: Likewise.
10273 * pthread_join.c: Likewise.
10274 * pthread_key_delete.c: Likewise.
10275 * pthread_setcancelstate.c: Likewise.
10276 * pthread_setcanceltype.c: Likewise.
10277 * pthread_timedjoin.c: Likewise.
10278 * pthread_tryjoin.c: Likewise.
10279 * sysdeps/pthread/createthread.c: Likewise.
10280
b1aea098
UD
102812003-03-20 Ulrich Drepper <drepper@redhat.com>
10282
10283 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: Include <atomic.h>.
4baa087a 10284 Remove __lll_add, __lll_dec_if_positive, and __lll_test_and_set
b1aea098
UD
10285 definitions. Replace uses with calls to atomic_* functions.
10286 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Likewise.
10287 * sysdeps/unix/sysv/linux/lowlevellock.c: Replace __lll_add and
10288 __lll_test_and_set calls with atomic_exchange_and_add and
10289 atomic_exchange calls respectively.
10290 * sysdeps/unix/sysv/linux/sem_post.c: Likewise.
10291 * sysdeps/unix/sysv/linux/sem_timedwait.c: Likewise.
10292 * sysdeps/unix/sysv/linux/sem_trywait.c: Likewise.
10293 * sysdeps/unix/sysv/linux/sem_wait.c: Likewise.
10294 * sysdeps/unix/sysv/linux/ia64/pthread_once.c: Likewise.
10295 * sysdeps/unix/sysv/linux/ia64/sem_port.c: Likewise.
10296 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c: Likewise.
10297
10298 * allocatestack.c (allocate_stack): Assume atomic_exchange_and_add
10299 returns the old value.
10300
100a7100
RM
103012003-03-20 Martin Schwidefsky <sky@mschwid3.boeblingen.de.ibm.com>
10302
10303 * sysdeps/s390/pthread_spin_lock.c (pthread_spin_lock): Use type
10304 int for variable OLDVAL and correct inline assembler contraint.
10305 * sysdeps/s390/pthread_spin_trylock.c (pthread_spin_trylock): Use
10306 type int for variable OLD.
10307
10308 * sysdeps/s390/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define it
10309 only for s390-32.
10310 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
10311 (SINGLE_THREAD_P): Use global variable __local_multiple_threads
10312 instead of multiple_threads field in the TCB.
10313
95767b36
UD
103142003-03-19 Ulrich Drepper <drepper@redhat.com>
10315
4009bf40
UD
10316 * sysdeps/i386/i686/bits/atomic.h: Removed.
10317 * sysdeps/i386/i586/bits/atomic.h: Removed.
10318 * sysdeps/i386/i486/bits/atomic.h: Removed. Moved to glibc.
10319 * sysdeps/x86_64/bits/atomic.h: Removed. Moved to glibc.
10320 * sysdeps/s390/bits/atomic.h: Removed. Moved to glibc.
10321 * sysdeps/sh/bits/atomic.h: Removed. Moved to glibc.
10322 * sysdeps/ia64/bits/atomic.h: Removed. Moved to glibc.
10323 * sysdeps/powerpc/bits/atomic.h: Removed. Moved to glibc.
10324 * atomic.h: Removed. Moved to glibc.
10325
560a784f
UD
10326 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Add
10327 support for clock selection.
10328
95767b36
UD
10329 * sysdeps/pthread/pthread_cond_broadcast.c: Release lock before
10330 signalling waiters.
10331
043ad426
RM
103322003-03-18 Roland McGrath <roland@redhat.com>
10333
94659495
RM
10334 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (__lll_test_and_set):
10335 Add __lll_rel_instr first. Add memory clobber.
10336 (lll_mutex_unlock): Use __lll_test_and_set.
10337 From Paul Mackerras <paulus@samba.org>.
10338
10339 * sysdeps/powerpc/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define
10340 unconditionally.
10341 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h
10342 (SINGLE_THREAD_P): Add `header.' prefix.
10343 From Paul Mackerras <paulus@samba.org>.
10344
043ad426
RM
10345 * Versions (libpthread: GLIBC_2.3.2): Move pthread_tryjoin_np and
10346 pthread_timedjoin_np to ...
10347 (libpthread: GLIBC_2.3.3): ... here.
10348 (libpthread: GLIBC_2.2): Move pthread_barrierattr_getpshared there too.
10349
10350 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
10351 Avoid shadowing VAL variable.
10352
10353 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h (__lll_test_and_set):
10354 New macro.
10355
86a9ee5e
UD
103562003-03-18 Ulrich Drepper <drepper@redhat.com>
10357
ac9e0aa1
UD
10358 * Makefile (tests): Add tst-cond11.
10359 * tst-cond11.c: New file.
10360
a14b373c
UD
10361 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Reorder
10362 struct passed to cleanup handler to eliminate one more
10363 instruction.
10364 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
10365
24a49f38
UD
10366 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
10367 (pthrad_cond_t): Replace __unused field with __clock.
10368
10369 * sysdeps/pthread/pthread_cond_wait.c: Release condvar lock before
10370 waken all waiters in cleanup handler.
10371 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
10372 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
10373
86a9ee5e
UD
10374 * pthread_condattr_getclock.c: New file.
10375 * pthread_condattr_setclock.c: New file.
10376 * sysdeps/pthread/pthread.h: Declare these new functions.
10377 * Versions [GLIBC_2.3.3] (libpthread): Add the new functions.
10378 * Makefile (libpthread-routines): Add the new functions.
10379 * sysdeps/unix/sysv/linux/internaltypes.h (struct pthread_condattr):
10380 Renamed field to value. Document use of the bits.
10381 * pthread_condattr_getpshared.c: Adjust for struct pthread_condattr
10382 change.
10383 * pthread_condattr_setpshared.c: Likewise.
d5cb8389 10384 * pthread_cond_init.c (__pthread_cond_init): Initialized __clock field.
86a9ee5e
UD
10385 * sysdeps/unix/sysv/linux/lowlevelcond.sym: Add cond_clock symbol.
10386 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
10387 Add __clock field.
10388 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: Likewise.
10389 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: Likewise.
10390 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: Likewise.
10391 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: Likewise.
10392 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S:
10393 Implement clock selection.
10394 * sysdeps/pthread/pthread_cond_timedwait.c: Likewise.
10395 * pthread-errnos.sym: Add ENOSYS.
10396 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
10397 _POSIX_CLOCK_SELECTION.
10398 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
10399
10400 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Remove
10401 invalid .size directive.
10402
98054a05
RM
104032003-03-17 Roland McGrath <roland@redhat.com>
10404
10405 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_lock_wait):
10406 Formatting tweaks.
10407
001bea71
UD
104082003-03-17 Ulrich Drepper <drepper@redhat.com>
10409
4773086e
UD
10410 * sysdeps/unix/sysv/linux/ia64/pthread_once.c: Use __builtin_expect.
10411 Use __lll_add instead of spelling it out. Use protected symbol names.
10412 * sysdeps/unix/sysv/linux/ia64/sem_post.c: Use __builtin_expect.
10413 Use __lll_add.
10414 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (__lll_compare_and_swap):
10415 Renamed from lll_compare_and_swap. Use new name where necessary.
10416 (__lll_add): Defined.
10417 (__lll_dec_if_positive): Defined.
10418 (__lll_test_and_set): Defined.
10419 * sysdeps/ia64/pthread_spin_init.c: Removed.
10420 * sysdeps/unix/sysv/linux/ia64/lowlevelmutex.c: Removed.
10421 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: Removed.
10422 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: Removed.
10423 * sysdeps/unix/sysv/linux/ia64/lowlevellock.c: Removed.
10424 * sysdeps/unix/sysv/linux/ia64/libc-lowlevellock.c: Removed.
10425 * sysdeps/unix/sysv/linux/ia64/libc-lowlevelmutex.c: Removed.
10426 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: Removed.
001bea71
UD
10427 * sysdeps/ia64/bits/atomic.h: Add __builtin_expect where appropriate.
10428 * sysdeps/ia64/pthread_spin_unlock.c (pthread_spin_unlock): Use
10429 __sync_lock_release_si.
10430 Patch by Jakub Jelinek.
10431
10432 * sysdeps/unix/sysv/linux/lowlevellock.c (__lll_timedlock_wait):
10433 Fix timeout handling.
10434 (__lll_timedwait_tid): Likewise.
10435 (lll_unlock_wake_cb): Wake up other waiters if necessary.
10436 Patch by Jakub Jelinek.
10437
10438 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: Pretty printing.
10439
de4471dd
RM
104402003-03-17 Roland McGrath <roland@redhat.com>
10441
10442 PowerPC port contributed by Paul Mackerras <paulus@samba.org>.
10443 * sysdeps/pthread/pthread_spin_init.c: New file.
10444 * sysdeps/pthread/pthread_spin_unlock.c: New file.
10445 * sysdeps/powerpc/Makefile: New file.
10446 * sysdeps/powerpc/pthread_spin_lock.c: New file.
10447 * sysdeps/powerpc/pthread_spin_trylock.c: New file.
10448 * sysdeps/powerpc/pthreaddef.h: New file.
10449 * sysdeps/powerpc/tcb-offsets.sym: New file.
10450 * sysdeps/powerpc/td_ta_map_lwp2thr.c: New file.
10451 * sysdeps/powerpc/tls.h: New file.
10452 * sysdeps/powerpc/bits/atomic.h: New file.
10453 * sysdeps/unix/sysv/linux/libc-lowlevelmutex.c: New file.
10454 * sysdeps/unix/sysv/linux/libc-lowlevellock.c: New file.
10455 * sysdeps/unix/sysv/linux/lowlevellock.c: New file.
98054a05 10456
de4471dd
RM
10457 * sysdeps/unix/sysv/linux/lowlevelmutex.c: New file.
10458 * sysdeps/unix/sysv/linux/sem_post.c: New file.
10459 * sysdeps/unix/sysv/linux/sem_timedwait.c: New file.
10460 * sysdeps/unix/sysv/linux/sem_trywait.c: New file.
10461 * sysdeps/unix/sysv/linux/sem_wait.c: New file.
10462 * sysdeps/unix/sysv/linux/powerpc/Makefile: New file.
10463 * sysdeps/unix/sysv/linux/powerpc/createthread.c: New file.
10464 * sysdeps/unix/sysv/linux/powerpc/fork.c: New file.
10465 * sysdeps/unix/sysv/linux/powerpc/lowlevellock.h: New file.
10466 * sysdeps/unix/sysv/linux/powerpc/pt-vfork.S: New file.
10467 * sysdeps/unix/sysv/linux/powerpc/pthread_once.c: New file.
10468 * sysdeps/unix/sysv/linux/powerpc/bits/pthreadtypes.h: New file.
10469 * sysdeps/unix/sysv/linux/powerpc/bits/semaphore.h: New file.
10470 * sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep-cancel.h: New file.
10471 * sysdeps/unix/sysv/linux/powerpc/powerpc64/sysdep-cancel.h: New file.
10472
10473 * sysdeps/unix/sysv/linux/ia64/lowlevellock.c: Use __gettimeofday,
10474 not gettimeofday.
10475 * sysdeps/unix/sysv/linux/ia64/lowlevelmutex.c: Likewise.
10476 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: Likewise.
10477 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Likewise.
10478 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c: Likewise.
10479 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
10480
5778033f
UD
104812003-03-17 Ulrich Drepper <drepper@redhat.com>
10482
10483 * sysdeps/pthread/pthread_cond_wait.c: Correct exit criteria.
10484 * sysdeps/pthread/pthread_cond_timedwait.c: Likewise.
10485 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
10486 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
10487 Patch by Ewald Snel <ewald@rambo.its.tudelft.nl>.
10488
796038f8
RM
104892003-03-16 Roland McGrath <roland@redhat.com>
10490
10491 * tst-fork4.c: Include <string.h>.
10492 * tst-signal2.c: Likewise.
10493 * tst-mutex5.c (do_test): exit -> return.
10494 * tst-mutex2.c: Include <stdlib.h>.
10495
51d0678c
UD
104962003-03-16 Ulrich Drepper <drepper@redhat.com>
10497
5778033f
UD
10498 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S
10499 (__lll_mutex_timedlock_wait): Correct expected value after
10500 spurious wakeup. Otherwise we would never wait again.
10501
b6e2f87a
UD
10502 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Work around red
10503 zone versus inline asm stupidity. Use correct instructions.
10504
51d0678c
UD
10505 * tst-rwlock6.c: Add some more status output.
10506
8112cc70
RM
105072003-03-15 Roland McGrath <roland@redhat.com>
10508
10509 * sysdeps/pthread/configure.in: New file.
10510 * sysdeps/pthread/configure: New file (generated).
10511
49773c19
UD
105122003-03-15 Ulrich Drepper <drepper@redhat.com>
10513
10514 * allocatestack.c (allocate_stack): Store the exact stack size of
10515 user allocated stacks.
10516
eec0ca9f
JJ
105172003-03-15 Jakub Jelinek <jakub@redhat.com>
10518
10519 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h
10520 (SINGLE_THREAD): Use `header' prefix instead of `header.data'.
10521 * sysdeps/sh/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Likewise.
10522 * sysdeps/sh/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define.
10523 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h (SINGLE_THREAD_P):
10524 Use `header.' prefix.
10525 * sysdeps/ia64/tcb-offsets.sym (MULTIPLE_THREADS_OFFSET): Likewise.
10526
a87731e2
UD
105272003-03-15 Ulrich Drepper <drepper@redhat.com>
10528
10529 * sysdeps/x86_64/pthreaddef.h (CURRENT_STACK_FRAME): Don't use
10530 __builtin_frame_address, use stack pointer.
10531
10532 * sysdeps/unix/sysv/linux/jmp-unwind.c: Use CURRENT_STACK_FRAME
10533 instead of __builtin_frame_pointer.
10534
e22a221d
UD
105352003-03-14 Ulrich Drepper <drepper@redhat.com>
10536
92ed3daf
UD
10537 * tst-basic1.c (do_test): Add cast to avoid warning.
10538 * tst-basic2.c (do_test): Likewise.
10539
9b89567d
UD
10540 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Use correct
10541 amount of stack correction.
10542
e22a221d
UD
10543 * tst-fork4.c: Use test-skeleton.c.
10544
2e49caba
RM
105452003-03-14 Roland McGrath <roland@redhat.com>
10546
10547 * init.c: Fix typo "#eli" for "#else".
10548
415ef7d8
RM
105492003-03-14 Steven Munroe <sjmunroe@us.ibm.com>
10550
10551 * allocatestack.c (__stack_user): Use hidden_data_def.
10552 * pthread_create.c (__pthread_keys): Likewise.
10553
10554 * init.c [__powerpc__] (__NR_set_tid_address): Define it.
10555
52287505
RM
105562003-03-14 Roland McGrath <roland@redhat.com>
10557
415ef7d8
RM
10558 * tst-fork4.c: New file.
10559 * Makefile (tests): Add it.
10560
52287505
RM
10561 * descr.h (struct pthread): Move the union out of [!TLS_DTV_AT_TP], so
10562 we always define the padding space.
10563 [!TLS_DTV_AT_TP]: Give tcbhead_t field a name, `header', since GCC
10564 stopped supporting its own extensions fully.
10565 [TLS_MULTIPLE_THREADS_IN_TCB]: Put `multiple_threads' inside a wrapper
10566 struct also called `header', so `header.multiple_threads' is the field
10567 name to use on all machines.
10568 * allocatestack.c (allocate_stack): Use `header.' prefix.
10569 * sysdeps/pthread/createthread.c (create_thread): Likewise.
10570 * pthread_create.c (__pthread_create_2_1): Likewise.
10571 * sysdeps/i386/tls.h (INSTALL_NEW_DTV, THREAD_DTV): Likewise.
10572 (THREAD_SELF): Likewise.
10573 * sysdeps/x86_64/tls.h: Likewise.
10574 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
10575 (SINGLE_THREAD_P): Likewise.
10576 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
10577 (SINGLE_THREAD_P): Likewise.
10578 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
10579 (SINGLE_THREAD_P): Likewise.
10580
10581 * sysdeps/s390/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Use REGS[18]
10582 value directly.
10583
c44bf9aa
UD
105842003-03-14 Ulrich Drepper <drepper@redhat.com>
10585
e22a221d
UD
10586 * pthread_create.c (start_thread): Use CALL_THREAD_FCT if defined.
10587 * sysdeps/i386/tls.h: Define CALL_THREAD_FCT.
10588
0eb18281
UD
10589 * pthread_create.c (start_thread): setjmp is expected to return 0.
10590
c44bf9aa
UD
10591 * sysdeps/x86_64/tls.h (THREAD_GETMEM): Mark asms volatile.
10592 (THREAD_GETMEM_NC): Likewise.
10593
564cd8b6
UD
105942003-03-13 Ulrich Drepper <drepper@redhat.com>
10595
10596 * allocatestack.c (allocate_stack): If MULTI_PAGE_ALIASING is defined
10597 and the size of the stack which must be allocated is a multiple,
10598 allocate one more page.
10599 * sysdeps/i386/i686/Makefile: Don't define COLORING_INCREMENT, but
10600 MULTI_PAGE_ALIASING.
10601
6461e577
RM
106022003-03-13 Roland McGrath <roland@redhat.com>
10603
10604 * pthread_create.c (start_thread): Set EXITING_BIT after the
10605 event-reporting (and destructors), not before.
10606
b5ec5617
UD
106072003-03-13 Jakub Jelinek <jakub@redhat.com>
10608
6461e577
RM
10609 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_timed_wait,
10610 lll_futex_wake): Declare register variables as long int instead of
10611 unsigned long int. Patch by Ian Wienand <ianw@gelato.unsw.edu.au>.
10612 Make syscall arguments clobbered by the syscall.
10613 (lll_futex_wait): Define using lll_futex_timed_wait.
10614
10615 * sysdeps/ia64/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Cast regs[13]
10616 to void *.
10617
10618 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Only declare and set
10619 PPID if [! NDEBUG].
10620
10621 * allocatestack.c (nptl_ncreated): Only declare if
10622 COLORING_INCREMENT != 0.
10623
10624 * pthreadP.h (__pthread_enable_asynccancel_2): New prototype.
10625 (__libc_enable_asynccancel_2): Remove prototype.
10626
b5ec5617
UD
10627 * sysdeps/unix/sysv/linux/ia64/fork.c (ARCH_FORK): Swap ptid and
10628 ctid to match kernel.
10629
d0369fb8
UD
106302003-03-12 Ulrich Drepper <drepper@redhat.com>
10631
7588880f
UD
10632 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Add
10633 libc_multiple_threads.
10634 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Move definition of
10635 __libc_multiple_threads to...
10636 * sysdeps/unix/sysv/linux/libc_multiple_threads.c: ...here. New file.
10637
10638 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Remove unnecessary
10639 versioning.
10640 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
10641 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
10642
10643 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S
10644 (__pthread_once_internal): Define.
10645
10646 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Use shlib-compat.h
10647 macros instead of .symver directly.
10648 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
10649 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
10650
d0369fb8
UD
10651 * sysdeps/x86_64/tls.h [__ASSEMBLER__]: Include tcb-offsets.h.
10652 * sysdeps/x86_64/tcb-offsets.sym: New file.
10653 * sysdeps/x86_64/Makefile: New file.
10654
10655 * sysdeps/i386/tcb-offsets.sym: Add SELF.
10656 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Use SELF
10657 to access own pthread_t in TCB.
10658 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
10659 Likewise.
10660 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
10661 Likewise.
10662 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
10663
0bb2ac85
RM
106642003-03-12 Roland McGrath <roland@redhat.com>
10665
10666 * pthread-errnos.sym: New file.
10667 * Makefile (gen-as-const-headers): New variable, list that file.
10668 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Include generated
10669 header <pthread-errnos.h> instead of defining errno values here.
10670 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
10671 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
10672 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
10673 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
10674 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
10675 Likewise.
10676 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
10677 Likewise.
10678 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
10679 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
10680 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
10681 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
10682 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
10683 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
10684 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
10685 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
10686 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
10687 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Likewise.
10688 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
10689 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Likewise.
10690 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
10691 * sysdeps/unix/sysv/linux/sh/sem_post.S: Likewise.
10692 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Likewise.
10693 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
10694 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
10695 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
10696 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
10697 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
10698 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
10699 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Likewise.
10700 * sysdeps/i386/i486/pthread_spin_trylock.S: Likewise.
10701 * sysdeps/x86_64/pthread_spin_trylock.S: Likewise.
10702 * sysdeps/sh/pthread_spin_trylock.S: Likewise.
10703 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
10704 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
10705
10706 * sysdeps/unix/sysv/linux/fork.c: Add an assert to check that
10707 CLONE_CHILD_SETTID worked.
10708
35e148cb
UD
107092003-03-12 Ulrich Drepper <drepper@redhat.com>
10710
d0369fb8
UD
10711 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S: New
10712 file.
10713 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S: New
10714 file.
10715
10716 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
10717 (pthread_cond_t): Add padding.
10718
da49194d
UD
10719 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: New file.
10720 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: New file.
10721 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: New file.
10722
35e148cb
UD
10723 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
10724 (__pthread_rwlock_timedwrlock): Add missing opcode suffix.
10725 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
10726 (__pthread_rwlock_timedrdlock): Likewise.
10727 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S
10728 (__pthread_rwlock_wrlock): Likewise.
10729 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S
10730 (__pthread_rwlock_rdlock): Likewise.
10731
10732 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: New file.
10733
10734 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Return
10735 result of lock re-get if it fails.
10736
3e976b96
UD
107372003-03-11 Ulrich Drepper <drepper@redhat.com>
10738
5a03acfe
UD
10739 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Fix asm syntax.
10740 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
10741 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Likewise.
10742 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
10743 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
10744 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
10745 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
10746 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
10747 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
10748 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
10749
10750 * sysdeps/x86_64/tls.h (THREAD_SELF, THREAD_GETMEM, THREAD_GETMEM_NC,
10751 THREAD_SETMEM, THREAD_SETMEM_NC): Correct asm syntax.
10752
10753 * allocatestack.c [! TLS_MULTIPLE_THREADS_IN_TCB] (allocate_stack):
10754 Initialize *__libc_multiple_threads_ptr not __libc_multiple_threads.
10755 * sysdeps/pthread/createthread.c [! TLS_MULTIPLE_THREADS_IN_TCB]
10756 (create_thread): Likewise.
10757 Define __pthread_multiple_threads and __libc_multiple_threads_ptr.
10758 * init.c (__pthread_initialize_minimal_internal): Initialize
10759 __libc_multiple_threads_ptr if necessary.
10760 * pthreadP.h: Adjust prototype for __libc_pthread_init. Declare
10761 __pthread_multiple_threads and __libc_multiple_threads_ptr.
10762 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Define
10763 __libc_multiple_threads.
10764 (__libc_pthread_init): Return pointer to __libc_pthread_init if
10765 necessary.
10766
10767 * sysdeps/i386/tls.h (THREAD_SETMEM): Fix one-byte variant.
10768 (THREAD_SETMEM_NC): Likewise.
10769
10770 * sysdeps/x86_64/pthread_spin_trylock.c: Removed.
10771 * sysdeps/x86_64/pthread_spin_trylock.S: New file.
10772 * sysdeps/x86_64/pthread_spin_unlock.c: Removed.
10773 * sysdeps/x86_64/pthread_spin_unlock.S: New file.
10774
10775 * sysdeps/i386/i486/pthread_spin_trylock.S (pthread_spin_trylock):
10776 Eliminate one entire instruction.
10777
32a589b1
UD
10778 * cancellation.c (__pthread_enable_asynccancel_2): New function.
10779 * pthreadP.h: Declare __pthread_enable_asynccancel_2.
10780 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
10781 (__pthread_cond_timedwait): Use __pthread_enable_asynccancel_2
10782 instead of __pthread_enable_asynccancel.
10783 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
10784 (__pthread_cond_wait): Likewise.
10785 * sysdeps/pthread/pthread_cond_timedwait.c
10786 (__pthread_cond_timedwait): Likewise.
10787 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
10788
3e976b96
UD
10789 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
10790 (__condvar_cleanup): Wake up all waiters in case we got signaled
10791 after being woken up but before disabling asynchronous
10792 cancellation.
10793 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Likewise.
10794 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
10795 (__condvar_cleanup): Likewise.
10796
10797 * init.c (__NR_set_tid_address): If already defined, don't redefine.
10798 Make it an error if architecture has no #if case. Add x86-64.
10799
10800 * sysdeps/unix/sysv/linux/x86_64/Makefile: Add flags for
10801 pt-initfini.s generation.
10802
10803 * sysdeps/x86_64/tls.h: Include <asm/prctl.h>.
10804 (TLS_INIT_TP): Fix typo.
10805
6c477888
UD
108062003-03-11 Jakub Jelinek <jakub@redhat.com>
10807
10808 * sysdeps/ia64/bits/atomic.h (atomic_exchange_and_add): Swap 2nd and
10809 3rd argument of __arch_compare_and_exchange_{32,64}_val_acq.
10810
10811 * sysdeps/unix/sysv/linux/ia64/sem_post.c: Include semaphore.h.
10812 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: Likewise.
10813 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: Likewise.
10814 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: Likewise.
10815 * sysdeps/unix/sysv/linux/s390/sem_post.c: Likewise.
10816 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
10817 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Likewise.
10818 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Likewise.
10819
ea694823
UD
108202003-03-11 Ulrich Drepper <drepper@redhat.com>
10821
6c477888
UD
10822 * sysdeps/pthread/pthread_cond_timedwait.c
10823 (__pthread_cond_timedwait): Return the result of the final
10824 locking. If it succeeds, the regular function return value.
10825
10826 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait):
10827 Return result of the final locking.
10828 * version.c (__nptl_main): Work around problems with the strange
10829 INTERNAL_SYSCALL macro on ppc32.
10830 * init.c (__pthread_initialize_minimal_internal): Unblock
10831 SIGCANCEL in case the parent blocked it.
10832 Reported by Paul Mackerras <paulus@samba.org>.
10833
ea694823
UD
10834 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: New file.
10835 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: New file.
10836 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: New file.
10837
b33e6163
RM
108382003-03-11 Jakub Jelinek <jakub@redhat.com>
10839
10840 * sysdeps/pthread/pthread_cond_timedwait.c
10841 (__pthread_cond_timedwait): Unlock and fail if
10842 __pthread_mutex_unlock_internal failed.
10843
10844 * sysdeps/pthread/createthread.c (ARCH_CLONE): Define if not defined.
10845 (create_thread): Only assert PD->tcb != NULL under [TLS_TCB_AT_TP].
10846 Use ARCH_CLONE.
10847 * allocatestack.c (ALLOCATE_STACK_PARMS): New macro.
10848 [NEED_SEPARATE_REGISTER_STACK] (STACK_VARIABLES,
10849 STACK_VARIABLES_ARGS, STACK_VARIABLES_PARMS, ALLOCATE_STACK_PARMS,
10850 ALLOCATE_STACK): New macros.
10851 (TLS_TPADJ): New macro.
10852 (get_cached_stack, queue_stack, __deallocate_stack): Use TLS_TPADJ.
10853 (allocate_stack): Handle TLS_DTV_AT_TP and
10854 NEED_SEPARATE_REGISTER_STACK. Use TLS_TPADJ.
10855 * pthread_create.c (__pthread_create_2_1) [! TLS_TCB_AT_TP]:
10856 Don't set PD->self.
10857 * init.c [__ia64__] (__NR_set_tid_address): Define.
10858
10859 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: New file.
10860 * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: New file.
10861 * sysdeps/unix/sysv/linux/ia64/fork.c: New file.
10862 * sysdeps/unix/sysv/linux/ia64/createthread.c: New file.
10863 * sysdeps/unix/sysv/linux/ia64/libc-lowlevellock.c: New file.
10864 * sysdeps/unix/sysv/linux/ia64/libc-lowlevelmutex.c: New file.
10865 * sysdeps/unix/sysv/linux/ia64/lowlevellock.c: New file.
10866 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: New file.
10867 * sysdeps/unix/sysv/linux/ia64/lowlevelmutex.c: New file.
10868 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: New file.
10869 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: New file.
10870 * sysdeps/unix/sysv/linux/ia64/pthread_once.c: New file.
10871 * sysdeps/unix/sysv/linux/ia64/sem_post.c: New file.
10872 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: New file.
10873 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: New file.
10874 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: New file.
10875 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: New file.
10876 * sysdeps/ia64/bits/atomic.h: New file.
10877 * sysdeps/ia64/Makefile: New file.
10878 * sysdeps/ia64/pthread_spin_init.c: New file.
10879 * sysdeps/ia64/pthread_spin_lock.c: New file.
10880 * sysdeps/ia64/pthread_spin_trylock.c: New file.
10881 * sysdeps/ia64/pthread_spin_unlock.c: New file.
10882 * sysdeps/ia64/pthreaddef.h: New file.
10883 * sysdeps/ia64/tcb-offsets.sym: New file.
10884 * sysdeps/ia64/td_ta_map_lwp2thr.c: New file.
10885 * sysdeps/ia64/tls.h: New file.
10886
10887 * sysdeps/s390/pthreaddef.h (__exit_thread_inline): Pass 1 argument
10888 to syscall instead of no arguments.
10889
2b30b2e5
UD
108902003-03-10 Ulrich Drepper <drepper@redhat.com>
10891
db5f2fc9
UD
10892 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: New file.
10893 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: New file.
10894 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: New file.
10895 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: New file.
10896
10897 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Fix error value in
10898 unused code.
10899
6a4263e3
UD
10900 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: New file
10901
3de7c2a9
UD
10902 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
10903 lowlevelbarrier.sym.
10904 * sysdeps/unix/sysv/linux/lowlevelbarrier.sym: New file.
10905 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S:
10906 Include lowlevelbarrier.h and don't define offsets locally.
6a4263e3 10907 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Likewise.
3de7c2a9 10908
2a544d82
UD
10909 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
10910 (__lll_mutex_lock_wait): Reverse order of first two parameters.
10911 (__lll_mutex_timedlock_wait): Likewise.
10912 (lll_mutex_lock): Adjust asm for that.
10913 (lll_mutex_timedlock): Likewise. Mark cx, cc, r10 as clobbered.
10914 (lll_lock): Adjust asm for operand order change.
10915 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: New file.
10916 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevelmutex.S: New file.
10917
ec06436c
UD
10918 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (__lll_lock_wait):
10919 Reverse order of parameters.
10920 (__lll_timedwait_tid): Remove regparms attribute.
10921 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: New file.
10922 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: New file.
10923
3273832c
UD
10924 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
10925 (__lll_timedwait_tid): Remove one unnecessary instruction.
10926
51f32ab8
UD
10927 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Define
10928 __lll_mutex_timedlock_wait only for NOT_IN_libc.
10929 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: Include
10930 lowlevelmutex.S.
10931
10932 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Define
10933 lll_unlock_wake_cb, __lll_wait_tid, and __lll_timedwait_tid only
10934 for NOT_IN_libc.
10935 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Include
10936 lowlevellock.S.
10937
fad48d9e
UD
10938 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Don't define
10939 LOCK is already defined. Don't define __lll_mutex_timedlock_wait
10940 for libc.so.
10941 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Only
10942 define LOCK here (if UP is not defined). The actual code is in
10943 lowlevelmutex.S.
10944
9356d063
UD
10945 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Don't define
10946 LOCK is already defined. Don't define lll_unlock_wake_cb and
10947 __lll_timedwait_tid for libc.so.
10948 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Only
10949 define LOCK here (if UP is not defined). The actual code is in
10950 lowlevellock.S.
10951
ebf0cbc5 10952 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Not needed anymore.
106f6f9d
UD
10953 * sysdeps/unix/sysv/linux/s390/lowlevelsem.h: Likewise.
10954 * sysdeps/unix/sysv/linux/s390/sem_post.c: Include lowlevellock.h
10955 instead of lowlevelsem.h.
10956 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
10957 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Likewise.
10958 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Likewise.
0be8ee21 10959
c915e5ad
UD
10960 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
10961 lowlevelrwlock.sym.
10962 * sysdeps/unix/sysv/linux/lowlevelrwlock.sym: New file.
10963 * sysdeps/unix/sysv/linux/i386/lowlevelrwlock.h: Removed.
146fa1ee 10964 * sysdeps/unix/sysv/linux/sh/lowlevelrwlock.h: Removed.
c915e5ad 10965
4c3c2e8a
UD
10966 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_trylock): Fix
10967 register loading.
10968 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_trylock): Undo
10969 last changed. D'oh.
10970
2b30b2e5
UD
10971 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: New file.
10972
10973 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove declaration
10974 of __libc_locking_needed.
10975 (lll_trylock): Initialize %eax to zero.
10976
2b30b2e5
UD
10977 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Update
10978 pthread_cond_t definition.
10979
e48f9638
RM
109802003-03-10 Roland McGrath <roland@redhat.com>
10981
10982 * sysdeps/unix/sysv/linux/lowlevelcond.sym: New file.
10983 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add it.
10984 * sysdeps/unix/sysv/linux/sh/lowlevelcond.h: File removed.
10985 * sysdeps/unix/sysv/linux/i386/lowlevelcond.h: Likewise.
10986 * sysdeps/unix/sysv/linux/x86_64/lowlevelcond.h: Likewise.
10987
10988 * allocatestack.c (allocate_stack) [!TLS_MULTIPLE_THREADS_IN_TCB]:
10989 Instead of setting PD->multiple_threads, set globals
10990 __pthread_multiple_threads and __libc_multiple_threads.
10991 * sysdeps/pthread/createthread.c (create_thread): Likewise.
10992 * sysdeps/i386/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define it.
10993 * sysdeps/s390/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Likewise.
10994
10995 * descr.h (struct pthread): Conditionalize first member on
10996 [!TLS_DTV_AT_TP]. Replace the `header' member with an anonymous union
10997 containing an anonymous tcbhead_t. Move `list' member out.
10998 [TLS_MULTIPLE_THREADS_IN_TCB]: Define a `multiple_threads' member.
10999 * allocatestack.c: Remove use of `header.data.' prefix.
11000 * pthread_create.c: Likewise.
11001 * init.c (__pthread_initialize_minimal_internal): Likewise.
11002 * sysdeps/pthread/createthread.c (create_thread): Likewise.
11003 * sysdeps/i386/tls.h (INSTALL_DTV): Add parens.
11004 (THREAD_SELF, THREAD_DTV, INSTALL_NEW_DTV): No `header.data.' prefix.
11005 * sysdeps/x86_64/tls.h: Likewise.
11006 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
11007 (SINGLE_THREAD_P): Likewise.
11008 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
11009 (SINGLE_THREAD_P): Likewise.
11010 * sysdeps/i386/tls.h (tcbhead_t): Remove `list' member.
11011 * sysdeps/s390/tls.h (tcbhead_t): Likewise.
11012
c37cae9e
UD
110132003-03-09 Ulrich Drepper <drepper@redhat.com>
11014
d38c777e
RM
11015 * sysdeps/unix/sysv/linux/x86_64/lowlevelcond.h: New file.
11016
7b44a5e0 11017 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: New file.
2b30b2e5 11018 * sysdeps/unix/sysv/linux/x86_64/fork.c: New file.
7b44a5e0 11019
c2e5e085
UD
11020 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Fix many
11021 leftovers from the ia32 code.
11022
11023 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Remove unneccessary
11024 memory load.
11025 (clear_once_control): Don't load %esi.
11026
11027 * sysdeps/x86_64/tls.h: Remove all traces of segment descriptor
11028 handling.
11029
11030 * sysdeps/unix/sysv/linux/x86_64/fork.c: New file.
11031
cd4b2a55
UD
11032 * sysdeps/unix/sysv/linux/s390/createthread.c: Moved to...
11033 * sysdeps/unix/sysv/linux/createthread.c: ...here.
11034
c37cae9e
UD
11035 * Makefile (tests): Add tst-cond10.
11036 * tst-cond10.c: New file.
11037
d130a341
UD
110382003-03-08 Ulrich Drepper <drepper@redhat.com>
11039
ccf1d573
UD
11040 * tst-tls2.c (do_test): Add TEMP_FAILURE_RETRY around sem_wait call.
11041 * tst-signal3.c (do_test): Likewise.
11042 * tst-sem5.c (do_test): Likewise.
11043 * tst-kill6.c (do_test): Likewise.
11044 * tst-tls3.c (do_test): Likewise. Include <errno.h>.
11045
11046 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use add/sub instead
11047 of inc/dec.
11048 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Likewise.
11049 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise
11050 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
11051 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
11052 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
11053 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
11054 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
11055 Likewise.
11056 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
11057 Likewise.
11058 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
11059 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
11060 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
11061 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
11062 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
11063 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
11064 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
11065 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
11066
d130a341
UD
11067 * allocatestack.c (allocate_stack): If mprotect() fails free the
11068 TLS memory.
11069
bc6389ad
UD
110702003-03-07 Ulrich Drepper <drepper@redhat.com>
11071
41d4d223
UD
11072 * sysdeps/i386/i486/bits/atomic.h: Fix a few unused definitions.
11073
11074 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove all trace of
11075 lll_wake_tid. This was used only to work around kernel limits in
11076 the early days.
11077 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
11078 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Likewise.
11079 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
11080 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
11081
bc6389ad
UD
11082 * init.c (__static_tls_align_m1): Renamed from __static_tls_align.
11083 (__pthread_initialize_minimal_internal): Change initialization of
11084 __static_tls_align_m1 appropriately.
11085 * pthreadP.h (__static_tls_align_m1): Renamed from
11086 __static_tls_align.
11087 * allocatestack.c (allocate_stack): Use __static_tls_align_m1
11088 instead of __static_tls_align-1.
11089
cc775edf
UD
110902003-03-04 Ulrich Drepper <drepper@redhat.com>
11091
0de28d5c 11092 * sysdeps/unix/sysv/linux/x86_64/Makefile: New file.
6245b6ae 11093
518b5308
UD
11094 * pthread_create.c: Define __pthread_keys using nocommon
11095 attribute, not by placing it explicitly in bss.
11096 Remove DEFINE_DEALLOC definition. Not needed anymore.
11097
11098 * allocatestack.c: Define ARCH_MAP_FLAGS if not already defined.
11099 Use it in mmap call to allocate stacks.
11100
11101 * sysdeps/pthread/createthread.c (create_thread): Fix comment.
11102
cc775edf
UD
11103 * pthread_create.c (start_thread): Use THREAD_SETMEM to store
11104 result of the thread function.
11105
4f6f0a8f
UD
111062003-03-03 Ulrich Drepper <drepper@redhat.com>
11107
f04a2721
UD
11108 * sysdeps/unix/sysv/linux/s390/dl-sysdep.h: Removed. The generic
11109 version is just fine.
11110
4f6f0a8f
UD
11111 * sysdeps/unix/sysv/linux/libc_pthread_init.c
11112 (__pthread_child_handler): Renamed from pthread_child_handler,
11113 exported, and marked hidden. Change all users.
11114 * sysdeps/unix/sysv/linux/register-atfork.c (free_mem): Do not
11115 free __pthread_child_handler from child list.
11116
7ce5c164
UD
111172003-03-03 Martin Schwidefsky <schwidefsky@de.ibm.com>
11118
11119 * atomic.h (atomic_exchange_and_add): Return newval, not oldval.
11120
11121 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
11122 Fix handling of cancellation and failing pthread_mutex_unlock call.
11123 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Likewise.
11124 (__pthread_cond_wait): Likewise.
11125
11126 * sysdeps/pthread/pthread_rwlock_timedrdlock.c
11127 (pthread_rwlock_timedrdlock): Fix clobber of result variable by
11128 lll_futex_timed_wait call.
11129 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
11130 (pthread_rwlock_timedwrlock): Likewise.
11131
11132 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c (___lll_lock):
11133 Don't define lll_unlock_wake_cb and ___lll_timedwait_tid in libc.so.
11134 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Remove XXX comments.
11135
11136 * sysdeps/unix/sysv/linux/s390/sem_post.c (__new_sem_post): Fix
11137 check of lll_futex_wake return value.
11138
ea6a015b
RM
111392003-03-03 Roland McGrath <roland@redhat.com>
11140
11141 * forward.c: Fix typo in __pthread_attr_init_2_0 compat_symbol decl.
11142
11143 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
11144 Argument to ptr___pthread_cleanup_upto is __jmp_buf, not jmp_buf.
11145 * sysdeps/unix/sysv/linux/jmp-unwind.c: Likewise.
11146
4adacf57
UD
111472003-03-02 Ulrich Drepper <drepper@redhat.com>
11148
1be3d664
UD
11149 * sysdeps/pthread/timer_create.c (timer_create): Return correct
11150 error for CPU clocks.
11151
885bafa1
UD
11152 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
11153 _POSIX_MONOTONIC_CLOCK.
11154 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
11155
4adacf57
UD
11156 * tst-cancel4.c (tf_sleep): Lower sleep time a bit to not upset
11157 recent kernels.
11158
86bfff4d
UD
111592003-03-01 Ulrich Drepper <drepper@redhat.com>
11160
11161 * descr.h (struct pthread): Move cleanup field to the front.
11162
d1149385
RM
111632003-03-01 Roland McGrath <roland@redhat.com>
11164
11165 * sem_open.c (sem_open): Braino fix.
11166
bd8bb78b
UD
111672003-03-01 Ulrich Drepper <drepper@redhat.com>
11168
748bec08
UD
11169 * sysdeps/i386/tcb-offsets.sym: Add CLEANUP and CLEANUP_PREV.
11170 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Inline
11171 __pthread_cleanup_pop functionality.
11172 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
11173
bd8bb78b
UD
11174 * descr.h (struct pthread): Move tid field to the front now that
11175 it is often used.
11176
11177 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S
11178 (__lll_mutex_timedlock_wait): Remove.
11179 (__lll_mutex_unlock_wake): Don't save, load, and restore %esi.
11180 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S
11181 (__lll_mutex_unlock_wake): Don't save, load, and restore %esi.
11182 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
11183 (lll_unlock_wake_cb): Don't save and restore %esi.
11184 (__lll_unlock_wake): Add alignment. Don't save, load, and restore
11185 %esi.
11186 (__lll_timedwait_tid): Add alignment.
11187 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S
11188 (__lll_unlock_wake): Add alignment. Don't save, load, and restore
11189 %esi.
11190 (__lll_timedwait_tid): Removed.
11191 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
11192 (__pthread_cond_broadcast): Don't save, load, and restore %esi.
11193 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
11194 (pthread_barrier_wait): Don't save, load, and restore %esi for
11195 last thread.
11196 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
11197 (__pthread_cond_signal): Don't save, load, and restore %esi.
11198 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
11199 (__pthread_rwlock_unlock): Don't save, load, and restore %esi.
11200 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__new_sem_post):
11201 Don't save, load, and restore %esi.
11202
d2637c70
UD
112032003-02-27 Ulrich Drepper <drepper@redhat.com>
11204
567fb22a
UD
11205 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S:
11206 Release lock before waking up the waiters.
11207
427f5fa1
UD
11208 * tst-exit1.c (do_test): Don't start more than one thread in parallel.
11209
a2d83cfb
UD
11210 * tst-rwlock9.c (writer_thread): Correct adding TIMEOUT.
11211 (reader_thread): Likewise.
11212
d2637c70
UD
11213 * sysdeps/pthread/pthread_rwlock_unlock.c
11214 (__pthread_rwlock_unlock): Release internal lock early. Don't try
11215 to wake up readers if there are none.
11216
11217 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
11218 Release internal lock before wake threads.
11219
b1531183
UD
112202003-02-26 Ulrich Drepper <drepper@redhat.com>
11221
dbf6131c
UD
11222 * Makefile (tests): Add tst-rwlock10 and tst-rwlock11.
11223 * tst-rwlock8.c: Initialize lock with INIT. Allow INIT to be
11224 predefined.
11225 * tst-rwlock9.c: Likewise.
11226 * tst-rwlock10.c: New file.
11227 * tst-rwlock11.c: New file.
11228
695799fe
UD
11229 * Makefile (tests): Add tst-dlsym1.
11230 * tst-dlsym1.c: New file.
11231
b1531183
UD
11232 * init.c (__pthread_initialize_minimal_internal): Set
11233 GL(dl_error_catch_tsd) to __libc_dl_error_tsd.
11234 * Versions (libc:GLIBC_PRIVATE): Export __libc_dl_error_tsd.
11235
3724f268
UD
112362003-02-24 Ulrich Drepper <drepper@redhat.com>
11237
3857ca78
UD
11238 * sem_open.c (sem_open): Fix handling of O_CREAT without O_EXCL.
11239
80d80779
UD
11240 * tst-cond2.c: Fix sychronization with child.
11241
86371308
UD
11242 * tst-rwlock8.c (reader_thread): Remove unused variable.
11243
ffeb4481
UD
11244 * Makefile: Add rules to build and run tst-tls3.
11245 * tst-tls3.c: New file.
11246 * tst-tls3mod.c: New file.
11247
3724f268
UD
11248 * Makefile (tests): Add tst-rwlock8 and tst-rwlock9.
11249 * tst-rwlock8.c: New file.
11250 * tst-rwlock9.c: New file.
11251 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Fix
11252 complete broken rwlock implementation.
11253 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
11254 Likewise.
11255 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
11256 Likewise.
11257 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
11258 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
18a53579
UD
11259 * sysdeps/pthread/pthread_rwlock_rdlock.c: Likewise.
11260 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Likewise.
11261 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
11262 * sysdeps/pthread/pthread_rwlock_unlock.c: Likewise.
11263 * sysdeps/pthread/pthread_rwlock_wrlock.c: Likewise.
3724f268 11264
8915cc40
RM
112652003-02-23 Roland McGrath <roland@redhat.com>
11266
11267 * Makefile (nptl-version): Change regexp so case sensitivity is ok.
11268
fd1a0d0c
UD
112692003-02-23 Ulrich Drepper <drepper@redhat.com>
11270
ecf28959
UD
11271 * Makefile (tests): Add tst-context1.
11272 * tst-context1.c: New file.
11273
5e47b76b
UD
11274 * Makefile (tests): Add tst-tls1 and tst-tls2.
11275 * tst-tls1.c: New file.
11276 * tst-tls2.c: New file.
11277
5a6bbb41
UD
11278 * libc-cancellation.c (__libc_enable_asynccancel): Correct test
11279 for failed cmpxchg.
11280
fd1a0d0c
UD
11281 * pthread_create.c (start_thread): Set EXITING_BIT early.
11282
11283 * sysdeps/i386/tls.h (THREAD_GETMEM): Mark asm as volatile.
11284 (THREAD_GETMEM_NC): Likewise.
11285
757f9fcb
UD
112862003-02-22 Ulrich Drepper <drepper@redhat.com>
11287
b1b8e747
UD
11288 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Shave
11289 off 3 more bytes by using offset-less instructions when possible.
11290
c780aa21 11291 * Makefile: Add dependency for $(objpfx)version.d.
757f9fcb
UD
11292
11293 * eintr.c (eintr_source): Add unnecessary return but the compiler
11294 insists.
11295
11296 * tst-kill3.c: Include <unistd.h>.
11297
5148559c
RM
112982003-02-21 Roland McGrath <roland@redhat.com>
11299
11300 * pthread_create.c (start_thread): Call __libc_thread_freeres.
11301
ab2d98e3
UD
113022003-02-21 Ulrich Drepper <drepper@redhat.com>
11303
71028edd
UD
11304 * Makefile (tests): Add tst-eintr1.
11305 (distribute): Add eintr.c.
11306 * tst-eintr1.c: New file.
11307 * eintr.c: New file.
11308
e814f748
UD
11309 * pthread_cancel.c (pthread_cancel): Use tkill directly.
11310
11311 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill):
11312 Disallow sending SIGCANCEL.
11313
ab2d98e3 11314 * Makefile (tests): Remove tst-basic7. Add tst-kill1, tst-kill2,
9c03686d 11315 tst-kill3, tst-kill4, tst-kill5, tst-kill6.
e814f748
UD
11316 * tst-kill1.c: New file.
11317 * tst-kill2.c: New file.
11318 * tst-kill3.c: New file.
11319 * tst-kill5.c: New file.
9c03686d 11320 * tst-kill6.c: New file.
e814f748
UD
11321 * tst-basic7.c: Renamed to...
11322 * tst-kill4.c: ...this.
ab2d98e3 11323
59fed0e2
RM
113242003-02-21 Roland McGrath <roland@redhat.com>
11325
11326 * Makefile (install-lib-ldscripts): New variable.
11327
49dc759f
UD
113282003-02-21 Ulrich Drepper <drepper@redhat.com>
11329
8c2e9a29
UD
11330 * pthreadP.h: Define INVALID_TD_P and INVALID_NOT_TERMINATED_TD_P.
11331 * pthread_cancel.c: Use INVALID_TD_P.
11332 * pthread_detach.c: Likewise.
11333 * pthread_getschedparam.c: Likewise.
11334 * pthread_setschedparam.c: Likewise.
11335 * sysdeps/pthread/pthread_getcpuclockid.c: Likewise.
11336 * sysdeps/unix/sysv/linux/pthread_kill.c: Likewise.
11337 * pthread_join.c: Use INVALID_NOT_TERMINATED_TD_P.
11338 * pthread_timedjoin.c: Likewise.
11339
11340 * tst-basic7.c: Include <signal.h>.
11341
49dc759f
UD
11342 * pthread_join.c (pthread_join): Limited checking for invalid
11343 descriptors.
11344 * pthread_timedjoin.c (pthread_timedjoin_np): Likewise.
11345
df5803bf
UD
113462003-02-20 Ulrich Drepper <drepper@redhat.com>
11347
c5acd3d7
UD
11348 * pthread_create.c (deallocate_tsd): Reset found_nonzero at the
11349 beginning of the loop. Clear the entire first block of TSD.
df5803bf
UD
11350 * Makefile (tests): Add tst-key4.
11351 * tst-key4.c: New file.
11352
729924a0
UD
113532003-02-18 Ulrich Drepper <drepper@redhat.com>
11354
2f7dc594
UD
11355 * Makefile (tests): Add tst-basic7.
11356 * tst-basic7.c: New file.
11357
ba25bb0f
UD
11358 * pthread_create.c (deallocate_tsd): Mark as internal_function.
11359 Add some more __builtin_expect.
11360
12fd3c5f 11361 * pthreadP.h: Define dummy version of DEBUGGING_P.
729924a0 11362
5430d926
UD
113632003-02-17 Ulrich Drepper <drepper@redhat.com>
11364
b0db7fbe
UD
11365 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remnove
11366 _POSIX_THREAD_PRIORITY_SCHEDULING.
11367 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remove
11368 _XOPEN_REALTIME_THREADS.
11369 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
11370
11371 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): The
11372 kernel returns EINVAL for PID <= 0, work around it.
11373
ecfda9bd
UD
11374 * Makefile (tests): Add tst-signal5.
11375 * tst-signal5.c: New file.
11376
7d78ab99
UD
11377 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define TTY_NAME_MAX
11378 and LOGIN_NAME_MAX.
11379
371a2972
UD
11380 * tst-cancel1.c (tf): Block all signals.
11381
5430d926
UD
11382 * Makefile (tests): Add tst-basic6.
11383 * tst-basic6.c: New file.
11384
11385 * tst-basic1.c: Add test for process ID.
11386
11387 * Makefile (tests): Add tst-cancel10.
11388 * tst-cancel10.c: New file.
11389
11390 * Makefile (tests): Add tst-signal4.
11391 * tst-signal4.c: New file.
11392
11393 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Use
11394 __sigismember instead of sigismember. Add __builtin_expect.
11395
1564916a
UD
113962003-02-16 Ulrich Drepper <drepper@redhat.com>
11397
179ff175
UD
11398 * tst-attr1.c (do_test): Add tests for pthread_setcanceltype,
11399 pthread_setcancelstate, and pthread_rwlock_setpshared.
11400
e4335f9a
UD
11401 * tst-cancel7.c (do_test): Make sure the pid file exists before
11402 canceling the thread.
11403
0a37669a
UD
11404 * tst-rwlock6.c: More pthread_rwlock_timedwrlock and
11405 pthread_rwlock_timedrdlock tests.
11406 * tst-rwlock7.c: More pthread_rwlock_timedwrlock tests.
11407 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
11408 Check for invalid tv_nsec field.
11409 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
11410 Likewise.
11411
11412 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Protect
11413 recursive mutex of overflow.
11414
11415 * tst-attr1.c (do_test): Add test for pthread_mutexattr_setpshared.
11416
e4335f9a 11417 * libc-cancellation.c (__libc_enable_asynccancel): Rewrite to avoid
1564916a
UD
11418 going into an endless loop.
11419 * Makefile (tests): Add tst-cancel9.
11420 * tst-cancel9.c: New file.
11421
11422 * pthread_cancel.c (pthread_cancel): Use the result of __pthread_kill.
11423
b270b548
UD
114242003-02-15 Ulrich Drepper <drepper@redhat.com>
11425
1c82b97f
UD
11426 * tst-mutex5.c (do_test): Add more timedlock tests.
11427
b2f05465 11428 * tst-mutex2.c: Tests of trylock and unlock with ERROR mutexes.
c3bb9ee1
UD
11429 * tst-mutex3.c (do_test): Add tests for trylock with RECURSIVE mutexes.
11430
e798b60f
UD
11431 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): Don't
11432 use INLINE_SYSCALL. Error number is returned, not -1.
11433
90491dc4
UD
11434 * pthreadP.h: Mark declarations of __find_in_stack_list, __free_tcb,
11435 and __deallocate_stack with internal_function.
11436 * pthread_create.c: Adjust definitions appropriately.
11437 * allocatestack.c: Likewise.
11438
11439 * pthread_join.c: Add one more __builtin_expect.
11440 * pthread_timedjoin.c: Likewise.
11441
11442 * pthread_getspecific.c (__pthread_getspecific): Clear data->data
11443 not data of sequence number does not match.
11444 Add one __builtin_expect.
11445
c6247c9d
UD
11446 * Makefile (tests): Add tst-clock1.
11447 * tst-clock1.c: New file.
11448
b270b548
UD
11449 * pthread_setconcurrency.c (pthread_setconcurrency): Fail for
11450 negative arguments.
11451 * Makefile (tests): Add tst-basic5.
11452 * tst-basic5.c: New file.
11453
700bf7af
UD
114542003-02-14 Ulrich Drepper <drepper@redhat.com>
11455
757de559
UD
11456 * Makefile (tests): Add tst-basic4.
11457 * tst-basic4.c: New file.
11458
47202270
UD
11459 * pthreadP.h: Add declaraction for __nptl_nthreads.
11460 * pthread_create.c: Define __nptl_nthreads
11461 (start_thread): Increment __nptl_nthreads at beginning. Decrement
b270b548 11462 after thread is done. If then zero, call exit(0).
47202270
UD
11463 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
11464 Add ptr_nthreads. Define HAVE_PTR_NTHREADS.
11465 * init.c (pthread_functions): Initialize ptr_nthreads.
11466 * allocatestack.c (nptl_nthreads): Remove definition and all uses.
11467 (__reclaim_stacks): Decrement __nptl_nthreads.
11468 * sysdeps/pthread/Makefile [$(subdir)==csu] (CFLAGS-libc-start.c):
11469 Define.
11470 * Makefile (tests): Add tst-basic3.
11471 * tst-basic3.c: New file.
11472
e320ef46
UD
11473 * descr.h: Define CANCELING_BIT and CANCELING_BITMASK. Introduce
11474 after CANCELTYPE_BIT, move the other bits up. Update CANCEL_RESTMASK.
11475 * init.c (sigcancel_handler): Also set CANCELING_BITMASK bit in newval.
11476 * pthread_cancel.c (pthread_cancel): Likewise. Also set CANCELING_BIT
11477 if asynchronous canceling is enabled.
11478 * pthread_join.c (pthread_join): When recognizing circular joins,
11479 take into account the other thread might be already canceled.
11480 * Makefile (tests): Add tst-join5.
11481 * tst-join5.c: New file.
11482
700bf7af
UD
11483 * Makefile (tests): Add tst-join4.
11484 * tst-join4.c: New file.
11485
114862003-02-13 Ulrich Drepper <drepper@redhat.com>
11487
11488 * tst-cond4.c (main): Add test of pthread_attr_getpshared.
11489
dac0f772
UD
114902003-02-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
11491
11492 * sysdeps/s390/tls.h (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM,
11493 THREAD_SETMEM_NC): Use passed descr instead of THREAD_SELF.
11494 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c (_longjmp_unwind): Avoid
11495 warning.
11496 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Include <sys/time.h>
11497 to avoid warning.
11498 * sysdeps/unix/sysv/linux/s390/sem_post.c (__new_sem_post): Return
11499 error if lll_futex_wake failed.
11500
e8cda341
UD
115012003-02-13 Ulrich Drepper <drepper@redhat.com>
11502
a7720b5e
UD
11503 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Fix
11504 handling of cancellation and failung pthread_mutex_unlock call.
11505 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
11506 * Makefile (tests): Add tst-cond8 and tst-cond9.
11507 * tst-cond8.c: New file.
11508 * tst-cond9.c: New file.
11509
a1ea4c06
UD
11510 * tst-cond7.c (do_test): Unlock the mutex before canceling the thread.
11511
11512 * sysdeps/pthread/pthread.h: Add missing initializers. Protect
11513 non-standard initializers with __USE_GNU.
11514
e8cda341
UD
11515 * Makefile (tests): Add tst-cleanup3.
11516 * tst-cleanup3.c: New file.
11517
2067577c
UD
115182003-02-12 Ulrich Drepper <drepper@redhat.com>
11519
89e78a95
UD
11520 * Makefile (tests): Add tst-attr1 and tst-attr2.
11521 * tst-attr1.c: New file.
11522 * tst-attr2.c: New file.
11523
dfdd294a
UD
11524 * Makefile: Add rules to build and run tst-atfork2 test.
11525 * tst-atfork2.c: New file.
11526 * tst-atfork2mod.c: New file.
11527
11528 * sysdeps/unix/sysv/linux/unregister-atfork.c
11529 (__unregister_atfork): Free the memory allocated for the handlers
11530 after removing them from the lists.
11531
11532 * sysdeps/unix/sysv/linux/register-atfork.c: Define memeory
11533 cleanup function.
11534
11535 * tst-atfork1.c (do_test): Wait for the child we forked.
11536 Report error in child.
11537
11538 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Fix comment.
11539
2067577c
UD
11540 * sysdeps/pthread/Makefile: Define CFLAGS-confstr.c.
11541
2a8a8a84
UD
115422003-02-10 Ulrich Drepper <drepper@redhat.com>
11543
d9dd121e
UD
11544 * Makefile (tests): Add tst-cancel8.
11545 * tst-cancel8.c: New file.
11546
2a8a8a84
UD
11547 * sysdeps/unix/sysv/linux/i386/pthread_once.S (clear_once_control): Fix
11548 clearing of control variable.
defd1870 11549 * Makefile (tests): Add tst-once3 and tst-once4.
2a8a8a84 11550 * tst-once3.c: New file.
defd1870 11551 * tst-once4.c: New file.
2a8a8a84 11552
a54e8d33
UD
115532003-02-08 kaz Kojima <kkojima@rr.iij4u.or.jp>
11554
11555 * sysdeps/sh/Makefile: New file.
11556 * sysdeps/sh/bits/atomic.h: New file.
11557 * sysdeps/sh/pthread_spin_init.c: New file.
11558 * sysdeps/sh/pthread_spin_lock.c: New file.
11559 * sysdeps/sh/pthread_spin_trylock.S: New file.
11560 * sysdeps/sh/pthread_spin_unlock.S: New file.
11561 * sysdeps/sh/pthreaddef.h: New file.
11562 * sysdeps/sh/tcb-offsets.sym: New file.
11563 * sysdeps/sh/td_ta_map_lwp2thr.c: New file.
11564 * sysdeps/sh/tls.h: New file.
11565 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: New file.
11566 * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: New file.
11567 * sysdeps/unix/sysv/linux/sh/createthread.c: New file.
11568 * sysdeps/unix/sysv/linux/sh/fork.c: New file.
11569 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: New file.
11570 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: New file.
11571 * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h: New file.
11572 * sysdeps/unix/sysv/linux/sh/lowlevelcond.h: New file.
11573 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: New file.
11574 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: New file.
11575 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: New file.
11576 * sysdeps/unix/sysv/linux/sh/lowlevelrwlock.h: New file.
11577 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: New file.
11578 * sysdeps/unix/sysv/linux/sh/pt-vfork.S: New file.
11579 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: New file.
11580 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: New file.
11581 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: New file.
11582 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: New file.
11583 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: New file.
11584 * sysdeps/unix/sysv/linux/sh/pthread_once.S: New file.
11585 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: New file.
11586 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: New file.
11587 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: New file.
11588 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: New file.
11589 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: New file.
11590 * sysdeps/unix/sysv/linux/sh/sem_post.S: New file.
11591 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: New file.
11592 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: New file.
11593 * sysdeps/unix/sysv/linux/sh/sem_wait.S: New file.
11594 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: New file.
11595
696e556e
UD
115962003-02-08 Ulrich Drepper <drepper@redhat.com>
11597
11598 * tst-cond2.c: Rearrange code to not rely on behavior undefined
11599 according to POSIX.
11600
11601 * tst-basic2.c (do_test): Lock mutex before creating the thread.
11602
fef710d6
UD
116032003-02-07 Ulrich Drepper <drepper@redhat.com>
11604
c6180643
UD
11605 * sysdeps/x86_64/tls.h: Remove unnecessary macros, left over from x86.
11606 (TLS_GET_FS): New #define.
11607 (TLS_SET_FS): New #define.
11608 Correct value of __NR_set_thread_area.
11609
fef710d6
UD
11610 * sysdeps/x86_64/td_ta_map_lwp2thr.c: New file.
11611
11090a99
UD
116122003-02-06 Ulrich Drepper <drepper@redhat.com>
11613
65c68990
UD
11614 * Makefile (tests): Add tst-popen1.
11615 * tst-popen1.c: New file.
11616
11090a99
UD
11617 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Remove wrong
11618 but inactive generalization.
11619 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
11620 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
11621 Minor optimization, remove one instruction.
11622 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
11623
a88c9263
UD
116242003-02-04 Martin Schwidefsky <schwidefsky@de.ibm.com>
11625
11626 * sysdeps/unix/sysv/linux/s390/fork.c: Correct order of parameters.
11627
116282003-01-31 Martin Schwidefsky <schwidefsky@de.ibm.com>
11629
11630 * init.c (__NR_set_tid_address): Add #ifdef for s390.
11631 * sysdeps/pthread/pthread_barrier_wait.c: New file.
11632 * sysdeps/pthread/pthread_cond_broadcast.c: New file.
11633 * sysdeps/pthread/pthread_cond_signal.c: New file.
11634 * sysdeps/pthread/pthread_cond_timedwait.c: New file.
11635 * sysdeps/pthread/pthread_cond_wait.c: New file.
11636 * sysdeps/pthread/pthread_rwlock_rdlock.c: New file.
11637 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: New file.
11638 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: New file.
11639 * sysdeps/pthread/pthread_rwlock_unlock.c: New file.
11640 * sysdeps/pthread/pthread_rwlock_wrlock.c: New file.
11641 * sysdeps/s390/Makefile: New file.
11642 * sysdeps/s390/bits/atomic.h: New file.
11643 * sysdeps/s390/pthread_spin_init.c: New file.
11644 * sysdeps/s390/pthread_spin_lock.c: New file.
11645 * sysdeps/s390/pthread_spin_trylock.c: New file.
11646 * sysdeps/s390/pthread_spin_unlock.c: New file.
11647 * sysdeps/s390/pthreaddef.h: New file.
11648 * sysdeps/s390/tcb-offsets.sym: New file.
11649 * sysdeps/s390/td_ta_map_lwp2thr.c: New file.
11650 * sysdeps/s390/tls.h: New file.
11651 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: New file.
11652 * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: New file.
11653 * sysdeps/unix/sysv/linux/s390/createthread.c: New file.
11654 * sysdeps/unix/sysv/linux/s390/dl-sysdep.h: New file.
11655 * sysdeps/unix/sysv/linux/s390/fork.c: New file.
11656 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: New file.
11657 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: New file.
11658 * sysdeps/unix/sysv/linux/s390/libc-lowlevelmutex.c: New file.
11659 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: New file.
11660 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: New file.
11661 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c: New file.
11662 * sysdeps/unix/sysv/linux/s390/lowlevelsem.h: New file.
11663 * sysdeps/unix/sysv/linux/s390/pthread_once.c: New file.
11664 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c: New file.
11665 * sysdeps/unix/sysv/linux/s390/s390-32/pt-vfork.S: New file.
11666 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: New file.
11667 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: New file.
11668 * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S: New file.
11669 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: New file.
11670 * sysdeps/unix/sysv/linux/s390/sem_post.c: New file.
11671 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: New file.
11672 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: New file.
11673 * sysdeps/unix/sysv/linux/s390/sem_wait.c: New file.
11674
6f1cff95
UD
116752003-02-04 Ulrich Drepper <drepper@redhat.com>
11676
ec609a8e
UD
11677 * atomic.h: Add a couple more default implementations.
11678 (atomic_compare_and_exchange_acq): Use
d45e8740
UD
11679 __arch_compare_and_exchange_32_acq in return value definition. It
11680 always exists.
11681 (atomic_bit_set): Renamed from atomic_set_bit.
0289bef9 11682 Add missing atomic_ prefixes.
e3ec8904 11683
6f1cff95
UD
11684 * sysdeps/pthread/bits/libc-lock.h (__libc_once): In case no
11685 thread library is available, use correct value to mark initialized
11686 once variable.
11687
4f088329
UD
116882003-02-03 Ulrich Drepper <drepper@redhat.com>
11689
6f1cff95
UD
11690 * allocatestack.c (allocate_stack): Use __getpagesize instead of
11691 __sysconf to determine pagesize.
11692
3e4fc359 11693 * pthread_create.c: Include <atomic.h>.
4f088329
UD
11694 * allocatestack.c (allocate_stack): Implement coloring of the
11695 allocated stack memory. Rename pagesize to pagesize_m1. It's the
11696 size minus one. Adjust users.
3e4fc359 11697 * sysdeps/i386/i686/Makefile: New file.
4f088329 11698
2f42e8be
UD
116992003-02-02 Ulrich Drepper <drepper@redhat.com>
11700
4301f7e2
UD
11701 * allocatestack.c: Improve comment throughout the file.
11702
2f42e8be 11703 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
a37818b3 11704 (__lll_lock_wait): Add branch prediction.
2f42e8be
UD
11705 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S
11706 (__lll_lock_wait): Likewise.
11707 (lll_unlock_wake_cb): Removed.
11708
4a7d6545
UD
117092003-01-31 Ulrich Drepper <drepper@redhat.com>
11710
11711 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Remove
11712 _POSIX_THREAD_PRIORITY_SCHEDULING.
11713
886d5973
UD
117142003-01-30 Jakub Jelinek <jakub@redhat.com>
11715
11716 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
11717 Fix return type of ptr___pthread_getspecific.
11718
e474ca78
UD
117192003-01-29 Ulrich Drepper <drepper@redhat.com>
11720
11721 * Makefile (tests): Add tst-umask1.
11722 (tst-umask1-ARGS): Define.
11723 * tst-umask1.c: New file.
11724
e6ebd2e4
UD
117252003-01-28 Ulrich Drepper <drepper@redhat.com>
11726
6cf26f41
UD
11727 * Makefile (libpthread-routines): Remove lowlevelrwlock. Add
11728 pthread_rwlock_rdlock, pthread_rwlock_timedrdlock,
11729 pthread_rwlock_wrlock, pthread_rwlock_timedwrlock, and
11730 pthread_rwlock_unlock.
11731 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Removed
11732 * sysdeps/unix/sysv/linux/i386/i586/lowlevelrwlock.S: Removed
11733 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrwlock.S: Removed
11734 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: New file.
11735 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
11736 New file.
11737 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: New file.
11738 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
11739 New file.
11740 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: New file.
11741 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_rdlock.S: New file.
11742 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_timedrdlock.S:
11743 New file.
11744 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_wrlock.S: New file.
11745 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_timedwrlock.S:
11746 New file.
11747 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_unlock.S: New file.
11748 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_rdlock.S: New file.
11749 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_timedrdlock.S:
11750 New file.
11751 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_wrlock.S: New file.
11752 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_timedwrlock.S:
11753 New file.
11754 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_unlock.S: New file.
11755
1d087a7e
UD
11756 * Makefile (libpthread-routines): Remove lowlevelcond and
11757 lowlevelsem. Add sem_wait, sem_trywait, sem_timedwait, sem_post,
11758 pthread_cond_wait, pthread_cond_timedwait, pthread_cond_signal,
11759 and pthread_cond_broadcast.
4a99d160
UD
11760 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Removed
11761 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Removed
11762 * sysdeps/unix/sysv/linux/i386/i586/lowlevelsem.S: Removed
11763 * sysdeps/unix/sysv/linux/i386/i586/lowlevelcond.S: Removed
11764 * sysdeps/unix/sysv/linux/i386/i686/lowlevelsem.S: Removed
11765 * sysdeps/unix/sysv/linux/i386/i686/lowlevelcond.S: Removed
11766 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: New file.
11767 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: New file.
11768 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: New file.
11769 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: New file.
11770 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: New file.
11771 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: New file.
11772 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: New file.
11773 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: New file.
11774 * sysdeps/unix/sysv/linux/i386/i586/sem_wait.S: New file.
11775 * sysdeps/unix/sysv/linux/i386/i586/sem_trywait.S: New file.
11776 * sysdeps/unix/sysv/linux/i386/i586/sem_timedwait.S: New file.
11777 * sysdeps/unix/sysv/linux/i386/i586/sem_post.S: New file.
11778 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_wait.S: New file.
11779 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_timedwait.S: New file.
11780 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_signal.S: New file.
11781 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_broadcast.S: New file.
11782 * sysdeps/unix/sysv/linux/i386/i686/sem_wait.S: New file.
11783 * sysdeps/unix/sysv/linux/i386/i686/sem_trywait.S: New file.
11784 * sysdeps/unix/sysv/linux/i386/i686/sem_timedwait.S: New file.
11785 * sysdeps/unix/sysv/linux/i386/i686/sem_post.S: New file.
11786 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_wait.S: New file.
11787 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_timedwait.S: New file.
11788 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_signal.S: New file.
11789 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_broadcast.S: New file.
11790 * sysdeps/unix/sysv/linux/i386/lowlevelcond.h: New file.
1d087a7e 11791
e6ebd2e4
UD
11792 * sysdeps/unix/sysv/linux/i386/createthread.c: Define
11793 PREPARE_CREATE and TLS_VALUE with x86-specific bits. All the rest
11794 of the code is moved to ...
11795 * sysdeps/pthread/createthread.c: ...here. New file.
11796
a15698cb
UD
117972003-01-27 Ulrich Drepper <drepper@redhat.com>
11798
0566b130
UD
11799 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S
11800 (__new_sem_post): Clear %eax before returning.
11801 Reported by MAEDA Naoaki <maeda.naoaki@jp.fujitsu.com>.
11802
e6fb8846
UD
11803 * Makefile (tests): Add tst-cleanup2.
11804 * tst-cleanup2.c: New file.
11805
a15698cb
UD
11806 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start):
11807 Interpret first parameter correctly.
11808
8824b0a1
UD
118092003-01-17 Ulrich Drepper <drepper@redhat.com>
11810
11811 * Makefile (headers): Add bits/semaphore.h.
11812
850dcfca
UD
118132003-01-16 Jakub Jelinek <jakub@redhat.com>
11814
11815 * sysdeps/i386/tls.h (INIT_SYSINFO): Initialize _head->sysinfo even
11816 if not SHARED.
11817
574b892e
UD
118182003-01-14 Ulrich Drepper <drepper@redhat.com>
11819
a8d87c92
UD
11820 * sem_open.c (sem_open): Return SEM_FAILED if existing semaphore
11821 must be used and mapping failed.
11822 Reported by Luke Elliott <luke.elliott@activfinancial.com>.
11823
574b892e
UD
11824 * Makefile (CFLAGS-pthread_self.os): Define this, not
11825 CFLAGS-pthread_self.c.
11826
fb48047a
UD
118272003-01-13 Ulrich Drepper <drepper@redhat.com>
11828
47805511
UD
11829 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Don't export
11830 lll_unlock_wake_cb.
11831
fb48047a
UD
11832 * Makefile (libpthread-routines): Add version. Add rules to build
11833 version.os and banner.h.
11834 * version.c: New file.
11835
115bb61d
UD
118362003-01-13 Jakub Jelinek <jakub@redhat.com>
11837
11838 * pthread_mutex_lock.c (__pthread_mutex_lock_internal): Make
11839 the alias unconditional.
11840 * pthread_mutex_unlock.c (__pthread_mutex_unlock_internal): Likewise.
11841
118422003-01-13 Ulrich Drepper <drepper@redhat.com>
11843
11844 * Makefile (CFLAGS-pthread_self.c): New definition.
11845
6aca81bb
UD
118462003-01-06 Jakub Jelinek <jakub@redhat.com>
11847
11848 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Add
11849 INTERNAL_SYSCALL_DECL, add err argument to INTERNAL_SYSCALL* macros.
11850 * sysdeps/unix/sysv/linux/raise.c (raise): Likewise.
11851 * init.c (__pthread_initialize_minimal_internal): Likewise.
11852
e9c7764e
UD
118532003-01-07 Jakub Jelinek <jakub@redhat.com>
11854
b5facfda
UD
11855 * pthreadP.h (__pthread_cond_timedwait): Add prototype.
11856
e9c7764e
UD
11857 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
11858 (RTLD_CORRECT_DYNAMIC_WEAK): Remove.
11859 (DL_SYSINFO_IMPLEMENTATION): Change into .text section and back.
11860 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h
11861 (RTLD_CORRECT_DYNAMIC_WEAK): Remove.
11862 (DL_SYSINFO_IMPLEMENTATION): Change into .text section and back.
11863
bef1e42f
UD
118642003-01-06 Jakub Jelinek <jakub@redhat.com>
11865
11866 * pthreadP.h (LIBC_CANCEL_HANDLED): Define.
11867 * pt-system.c (LIBC_CANCEL_HANDLED): Add.
11868 * tst-cancel-wrappers.sh: Remove all exceptions.
11869
bbd17455
UD
118702003-01-05 Ulrich Drepper <drepper@redhat.com>
11871
a73ab6df
UD
11872 * tst-cancel-wrappers.sh: Invoke gawk not awk since we use GNU awk
11873 features. Reported by Marijn Ros <marijn@mad.scientist.com>.
11874
bbd17455
UD
11875 * sysdeps/unix/sysv/linux/jmp-unwind.c: Include <pthread-functions.h>.
11876 Use __libc_pthread_functions array if SHARED.
11877
11878 * pthreadP.h: Move pthread_cond_2_0_t definition to...
11879 * sysdeps/unix/sysv/linux/internaltypes.h: ...here.
11880
11881 * sysdeps/pthread/bits/libc-lock.h (__libc_ptf_call): New #define.
11882 (__libc_rwlock_rdlock, __libc_rwlock_wrlock, __libc_rwlock_unlock,
11883 __libc_key_create, __libc_getspecific, __libc_setspecific): Use
11884 __libc_ptf_call instead of __libc_maybe_call.
11885 (PTF): New #define.
11886 (__libc_cleanup_region_start): Wrap function name with PTF call.
11887 (__libc_cleanup_region_end): Likewise.
11888 (__libc_cleanup_end): Likewise.
11889
11890 * pthread_getspecific.c: Add __pthread_getspecific_internal alias.
11891 * pthread_setspecific.c: Add __pthread_setspecific_internal alias.
11892 * pthread_key_create.c: Add __pthread_key_create_internal alias.
11893 * pthreadP.h: Add prototypes.
11894
11895 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Add
11896 __pthread_rwlock_rdlock, __pthread_rwlock_wrlock, and
11897 __pthread_rwlock_unlock aliases.
11898 * pthreadP.h: Add prototypes for new aliases.
11899
11900 * pthreadP.h (struct pthead_functions): Moved to...
11901 * sysdeps/pthread/pthread-functions.h: ...here. New file.
11902 * init.c (pthread_functions): Add initializers for new elements.
11903
11904 * cleanup_defer.c: Add __pthread_cleanup_push_defer and
11905 __pthread_cleanup_pop_restore aliases.
11906 * pthreadP.h: Add prototypes.
11907
11908 * cleanup.c: Rename _GI_pthread_cleanup_push to __pthread_cleanup_push
11909 and _GI_pthread_cleanup_pop to __pthread_cleanup_pop.
11910 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Adjust caller.
11911 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
11912 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
11913 * pthreadP.h: Adjust prototypes and callers.
11914
d27a78be
UD
119152003-01-04 Ulrich Drepper <drepper@redhat.com>
11916
b74121ae
UD
11917 * Makefile (tests): Add tst-cancel7.
11918 (tst-cancel7-ARGS): New variable.
bbd17455 11919 * tst-cancel7.c: New file.
b74121ae 11920
29bc410c
UD
11921 * old_pthread_cond_broadcast.c: Optimize initialization a bit to work
11922 around gcc defficiencies.
11923 * old_pthread_cond_signal.c: Likewise.
11924 * old_pthread_cond_timedwait.c: Likewise.
11925 * old_pthread_cond_wait.c: Likewise.
11926
d27a78be
UD
11927 * pthreadP.h (pthread_cond_2_0_t): Remove unneeded lock element.
11928
733f25e6
UD
119292003-01-03 Ulrich Drepper <drepper@redhat.com>
11930
7edb2ae3
UD
11931 * Makefile (tests): Add tst-cond7.
11932 * tst-cond7.c: New file.
11933
b1151300
UD
11934 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S
11935 (condvar_cleanup): Get condvar address from the right place.
11936
733f25e6
UD
11937 * atomic.h: Correct definitions of atomic_full_barrier,
11938 atomic_read_barrier, atomic_write_barrier.
11939
11940 * old_pthread_cond_broadcast.c: Make memory allocate and initialization
11941 race-free.
11942 * old_pthread_cond_signal.c: Likewise.
11943 * old_pthread_cond_timedwait.c: Likewise.
11944 * old_pthread_cond_wait.c: Likewise.
11945
686b7223
UD
119462003-01-03 Jakub Jelinek <jakub@redhat.com>
11947
11948 * Makefile ($(objpfx)libpthread.so): Depend on ld.so.
11949
0e07706e
UD
119502003-01-03 Ulrich Drepper <drepper@redhat.com>
11951
997256dd
UD
11952 * pthreadP.h (pthread_cond_2_0_t): New type.
11953 (struct pthread_functions): Use new type for 2.0 condvar callbacks.
11954 Use new type for the 2.0 condvar function prototypes.
11955 * forward.c: Use pthread_cond_2_0_t for 2.0 condvar functions.
11956 * old_pthread_cond_init.c: Use pthread_cond_2_0_t for condvar
11957 parameter.
11958 * old_pthread_cond_destroy.c: Likewise.
11959 * old_pthread_cond_broadcast.c: Likewise. Lock appropriately.
11960 * old_pthread_cond_signal.c: Likewise.
11961 * old_pthread_cond_timedwait.c: Likewise.
11962 * old_pthread_cond_wait.c: Likewise.
11963
842d2817
UD
11964 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S
11965 (__pthread_cond_wait): Don't save cancellation mode and seq value
11966 in same location.
11967
0e07706e
UD
11968 * herrno.c (__h_errno_location): Don't define as weak.
11969
bf293afe
UD
119702003-01-02 Jakub Jelinek <jakub@redhat.com>
11971
11972 * Versions [libc] (GLIBC_2.3.2): Export pthread_cond_broadcast,
11973 pthread_cond_destroy, pthread_cond_init, pthread_cond_signal
11974 and pthread_cond_wait.
11975 * old_pthread_cond_broadcast.c (__old_pthread_cond_broadcast):
11976 Renamed to...
11977 (__pthread_cond_broadcast_2_0): ... this.
11978 * old_pthread_cond_destroy.c (__old_pthread_cond_destroy):
11979 Renamed to...
11980 (__pthread_cond_destroy_2_0): ... this.
11981 * old_pthread_cond_init.c (__old_pthread_cond_init):
11982 Renamed to...
11983 (__pthread_cond_init_2_0): ... this.
11984 * old_pthread_cond_signal.c (__old_pthread_cond_signal):
11985 Renamed to...
11986 (__pthread_cond_signal_2_0): ... this.
11987 * old_pthread_cond_wait.c (__old_pthread_cond_wait):
11988 Renamed to...
11989 (__pthread_cond_wait_2_0): ... this.
11990 * pthread_cond_destroy.c: Include shlib-compat.h.
11991 (pthread_cond_destroy): Change strong_alias into versioned_symbol.
11992 * pthread_cond_init.c: Include shlib-compat.h.
11993 (pthread_cond_init): Change strong_alias into versioned_symbol.
11994 * pthreadP.h (struct pthread_functions): Rename ptr_pthread_cond_*
11995 fields to ptr___pthread_cond_* and add ptr___pthread_cond_*_2_0
11996 fields.
11997 (__pthread_cond_broadcast_2_0, __pthread_cond_destroy_2_0,
11998 __pthread_cond_init_2_0, __pthread_cond_signal_2_0,
11999 __pthread_cond_wait_2_0): New prototypes.
12000 (__old_pthread_cond_broadcast, __old_pthread_cond_destroy,
12001 __old_pthread_cond_init, __old_pthread_cond_signal,
12002 __old_pthread_cond_wait): Removed.
12003 * init.c: Include shlib-compat.h.
12004 (pthread_functions): Guard ptr___pthread_attr_init_2_0
12005 initialization with SHLIB_COMPAT (GLIBC_2_0, GLIBC_2_1).
12006 Rename ptr_pthread_cond_* to ptr___pthread_cond_*, initialize
12007 ptr___pthread_cond_*_2_0 fields.
12008 * forward.c: Export both pthread_cond_*@@GLIBC_2.3.2 and
12009 pthread_cond_*@GLIBC_2.0 compatibility symbols.
12010
12011 * sysdeps/pthread/sigaction.c (SIGCANCEL): Only define if
12012 LIBC_SIGACTION was not yet defined.
12013 [!defined LIBC_SIGACTION]: Define LIBC_SIGACTION, #include self.
12014 [!defined LIBC_SIGACTION] (__sigaction): New function and
12015 libc_hidden_weak.
12016 [!defined LIBC_SIGACTION] (sigaction): New weak_alias.
12017 [defined LIBC_SIGACTION]: #include_next <sigaction.c>.
12018
120192003-01-02 Jakub Jelinek <jakub@redhat.com>
12020
12021 * Makefile (CFLAGS-pthread_atfork.c): Add -DNOT_IN_libc.
12022
05df18c3
UD
120232003-01-02 Ulrich Drepper <drepper@redhat.com>
12024
12025 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
12026 New, larger type definition.
12027 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: New condvar
12028 implementation.
12029 * Versions [libpthread]: Add definitions for new pthread_cond_*
12030 interfaces for version GLIBC_2.3.2.
12031 * pthread_cond_init.c: Update initialization for new type definition.
12032 * Makefile (libpthread-routines): Remove pthread_cond_wait,
12033 pthread_cond_timedwait, pthread_cond_signal, and
12034 pthread_cond_broadcast. Add old_pthread_cond_init,
12035 old_pthread_cond_destroy, old_pthread_cond_wait,
12036 old_pthread_cond_timedwait, old_pthread_cond_signal, and
12037 old_pthread_cond_broadcast.
12038 * old_pthread_cond_broadcast.c: New file.
12039 * old_pthread_cond_destroy.c: New file.
12040 * old_pthread_cond_init.c: New file.
12041 * old_pthread_cond_signal.c: New file.
12042 * old_pthread_cond_timedwait.c: New file.
12043 * old_pthread_cond_wait.c: New file.
12044 * pthreadP.h: Add prototypes for the compatibility interfaces.
12045
12046 * pthread_cond_destroy.c: Don't include <errno.h>.
12047
fd8979e4
UD
120482003-01-01 Ulrich Drepper <drepper@redhat.com>
12049
12050 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Avoid
12051 unnecessary zero offset when addressing MUTEX.
12052
6d6ee629
UD
120532002-12-31 Ulrich Drepper <drepper@redhat.com>
12054
12055 * sysdeps/unix/sysv/linux/fork.h: Add libc_hidden_proto for
12056 __register_atfork.
12057 * sysdeps/unix/sysv/linux/register-atfork.c: Add libc_hidden_def
12058 for __register_atfork.
12059
a4baf360
UD
120602002-12-31 Jakub Jelinek <jakub@redhat.com>
12061
12062 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Use __ASSEMBLER__
12063 instead of ASSEMBLER test macro.
12064
12065 * sysdeps/unix/sysv/linux/allocrtsig.c (__libc_current_sigrtmin,
12066 __libc_current_sigrtmax): Add libc_hidden_def.
12067
12068 * sysdeps/pthread/list.h: Remove assert.h include.
12069
e9395a94
UD
120702002-12-31 Ulrich Drepper <drepper@redhat.com>
12071
12072 * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Use
12073 __pthread_initialize_minimal_internal not
12074 __pthread_initialize_minimal.
12075
89d6e444
UD
120762002-12-30 Ulrich Drepper <drepper@redhat.com>
12077
416d2de6
UD
12078 * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Mark
12079 __pthread_initialize_minimal as hidden.
12080
89d6e444
UD
12081 * init.c (__pthread_initialize_minimal_internal): Don't mark as
12082 constructor.
12083
120842002-12-31 Jakub Jelinek <jakub@redhat.com>
12085
12086 * Makefile ($(inst_libdir)/libpthread.so): Depend on
12087 $(common-objpfx)format.lds, include that into the output script.
12088 Fix comment.
12089 (extra-B-pthread.so): Change linuxthreads/ into nptl/.
12090
8cac677c
UD
120912002-12-28 Andreas Jaeger <aj@suse.de>
12092
12093 * sysdeps/unix/sysv/linux/xstatconv.c (xstat_conv): Adjust for
12094 nsec resolution changes.
12095 (xstat64_conv): Likewise.
12096 (xstat32_conv): Likewise.
12097 * sysdeps/unix/sysv/linux/kernel_stat.h: Add nsec resolution for
12098 struct kernel_stat.
12099 * sysdeps/unix/sysv/linux/bits/stat.h: Add nsec resolution for
12100 structs stat and stat64.
12101 * time/time.h (__timespec_defined): Define for __USE_MISC.
89d6e444 12102 * io/sys/stat.h [__USE_MISC]: Define __need_timespec for struct stat.
8cac677c 12103
49e9f864
UD
121042002-12-30 Jakub Jelinek <jakub@redhat.com>
12105
12106 * forward.c (FORWARD2): Renamed from FORWARD3. Remove unused export
12107 argument.
12108 (pthread_attr_init_2_0, pthread_attr_init_2_1): Use FORWARD macro.
12109 (pthread_exit): Use strong_alias to avoid warnings.
12110 * pthreadP.h (struct pthread_functions): Rename ptr_pthread_exit
12111 and ptr_pthread_attr_init_2_* to ptr___pthread_exit and
12112 ptr___pthread_attr_init_2_*.
12113 * init.c (pthread_functions): Adjust.
12114
bab09b26
UD
121152002-12-29 Ulrich Drepper <drepper@redhat.com>
12116
598d7a42
UD
12117 * forward.c: Make all functions available by default again. It
12118 caused too much trouble.
12119
bab09b26
UD
12120 * pt-siglongjmp.c: Removed.
12121
3b7ed871
UD
121222002-12-28 Jakub Jelinek <jakub@redhat.com>
12123
12124 * sysdeps/i386/tls.h: Include tcb-offsets.h in assembler.
12125 (SYSINFO_OFFSET, MULTIPLE_THREADS_OFFSET): Remove.
12126 * sysdeps/i386/Makefile: New file.
12127 * sysdeps/i386/tcb-offsets.sym: New file.
12128 * sysdeps/pthread/tcb-offsets.h: New file.
12129 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
12130 Remove MULTIPLE_THREADS_OFFSET and SYSINFO_OFFSET checks.
12131
12132 * sysdeps/unix/sysv/linux/Versions [libc] (GLIBC_PRIVATE): Move
12133 __register_atfork...
12134 (GLIBC_2.3.2): ...here.
12135
121362002-12-28 Ulrich Drepper <drepper@redhat.com>
12137
12138 * sysdeps/pthread/pthread.h: Mark pthread_attr_getstackaddr and
12139 pthread_attr_setstackaddr with __attribute_deprecated__.
12140
270d9d47
UD
121412002-12-27 Jakub Jelinek <jakub@redhat.com>
12142
12143 * pt-system.c (system): Remove cancellation handling.
12144 * tst-cancel-wrappers.sh: Allow pt-system.o* to not use the
12145 cancellation routines.
12146
131fd126
UD
121472002-12-28 Ulrich Drepper <drepper@redhat.com>
12148
afb2e954
UD
12149 * descr.h: Include <dl-sysdep.h>.
12150 (struct pthread): Move header.data.list to the back of the struct.
131fd126
UD
12151 * sysdeps/i386/tls.h (tcbhead_t): Move list to the back of the struct.
12152 (MULTIPLE_THREADS_OFFSET): Adjust offset.
12153 (SYSINFO_OFFSEET): Likewise.
12154
121552002-12-27 Jakub Jelinek <jakub@redhat.com>
12156
12157 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h (USE_DL_SYSINFO):
12158 Define.
12159 (DL_SYSINFO_DEFAULT): Cast to uintptr_t to avoid warnings.
12160 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h (NEED_DL_SYSINFO,
12161 DL_SYSINFO_DEFAULT, DL_SYSINFO_IMPLEMENTATION): Define.
12162 (USE_DL_SYSINFO): Undef.
12163
121642002-12-22 Jakub Jelinek <jakub@redhat.com>
12165
12166 * Makefile (tests-reverse): Use $(objpfx)../libc.so instead of
12167 $(common-objpfx)libc.so.
12168 * tst-cancel4.c (tf_write, tf_writev): Increase buf sizes so that
12169 it is bigger than pipe buffer size even on arches with bigger
12170 page size.
12171 (tf_usleep): Cast usleep argument to useconds_t to avoid warnings.
12172
a218c9cf
UD
121732002-12-25 Ulrich Drepper <drepper@redhat.com>
12174
12175 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Implement
12176 correct errno access for case that USE___THREAD is not defined.
12177
015a2dc9
UD
121782002-12-24 Ulrich Drepper <drepper@redhat.com>
12179
12180 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Add missing #endif.
12181 Patch by Marijn Ros <marijn@mad.scientist.com>.
12182
5220f9ac
RM
121832002-12-22 Roland McGrath <roland@redhat.com>
12184
12185 * Makefile (omit-deps): Add $(unix-syscalls:%=ptw-%).
12186
1561bf63
UD
121872002-12-20 Ulrich Drepper <drepper@redhat.com>
12188
12189 * sysdeps/pthread/bits/stdio-lock.h (_IO_lock_inexpensive): Define.
12190
3325198e
UD
121912002-12-19 Ulrich Drepper <drepper@redhat.com>
12192
057c823f
UD
12193 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Don't define
12194 NEED_DL_SYSINFO since no processor < i686 had the sysenter opcode.
12195 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h: New file.
12196
097eca29
UD
12197 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Use ENTER_KERNEL instead
12198 of int $0x80.
12199 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
12200 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Likewise.
12201 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Likewise.
12202 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
12203 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
12204 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Likewise.
12205 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Likewise.
12206 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
12207
12208 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Add support for using
12209 sysenter.
12210 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Likewise.
12211
12212 * sysdeps/i386/tls.h: Unconditionally include <dl-sysdep.h>.
12213
5f5843e3
UD
12214 * allocatestack.c (allocate_stack) [NEED_DL_SYSINFO]: Set sysinfo
12215 in new TCB.
12216 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Check
12217 that sysinfo is properly initialized.
12218 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define RTLD_PRIVATE_ERRNO
12219 to 1 only for ld.so.
12220
3325198e
UD
12221 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define
12222 RTLD_CORRECT_DYNAMIC_WEAK.
12223
74e8f2dc
UD
122242002-12-19 Jakub Jelinek <jakub@redhat.com>
12225
12226 * forward.c (pthread_attr_init_2_0, pthread_attr_init_2_1):
12227 Use return 0 as 6th argument to FORWARD4.
12228 * pthread_equal.c: Include pthreadP.h instead of pthread.h.
12229
df45b31e
UD
122302002-12-18 Ulrich Drepper <drepper@redhat.com>
12231
12232 * descr.h (struct pthread) [NEED_DL_SYSINFO]: Add sysinfo member.
12233 * sysdeps/i386/tls.h (tcbhead_t): Add sysinfo member.
12234 Define SYSINFO_OFFSEET if NEED_DL_SYSINFO is defined.
12235 (INIT_SYSINFO): New #define.
12236 (TLS_TP_INIT): Use INIT_SYSINFO.
12237 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
12238 At test to make sure SYSINFO_OFFSET value is correct.
12239 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: New file.
12240
3d539579
UD
122412002-12-18 Jakub Jelinek <jakub@redhat.com>
12242
12243 * sysdeps/pthread/flockfile.c (flockfile): Change into weak alias.
12244 * sysdeps/unix/sysv/linux/raise.c (gsignal): Add weak alias to raise.
12245 * Versions [libc: GLIBC_2.0]: Add pthread_attr_init.
12246 [libpthread: GLIBC_2.1]: Remove __pthread_rwlock_init,
12247 __pthread_rwlock_destroy, __pthread_rwlock_rdlock,
12248 __pthread_rwlock_wrlock, __pthread_rwlock_unlock,
12249 __pthread_rwlock_tryrdlock and __pthread_rwlock_trywrlock.
12250
d7913e0e
UD
122512002-12-18 Ulrich Drepper <drepper@redhat.com>
12252
f051627f
UD
12253 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Use ENTER_KERNEL
12254 macro instead of using int $0x80 directly.
12255
d7913e0e
UD
12256 * sysdeps/pthread/bits/stdio-lock.h: New file.
12257 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: New file.
12258 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevelmutex.S: New file.
12259 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevelmutex.S: New file.
12260 * Makefile (routines): Add libc-lowlevelmutex.
12261
12262 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Remove
12263 __i686.get_pc_thunk.dx.
12264
f077a4a9
UD
122652002-12-17 Jakub Jelinek <jakub@redhat.com>
12266
12267 * Makefile (libpthread-shared-only-routines): Add pt-allocrtsig.
12268 (tests): Depend on $(objpfx)tst-cancel-wrappers.out.
12269 ($(objpfx)tst-cancel-wrappers.out): New rule.
12270 * tst-cancel-wrappers.sh: New test.
12271 * tst-locale1.c: Include signal.h.
12272 (uselocale): Test static linking of __libc_current_sigrt*.
12273
122742002-12-17 Ulrich Drepper <drepper@redhat.com>
12275
12276 * Makefile (tests): Add tst-cancel6.
12277 * tst-cancel6.c: New file
12278
bd499a3b
UD
122792002-12-17 Jakub Jelinek <jakub@redhat.com>
12280
12281 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (SINGLE_THREAD_P):
12282 Define meaningfully for assembler as well.
12283 * pthreadP.h (struct pthread_functions): Remove
12284 ptr_pthread_attr_init field. Add ptr_pthread_attr_init_2_0
12285 and ptr_pthread_attr_init_2_1 fields.
12286 * init.c (pthread_functions): Initialize ptr_pthread_attr_init_2_0
12287 and ptr_pthread_attr_init_2_1 instead of ptr_pthread_attr_init.
12288 * forward.c (FORWARD4): Renamed from FORWARD3. Add export argument.
12289 (FORWARD3): Define using FORWARD4.
12290 (pthread_attr_init): Provide both @GLIBC_2.0 and @@GLIBC_2.1
12291 versions.
12292 * pt-system.c: Remove duplicate stdlib.h include.
12293
0a1063f4
UD
122942002-12-16 Ulrich Drepper <drepper@redhat.com>
12295
87d60668
UD
12296 * sem_init.c: Define sem_init@GLIBC_2.0.
12297 * sem_destroy.c: Define sem_destroy@GLIBC_2.0.
12298 * sem_getvalue.c: Define sem_getvalue@GLIBC_2.0.
12299
0a1063f4
UD
12300 * flockfile.c: Moved to...
12301 * sysdeps/pthread/flockfile.c: ...here. New file.
12302 * funlockfile.c: Moved to...
12303 * sysdeps/pthread/funlockfile.c: ...here. New file.
12304 * ftrylockfile.c: Moved to...
12305 * sysdeps/pthread/ftrylockfile.c: ...here. New file.
12306
9634cf9d
UD
123072002-12-16 Jakub Jelinek <jakub@redhat.com>
12308
12309 * libc-cancellation.c: Guard both function with
12310 #if !defined NOT_IN_libc.
12311 * Makefile (libpthread-routines): Use ptw-, not pt- prefix for the
12312 automatically provided pthread wrappers.
12313 * pthreadP.h (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): Define to
12314 CANCEL_* if IS_IN_libpthread and to dummy versions if not in libc
12315 nor in libpthread.
12316 * pt-open.c: Removed.
12317 * pt-fcntl.c: Removed.
12318 * pt-fsync.c: Removed.
12319 * pt-lseek.c: Removed.
12320 * pt-msgrcv.c: Removed.
12321 * pt-msgsnd.c: Removed.
12322 * pt-msync.c: Removed.
12323 * pt-nanosleep.c: Removed.
12324 * pt-open64.c: Removed.
12325 * pt-pause.c: Removed.
12326 * pt-pread.c: Removed.
12327 * pt-pread64.c: Removed.
12328 * pt-pwrite.c: Removed.
12329 * pt-pwrite64.c: Removed.
12330 * pt-read.c: Removed.
12331 * pt-recv.c: Removed.
12332 * pt-recvfrom.c: Removed.
12333 * pt-recvmsg.c: Removed.
12334 * pt-send.c: Removed.
12335 * pt-sendto.c: Removed.
12336 * pt-sigtimedwait.c: Removed.
12337 * pt-sigwait.c: Removed.
12338 * pt-wait.c: Removed.
12339 * pt-waitpid.c: Removed.
12340 * pt-write.c: Removed.
12341 * pt-accept.c: Removed.
12342 * pt-close.c: Removed.
12343 * pt-connect.c: Removed.
12344 * pt-lseek64.c: Removed.
12345 * pt-sendmsg.c: Removed.
12346 * pt-tcdrain.c: Removed.
12347
6ee8d334
UD
123482002-12-15 Ulrich Drepper <drepper@redhat.com>
12349
81fa9371
UD
12350 * init.c (__pthread_initialize_minimal_internal): Renamed from
12351 __pthread_initialize_minimal. Make old name an alias. This
12352 converts a normal relocation into a relative relocation.
12353
f3015aa5
UD
12354 * pt-fcntl.c (__fcntl): Use fcntl64 syscall, not fcntl.
12355
4cbc1950
UD
12356 * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect,
12357 readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev.
12358 * Makefile (libpthread-routines): Remove pt-creat, pt-poll,
12359 pt-pselect, pt-readv, pt-select, pt-sigpause, pt-sigsuspend,
12360 pt-sigwaitinfo, pt-waitid, and pt-writev.
12361 * pt-creat.c: Removed.
12362 * pt-poll.c: Removed.
12363 * pt-pselect.c: Removed.
12364 * pt-readv.c: Removed.
12365 * pt-select.c: Removed.
12366 * pt-sigpause.c: Removed.
12367 * pt-sigsuspend.c: Removed.
12368 * pt-sigwaitinfo.c: Removed.
12369 * pt-waitid.c: Removed.
12370 * pt-writev.c: Removed.
12371
8454830b
UD
12372 * init.c (pthread_functions): New variable.
12373 (__pthread_initialize_minimal): Pass pointer to pthread_functions
12374 (or NULL) to __libc_pthread_init.
12375 * forward.c: Rewrite to use __libc:pthread_functions array to get
12376 function addresses.
12377 * sysdeps/unix/sysv/linux/fork.h: Remove __libc_pthread_init
12378 prototype.
12379 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
12380 Take new parameter. Copy content of variable pointed to by it
12381 to __libc_pthread_init.
12382
12383 * pthreadP.h (struct pthread_functions): New type.
12384 (__libc_pthread_init): Declare.
12385
12386 * pthread_attr_destroy.c: Add namespace protected alias.
12387 * pthread_attr_getdetachstate.c: Likewise.
12388 * pthread_attr_getinheritsched.c: Likewise.
12389 * pthread_attr_getschedparam.c: Likewise.
12390 * pthread_attr_getschedpolicy.c: Likewise.
12391 * pthread_attr_getscope.c: Likewise.
12392 * pthread_attr_setdetachstate.c: Likewise.
12393 * pthread_attr_setinheritsched.c: Likewise.
12394 * pthread_attr_setschedparam.c: Likewise.
12395 * pthread_attr_setschedpolicy.c: Likewise.
12396 * pthread_attr_setscope.c: Likewise.
12397 * pthread_cond_broadcast.c: Likewise.
12398 * pthread_cond_destroy.c: Likewise.
12399 * pthread_cond_init.c: Likewise.
12400 * pthread_cond_signal.c: Likewise.
12401 * pthread_cond_wait.c: Likewise.
12402 * pthread_condattr_destroy.c: Likewise.
12403 * pthread_condattr_init.c: Likewise.
12404 * pthread_equal.c: Likewise.
12405 * pthread_exit.c: Likewise.
12406 * pthread_getschedparam.c: Likewise.
12407 * pthread_self.c: Likewise.
12408 * pthread_setcancelstate.c: Likewise.
12409 * pthread_setschedparam.c: Likewise.
12410 * pthread_mutex_destroy.c: Likewise.
12411 * pthread_mutex_init.c: Likewise.
12412 * pthreadP.h: Add prototypes for the aliases.
12413
0d5f4929
UD
12414 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Set
12415 multiple_threads member in correct TCB to 1.
12416
6ee8d334
UD
12417 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define
12418 SINGLE_THREAD_P. If in libc or libpthread examine multiple_thread
12419 member of thread decriptor, otherwise return unconditionally 1.
12420
2fb6444d
UD
124212002-12-14 Ulrich Drepper <drepper@redhat.com>
12422
12423 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Changes folded into the
12424 regular Linux version. Remove file.
12425 * sysdeps/unix/sysv/linux/connect.S: Likewise. Remove file.
12426 * sysdeps/unix/sysv/linux/llseek.c: Likewise. Remove file.
12427 * sysdeps/unix/sysv/linux/msgrcv.c: Likewise. Remove file.
12428 * sysdeps/unix/sysv/linux/msgsnd.c: Likewise. Remove file.
12429 * sysdeps/unix/sysv/linux/open64.c: Likewise. Remove file.
12430 * sysdeps/unix/sysv/linux/poll.c: Likewise. Remove file.
12431 * sysdeps/unix/sysv/linux/pread.c: Likewise. Remove file.
12432 * sysdeps/unix/sysv/linux/pread64.c: Likewise. Remove file.
12433 * sysdeps/unix/sysv/linux/pselect.c: Likewise. Remove file.
12434 * sysdeps/unix/sysv/linux/pwrite.c: Likewise. Remove file.
12435 * sysdeps/unix/sysv/linux/pwrite64.c: Likewise. Remove file.
12436 * sysdeps/unix/sysv/linux/readv.c: Likewise. Remove file.
12437 * sysdeps/unix/sysv/linux/recv.S: Likewise. Remove file.
12438 * sysdeps/unix/sysv/linux/recvfrom.S: Likewise. Remove file.
12439 * sysdeps/unix/sysv/linux/recvmsg.S: Likewise. Remove file.
12440 * sysdeps/unix/sysv/linux/send.S: Likewise. Remove file.
12441 * sysdeps/unix/sysv/linux/sendmsg.S: Likewise. Remove file.
12442 * sysdeps/unix/sysv/linux/sendto.S: Likewise. Remove file.
12443 * sysdeps/unix/sysv/linux/sigpause.c: Likewise. Remove file.
12444 * sysdeps/unix/sysv/linux/sigsuspend.c: Likewise. Remove file.
12445 * sysdeps/unix/sysv/linux/sigtimedwait.c: Likewise. Remove file.
12446 * sysdeps/unix/sysv/linux/sigwait.c: Likewise. Remove file.
12447 * sysdeps/unix/sysv/linux/sigwaitinfo.c: Likewise. Remove file.
12448 * sysdeps/unix/sysv/linux/system.c: Likewise. Remove file.
12449 * sysdeps/unix/sysv/linux/tcdrain.c: Likewise. Remove file.
12450 * sysdeps/unix/sysv/linux/wait.c: Likewise. Remove file.
12451 * sysdeps/unix/sysv/linux/waitid.c: Likewise. Remove file.
12452 * sysdeps/unix/sysv/linux/waitpid.c: Likewise. Remove file.
12453 * sysdeps/unix/sysv/linux/writev.c: Likewise. Remove file.
12454 * sysdeps/unix/sysv/linux/i386/fcntl.c: Likewise. Remove file.
12455
86b2dc40
UD
124562002-12-14 Jakub Jelinek <jakub@redhat.com>
12457
12458 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: New file.
12459 * sysdeps/unix/sysv/linux/open.c: Removed.
12460 * sysdeps/unix/sysv/linux/fsync.c: Removed.
12461 * sysdeps/unix/sysv/linux/lseek.c: Removed.
12462 * sysdeps/unix/sysv/linux/msync.c: Removed.
12463 * sysdeps/unix/sysv/linux/read.c: Removed.
12464 * sysdeps/unix/sysv/linux/close.c: Removed.
12465 * sysdeps/unix/sysv/linux/creat.c: Removed.
12466 * sysdeps/unix/sysv/linux/nanosleep.c: Removed.
12467 * sysdeps/unix/sysv/linux/pause.c: Removed.
12468 * sysdeps/unix/sysv/linux/select.c: Removed.
12469 * sysdeps/unix/sysv/linux/write.c: Removed.
12470
9d263d72
UD
124712002-12-14 Ulrich Drepper <drepper@redhat.com>
12472
12473 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Check multiple_threads
12474 element in TCB to see whether locking is needed.
12475
12476 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Check that
12477 MULTIPLE_THREADS_OFFSET value is correct.
12478
12479 * sysdeps/unix/sysv/linux/close.c: New file.
12480 * sysdeps/unix/sysv/linux/connect.S: New file.
12481 * sysdeps/unix/sysv/linux/creat.c: New file.
12482 * sysdeps/unix/sysv/linux/fsync.c: New file.
12483 * sysdeps/unix/sysv/linux/llseek.c: New file.
12484 * sysdeps/unix/sysv/linux/lseek.c: New file.
12485 * sysdeps/unix/sysv/linux/msgrcv.c: New file.
12486 * sysdeps/unix/sysv/linux/msgsnd.c: New file.
12487 * sysdeps/unix/sysv/linux/msync.c: New file.
12488 * sysdeps/unix/sysv/linux/nanosleep.c: New file.
12489 * sysdeps/unix/sysv/linux/open.c: New file.
12490 * sysdeps/unix/sysv/linux/open64.c: New file.
12491 * sysdeps/unix/sysv/linux/pause.c: New file.
12492 * sysdeps/unix/sysv/linux/poll.c: New file.
12493 * sysdeps/unix/sysv/linux/pread.c: New file.
12494 * sysdeps/unix/sysv/linux/pread64.c: New file.
12495 * sysdeps/unix/sysv/linux/pselect.c: New file.
12496 * sysdeps/unix/sysv/linux/pwrite.c: New file.
12497 * sysdeps/unix/sysv/linux/pwrite64.c: New file.
12498 * sysdeps/unix/sysv/linux/readv.c: New file.
12499 * sysdeps/unix/sysv/linux/recv.S: New file.
12500 * sysdeps/unix/sysv/linux/recvfrom.S: New file.
12501 * sysdeps/unix/sysv/linux/recvmsg.S: New file.
12502 * sysdeps/unix/sysv/linux/select.c: New file.
12503 * sysdeps/unix/sysv/linux/send.S: New file.
12504 * sysdeps/unix/sysv/linux/sendmsg.S: New file.
12505 * sysdeps/unix/sysv/linux/sendto.S: New file.
12506 * sysdeps/unix/sysv/linux/sigpause.c: New file.
12507 * sysdeps/unix/sysv/linux/sigsuspend.c: New file.
12508 * sysdeps/unix/sysv/linux/sigtimedwait.c: New file.
12509 * sysdeps/unix/sysv/linux/sigwait.c: New file.
12510 * sysdeps/unix/sysv/linux/sigwaitinfo.c: New file.
12511 * sysdeps/unix/sysv/linux/system.c: New file.
12512 * sysdeps/unix/sysv/linux/tcdrain.c: New file.
12513 * sysdeps/unix/sysv/linux/wait.c: New file.
12514 * sysdeps/unix/sysv/linux/waitid.c: New file.
12515 * sysdeps/unix/sysv/linux/waitpid.c: New file.
12516 * sysdeps/unix/sysv/linux/writev.c: New file.
12517 * sysdeps/unix/sysv/linux/i386/fcntl.c: New file.
12518
12519 * pt-readv.c: Fix comment.
12520
125212002-12-14 Jakub Jelinek <jakub@redhat.com>
12522
12523 * tst-cleanup1.c: Include stdlib.h.
12524
12525 * tst-cancel5.c: New test.
12526 * Makefile (tests): Add tst-cancel5.
12527 (tst-cancel5): Link against libc.so libpthread.so in that order.
12528
9ae0909b
UD
125292002-12-13 Ulrich Drepper <drepper@redhat.com>
12530
b7bdd9c4
UD
12531 * forward.c (test_loaded): Prevent recursive calls.
12532
9ae0909b
UD
12533 * Makefile (routines): Add libc-cancellation.
12534 * libc-cancellation.c: New file.
12535 * descr.h (struct pthread): Add multiple_threads field.
12536 * allocatestack.c (allocate_stack): Initialize multiple_header field of
12537 new thread descriptor to 1.
12538 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread):
12539 Initialize multiple_thread field after successful thread creation.
12540 * cancellation.c (__do_cancel): Move to pthreadP.h.
12541 (__pthread_enable_asynccancel): Remove parameter from __do_cancel call.
12542 (__pthread_disable_asynccancel): Add internal_function attribute.
12543 * init.c (sigcancel_handler): Remove parameter from __do_cancel call.
12544 * pthread_setcancelstate.c: Likewise.
12545 * pthread_setcanceltype.c: Likewise.
12546 * pthread_exit.c: Likewise.
12547 * pthreadP.h (CANCELLATION_P): Likewise.
12548 (__do_cancel): Define as static inline.
12549 (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): New #defines.
12550 (__libc_enable_asynccancel, __libc_disable_asynccancel): New
12551 declarations.
12552 * sysdeps/i386/tls.h (tcbhead_t): Add list and multiple_threads
12553 fields. Define MULTIPLE_THREADS_OFFSET.
12554 * sysdeps/pthread/bits/libc-lock.h: Remove __libc_locking_needed
12555 declaration.
12556 * sysdeps/unix/sysv/linux/accept.S: New file.
12557 * sysdeps/unix/sysv/linux/read.c: New file.
12558 * sysdeps/unix/sysv/linux/write.c: New file.
12559 * sysdeps/unix/sysv/linux/i386/pt-socket.S: New file.
12560 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Remove definition and
12561 initialization of __libc_locking_needed.
12562 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Don't use
12563 __libc_locking_needed, use multiple_threads field in TCB.
12564 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
12565
22f20674
UD
125662002-12-12 Ulrich Drepper <drepper@redhat.com>
12567
2ad2e1e7
UD
12568 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: Use i486
12569 version.
12570 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: Likewise.
12571
22f20674
UD
12572 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Correct
12573 access to __libc_locking_needed for PIC.
12574
aa80bf86
UD
125752002-12-12 Jakub Jelinek <jakub@redhat.com>
12576
12577 * sysdeps/pthread/bits/libc-lock.h (__libc_locking_needed): Only
12578 declare for libc.so.
12579 (__libc_lock_init, __libc_lock_init_recursive): Change into comma
12580 expression.
12581 (__libc_lock_lock): Put into statement expression.
12582 (__libc_lock_unlock): Remove trailing semicolon.
12583 * sysdeps/unix/sysv/linux/fork.h (__libc_pthread_init): Fix typo.
12584
24021373
RM
125852002-12-12 Roland McGrath <roland@redhat.com>
12586
12587 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use asm operand with
12588 "m" constraint to refer to __libc_locking_needed. Declare it here.
12589
14e7aece
UD
125902002-12-12 Ulrich Drepper <drepper@redhat.com>
12591
12592 * sysdeps/unix/sysv/linux/fork-gen.c: Renamed to...
12593 * sysdeps/unix/sysv/linux/libc_pthread_init.c: ...this.
12594 Initialize __libc_locking_needed.
12595 * init.c (__pthread_initialize_minimal): Call __libc_pthread_init
12596 instead of __register_pthread_fork_handler.
12597 * sysdeps/pthread/bits/libc-lock.h: Declare __libc_locking_needed.
12598 * sysdeps/unix/sysv/linux/Makefile (sysdep_routimes): Replace
12599 fork-gen with libc_pthread_init.
12600 * sysdeps/unix/sysv/linux/Versions: Use __libc_pthread_init instead
12601 of __register_pthread_fork_handler.
12602 * sysdeps/unix/sysv/linux/fork.h: Declare __libc_pthread_init instead
12603 of __register_pthread_fork_handler.
12604 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use
12605 __libc_locking_needed to determine whether lock prefix can be avoided.
12606 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
12607
85631c8e
UD
126082002-12-11 Ulrich Drepper <drepper@redhat.com>
12609
da63009e
UD
12610 * Makefile (tests): Add tst-cleanup1.
12611 * tst-cleanup1.c: New file.
12612 * cancellation.c (__cleanup_thread): Removed.
12613 (__do_cancel): Remove call to __cleanup_thread.
12614 * pthreadP.h: Remove __cleanup_thread prorotype.
12615
000160a2
UD
12616 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start):
12617 Remember function and argument even if cancellation handler
12618 function is not available.
12619 (__libc_cleanup_region_end): Execute registered function directly if
12620 pthread functions are not available.
12621 (__libc_cleanup_end): Likewise.
12622
85631c8e
UD
12623 * init.c (__pthread_initialize_minimal): Fix initialization in
12624 static lib by preventing gcc from being too clever.
12625
dce8f2b6
UD
126262002-12-10 Ulrich Drepper <drepper@redhat.com>
12627
34a075be
UD
12628 * init.c (__pthread_initialize_minimal): Remove unneccesary
12629 sigaddset call.
12630
dce8f2b6
UD
12631 * Makefile (tests): We can run tst-locale2 now.
12632
e5e45b53
UD
126332002-12-09 Ulrich Drepper <drepper@redhat.com>
12634
12635 * Versions: Remove duplicated sigwait entry.
12636
bdb04f92
UD
126372002-12-08 Ulrich Drepper <drepper@redhat.com>
12638
1e506629
UD
12639 * pthreadP.h: Enable pthread_cleanup_{push,pop} optimizations only
12640 inside libpthread.
12641
a3957dd5
UD
12642 * pt-fcntl.c (__fcntl): Initialize oldtype to avoid warning.
12643
bdb04f92
UD
12644 * pthreadP.h: Declare __pthread_enable_asynccancel and
12645 __pthread_disable_asynccancel.
12646 (CANCEL_ASYNC): Use __pthread_enable_asynccancel.
12647 (CANCEL_RESET): Use __pthread_disable_asynccancel.
12648 * cancellation.c (__pthread_enable_asynccancel): New function.
12649 (__pthread_disable_asynccancel): New function.
12650 * pt-accept.c: Adjust for CANCEL_ASYNC and CANCEL_RESET change.
12651 * pt-close.c: Likewise.
12652 * pt-connect.c: Likewise.
12653 * pt-creat.c: Likewise.
12654 * pt-fcntl.c: Likewise.
12655 * pt-fsync.c: Likewise.
12656 * pt-lseek.c: Likewise.
12657 * pt-lseek64.c: Likewise.
12658 * pt-msgrcv.c: Likewise.
12659 * pt-msgsnd.c: Likewise.
12660 * pt-msync.c: Likewise.
12661 * pt-nanosleep.c: Likewise.
12662 * pt-open.c: Likewise.
12663 * pt-open64.c: Likewise.
12664 * pt-pause.c: Likewise.
12665 * pt-poll.c: Likewise.
12666 * pt-pread.c: Likewise.
12667 * pt-pread64.c: Likewise.
12668 * pt-pselect.c: Likewise.
12669 * pt-pwrite.c: Likewise.
12670 * pt-pwrite64.c: Likewise.
12671 * pt-read.c: Likewise.
12672 * pt-readv.c: Likewise.
12673 * pt-recv.c: Likewise.
12674 * pt-recvfrom.c: Likewise.
12675 * pt-recvmsg.c: Likewise.
12676 * pt-select.c: Likewise.
12677 * pt-send.c: Likewise.
12678 * pt-sendmsg.c: Likewise.
12679 * pt-sendto.c: Likewise.
12680 * pt-sigpause.c: Likewise.
12681 * pt-sigsuspend.c: Likewise.
12682 * pt-sigtimedwait.c: Likewise.
12683 * pt-sigwait.c: Likewise.
12684 * pt-sigwaitinfo.c: Likewise.
12685 * pt-system.c: Likewise.
12686 * pt-tcdrain.c: Likewise.
12687 * pt-wait.c: Likewise.
12688 * pt-waitid.c: Likewise.
12689 * pt-waitpid.c: Likewise.
12690 * pt-write.c: Likewise.
12691 * pt-writev.c: Likewise.
a3957dd5
UD
12692 * pthread_join.c: Likewise.
12693 * pthread_timedjoin.c: Likewise.
bdb04f92
UD
12694
12695 * pt-sigpause.c (sigsuspend): Call __sigsuspend.
12696 (__xpg_sigpause): New function.
12697 * Versions (libpthread:GLIBC_2.3.2): Add __xpg_sigpause.
12698
6ccb3834
UD
126992002-12-07 Ulrich Drepper <drepper@redhat.com>
12700
09efc3ba
UD
12701 * Makefile (CFLAGS-ftrylockfile.c): Add -D_IO_MTSAFE_IO.
12702
12703 * cleanup.c: Move declarations of _GI_pthread_cleanup_push and
12704 _GI_pthread_cleanup_pop to pthreadP.h.
12705
12706 * ftrylockfile.c: Use _IO_lock_trylock instead of
12707 pthread_mutex_trylock.
12708
12709 * pthreadP.h (CANCEL_ASYNC): Use __pthread_setcanceltype.
12710 (CANCEL_RESET): Likewise.
12711 (__pthread_setcanceltype_): Declare.
12712 (__pthread_mutex_lock_internal): Declare.
12713 (__pthread_mutex_unlock_internal): Declare.
12714 (__pthread_once_internal): Declare.
12715 (pthread_cleanup_push): Redefine using _GI_pthread_cleanup_push.
12716 (pthread_cleanup_pop): Redefine using _GI_pthread_cleanup_pop.
12717
12718 * pthread_cond_timedwait.c: Use INTUSE is calls to pthread_mutex_lock
12719 and pthread_mutex_unlock.
12720 * pthread_cond_wait.c: Likewise.
12721 * pthread_mutex_lock.c: Use INTDEF to define alias if needed.
12722 * pthread_mutex_unlock.c: Likewise.
12723
12724 * pthread_setcanceltype.c: Add additional alias
12725 __pthread_setcanceltype.
12726
12727 * sem_unlink.c (sem_unlink): Use __pthread_once with INTDEF.
12728 * sem_open.c (sem_open): Likewise.
12729 Use __libc_open, __libc_write, and __libc_close instead of
12730 open, write, and close respectively.
12731
12732 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_trylock_internal):
12733 Rewrite as statement expression since it must return a value.
12734
12735 * pthread_cancel.c: Use __pthread_kill instead of pthread_kill.
12736 * sysdeps/unix/sysv/linux/pthread_kill.c: Define additional alias
12737 __pthread_kill.
12738
12739 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Define additional
12740 alias __pthread_once_internal.
12741
6ccb3834
UD
12742 * sysdeps/unix/sysv/linux/raise.c: Use libc_hidden_def for raise.
12743
d3c9f895
UD
127442002-12-06 Ulrich Drepper <drepper@redhat.com>
12745
4614167a
UD
12746 * Makefile (tests): Add tst-stdio1 and tst-stdio2.
12747 * tst-stdio1.c: New file.
12748 * tst-stdio2.c: New file.
12749
a4548cea
UD
12750 * init.c (__pthread_initialize_minimal): Correct INIT_LIST_HEAD use.
12751
d3c9f895
UD
12752 * Makefile (tests): Comment out tst-locale2 for now.
12753 (CFLAGS-flockfile.c, CFLAGS-funlockfile.c): Define to -D_IO_MTSAFE_IO.
12754
12755 * sysdeps/unix/sysv/linux/Makefile: Define CFLAGS-fork.c to
12756 -D_IO_MTSAFE_IO.
12757 * sysdeps/unix/sysv/linux/fork.c: Include <bits/stdio-lock.h>.
12758 Use _IO_lock_init instead of explicit assignment.
12759
12760 * sysdeps/pthread/bits/libc-lock.h: Define __rtld_lock_* macros.
12761 Define __libc_lock_* and __libc_lock_recursive macros with
12762 lowlevellock macros, not pthread mutexes.
12763
12764 * flockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_lock instead
12765 of pthread_mutex_lock.
12766 * funlockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_unlock
12767 instead of pthread_mutex_unlock.
12768
fde89ad0
RM
127692002-12-06 Roland McGrath <roland@redhat.com>
12770
12771 * allocatestack.c (__stack_user): Use uninitialized defn.
12772 * init.c (__pthread_initialize_minimal): Initialize it here.
12773
11767d47
RM
127742002-12-05 Roland McGrath <roland@redhat.com>
12775
fde89ad0
RM
12776 * sysdeps/i386/tls.h (TLS_INIT_TP): Make it return zero or an error
12777 string.
12778 * sysdeps/x86_64/tls.h (TLS_INIT_TP): Likewise.
12779
11767d47
RM
12780 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Add
12781 missing & here too.
12782
440d8bc2
UD
127832002-12-05 Ulrich Drepper <drepper@redhat.com>
12784
12785 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
12786 lowlevellock.
12787 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: New file.
12788 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: New file.
12789 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: New file.
12790 * sysdeps/pthread/bits/libc-lock.h: Use lowlevellock implementation
12791 for __libc_lock_* macros.
12792 * Makefile (routines): Add libc-lowlevellock.
12793
127942002-10-09 Roland McGrath <roland@redhat.com>
12795
12796 * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call): New macro.
12797 Under [__PIC__], call the function via the pointer fetched for
12798 comparison rather than a call by name that uses the PLT.
12799 (__libc_lock_init, __libc_rwlock_init, __libc_lock_fini)
12800 (__libc_rwlock_fini, __libc_lock_lock, __libc_rwlock_rdlock)
12801 (__libc_rwlock_wrlock, __libc_lock_trylock, __libc_rwlock_tryrdlock)
12802 (__libc_rwlock_trywrlock, __libc_lock_unlock, __libc_rwlock_unlock)
12803 (__libc_key_create, __libc_getspecific, __libc_setspecific): Use it.
12804
d5ed0118
RM
128052002-12-04 Roland McGrath <roland@redhat.com>
12806
12807 * forward.c (pthread_self): Use FORWARD3 macro to correct return type.
12808
12809 * sysdeps/i386/td_ta_map_lwp2thr.c: Moved from ../nptl_db.
12810 * sysdeps/generic/td_ta_map_lwp2thr.c: New file.
12811
12812 * pthread_create.c (start_thread): Add missing & on __nptl_last_event.
12813
eaa4099f
UD
128142002-12-04 Ulrich Drepper <drepper@redhat.com>
12815
12816 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Make pthread_t
12817 a completely opaque, non-integer type.
12818 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
12819
33b5d0cc
UD
128202002-12-05 Jakub Jelinek <jakub@redhat.com>
12821
12822 * sysdeps/i386/tls.h: Include stdlib.h.
12823 * sysdeps/x86_64/tls.h: Likewise.
12824
7a5cdb30
UD
128252002-12-04 Ulrich Drepper <drepper@redhat.com>
12826
c4a6d859
UD
12827 * Makefile (tests): Add tst-locale2.
12828 (tests-static): Likewise.
12829 * tst-locale2.c: New file.
12830
7a5cdb30
UD
12831 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Mark asms as
12832 volatile and add memory clobbers to lock operations.
12833
d82d5d12
UD
128342002-12-03 Ulrich Drepper <drepper@redhat.com>
12835
69cae3cf
UD
12836 * sysdeps/i386/i686/bits/atomic.h: Use i486 version.
12837 * sysdeps/i386/i486/bits/atomic.h: New file.
12838 * sysdeps/i386/i586/bits/atomic.h: New file.
12839 * sysdeps/i386/i686/pthread_spin_trylock.S: Define HAVE_CMOV and
12840 include i486 version.
12841 * sysdeps/i386/i486/pthread_spin_trylock.S: New file.
12842 * sysdeps/i386/i586/pthread_spin_trylock.S: New file.
c97c64de 12843 Patch by Marijn Ros <marijn@mad.scientist.com>.
69cae3cf 12844
e4044c01
UD
12845 * allocatestack.c (get_cached_stack): Don't crash if we first
12846 found a stack with a larger size then needed.
12847 Reported by Hui Huang <hui.huang@sun.com>.
12848
d82d5d12
UD
12849 * Makefile (tests): Add tst-sysconf.
12850 * tst-sysconf.c: New file.
12851
12852 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine
12853 PTHREAD_THREADS_MAX.
12854
fa9a4ff0
RM
128552002-12-02 Roland McGrath <roland@redhat.com>
12856
12857 * pthreadP.h (__stack_user, __nptl_create_event, __nptl_death_event):
12858 Declare using hidden_proto instead of attribute_hidden, so there are
12859 non-.hidden static symbols for gdb to find.
12860 (__pthread_keys): Likewise.
12861 * events.c (__nptl_create_event, __nptl_death_event): Add hidden_def.
12862 * allocatestack.c (__stack_user): Likewise.
12863 * pthread_create.c (__pthread_keys): Likewise.
12864 (__nptl_threads_events, __nptl_last_event): Make these static instead
12865 of hidden.
12866 * pthread_key_create.c (__pthread_pthread_keys_max,
12867 __pthread_pthread_key_2ndlevel_size): Renamed from __linuxthreads_*.
12868
91949a33
UD
128692002-12-02 Ulrich Drepper <drepper@redhat.com>
12870
c22b52fa
UD
12871 * Makefile (tests): Add tst-locale1. If buid-static is yes link
12872 statically.
12873 * tst-locale1.c: New file.
12874
beb6aa41
UD
12875 * pthread_cond_timedwait.c: Include <stdlib.h>.
12876
91949a33
UD
12877 * Makefile (tests): Add tst-fork2 and tst-fork3.
12878 * tst-fork2.c: New file.
12879 * tst-fork3.c: New file.
12880
654dff90
UD
128812002-11-28 Ulrich Drepper <drepper@redhat.com>
12882
cb0e76b4
UD
12883 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: New file.
12884
12885 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define macros which
12886 require it to 200112L.
12887
12888 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Use cmov
12889 instruction only if HAVE_CMOV is defined.
12890 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrwlock.S: Define HAVE_CMOV.
12891
975aa229
UD
12892 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: New file.
12893
654dff90
UD
12894 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: New file.
12895
12896 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: New file.
12897
12898 * sysdeps/unix/sysv/linux/x86_64/pt-vfork.S: New file.
12899
a3931336
UD
129002002-11-27 Ulrich Drepper <drepper@redhat.com>
12901
c10c099c
UD
12902 * sysdeps/x86_64/bits/atomic.h: New file.
12903
12904 * sysdeps/i386/i686/bits/atomic.h: Fix asm syntax for 8- and
12905 16-bit operations.
12906
dca99d27
UD
12907 * sysdeps/unix/sysv/linux/raise.c (raise): Use INTERNAL_SYSCALL if
12908 possible since gettid cannot fail.
12909
f78deea6
UD
12910 * sysdeps/x86_64/pthreaddef.h: New file.
12911
12912 * sysdeps/i386/pthreaddef.h (gettid): Removed.
12913
12914 * sysdeps/x86_64/pthread_spin_init.c: New file.
12915 * sysdeps/x86_64/pthread_spin_lock.c: New file.
12916 * sysdeps/x86_64/pthread_spin_trylock.c: New file.
12917 * sysdeps/x86_64/pthread_spin_unlock.c: New file.
12918
12919 * sysdeps/i386/i686/pthread_spin_trylock.S (pthread_spin_trylock):
12920 Add missing lock prefix. Minute optimization.
12921
12922 * tst-spin2.c (main): Also check successful trylock call.
12923
12924 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Use correct
12925 syscall. Fix typo in case INTERNAL_SYSCALL is not used.
12926
12927 * sysdeps/i386/pthread_spin_destroy.c: Moved to...
12928 * sysdeps/pthread/pthread_spin_destroy.c: ...here. New file.
12929
12930 * sysdeps/i386/pthread_sigmask.c: Removed. Use the generic code.
12931 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Return correct
12932 value in case of an error. Add support for INTERNAL_SYSCALL.
b54e18eb
UD
12933
12934 * sysdeps/i386/pthread_sigmask.c (pthread_sigmask): Return correct
12935 value in case of an error.
12936
a3931336
UD
12937 * sysdeps/x86_64/tls.h: New file.
12938
76a50749
UD
129392002-11-26 Ulrich Drepper <drepper@redhat.com>
12940
117c452c
UD
12941 * sysdeps/i386/tls.h (THREAD_GETMEM_NC): Change interface. It now
12942 takes the array member name and the index as parameters.
12943 (THREAD_SETMEM_NC): Likewise.
12944 * pthread_getspecific.c: Use new THREAD_GETMEM_NC interface.
12945 * pthread_setspecific.c: Use new THREAD_GETMEM_NC and THREAD_SETMEM_NC
12946 interfaces.
12947
12948 * sysdeps/i386/tls.h (THREAD_SETMEM): Use size of member element
12949 to decide which code to use.
12950 (THREAD_SETMEM_NC): Likewise.
12951
76a50749
UD
12952 * allocatestack.c (queue_stack): Don't remove stack from list here.
12953 Do it in the caller. Correct condition to prematurely terminate
12954 loop to free stacks.
12955 (__deallocate_stack): Remove stack from list here.
12956
129572002-11-26 Ulrich Drepper <drepper@redhat.com>
12958
12959 * Makefile (tests): Add tst-stack1.
12960 * tst-stack1.c: New file.
12961
12962 * allocatestack.c (allocate_stack): Initialize the TCB on a user
12963 provided stack.
12964
12965 * pthread_attr_getstack.c: Return bottom of the thread area.
12966
129672002-11-25 Ulrich Drepper <drepper@redhat.com>
12968
12969 * Makefile (libpthread-routines): Add pt-allocrtsig and
12970 pthread_kill_other_threads.
12971 * pt-allocrtsig.c: New file.
12972 * pthread_kill_other_threads.c: New file.
12973 * sysdeps/unix/sysv/linux/allocrtsig.c: Add additional aliases for
12974 all three functions.
12975 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
12976 allocrtsig.
12977 * sysdeps/unix/sysv/linux/Versions (libc:GLIBC_PRIVATE): Export
12978 __libc_current_sigrtmin_private, __libc_current_sigrtmax_private,
12979 and __libc_allocate_rtsig_private.
12980 * Versions (libpthread): Export pthread_kill_other_threads_np,
12981 __libc_current_sigrtmin, and __libc_current_sigrtmax.
12982
129832002-11-24 Ulrich Drepper <drepper@redhat.com>
12984
12985 * allocatestack.c (allocate_stack): stackaddr in attribute points to
12986 the end of the stack. Adjust computations.
12987 When mprotect call fails dequeue stack and free it.
12988 * pthread_attr_setstack.c: Store top of the stack in stackaddr
12989 attribute.
12990 * pthread_getattr_np.c: Likewise.
12991
12992 * descr.h (IS_DETACHED): Add some more parenthesis to prevent
12993 surprises.
12994
129952002-11-23 Ulrich Drepper <drepper@redhat.com>
12996
12997 * sysdeps/pthread/pthread.h (pthread_self): __THROW must come before
12998 attribute definitions. Patch by Luca Barbieri <ldb@ldb.ods.org>.
12999
130002002-11-22 Ulrich Drepper <drepper@redhat.com>
13001
13002 * pthread_getspecific.c: Optimize access to first 2nd-level array.
13003 * pthread_setspecific.c: Likewise.
13004
130052002-11-21 Ulrich Drepper <drepper@redhat.com>
13006
13007 * sysdeps/unix/sysv/linux/i386/createthread.c: Remove CLONE_ flags
13008 definitions. Get them from the official place.
13009 * sysdeps/unix/sysv/linux/i386/fork.c: Likewise.
13010
13011 * sysdeps/unix/sysv/linux/i386/createthread.c: Update CLONE_* flags.
13012 Use new CLONE_ flags in clone() calls.
13013
13014 * sysdeps/unix/sysv/linux/fork.c: Use ARCH_FORK to actually fork.
13015 * sysdeps/unix/sysv/linux/i386/fork.c: New file.
13016
13017 * Versions: Add pthread_* functions for libc.
13018 * forward.c: New file.
13019
13020 * sysdeps/pthread/Makefile (libpthread-sysdeps_routines): Add
13021 errno-loc.
13022 * herrno.c: New file.
13023 * res.c: New file.
13024
13025 * Makefile (libpthread-routines): Remove sem_post, sem_wait,
13026 sem_trywait, and sem_timedwait. Add herrno and res.
13027 * sem_init.c: Don't initialize lock and waiters members.
13028 * sem_open.c: Likewise.
13029 * sem_post.c: Removed.
13030 * sem_wait.c: Removed.
13031 * sem_trywait.c: Removed.
13032 * sem_timedwait.c: Removed.
13033 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Complete rewrite.
13034 Includes full implementations of sem_post, sem_wait, sem_trywait,
13035 and sem_timedwait.
13036 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Adjust
13037 for new implementation.
13038 * sysdeps/unix/sysv/linux/internaltypes.h (struct sem): Remove lock
13039 and waiters fields.
13040
13041 * tst-sem3.c: Improve error message.
13042 * tst-signal3.c: Likewise.
13043
13044 * init.c (__pthread_initialize_minimal): Use set_tid_address syscall
13045 to tell the kernel about the termination futex and to initialize tid
13046 member. Don't initialize main_thread.
13047 * descr.h (struct pthread): Remove main_thread member.
13048 * cancelllation.c (__do_cancel): Remove code handling main thread.
13049 The main thread is not special anymore.
13050
13051 * allocatestack.c (__reclaim_stacks): Mark stacks as unused. Add
13052 size of the stacks to stack_cache_actsize.
13053
13054 * pt-readv.c: Add missing "defined".
13055 * pt-sigwait.c: Likewise.
13056 * pt-writev.c: Likewise.
13057
130582002-11-09 Ulrich Drepper <drepper@redhat.com>
13059
13060 * Versions: Export __connect from libpthread.
13061 Patch by Luca Barbieri <ldb@ldb.ods.org>.
13062
13063 * Makefile (libpthread-routines): Add pt-raise.
13064 * sysdeps/unix/sysv/linux/raise.c: New file.
13065 * sysdeps/unix/sysv/linux/pt-raise.c: New file.
13066 * sysdeps/generic/pt-raise.c: New file.
13067
13068 * pthread_cond_init.c: Initialize all data elements of the condvar
13069 structure. Patch by Luca Barbieri <ldb@ldb.ods.org>.
13070
13071 * pthread_attr_init.c: Actually implement 2.0 compatibility version.
13072 * pthread_create.c: Likewise.
13073
13074 * Makefile (tests): Add tst-key1, tst-key2, tst-key3.
13075 * tst-key1.c: New file.
13076 * tst-key2.c: New file.
13077 * tst-key3.c: New file.
13078
13079 * Versions: Export pthread_detach for version GLIBC_2.0.
13080 Reported by Saurabh Desai <sdesai@austin.ibm.com>.
13081
130822002-11-08 Ulrich Drepper <drepper@redhat.com>
13083
13084 * pthread_key_create.c: Terminate search after an unused key was found.
13085 Patch by Luca Barbieri <ldb@ldb.ods.org>.
13086
13087 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Return zero.
13088 Patch by Luca Barbieri <ldb@ldb.ods.org>.
13089
130902002-10-10 Ulrich Drepper <drepper@redhat.com>
13091
13092 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Use slow generic
13093 dynamic lookup for errno in PIC.
13094
13095 * allocatestack.c (get_cached_stack): Rearrange code slightly to
13096 release the stack lock as soon as possible.
13097 Call _dl_allocate_tls_init for TCB from the cache to re-initialize
13098 the static TLS block.
13099 (allocate_stack): Call _dl_allocate_tls_init for user-provided stack.
13100
13101 * cancellation.c: Renamed from cancelation.c.
13102 * Makefile: Adjust accordingly.
13103 * pthreadP.h (CANCELLATION_P): Renamed from CANCELATION_P.
13104 * cleanup_defer.c: Use CANCELLATION_P.
13105 * pthread_testcancel.c: Likewise.
13106 * descr.h: Fix spelling in comments.
13107 * init.c: Likewise.
13108 * pthread_getattr_np.c: Likewise.
13109 * pthread_getschedparam.c: Likewise.
13110 * pthread_setschedparam.c: Likewise.
13111 * Versions: Likewise.
13112
13113 * pt-pselect.c: New file.
13114 * Makefile (libpthread-routines): Add pt-pselect.
13115 * Versions: Add pselect.
13116
13117 * tst-cancel4.c: New file.
13118 * Makefile (tests): Add tst-cancel4.
13119
131202002-10-09 Ulrich Drepper <drepper@redhat.com>
13121
13122 * pthread_mutex_lock.c: Always record lock ownership.
13123 * pthread_mutex_timedlock.c: Likewise.
13124 * pthread_mutex_trylock.c: Likewise.
13125
13126 * pt-readv.c: New file.
13127 * pt-writev.c: New file.
13128 * pt-creat.c: New file.
13129 * pt-msgrcv.c: New file.
13130 * pt-msgsnd.c: New file.
13131 * pt-poll.c: New file.
13132 * pt-select.c: New file.
13133 * pt-sigpause.c: New file.
13134 * pt-sigsuspend.c: New file.
13135 * pt-sigwait.c: New file.
13136 * pt-sigwaitinfo.c: New file.
13137 * pt-waitid.c: New file.
13138 * Makefile (libpthread-routines): Add pt-readv, pt-writev, pt-creat,
13139 pt-msgrcv, pt-msgsnd, pt-poll, pt-select, pt-sigpause, pt-sigsuspend,
13140 pt-sigwait, pt-sigwaitinfo, and pt-waitid.
13141 * Versions: Add all the new functions.
13142
13143 * tst-exit1.c: New file.
13144 * Makefile (tests): Add tst-exit1.
13145
13146 * sem_timedwait.c: Minor optimization for more optimal fastpath.
13147
131482002-10-08 Ulrich Drepper <drepper@redhat.com>
13149
13150 * pt-fcntl.c: Only enable asynchronous cancellation for F_SETLKW.
13151
13152 * pthread_join.c: Enable asynchronous cancellation around lll_wait_tid
13153 call. pthread_join is an official cancellation point.
13154 * pthread_timedjoin.c: Likewise.
13155
13156 * pthread_cond_wait.c: Revert order in which internal lock are dropped
13157 and the condvar's mutex are retrieved.
13158 * pthread_cond_timedwait.c: Likewise.
13159 Reported by dice@saros.East.Sun.COM.
13160
131612002-10-07 Ulrich Drepper <drepper@redhat.com>
13162
13163 * pthreadP.h: Cut out all type definitions and move them...
13164 * sysdeps/unix/sysv/linux/internaltypes.h: ...here. New file.
13165 * pthreadP.h: Include <internaltypes.h>.
13166
13167 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Little
13168 performance tweaks.
13169
13170 * sem_trywait.c: Shuffle #includes around to get right order.
13171 * sem_timedwait.c: Likewise.
13172 * sem_post.c: Likewise.
13173 * sem_wait.c: Likewise.
13174
13175 * nptl 0.3 released.
13176
13177 * Makefile (tests): Add tst-signal3.
13178 * tst-signal3.c: New file.
13179
131802002-10-05 Ulrich Drepper <drepper@redhat.com>
13181
13182 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Tell the compiler that
13183 the asms modify the sem object.
13184 (__lll_sem_timedwait): Now takes struct sem* as first parameter.
13185
13186 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h (sem_t): Don't expose
13187 the actual members.
13188 * pthreadP.h (struct sem): New type. Actual semaphore type.
13189 * semaphoreP.h: Include pthreadP.h.
13190 * sem_getvalue.c: Adjust to sem_t change.
13191 * sem_init.c: Likewise.
13192 * sem_open.c: Likewise.
13193 * sem_post.c: Likewise.
13194 * sem_timedwait.c: Likewise.
13195 * sem_trywait.c: Likewise.
13196 * sem_wait.c: Likewise.
13197
131982002-10-04 Ulrich Drepper <drepper@redhat.com>
13199
13200 * Makefile (tests): Add tst-basic2, tst-exec1, tst-exec3, tst-exec3.
13201 * tst-basic2.c: New file.
13202 * tst-exec1.c: New file.
13203 * tst-exec2.c: New file.
13204 * tst-exec3.c: New file.
13205
13206 * tst-fork1.c: Remove extra */.
13207
13208 * nptl 0.2 released. The API for IA-32 is complete.