]> sourceware.org Git - glibc.git/blame - nptl/ChangeLog
Update.
[glibc.git] / nptl / ChangeLog
CommitLineData
e22a221d
UD
12003-03-14 Ulrich Drepper <drepper@redhat.com>
2
9b89567d
UD
3 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Use correct
4 amount of stack correction.
5
e22a221d
UD
6 * tst-fork4.c: Use test-skeleton.c.
7
2e49caba
RM
82003-03-14 Roland McGrath <roland@redhat.com>
9
10 * init.c: Fix typo "#eli" for "#else".
11
415ef7d8
RM
122003-03-14 Steven Munroe <sjmunroe@us.ibm.com>
13
14 * allocatestack.c (__stack_user): Use hidden_data_def.
15 * pthread_create.c (__pthread_keys): Likewise.
16
17 * init.c [__powerpc__] (__NR_set_tid_address): Define it.
18
52287505
RM
192003-03-14 Roland McGrath <roland@redhat.com>
20
415ef7d8
RM
21 * tst-fork4.c: New file.
22 * Makefile (tests): Add it.
23
52287505
RM
24 * descr.h (struct pthread): Move the union out of [!TLS_DTV_AT_TP], so
25 we always define the padding space.
26 [!TLS_DTV_AT_TP]: Give tcbhead_t field a name, `header', since GCC
27 stopped supporting its own extensions fully.
28 [TLS_MULTIPLE_THREADS_IN_TCB]: Put `multiple_threads' inside a wrapper
29 struct also called `header', so `header.multiple_threads' is the field
30 name to use on all machines.
31 * allocatestack.c (allocate_stack): Use `header.' prefix.
32 * sysdeps/pthread/createthread.c (create_thread): Likewise.
33 * pthread_create.c (__pthread_create_2_1): Likewise.
34 * sysdeps/i386/tls.h (INSTALL_NEW_DTV, THREAD_DTV): Likewise.
35 (THREAD_SELF): Likewise.
36 * sysdeps/x86_64/tls.h: Likewise.
37 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
38 (SINGLE_THREAD_P): Likewise.
39 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
40 (SINGLE_THREAD_P): Likewise.
41 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h
42 (SINGLE_THREAD_P): Likewise.
43
44 * sysdeps/s390/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Use REGS[18]
45 value directly.
46
c44bf9aa
UD
472003-03-14 Ulrich Drepper <drepper@redhat.com>
48
e22a221d
UD
49 * pthread_create.c (start_thread): Use CALL_THREAD_FCT if defined.
50 * sysdeps/i386/tls.h: Define CALL_THREAD_FCT.
51
0eb18281
UD
52 * pthread_create.c (start_thread): setjmp is expected to return 0.
53
c44bf9aa
UD
54 * sysdeps/x86_64/tls.h (THREAD_GETMEM): Mark asms volatile.
55 (THREAD_GETMEM_NC): Likewise.
56
564cd8b6
UD
572003-03-13 Ulrich Drepper <drepper@redhat.com>
58
59 * allocatestack.c (allocate_stack): If MULTI_PAGE_ALIASING is defined
60 and the size of the stack which must be allocated is a multiple,
61 allocate one more page.
62 * sysdeps/i386/i686/Makefile: Don't define COLORING_INCREMENT, but
63 MULTI_PAGE_ALIASING.
64
6461e577
RM
652003-03-13 Roland McGrath <roland@redhat.com>
66
67 * pthread_create.c (start_thread): Set EXITING_BIT after the
68 event-reporting (and destructors), not before.
69
b5ec5617
UD
702003-03-13 Jakub Jelinek <jakub@redhat.com>
71
6461e577
RM
72 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h (lll_futex_timed_wait,
73 lll_futex_wake): Declare register variables as long int instead of
74 unsigned long int. Patch by Ian Wienand <ianw@gelato.unsw.edu.au>.
75 Make syscall arguments clobbered by the syscall.
76 (lll_futex_wait): Define using lll_futex_timed_wait.
77
78 * sysdeps/ia64/td_ta_map_lwp2thr.c (td_ta_map_lwp2thr): Cast regs[13]
79 to void *.
80
81 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Only declare and set
82 PPID if [! NDEBUG].
83
84 * allocatestack.c (nptl_ncreated): Only declare if
85 COLORING_INCREMENT != 0.
86
87 * pthreadP.h (__pthread_enable_asynccancel_2): New prototype.
88 (__libc_enable_asynccancel_2): Remove prototype.
89
b5ec5617
UD
90 * sysdeps/unix/sysv/linux/ia64/fork.c (ARCH_FORK): Swap ptid and
91 ctid to match kernel.
92
d0369fb8
UD
932003-03-12 Ulrich Drepper <drepper@redhat.com>
94
7588880f
UD
95 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Add
96 libc_multiple_threads.
97 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Move definition of
98 __libc_multiple_threads to...
99 * sysdeps/unix/sysv/linux/libc_multiple_threads.c: ...here. New file.
100
101 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Remove unnecessary
102 versioning.
103 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
104 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
105
106 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S
107 (__pthread_once_internal): Define.
108
109 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Use shlib-compat.h
110 macros instead of .symver directly.
111 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
112 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Likewise.
113
d0369fb8
UD
114 * sysdeps/x86_64/tls.h [__ASSEMBLER__]: Include tcb-offsets.h.
115 * sysdeps/x86_64/tcb-offsets.sym: New file.
116 * sysdeps/x86_64/Makefile: New file.
117
118 * sysdeps/i386/tcb-offsets.sym: Add SELF.
119 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Use SELF
120 to access own pthread_t in TCB.
121 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
122 Likewise.
123 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
124 Likewise.
125 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
126
0bb2ac85
RM
1272003-03-12 Roland McGrath <roland@redhat.com>
128
129 * pthread-errnos.sym: New file.
130 * Makefile (gen-as-const-headers): New variable, list that file.
131 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: Include generated
132 header <pthread-errnos.h> instead of defining errno values here.
133 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: Likewise.
134 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
135 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
136 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
137 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
138 Likewise.
139 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
140 Likewise.
141 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
142 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
143 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
144 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
145 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
146 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
147 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
148 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
149 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: Likewise.
150 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Likewise.
151 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Likewise.
152 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: Likewise.
153 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: Likewise.
154 * sysdeps/unix/sysv/linux/sh/sem_post.S: Likewise.
155 * sysdeps/unix/sysv/linux/sh/sem_wait.S: Likewise.
156 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: Likewise.
157 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: Likewise.
158 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: Likewise.
159 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: Likewise.
160 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: Likewise.
161 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
162 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Likewise.
163 * sysdeps/i386/i486/pthread_spin_trylock.S: Likewise.
164 * sysdeps/x86_64/pthread_spin_trylock.S: Likewise.
165 * sysdeps/sh/pthread_spin_trylock.S: Likewise.
166 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: Likewise.
167 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: Likewise.
168
169 * sysdeps/unix/sysv/linux/fork.c: Add an assert to check that
170 CLONE_CHILD_SETTID worked.
171
35e148cb
UD
1722003-03-12 Ulrich Drepper <drepper@redhat.com>
173
d0369fb8
UD
174 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedrdlock.S: New
175 file.
176 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_timedwrlock.S: New
177 file.
178
179 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h
180 (pthread_cond_t): Add padding.
181
da49194d
UD
182 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_rdlock.S: New file.
183 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_wrlock.S: New file.
184 * sysdeps/unix/sysv/linux/x86_64/pthread_rwlock_unlock.S: New file.
185
35e148cb
UD
186 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S
187 (__pthread_rwlock_timedwrlock): Add missing opcode suffix.
188 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S
189 (__pthread_rwlock_timedrdlock): Likewise.
190 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S
191 (__pthread_rwlock_wrlock): Likewise.
192 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S
193 (__pthread_rwlock_rdlock): Likewise.
194
195 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_timedwait.S: New file.
196
197 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Return
198 result of lock re-get if it fails.
199
3e976b96
UD
2002003-03-11 Ulrich Drepper <drepper@redhat.com>
201
5a03acfe
UD
202 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: Fix asm syntax.
203 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: Likewise.
204 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: Likewise.
205 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: Likewise.
206 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: Likewise.
207 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
208 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: Likewise.
209 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: Likewise.
210 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: Likewise.
211 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: Likewise.
212
213 * sysdeps/x86_64/tls.h (THREAD_SELF, THREAD_GETMEM, THREAD_GETMEM_NC,
214 THREAD_SETMEM, THREAD_SETMEM_NC): Correct asm syntax.
215
216 * allocatestack.c [! TLS_MULTIPLE_THREADS_IN_TCB] (allocate_stack):
217 Initialize *__libc_multiple_threads_ptr not __libc_multiple_threads.
218 * sysdeps/pthread/createthread.c [! TLS_MULTIPLE_THREADS_IN_TCB]
219 (create_thread): Likewise.
220 Define __pthread_multiple_threads and __libc_multiple_threads_ptr.
221 * init.c (__pthread_initialize_minimal_internal): Initialize
222 __libc_multiple_threads_ptr if necessary.
223 * pthreadP.h: Adjust prototype for __libc_pthread_init. Declare
224 __pthread_multiple_threads and __libc_multiple_threads_ptr.
225 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Define
226 __libc_multiple_threads.
227 (__libc_pthread_init): Return pointer to __libc_pthread_init if
228 necessary.
229
230 * sysdeps/i386/tls.h (THREAD_SETMEM): Fix one-byte variant.
231 (THREAD_SETMEM_NC): Likewise.
232
233 * sysdeps/x86_64/pthread_spin_trylock.c: Removed.
234 * sysdeps/x86_64/pthread_spin_trylock.S: New file.
235 * sysdeps/x86_64/pthread_spin_unlock.c: Removed.
236 * sysdeps/x86_64/pthread_spin_unlock.S: New file.
237
238 * sysdeps/i386/i486/pthread_spin_trylock.S (pthread_spin_trylock):
239 Eliminate one entire instruction.
240
32a589b1
UD
241 * cancellation.c (__pthread_enable_asynccancel_2): New function.
242 * pthreadP.h: Declare __pthread_enable_asynccancel_2.
243 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S
244 (__pthread_cond_timedwait): Use __pthread_enable_asynccancel_2
245 instead of __pthread_enable_asynccancel.
246 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
247 (__pthread_cond_wait): Likewise.
248 * sysdeps/pthread/pthread_cond_timedwait.c
249 (__pthread_cond_timedwait): Likewise.
250 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait): Likewise.
251
3e976b96
UD
252 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S
253 (__condvar_cleanup): Wake up all waiters in case we got signaled
254 after being woken up but before disabling asynchronous
255 cancellation.
256 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Likewise.
257 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S
258 (__condvar_cleanup): Likewise.
259
260 * init.c (__NR_set_tid_address): If already defined, don't redefine.
261 Make it an error if architecture has no #if case. Add x86-64.
262
263 * sysdeps/unix/sysv/linux/x86_64/Makefile: Add flags for
264 pt-initfini.s generation.
265
266 * sysdeps/x86_64/tls.h: Include <asm/prctl.h>.
267 (TLS_INIT_TP): Fix typo.
268
6c477888
UD
2692003-03-11 Jakub Jelinek <jakub@redhat.com>
270
271 * sysdeps/ia64/bits/atomic.h (atomic_exchange_and_add): Swap 2nd and
272 3rd argument of __arch_compare_and_exchange_{32,64}_val_acq.
273
274 * sysdeps/unix/sysv/linux/ia64/sem_post.c: Include semaphore.h.
275 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: Likewise.
276 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: Likewise.
277 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: Likewise.
278 * sysdeps/unix/sysv/linux/s390/sem_post.c: Likewise.
279 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
280 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Likewise.
281 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Likewise.
282
ea694823
UD
2832003-03-11 Ulrich Drepper <drepper@redhat.com>
284
6c477888
UD
285 * sysdeps/pthread/pthread_cond_timedwait.c
286 (__pthread_cond_timedwait): Return the result of the final
287 locking. If it succeeds, the regular function return value.
288
289 * sysdeps/pthread/pthread_cond_wait.c (__pthread_cond_wait):
290 Return result of the final locking.
291 * version.c (__nptl_main): Work around problems with the strange
292 INTERNAL_SYSCALL macro on ppc32.
293 * init.c (__pthread_initialize_minimal_internal): Unblock
294 SIGCANCEL in case the parent blocked it.
295 Reported by Paul Mackerras <paulus@samba.org>.
296
ea694823
UD
297 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_broadcast.S: New file.
298 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_signal.S: New file.
299 * sysdeps/unix/sysv/linux/x86_64/pthread_cond_wait.S: New file.
300
b33e6163
RM
3012003-03-11 Jakub Jelinek <jakub@redhat.com>
302
303 * sysdeps/pthread/pthread_cond_timedwait.c
304 (__pthread_cond_timedwait): Unlock and fail if
305 __pthread_mutex_unlock_internal failed.
306
307 * sysdeps/pthread/createthread.c (ARCH_CLONE): Define if not defined.
308 (create_thread): Only assert PD->tcb != NULL under [TLS_TCB_AT_TP].
309 Use ARCH_CLONE.
310 * allocatestack.c (ALLOCATE_STACK_PARMS): New macro.
311 [NEED_SEPARATE_REGISTER_STACK] (STACK_VARIABLES,
312 STACK_VARIABLES_ARGS, STACK_VARIABLES_PARMS, ALLOCATE_STACK_PARMS,
313 ALLOCATE_STACK): New macros.
314 (TLS_TPADJ): New macro.
315 (get_cached_stack, queue_stack, __deallocate_stack): Use TLS_TPADJ.
316 (allocate_stack): Handle TLS_DTV_AT_TP and
317 NEED_SEPARATE_REGISTER_STACK. Use TLS_TPADJ.
318 * pthread_create.c (__pthread_create_2_1) [! TLS_TCB_AT_TP]:
319 Don't set PD->self.
320 * init.c [__ia64__] (__NR_set_tid_address): Define.
321
322 * sysdeps/unix/sysv/linux/ia64/bits/pthreadtypes.h: New file.
323 * sysdeps/unix/sysv/linux/ia64/bits/semaphore.h: New file.
324 * sysdeps/unix/sysv/linux/ia64/fork.c: New file.
325 * sysdeps/unix/sysv/linux/ia64/createthread.c: New file.
326 * sysdeps/unix/sysv/linux/ia64/libc-lowlevellock.c: New file.
327 * sysdeps/unix/sysv/linux/ia64/libc-lowlevelmutex.c: New file.
328 * sysdeps/unix/sysv/linux/ia64/lowlevellock.c: New file.
329 * sysdeps/unix/sysv/linux/ia64/lowlevellock.h: New file.
330 * sysdeps/unix/sysv/linux/ia64/lowlevelmutex.c: New file.
331 * sysdeps/unix/sysv/linux/ia64/pt-initfini.c: New file.
332 * sysdeps/unix/sysv/linux/ia64/pt-vfork.S: New file.
333 * sysdeps/unix/sysv/linux/ia64/pthread_once.c: New file.
334 * sysdeps/unix/sysv/linux/ia64/sem_post.c: New file.
335 * sysdeps/unix/sysv/linux/ia64/sem_timedwait.c: New file.
336 * sysdeps/unix/sysv/linux/ia64/sem_trywait.c: New file.
337 * sysdeps/unix/sysv/linux/ia64/sem_wait.c: New file.
338 * sysdeps/unix/sysv/linux/ia64/sysdep-cancel.h: New file.
339 * sysdeps/ia64/bits/atomic.h: New file.
340 * sysdeps/ia64/Makefile: New file.
341 * sysdeps/ia64/pthread_spin_init.c: New file.
342 * sysdeps/ia64/pthread_spin_lock.c: New file.
343 * sysdeps/ia64/pthread_spin_trylock.c: New file.
344 * sysdeps/ia64/pthread_spin_unlock.c: New file.
345 * sysdeps/ia64/pthreaddef.h: New file.
346 * sysdeps/ia64/tcb-offsets.sym: New file.
347 * sysdeps/ia64/td_ta_map_lwp2thr.c: New file.
348 * sysdeps/ia64/tls.h: New file.
349
350 * sysdeps/s390/pthreaddef.h (__exit_thread_inline): Pass 1 argument
351 to syscall instead of no arguments.
352
2b30b2e5
UD
3532003-03-10 Ulrich Drepper <drepper@redhat.com>
354
db5f2fc9
UD
355 * sysdeps/unix/sysv/linux/x86_64/sem_post.S: New file.
356 * sysdeps/unix/sysv/linux/x86_64/sem_trywait.S: New file.
357 * sysdeps/unix/sysv/linux/x86_64/sem_wait.S: New file.
358 * sysdeps/unix/sysv/linux/x86_64/sem_timedwait.S: New file.
359
360 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Fix error value in
361 unused code.
362
6a4263e3
UD
363 * sysdeps/unix/sysv/linux/x86_64/pthread_barrier_wait.S: New file
364
3de7c2a9
UD
365 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
366 lowlevelbarrier.sym.
367 * sysdeps/unix/sysv/linux/lowlevelbarrier.sym: New file.
368 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S:
369 Include lowlevelbarrier.h and don't define offsets locally.
6a4263e3 370 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: Likewise.
3de7c2a9 371
2a544d82
UD
372 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h
373 (__lll_mutex_lock_wait): Reverse order of first two parameters.
374 (__lll_mutex_timedlock_wait): Likewise.
375 (lll_mutex_lock): Adjust asm for that.
376 (lll_mutex_timedlock): Likewise. Mark cx, cc, r10 as clobbered.
377 (lll_lock): Adjust asm for operand order change.
378 * sysdeps/unix/sysv/linux/x86_64/lowlevelmutex.S: New file.
379 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevelmutex.S: New file.
380
ec06436c
UD
381 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (__lll_lock_wait):
382 Reverse order of parameters.
383 (__lll_timedwait_tid): Remove regparms attribute.
384 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.S: New file.
385 * sysdeps/unix/sysv/linux/x86_64/libc-lowlevellock.S: New file.
386
3273832c
UD
387 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
388 (__lll_timedwait_tid): Remove one unnecessary instruction.
389
51f32ab8
UD
390 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: Define
391 __lll_mutex_timedlock_wait only for NOT_IN_libc.
392 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: Include
393 lowlevelmutex.S.
394
395 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Define
396 lll_unlock_wake_cb, __lll_wait_tid, and __lll_timedwait_tid only
397 for NOT_IN_libc.
398 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Include
399 lowlevellock.S.
400
fad48d9e
UD
401 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Don't define
402 LOCK is already defined. Don't define __lll_mutex_timedlock_wait
403 for libc.so.
404 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Only
405 define LOCK here (if UP is not defined). The actual code is in
406 lowlevelmutex.S.
407
9356d063
UD
408 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Don't define
409 LOCK is already defined. Don't define lll_unlock_wake_cb and
410 __lll_timedwait_tid for libc.so.
411 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Only
412 define LOCK here (if UP is not defined). The actual code is in
413 lowlevellock.S.
414
ebf0cbc5 415 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Not needed anymore.
106f6f9d
UD
416 * sysdeps/unix/sysv/linux/s390/lowlevelsem.h: Likewise.
417 * sysdeps/unix/sysv/linux/s390/sem_post.c: Include lowlevellock.h
418 instead of lowlevelsem.h.
419 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: Likewise.
420 * sysdeps/unix/sysv/linux/s390/sem_trywait.c: Likewise.
421 * sysdeps/unix/sysv/linux/s390/sem_wait.c: Likewise.
0be8ee21 422
c915e5ad
UD
423 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add
424 lowlevelrwlock.sym.
425 * sysdeps/unix/sysv/linux/lowlevelrwlock.sym: New file.
426 * sysdeps/unix/sysv/linux/i386/lowlevelrwlock.h: Removed.
146fa1ee 427 * sysdeps/unix/sysv/linux/sh/lowlevelrwlock.h: Removed.
c915e5ad 428
4c3c2e8a
UD
429 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h (lll_trylock): Fix
430 register loading.
431 * sysdeps/unix/sysv/linux/i386/lowlevellock.h (lll_trylock): Undo
432 last changed. D'oh.
433
2b30b2e5
UD
434 * sysdeps/unix/sysv/linux/x86_64/lowlevellock.h: New file.
435
436 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove declaration
437 of __libc_locking_needed.
438 (lll_trylock): Initialize %eax to zero.
439
2b30b2e5
UD
440 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Update
441 pthread_cond_t definition.
442
e48f9638
RM
4432003-03-10 Roland McGrath <roland@redhat.com>
444
445 * sysdeps/unix/sysv/linux/lowlevelcond.sym: New file.
446 * sysdeps/unix/sysv/linux/Makefile (gen-as-const-headers): Add it.
447 * sysdeps/unix/sysv/linux/sh/lowlevelcond.h: File removed.
448 * sysdeps/unix/sysv/linux/i386/lowlevelcond.h: Likewise.
449 * sysdeps/unix/sysv/linux/x86_64/lowlevelcond.h: Likewise.
450
451 * allocatestack.c (allocate_stack) [!TLS_MULTIPLE_THREADS_IN_TCB]:
452 Instead of setting PD->multiple_threads, set globals
453 __pthread_multiple_threads and __libc_multiple_threads.
454 * sysdeps/pthread/createthread.c (create_thread): Likewise.
455 * sysdeps/i386/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Define it.
456 * sysdeps/s390/tls.h (TLS_MULTIPLE_THREADS_IN_TCB): Likewise.
457
458 * descr.h (struct pthread): Conditionalize first member on
459 [!TLS_DTV_AT_TP]. Replace the `header' member with an anonymous union
460 containing an anonymous tcbhead_t. Move `list' member out.
461 [TLS_MULTIPLE_THREADS_IN_TCB]: Define a `multiple_threads' member.
462 * allocatestack.c: Remove use of `header.data.' prefix.
463 * pthread_create.c: Likewise.
464 * init.c (__pthread_initialize_minimal_internal): Likewise.
465 * sysdeps/pthread/createthread.c (create_thread): Likewise.
466 * sysdeps/i386/tls.h (INSTALL_DTV): Add parens.
467 (THREAD_SELF, THREAD_DTV, INSTALL_NEW_DTV): No `header.data.' prefix.
468 * sysdeps/x86_64/tls.h: Likewise.
469 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h
470 (SINGLE_THREAD_P): Likewise.
471 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h
472 (SINGLE_THREAD_P): Likewise.
473 * sysdeps/i386/tls.h (tcbhead_t): Remove `list' member.
474 * sysdeps/s390/tls.h (tcbhead_t): Likewise.
475
c37cae9e
UD
4762003-03-09 Ulrich Drepper <drepper@redhat.com>
477
d38c777e
RM
478 * sysdeps/unix/sysv/linux/x86_64/lowlevelcond.h: New file.
479
7b44a5e0 480 * sysdeps/unix/sysv/linux/x86_64/sysdep-cancel.h: New file.
2b30b2e5 481 * sysdeps/unix/sysv/linux/x86_64/fork.c: New file.
7b44a5e0 482
c2e5e085
UD
483 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Fix many
484 leftovers from the ia32 code.
485
486 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Remove unneccessary
487 memory load.
488 (clear_once_control): Don't load %esi.
489
490 * sysdeps/x86_64/tls.h: Remove all traces of segment descriptor
491 handling.
492
493 * sysdeps/unix/sysv/linux/x86_64/fork.c: New file.
494
cd4b2a55
UD
495 * sysdeps/unix/sysv/linux/s390/createthread.c: Moved to...
496 * sysdeps/unix/sysv/linux/createthread.c: ...here.
497
c37cae9e
UD
498 * Makefile (tests): Add tst-cond10.
499 * tst-cond10.c: New file.
500
d130a341
UD
5012003-03-08 Ulrich Drepper <drepper@redhat.com>
502
ccf1d573
UD
503 * tst-tls2.c (do_test): Add TEMP_FAILURE_RETRY around sem_wait call.
504 * tst-signal3.c (do_test): Likewise.
505 * tst-sem5.c (do_test): Likewise.
506 * tst-kill6.c (do_test): Likewise.
507 * tst-tls3.c (do_test): Likewise. Include <errno.h>.
508
509 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use add/sub instead
510 of inc/dec.
511 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Likewise.
512 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise
513 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: Likewise.
514 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: Likewise.
515 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
516 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
517 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
518 Likewise.
519 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
520 Likewise.
521 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Likewise.
522 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Likewise.
523 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
524 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
525 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
526 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
527 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
528 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
529
d130a341
UD
530 * allocatestack.c (allocate_stack): If mprotect() fails free the
531 TLS memory.
532
bc6389ad
UD
5332003-03-07 Ulrich Drepper <drepper@redhat.com>
534
41d4d223
UD
535 * sysdeps/i386/i486/bits/atomic.h: Fix a few unused definitions.
536
537 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Remove all trace of
538 lll_wake_tid. This was used only to work around kernel limits in
539 the early days.
540 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: Likewise.
541 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: Likewise.
542 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: Likewise.
543 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: Likewise.
544
bc6389ad
UD
545 * init.c (__static_tls_align_m1): Renamed from __static_tls_align.
546 (__pthread_initialize_minimal_internal): Change initialization of
547 __static_tls_align_m1 appropriately.
548 * pthreadP.h (__static_tls_align_m1): Renamed from
549 __static_tls_align.
550 * allocatestack.c (allocate_stack): Use __static_tls_align_m1
551 instead of __static_tls_align-1.
552
cc775edf
UD
5532003-03-04 Ulrich Drepper <drepper@redhat.com>
554
0de28d5c 555 * sysdeps/unix/sysv/linux/x86_64/Makefile: New file.
6245b6ae 556
518b5308
UD
557 * pthread_create.c: Define __pthread_keys using nocommon
558 attribute, not by placing it explicitly in bss.
559 Remove DEFINE_DEALLOC definition. Not needed anymore.
560
561 * allocatestack.c: Define ARCH_MAP_FLAGS if not already defined.
562 Use it in mmap call to allocate stacks.
563
564 * sysdeps/pthread/createthread.c (create_thread): Fix comment.
565
cc775edf
UD
566 * pthread_create.c (start_thread): Use THREAD_SETMEM to store
567 result of the thread function.
568
4f6f0a8f
UD
5692003-03-03 Ulrich Drepper <drepper@redhat.com>
570
f04a2721
UD
571 * sysdeps/unix/sysv/linux/s390/dl-sysdep.h: Removed. The generic
572 version is just fine.
573
4f6f0a8f
UD
574 * sysdeps/unix/sysv/linux/libc_pthread_init.c
575 (__pthread_child_handler): Renamed from pthread_child_handler,
576 exported, and marked hidden. Change all users.
577 * sysdeps/unix/sysv/linux/register-atfork.c (free_mem): Do not
578 free __pthread_child_handler from child list.
579
7ce5c164
UD
5802003-03-03 Martin Schwidefsky <schwidefsky@de.ibm.com>
581
582 * atomic.h (atomic_exchange_and_add): Return newval, not oldval.
583
584 * sysdeps/pthread/pthread_cond_timedwait.c (__pthread_cond_timedwait):
585 Fix handling of cancellation and failing pthread_mutex_unlock call.
586 * sysdeps/pthread/pthread_cond_wait.c (__condvar_cleanup): Likewise.
587 (__pthread_cond_wait): Likewise.
588
589 * sysdeps/pthread/pthread_rwlock_timedrdlock.c
590 (pthread_rwlock_timedrdlock): Fix clobber of result variable by
591 lll_futex_timed_wait call.
592 * sysdeps/pthread/pthread_rwlock_timedwrlock.c
593 (pthread_rwlock_timedwrlock): Likewise.
594
595 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c (___lll_lock):
596 Don't define lll_unlock_wake_cb and ___lll_timedwait_tid in libc.so.
597 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Remove XXX comments.
598
599 * sysdeps/unix/sysv/linux/s390/sem_post.c (__new_sem_post): Fix
600 check of lll_futex_wake return value.
601
ea6a015b
RM
6022003-03-03 Roland McGrath <roland@redhat.com>
603
604 * forward.c: Fix typo in __pthread_attr_init_2_0 compat_symbol decl.
605
606 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
607 Argument to ptr___pthread_cleanup_upto is __jmp_buf, not jmp_buf.
608 * sysdeps/unix/sysv/linux/jmp-unwind.c: Likewise.
609
4adacf57
UD
6102003-03-02 Ulrich Drepper <drepper@redhat.com>
611
1be3d664
UD
612 * sysdeps/pthread/timer_create.c (timer_create): Return correct
613 error for CPU clocks.
614
885bafa1
UD
615 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define
616 _POSIX_MONOTONIC_CLOCK.
617 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Likewise.
618
4adacf57
UD
619 * tst-cancel4.c (tf_sleep): Lower sleep time a bit to not upset
620 recent kernels.
621
86bfff4d
UD
6222003-03-01 Ulrich Drepper <drepper@redhat.com>
623
624 * descr.h (struct pthread): Move cleanup field to the front.
625
d1149385
RM
6262003-03-01 Roland McGrath <roland@redhat.com>
627
628 * sem_open.c (sem_open): Braino fix.
629
bd8bb78b
UD
6302003-03-01 Ulrich Drepper <drepper@redhat.com>
631
748bec08
UD
632 * sysdeps/i386/tcb-offsets.sym: Add CLEANUP and CLEANUP_PREV.
633 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Inline
634 __pthread_cleanup_pop functionality.
635 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
636
bd8bb78b
UD
637 * descr.h (struct pthread): Move tid field to the front now that
638 it is often used.
639
640 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S
641 (__lll_mutex_timedlock_wait): Remove.
642 (__lll_mutex_unlock_wake): Don't save, load, and restore %esi.
643 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S
644 (__lll_mutex_unlock_wake): Don't save, load, and restore %esi.
645 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
646 (lll_unlock_wake_cb): Don't save and restore %esi.
647 (__lll_unlock_wake): Add alignment. Don't save, load, and restore
648 %esi.
649 (__lll_timedwait_tid): Add alignment.
650 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S
651 (__lll_unlock_wake): Add alignment. Don't save, load, and restore
652 %esi.
653 (__lll_timedwait_tid): Removed.
654 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S
655 (__pthread_cond_broadcast): Don't save, load, and restore %esi.
656 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S
657 (pthread_barrier_wait): Don't save, load, and restore %esi for
658 last thread.
659 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S
660 (__pthread_cond_signal): Don't save, load, and restore %esi.
661 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S
662 (__pthread_rwlock_unlock): Don't save, load, and restore %esi.
663 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S (__new_sem_post):
664 Don't save, load, and restore %esi.
665
d2637c70
UD
6662003-02-27 Ulrich Drepper <drepper@redhat.com>
667
567fb22a
UD
668 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S:
669 Release lock before waking up the waiters.
670
427f5fa1
UD
671 * tst-exit1.c (do_test): Don't start more than one thread in parallel.
672
a2d83cfb
UD
673 * tst-rwlock9.c (writer_thread): Correct adding TIMEOUT.
674 (reader_thread): Likewise.
675
d2637c70
UD
676 * sysdeps/pthread/pthread_rwlock_unlock.c
677 (__pthread_rwlock_unlock): Release internal lock early. Don't try
678 to wake up readers if there are none.
679
680 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S:
681 Release internal lock before wake threads.
682
b1531183
UD
6832003-02-26 Ulrich Drepper <drepper@redhat.com>
684
dbf6131c
UD
685 * Makefile (tests): Add tst-rwlock10 and tst-rwlock11.
686 * tst-rwlock8.c: Initialize lock with INIT. Allow INIT to be
687 predefined.
688 * tst-rwlock9.c: Likewise.
689 * tst-rwlock10.c: New file.
690 * tst-rwlock11.c: New file.
691
695799fe
UD
692 * Makefile (tests): Add tst-dlsym1.
693 * tst-dlsym1.c: New file.
694
b1531183
UD
695 * init.c (__pthread_initialize_minimal_internal): Set
696 GL(dl_error_catch_tsd) to __libc_dl_error_tsd.
697 * Versions (libc:GLIBC_PRIVATE): Export __libc_dl_error_tsd.
698
3724f268
UD
6992003-02-24 Ulrich Drepper <drepper@redhat.com>
700
3857ca78
UD
701 * sem_open.c (sem_open): Fix handling of O_CREAT without O_EXCL.
702
80d80779
UD
703 * tst-cond2.c: Fix sychronization with child.
704
86371308
UD
705 * tst-rwlock8.c (reader_thread): Remove unused variable.
706
ffeb4481
UD
707 * Makefile: Add rules to build and run tst-tls3.
708 * tst-tls3.c: New file.
709 * tst-tls3mod.c: New file.
710
3724f268
UD
711 * Makefile (tests): Add tst-rwlock8 and tst-rwlock9.
712 * tst-rwlock8.c: New file.
713 * tst-rwlock9.c: New file.
714 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: Fix
715 complete broken rwlock implementation.
716 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
717 Likewise.
718 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
719 Likewise.
720 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: Likewise.
721 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: Likewise.
18a53579
UD
722 * sysdeps/pthread/pthread_rwlock_rdlock.c: Likewise.
723 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: Likewise.
724 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: Likewise.
725 * sysdeps/pthread/pthread_rwlock_unlock.c: Likewise.
726 * sysdeps/pthread/pthread_rwlock_wrlock.c: Likewise.
3724f268 727
8915cc40
RM
7282003-02-23 Roland McGrath <roland@redhat.com>
729
730 * Makefile (nptl-version): Change regexp so case sensitivity is ok.
731
fd1a0d0c
UD
7322003-02-23 Ulrich Drepper <drepper@redhat.com>
733
ecf28959
UD
734 * Makefile (tests): Add tst-context1.
735 * tst-context1.c: New file.
736
5e47b76b
UD
737 * Makefile (tests): Add tst-tls1 and tst-tls2.
738 * tst-tls1.c: New file.
739 * tst-tls2.c: New file.
740
5a6bbb41
UD
741 * libc-cancellation.c (__libc_enable_asynccancel): Correct test
742 for failed cmpxchg.
743
fd1a0d0c
UD
744 * pthread_create.c (start_thread): Set EXITING_BIT early.
745
746 * sysdeps/i386/tls.h (THREAD_GETMEM): Mark asm as volatile.
747 (THREAD_GETMEM_NC): Likewise.
748
757f9fcb
UD
7492003-02-22 Ulrich Drepper <drepper@redhat.com>
750
b1b8e747
UD
751 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Shave
752 off 3 more bytes by using offset-less instructions when possible.
753
c780aa21 754 * Makefile: Add dependency for $(objpfx)version.d.
757f9fcb
UD
755
756 * eintr.c (eintr_source): Add unnecessary return but the compiler
757 insists.
758
759 * tst-kill3.c: Include <unistd.h>.
760
5148559c
RM
7612003-02-21 Roland McGrath <roland@redhat.com>
762
763 * pthread_create.c (start_thread): Call __libc_thread_freeres.
764
ab2d98e3
UD
7652003-02-21 Ulrich Drepper <drepper@redhat.com>
766
71028edd
UD
767 * Makefile (tests): Add tst-eintr1.
768 (distribute): Add eintr.c.
769 * tst-eintr1.c: New file.
770 * eintr.c: New file.
771
e814f748
UD
772 * pthread_cancel.c (pthread_cancel): Use tkill directly.
773
774 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill):
775 Disallow sending SIGCANCEL.
776
ab2d98e3 777 * Makefile (tests): Remove tst-basic7. Add tst-kill1, tst-kill2,
9c03686d 778 tst-kill3, tst-kill4, tst-kill5, tst-kill6.
e814f748
UD
779 * tst-kill1.c: New file.
780 * tst-kill2.c: New file.
781 * tst-kill3.c: New file.
782 * tst-kill5.c: New file.
9c03686d 783 * tst-kill6.c: New file.
e814f748
UD
784 * tst-basic7.c: Renamed to...
785 * tst-kill4.c: ...this.
ab2d98e3 786
59fed0e2
RM
7872003-02-21 Roland McGrath <roland@redhat.com>
788
789 * Makefile (install-lib-ldscripts): New variable.
790
49dc759f
UD
7912003-02-21 Ulrich Drepper <drepper@redhat.com>
792
8c2e9a29
UD
793 * pthreadP.h: Define INVALID_TD_P and INVALID_NOT_TERMINATED_TD_P.
794 * pthread_cancel.c: Use INVALID_TD_P.
795 * pthread_detach.c: Likewise.
796 * pthread_getschedparam.c: Likewise.
797 * pthread_setschedparam.c: Likewise.
798 * sysdeps/pthread/pthread_getcpuclockid.c: Likewise.
799 * sysdeps/unix/sysv/linux/pthread_kill.c: Likewise.
800 * pthread_join.c: Use INVALID_NOT_TERMINATED_TD_P.
801 * pthread_timedjoin.c: Likewise.
802
803 * tst-basic7.c: Include <signal.h>.
804
49dc759f
UD
805 * pthread_join.c (pthread_join): Limited checking for invalid
806 descriptors.
807 * pthread_timedjoin.c (pthread_timedjoin_np): Likewise.
808
df5803bf
UD
8092003-02-20 Ulrich Drepper <drepper@redhat.com>
810
c5acd3d7
UD
811 * pthread_create.c (deallocate_tsd): Reset found_nonzero at the
812 beginning of the loop. Clear the entire first block of TSD.
df5803bf
UD
813 * Makefile (tests): Add tst-key4.
814 * tst-key4.c: New file.
815
729924a0
UD
8162003-02-18 Ulrich Drepper <drepper@redhat.com>
817
2f7dc594
UD
818 * Makefile (tests): Add tst-basic7.
819 * tst-basic7.c: New file.
820
ba25bb0f
UD
821 * pthread_create.c (deallocate_tsd): Mark as internal_function.
822 Add some more __builtin_expect.
823
12fd3c5f 824 * pthreadP.h: Define dummy version of DEBUGGING_P.
729924a0 825
5430d926
UD
8262003-02-17 Ulrich Drepper <drepper@redhat.com>
827
b0db7fbe
UD
828 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remnove
829 _POSIX_THREAD_PRIORITY_SCHEDULING.
830 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: Remove
831 _XOPEN_REALTIME_THREADS.
832 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Likewise.
833
834 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): The
835 kernel returns EINVAL for PID <= 0, work around it.
836
ecfda9bd
UD
837 * Makefile (tests): Add tst-signal5.
838 * tst-signal5.c: New file.
839
7d78ab99
UD
840 * sysdeps/unix/sysv/linux/bits/local_lim.h: Define TTY_NAME_MAX
841 and LOGIN_NAME_MAX.
842
371a2972
UD
843 * tst-cancel1.c (tf): Block all signals.
844
5430d926
UD
845 * Makefile (tests): Add tst-basic6.
846 * tst-basic6.c: New file.
847
848 * tst-basic1.c: Add test for process ID.
849
850 * Makefile (tests): Add tst-cancel10.
851 * tst-cancel10.c: New file.
852
853 * Makefile (tests): Add tst-signal4.
854 * tst-signal4.c: New file.
855
856 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Use
857 __sigismember instead of sigismember. Add __builtin_expect.
858
1564916a
UD
8592003-02-16 Ulrich Drepper <drepper@redhat.com>
860
179ff175
UD
861 * tst-attr1.c (do_test): Add tests for pthread_setcanceltype,
862 pthread_setcancelstate, and pthread_rwlock_setpshared.
863
e4335f9a
UD
864 * tst-cancel7.c (do_test): Make sure the pid file exists before
865 canceling the thread.
866
0a37669a
UD
867 * tst-rwlock6.c: More pthread_rwlock_timedwrlock and
868 pthread_rwlock_timedrdlock tests.
869 * tst-rwlock7.c: More pthread_rwlock_timedwrlock tests.
870 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
871 Check for invalid tv_nsec field.
872 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
873 Likewise.
874
875 * pthread_mutex_trylock.c (__pthread_mutex_trylock): Protect
876 recursive mutex of overflow.
877
878 * tst-attr1.c (do_test): Add test for pthread_mutexattr_setpshared.
879
e4335f9a 880 * libc-cancellation.c (__libc_enable_asynccancel): Rewrite to avoid
1564916a
UD
881 going into an endless loop.
882 * Makefile (tests): Add tst-cancel9.
883 * tst-cancel9.c: New file.
884
885 * pthread_cancel.c (pthread_cancel): Use the result of __pthread_kill.
886
b270b548
UD
8872003-02-15 Ulrich Drepper <drepper@redhat.com>
888
1c82b97f
UD
889 * tst-mutex5.c (do_test): Add more timedlock tests.
890
b2f05465 891 * tst-mutex2.c: Tests of trylock and unlock with ERROR mutexes.
c3bb9ee1
UD
892 * tst-mutex3.c (do_test): Add tests for trylock with RECURSIVE mutexes.
893
e798b60f
UD
894 * sysdeps/unix/sysv/linux/pthread_kill.c (__pthread_kill): Don't
895 use INLINE_SYSCALL. Error number is returned, not -1.
896
90491dc4
UD
897 * pthreadP.h: Mark declarations of __find_in_stack_list, __free_tcb,
898 and __deallocate_stack with internal_function.
899 * pthread_create.c: Adjust definitions appropriately.
900 * allocatestack.c: Likewise.
901
902 * pthread_join.c: Add one more __builtin_expect.
903 * pthread_timedjoin.c: Likewise.
904
905 * pthread_getspecific.c (__pthread_getspecific): Clear data->data
906 not data of sequence number does not match.
907 Add one __builtin_expect.
908
c6247c9d
UD
909 * Makefile (tests): Add tst-clock1.
910 * tst-clock1.c: New file.
911
b270b548
UD
912 * pthread_setconcurrency.c (pthread_setconcurrency): Fail for
913 negative arguments.
914 * Makefile (tests): Add tst-basic5.
915 * tst-basic5.c: New file.
916
700bf7af
UD
9172003-02-14 Ulrich Drepper <drepper@redhat.com>
918
757de559
UD
919 * Makefile (tests): Add tst-basic4.
920 * tst-basic4.c: New file.
921
47202270
UD
922 * pthreadP.h: Add declaraction for __nptl_nthreads.
923 * pthread_create.c: Define __nptl_nthreads
924 (start_thread): Increment __nptl_nthreads at beginning. Decrement
b270b548 925 after thread is done. If then zero, call exit(0).
47202270
UD
926 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
927 Add ptr_nthreads. Define HAVE_PTR_NTHREADS.
928 * init.c (pthread_functions): Initialize ptr_nthreads.
929 * allocatestack.c (nptl_nthreads): Remove definition and all uses.
930 (__reclaim_stacks): Decrement __nptl_nthreads.
931 * sysdeps/pthread/Makefile [$(subdir)==csu] (CFLAGS-libc-start.c):
932 Define.
933 * Makefile (tests): Add tst-basic3.
934 * tst-basic3.c: New file.
935
e320ef46
UD
936 * descr.h: Define CANCELING_BIT and CANCELING_BITMASK. Introduce
937 after CANCELTYPE_BIT, move the other bits up. Update CANCEL_RESTMASK.
938 * init.c (sigcancel_handler): Also set CANCELING_BITMASK bit in newval.
939 * pthread_cancel.c (pthread_cancel): Likewise. Also set CANCELING_BIT
940 if asynchronous canceling is enabled.
941 * pthread_join.c (pthread_join): When recognizing circular joins,
942 take into account the other thread might be already canceled.
943 * Makefile (tests): Add tst-join5.
944 * tst-join5.c: New file.
945
700bf7af
UD
946 * Makefile (tests): Add tst-join4.
947 * tst-join4.c: New file.
948
9492003-02-13 Ulrich Drepper <drepper@redhat.com>
950
951 * tst-cond4.c (main): Add test of pthread_attr_getpshared.
952
dac0f772
UD
9532003-02-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
954
955 * sysdeps/s390/tls.h (THREAD_GETMEM, THREAD_GETMEM_NC, THREAD_SETMEM,
956 THREAD_SETMEM_NC): Use passed descr instead of THREAD_SELF.
957 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c (_longjmp_unwind): Avoid
958 warning.
959 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: Include <sys/time.h>
960 to avoid warning.
961 * sysdeps/unix/sysv/linux/s390/sem_post.c (__new_sem_post): Return
962 error if lll_futex_wake failed.
963
e8cda341
UD
9642003-02-13 Ulrich Drepper <drepper@redhat.com>
965
a7720b5e
UD
966 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Fix
967 handling of cancellation and failung pthread_mutex_unlock call.
968 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
969 * Makefile (tests): Add tst-cond8 and tst-cond9.
970 * tst-cond8.c: New file.
971 * tst-cond9.c: New file.
972
a1ea4c06
UD
973 * tst-cond7.c (do_test): Unlock the mutex before canceling the thread.
974
975 * sysdeps/pthread/pthread.h: Add missing initializers. Protect
976 non-standard initializers with __USE_GNU.
977
e8cda341
UD
978 * Makefile (tests): Add tst-cleanup3.
979 * tst-cleanup3.c: New file.
980
2067577c
UD
9812003-02-12 Ulrich Drepper <drepper@redhat.com>
982
89e78a95
UD
983 * Makefile (tests): Add tst-attr1 and tst-attr2.
984 * tst-attr1.c: New file.
985 * tst-attr2.c: New file.
986
dfdd294a
UD
987 * Makefile: Add rules to build and run tst-atfork2 test.
988 * tst-atfork2.c: New file.
989 * tst-atfork2mod.c: New file.
990
991 * sysdeps/unix/sysv/linux/unregister-atfork.c
992 (__unregister_atfork): Free the memory allocated for the handlers
993 after removing them from the lists.
994
995 * sysdeps/unix/sysv/linux/register-atfork.c: Define memeory
996 cleanup function.
997
998 * tst-atfork1.c (do_test): Wait for the child we forked.
999 Report error in child.
1000
1001 * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Fix comment.
1002
2067577c
UD
1003 * sysdeps/pthread/Makefile: Define CFLAGS-confstr.c.
1004
2a8a8a84
UD
10052003-02-10 Ulrich Drepper <drepper@redhat.com>
1006
d9dd121e
UD
1007 * Makefile (tests): Add tst-cancel8.
1008 * tst-cancel8.c: New file.
1009
2a8a8a84
UD
1010 * sysdeps/unix/sysv/linux/i386/pthread_once.S (clear_once_control): Fix
1011 clearing of control variable.
defd1870 1012 * Makefile (tests): Add tst-once3 and tst-once4.
2a8a8a84 1013 * tst-once3.c: New file.
defd1870 1014 * tst-once4.c: New file.
2a8a8a84 1015
a54e8d33
UD
10162003-02-08 kaz Kojima <kkojima@rr.iij4u.or.jp>
1017
1018 * sysdeps/sh/Makefile: New file.
1019 * sysdeps/sh/bits/atomic.h: New file.
1020 * sysdeps/sh/pthread_spin_init.c: New file.
1021 * sysdeps/sh/pthread_spin_lock.c: New file.
1022 * sysdeps/sh/pthread_spin_trylock.S: New file.
1023 * sysdeps/sh/pthread_spin_unlock.S: New file.
1024 * sysdeps/sh/pthreaddef.h: New file.
1025 * sysdeps/sh/tcb-offsets.sym: New file.
1026 * sysdeps/sh/td_ta_map_lwp2thr.c: New file.
1027 * sysdeps/sh/tls.h: New file.
1028 * sysdeps/unix/sysv/linux/sh/bits/pthreadtypes.h: New file.
1029 * sysdeps/unix/sysv/linux/sh/bits/semaphore.h: New file.
1030 * sysdeps/unix/sysv/linux/sh/createthread.c: New file.
1031 * sysdeps/unix/sysv/linux/sh/fork.c: New file.
1032 * sysdeps/unix/sysv/linux/sh/libc-lowlevellock.S: New file.
1033 * sysdeps/unix/sysv/linux/sh/libc-lowlevelmutex.S: New file.
1034 * sysdeps/unix/sysv/linux/sh/lowlevel-atomic.h: New file.
1035 * sysdeps/unix/sysv/linux/sh/lowlevelcond.h: New file.
1036 * sysdeps/unix/sysv/linux/sh/lowlevellock.S: New file.
1037 * sysdeps/unix/sysv/linux/sh/lowlevellock.h: New file.
1038 * sysdeps/unix/sysv/linux/sh/lowlevelmutex.S: New file.
1039 * sysdeps/unix/sysv/linux/sh/lowlevelrwlock.h: New file.
1040 * sysdeps/unix/sysv/linux/sh/pt-initfini.c: New file.
1041 * sysdeps/unix/sysv/linux/sh/pt-vfork.S: New file.
1042 * sysdeps/unix/sysv/linux/sh/pthread_barrier_wait.S: New file.
1043 * sysdeps/unix/sysv/linux/sh/pthread_cond_broadcast.S: New file.
1044 * sysdeps/unix/sysv/linux/sh/pthread_cond_signal.S: New file.
1045 * sysdeps/unix/sysv/linux/sh/pthread_cond_timedwait.S: New file.
1046 * sysdeps/unix/sysv/linux/sh/pthread_cond_wait.S: New file.
1047 * sysdeps/unix/sysv/linux/sh/pthread_once.S: New file.
1048 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_rdlock.S: New file.
1049 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedrdlock.S: New file.
1050 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_timedwrlock.S: New file.
1051 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_unlock.S: New file.
1052 * sysdeps/unix/sysv/linux/sh/pthread_rwlock_wrlock.S: New file.
1053 * sysdeps/unix/sysv/linux/sh/sem_post.S: New file.
1054 * sysdeps/unix/sysv/linux/sh/sem_timedwait.S: New file.
1055 * sysdeps/unix/sysv/linux/sh/sem_trywait.S: New file.
1056 * sysdeps/unix/sysv/linux/sh/sem_wait.S: New file.
1057 * sysdeps/unix/sysv/linux/sh/sysdep-cancel.h: New file.
1058
696e556e
UD
10592003-02-08 Ulrich Drepper <drepper@redhat.com>
1060
1061 * tst-cond2.c: Rearrange code to not rely on behavior undefined
1062 according to POSIX.
1063
1064 * tst-basic2.c (do_test): Lock mutex before creating the thread.
1065
fef710d6
UD
10662003-02-07 Ulrich Drepper <drepper@redhat.com>
1067
c6180643
UD
1068 * sysdeps/x86_64/tls.h: Remove unnecessary macros, left over from x86.
1069 (TLS_GET_FS): New #define.
1070 (TLS_SET_FS): New #define.
1071 Correct value of __NR_set_thread_area.
1072
fef710d6
UD
1073 * sysdeps/x86_64/td_ta_map_lwp2thr.c: New file.
1074
11090a99
UD
10752003-02-06 Ulrich Drepper <drepper@redhat.com>
1076
65c68990
UD
1077 * Makefile (tests): Add tst-popen1.
1078 * tst-popen1.c: New file.
1079
11090a99
UD
1080 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: Remove wrong
1081 but inactive generalization.
1082 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: Likewise.
1083 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: Likewise.
1084 Minor optimization, remove one instruction.
1085 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: Likewise.
1086
a88c9263
UD
10872003-02-04 Martin Schwidefsky <schwidefsky@de.ibm.com>
1088
1089 * sysdeps/unix/sysv/linux/s390/fork.c: Correct order of parameters.
1090
10912003-01-31 Martin Schwidefsky <schwidefsky@de.ibm.com>
1092
1093 * init.c (__NR_set_tid_address): Add #ifdef for s390.
1094 * sysdeps/pthread/pthread_barrier_wait.c: New file.
1095 * sysdeps/pthread/pthread_cond_broadcast.c: New file.
1096 * sysdeps/pthread/pthread_cond_signal.c: New file.
1097 * sysdeps/pthread/pthread_cond_timedwait.c: New file.
1098 * sysdeps/pthread/pthread_cond_wait.c: New file.
1099 * sysdeps/pthread/pthread_rwlock_rdlock.c: New file.
1100 * sysdeps/pthread/pthread_rwlock_timedrdlock.c: New file.
1101 * sysdeps/pthread/pthread_rwlock_timedwrlock.c: New file.
1102 * sysdeps/pthread/pthread_rwlock_unlock.c: New file.
1103 * sysdeps/pthread/pthread_rwlock_wrlock.c: New file.
1104 * sysdeps/s390/Makefile: New file.
1105 * sysdeps/s390/bits/atomic.h: New file.
1106 * sysdeps/s390/pthread_spin_init.c: New file.
1107 * sysdeps/s390/pthread_spin_lock.c: New file.
1108 * sysdeps/s390/pthread_spin_trylock.c: New file.
1109 * sysdeps/s390/pthread_spin_unlock.c: New file.
1110 * sysdeps/s390/pthreaddef.h: New file.
1111 * sysdeps/s390/tcb-offsets.sym: New file.
1112 * sysdeps/s390/td_ta_map_lwp2thr.c: New file.
1113 * sysdeps/s390/tls.h: New file.
1114 * sysdeps/unix/sysv/linux/s390/bits/pthreadtypes.h: New file.
1115 * sysdeps/unix/sysv/linux/s390/bits/semaphore.h: New file.
1116 * sysdeps/unix/sysv/linux/s390/createthread.c: New file.
1117 * sysdeps/unix/sysv/linux/s390/dl-sysdep.h: New file.
1118 * sysdeps/unix/sysv/linux/s390/fork.c: New file.
1119 * sysdeps/unix/sysv/linux/s390/jmp-unwind.c: New file.
1120 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: New file.
1121 * sysdeps/unix/sysv/linux/s390/libc-lowlevelmutex.c: New file.
1122 * sysdeps/unix/sysv/linux/s390/lowlevellock.c: New file.
1123 * sysdeps/unix/sysv/linux/s390/lowlevellock.h: New file.
1124 * sysdeps/unix/sysv/linux/s390/lowlevelmutex.c: New file.
1125 * sysdeps/unix/sysv/linux/s390/lowlevelsem.h: New file.
1126 * sysdeps/unix/sysv/linux/s390/pthread_once.c: New file.
1127 * sysdeps/unix/sysv/linux/s390/s390-32/pt-initfini.c: New file.
1128 * sysdeps/unix/sysv/linux/s390/s390-32/pt-vfork.S: New file.
1129 * sysdeps/unix/sysv/linux/s390/s390-32/sysdep-cancel.h: New file.
1130 * sysdeps/unix/sysv/linux/s390/s390-64/pt-initfini.c: New file.
1131 * sysdeps/unix/sysv/linux/s390/s390-64/pt-vfork.S: New file.
1132 * sysdeps/unix/sysv/linux/s390/s390-64/sysdep-cancel.h: New file.
1133 * sysdeps/unix/sysv/linux/s390/sem_post.c: New file.
1134 * sysdeps/unix/sysv/linux/s390/sem_timedwait.c: New file.
1135 * sysdeps/unix/sysv/linux/s390/libc-lowlevellock.c: New file.
1136 * sysdeps/unix/sysv/linux/s390/sem_wait.c: New file.
1137
6f1cff95
UD
11382003-02-04 Ulrich Drepper <drepper@redhat.com>
1139
ec609a8e
UD
1140 * atomic.h: Add a couple more default implementations.
1141 (atomic_compare_and_exchange_acq): Use
d45e8740
UD
1142 __arch_compare_and_exchange_32_acq in return value definition. It
1143 always exists.
1144 (atomic_bit_set): Renamed from atomic_set_bit.
0289bef9 1145 Add missing atomic_ prefixes.
e3ec8904 1146
6f1cff95
UD
1147 * sysdeps/pthread/bits/libc-lock.h (__libc_once): In case no
1148 thread library is available, use correct value to mark initialized
1149 once variable.
1150
4f088329
UD
11512003-02-03 Ulrich Drepper <drepper@redhat.com>
1152
6f1cff95
UD
1153 * allocatestack.c (allocate_stack): Use __getpagesize instead of
1154 __sysconf to determine pagesize.
1155
3e4fc359 1156 * pthread_create.c: Include <atomic.h>.
4f088329
UD
1157 * allocatestack.c (allocate_stack): Implement coloring of the
1158 allocated stack memory. Rename pagesize to pagesize_m1. It's the
1159 size minus one. Adjust users.
3e4fc359 1160 * sysdeps/i386/i686/Makefile: New file.
4f088329 1161
2f42e8be
UD
11622003-02-02 Ulrich Drepper <drepper@redhat.com>
1163
4301f7e2
UD
1164 * allocatestack.c: Improve comment throughout the file.
1165
2f42e8be 1166 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S
a37818b3 1167 (__lll_lock_wait): Add branch prediction.
2f42e8be
UD
1168 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S
1169 (__lll_lock_wait): Likewise.
1170 (lll_unlock_wake_cb): Removed.
1171
4a7d6545
UD
11722003-01-31 Ulrich Drepper <drepper@redhat.com>
1173
1174 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Remove
1175 _POSIX_THREAD_PRIORITY_SCHEDULING.
1176
886d5973
UD
11772003-01-30 Jakub Jelinek <jakub@redhat.com>
1178
1179 * sysdeps/pthread/pthread-functions.h (struct pthread_functions):
1180 Fix return type of ptr___pthread_getspecific.
1181
e474ca78
UD
11822003-01-29 Ulrich Drepper <drepper@redhat.com>
1183
1184 * Makefile (tests): Add tst-umask1.
1185 (tst-umask1-ARGS): Define.
1186 * tst-umask1.c: New file.
1187
e6ebd2e4
UD
11882003-01-28 Ulrich Drepper <drepper@redhat.com>
1189
6cf26f41
UD
1190 * Makefile (libpthread-routines): Remove lowlevelrwlock. Add
1191 pthread_rwlock_rdlock, pthread_rwlock_timedrdlock,
1192 pthread_rwlock_wrlock, pthread_rwlock_timedwrlock, and
1193 pthread_rwlock_unlock.
1194 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Removed
1195 * sysdeps/unix/sysv/linux/i386/i586/lowlevelrwlock.S: Removed
1196 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrwlock.S: Removed
1197 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_rdlock.S: New file.
1198 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedrdlock.S:
1199 New file.
1200 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_wrlock.S: New file.
1201 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_timedwrlock.S:
1202 New file.
1203 * sysdeps/unix/sysv/linux/i386/i486/pthread_rwlock_unlock.S: New file.
1204 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_rdlock.S: New file.
1205 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_timedrdlock.S:
1206 New file.
1207 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_wrlock.S: New file.
1208 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_timedwrlock.S:
1209 New file.
1210 * sysdeps/unix/sysv/linux/i386/i586/pthread_rwlock_unlock.S: New file.
1211 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_rdlock.S: New file.
1212 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_timedrdlock.S:
1213 New file.
1214 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_wrlock.S: New file.
1215 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_timedwrlock.S:
1216 New file.
1217 * sysdeps/unix/sysv/linux/i386/i686/pthread_rwlock_unlock.S: New file.
1218
1d087a7e
UD
1219 * Makefile (libpthread-routines): Remove lowlevelcond and
1220 lowlevelsem. Add sem_wait, sem_trywait, sem_timedwait, sem_post,
1221 pthread_cond_wait, pthread_cond_timedwait, pthread_cond_signal,
1222 and pthread_cond_broadcast.
4a99d160
UD
1223 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Removed
1224 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Removed
1225 * sysdeps/unix/sysv/linux/i386/i586/lowlevelsem.S: Removed
1226 * sysdeps/unix/sysv/linux/i386/i586/lowlevelcond.S: Removed
1227 * sysdeps/unix/sysv/linux/i386/i686/lowlevelsem.S: Removed
1228 * sysdeps/unix/sysv/linux/i386/i686/lowlevelcond.S: Removed
1229 * sysdeps/unix/sysv/linux/i386/i486/sem_wait.S: New file.
1230 * sysdeps/unix/sysv/linux/i386/i486/sem_trywait.S: New file.
1231 * sysdeps/unix/sysv/linux/i386/i486/sem_timedwait.S: New file.
1232 * sysdeps/unix/sysv/linux/i386/i486/sem_post.S: New file.
1233 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_wait.S: New file.
1234 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_timedwait.S: New file.
1235 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_signal.S: New file.
1236 * sysdeps/unix/sysv/linux/i386/i486/pthread_cond_broadcast.S: New file.
1237 * sysdeps/unix/sysv/linux/i386/i586/sem_wait.S: New file.
1238 * sysdeps/unix/sysv/linux/i386/i586/sem_trywait.S: New file.
1239 * sysdeps/unix/sysv/linux/i386/i586/sem_timedwait.S: New file.
1240 * sysdeps/unix/sysv/linux/i386/i586/sem_post.S: New file.
1241 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_wait.S: New file.
1242 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_timedwait.S: New file.
1243 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_signal.S: New file.
1244 * sysdeps/unix/sysv/linux/i386/i586/pthread_cond_broadcast.S: New file.
1245 * sysdeps/unix/sysv/linux/i386/i686/sem_wait.S: New file.
1246 * sysdeps/unix/sysv/linux/i386/i686/sem_trywait.S: New file.
1247 * sysdeps/unix/sysv/linux/i386/i686/sem_timedwait.S: New file.
1248 * sysdeps/unix/sysv/linux/i386/i686/sem_post.S: New file.
1249 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_wait.S: New file.
1250 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_timedwait.S: New file.
1251 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_signal.S: New file.
1252 * sysdeps/unix/sysv/linux/i386/i686/pthread_cond_broadcast.S: New file.
1253 * sysdeps/unix/sysv/linux/i386/lowlevelcond.h: New file.
1d087a7e 1254
e6ebd2e4
UD
1255 * sysdeps/unix/sysv/linux/i386/createthread.c: Define
1256 PREPARE_CREATE and TLS_VALUE with x86-specific bits. All the rest
1257 of the code is moved to ...
1258 * sysdeps/pthread/createthread.c: ...here. New file.
1259
a15698cb
UD
12602003-01-27 Ulrich Drepper <drepper@redhat.com>
1261
0566b130
UD
1262 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S
1263 (__new_sem_post): Clear %eax before returning.
1264 Reported by MAEDA Naoaki <maeda.naoaki@jp.fujitsu.com>.
1265
e6fb8846
UD
1266 * Makefile (tests): Add tst-cleanup2.
1267 * tst-cleanup2.c: New file.
1268
a15698cb
UD
1269 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start):
1270 Interpret first parameter correctly.
1271
8824b0a1
UD
12722003-01-17 Ulrich Drepper <drepper@redhat.com>
1273
1274 * Makefile (headers): Add bits/semaphore.h.
1275
850dcfca
UD
12762003-01-16 Jakub Jelinek <jakub@redhat.com>
1277
1278 * sysdeps/i386/tls.h (INIT_SYSINFO): Initialize _head->sysinfo even
1279 if not SHARED.
1280
574b892e
UD
12812003-01-14 Ulrich Drepper <drepper@redhat.com>
1282
a8d87c92
UD
1283 * sem_open.c (sem_open): Return SEM_FAILED if existing semaphore
1284 must be used and mapping failed.
1285 Reported by Luke Elliott <luke.elliott@activfinancial.com>.
1286
574b892e
UD
1287 * Makefile (CFLAGS-pthread_self.os): Define this, not
1288 CFLAGS-pthread_self.c.
1289
fb48047a
UD
12902003-01-13 Ulrich Drepper <drepper@redhat.com>
1291
47805511
UD
1292 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Don't export
1293 lll_unlock_wake_cb.
1294
fb48047a
UD
1295 * Makefile (libpthread-routines): Add version. Add rules to build
1296 version.os and banner.h.
1297 * version.c: New file.
1298
115bb61d
UD
12992003-01-13 Jakub Jelinek <jakub@redhat.com>
1300
1301 * pthread_mutex_lock.c (__pthread_mutex_lock_internal): Make
1302 the alias unconditional.
1303 * pthread_mutex_unlock.c (__pthread_mutex_unlock_internal): Likewise.
1304
13052003-01-13 Ulrich Drepper <drepper@redhat.com>
1306
1307 * Makefile (CFLAGS-pthread_self.c): New definition.
1308
6aca81bb
UD
13092003-01-06 Jakub Jelinek <jakub@redhat.com>
1310
1311 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Add
1312 INTERNAL_SYSCALL_DECL, add err argument to INTERNAL_SYSCALL* macros.
1313 * sysdeps/unix/sysv/linux/raise.c (raise): Likewise.
1314 * init.c (__pthread_initialize_minimal_internal): Likewise.
1315
e9c7764e
UD
13162003-01-07 Jakub Jelinek <jakub@redhat.com>
1317
b5facfda
UD
1318 * pthreadP.h (__pthread_cond_timedwait): Add prototype.
1319
e9c7764e
UD
1320 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h
1321 (RTLD_CORRECT_DYNAMIC_WEAK): Remove.
1322 (DL_SYSINFO_IMPLEMENTATION): Change into .text section and back.
1323 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h
1324 (RTLD_CORRECT_DYNAMIC_WEAK): Remove.
1325 (DL_SYSINFO_IMPLEMENTATION): Change into .text section and back.
1326
bef1e42f
UD
13272003-01-06 Jakub Jelinek <jakub@redhat.com>
1328
1329 * pthreadP.h (LIBC_CANCEL_HANDLED): Define.
1330 * pt-system.c (LIBC_CANCEL_HANDLED): Add.
1331 * tst-cancel-wrappers.sh: Remove all exceptions.
1332
bbd17455
UD
13332003-01-05 Ulrich Drepper <drepper@redhat.com>
1334
a73ab6df
UD
1335 * tst-cancel-wrappers.sh: Invoke gawk not awk since we use GNU awk
1336 features. Reported by Marijn Ros <marijn@mad.scientist.com>.
1337
bbd17455
UD
1338 * sysdeps/unix/sysv/linux/jmp-unwind.c: Include <pthread-functions.h>.
1339 Use __libc_pthread_functions array if SHARED.
1340
1341 * pthreadP.h: Move pthread_cond_2_0_t definition to...
1342 * sysdeps/unix/sysv/linux/internaltypes.h: ...here.
1343
1344 * sysdeps/pthread/bits/libc-lock.h (__libc_ptf_call): New #define.
1345 (__libc_rwlock_rdlock, __libc_rwlock_wrlock, __libc_rwlock_unlock,
1346 __libc_key_create, __libc_getspecific, __libc_setspecific): Use
1347 __libc_ptf_call instead of __libc_maybe_call.
1348 (PTF): New #define.
1349 (__libc_cleanup_region_start): Wrap function name with PTF call.
1350 (__libc_cleanup_region_end): Likewise.
1351 (__libc_cleanup_end): Likewise.
1352
1353 * pthread_getspecific.c: Add __pthread_getspecific_internal alias.
1354 * pthread_setspecific.c: Add __pthread_setspecific_internal alias.
1355 * pthread_key_create.c: Add __pthread_key_create_internal alias.
1356 * pthreadP.h: Add prototypes.
1357
1358 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Add
1359 __pthread_rwlock_rdlock, __pthread_rwlock_wrlock, and
1360 __pthread_rwlock_unlock aliases.
1361 * pthreadP.h: Add prototypes for new aliases.
1362
1363 * pthreadP.h (struct pthead_functions): Moved to...
1364 * sysdeps/pthread/pthread-functions.h: ...here. New file.
1365 * init.c (pthread_functions): Add initializers for new elements.
1366
1367 * cleanup_defer.c: Add __pthread_cleanup_push_defer and
1368 __pthread_cleanup_pop_restore aliases.
1369 * pthreadP.h: Add prototypes.
1370
1371 * cleanup.c: Rename _GI_pthread_cleanup_push to __pthread_cleanup_push
1372 and _GI_pthread_cleanup_pop to __pthread_cleanup_pop.
1373 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Adjust caller.
1374 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Likewise.
1375 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: Likewise.
1376 * pthreadP.h: Adjust prototypes and callers.
1377
d27a78be
UD
13782003-01-04 Ulrich Drepper <drepper@redhat.com>
1379
b74121ae
UD
1380 * Makefile (tests): Add tst-cancel7.
1381 (tst-cancel7-ARGS): New variable.
bbd17455 1382 * tst-cancel7.c: New file.
b74121ae 1383
29bc410c
UD
1384 * old_pthread_cond_broadcast.c: Optimize initialization a bit to work
1385 around gcc defficiencies.
1386 * old_pthread_cond_signal.c: Likewise.
1387 * old_pthread_cond_timedwait.c: Likewise.
1388 * old_pthread_cond_wait.c: Likewise.
1389
d27a78be
UD
1390 * pthreadP.h (pthread_cond_2_0_t): Remove unneeded lock element.
1391
733f25e6
UD
13922003-01-03 Ulrich Drepper <drepper@redhat.com>
1393
7edb2ae3
UD
1394 * Makefile (tests): Add tst-cond7.
1395 * tst-cond7.c: New file.
1396
b1151300
UD
1397 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S
1398 (condvar_cleanup): Get condvar address from the right place.
1399
733f25e6
UD
1400 * atomic.h: Correct definitions of atomic_full_barrier,
1401 atomic_read_barrier, atomic_write_barrier.
1402
1403 * old_pthread_cond_broadcast.c: Make memory allocate and initialization
1404 race-free.
1405 * old_pthread_cond_signal.c: Likewise.
1406 * old_pthread_cond_timedwait.c: Likewise.
1407 * old_pthread_cond_wait.c: Likewise.
1408
686b7223
UD
14092003-01-03 Jakub Jelinek <jakub@redhat.com>
1410
1411 * Makefile ($(objpfx)libpthread.so): Depend on ld.so.
1412
0e07706e
UD
14132003-01-03 Ulrich Drepper <drepper@redhat.com>
1414
997256dd
UD
1415 * pthreadP.h (pthread_cond_2_0_t): New type.
1416 (struct pthread_functions): Use new type for 2.0 condvar callbacks.
1417 Use new type for the 2.0 condvar function prototypes.
1418 * forward.c: Use pthread_cond_2_0_t for 2.0 condvar functions.
1419 * old_pthread_cond_init.c: Use pthread_cond_2_0_t for condvar
1420 parameter.
1421 * old_pthread_cond_destroy.c: Likewise.
1422 * old_pthread_cond_broadcast.c: Likewise. Lock appropriately.
1423 * old_pthread_cond_signal.c: Likewise.
1424 * old_pthread_cond_timedwait.c: Likewise.
1425 * old_pthread_cond_wait.c: Likewise.
1426
842d2817
UD
1427 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S
1428 (__pthread_cond_wait): Don't save cancellation mode and seq value
1429 in same location.
1430
0e07706e
UD
1431 * herrno.c (__h_errno_location): Don't define as weak.
1432
bf293afe
UD
14332003-01-02 Jakub Jelinek <jakub@redhat.com>
1434
1435 * Versions [libc] (GLIBC_2.3.2): Export pthread_cond_broadcast,
1436 pthread_cond_destroy, pthread_cond_init, pthread_cond_signal
1437 and pthread_cond_wait.
1438 * old_pthread_cond_broadcast.c (__old_pthread_cond_broadcast):
1439 Renamed to...
1440 (__pthread_cond_broadcast_2_0): ... this.
1441 * old_pthread_cond_destroy.c (__old_pthread_cond_destroy):
1442 Renamed to...
1443 (__pthread_cond_destroy_2_0): ... this.
1444 * old_pthread_cond_init.c (__old_pthread_cond_init):
1445 Renamed to...
1446 (__pthread_cond_init_2_0): ... this.
1447 * old_pthread_cond_signal.c (__old_pthread_cond_signal):
1448 Renamed to...
1449 (__pthread_cond_signal_2_0): ... this.
1450 * old_pthread_cond_wait.c (__old_pthread_cond_wait):
1451 Renamed to...
1452 (__pthread_cond_wait_2_0): ... this.
1453 * pthread_cond_destroy.c: Include shlib-compat.h.
1454 (pthread_cond_destroy): Change strong_alias into versioned_symbol.
1455 * pthread_cond_init.c: Include shlib-compat.h.
1456 (pthread_cond_init): Change strong_alias into versioned_symbol.
1457 * pthreadP.h (struct pthread_functions): Rename ptr_pthread_cond_*
1458 fields to ptr___pthread_cond_* and add ptr___pthread_cond_*_2_0
1459 fields.
1460 (__pthread_cond_broadcast_2_0, __pthread_cond_destroy_2_0,
1461 __pthread_cond_init_2_0, __pthread_cond_signal_2_0,
1462 __pthread_cond_wait_2_0): New prototypes.
1463 (__old_pthread_cond_broadcast, __old_pthread_cond_destroy,
1464 __old_pthread_cond_init, __old_pthread_cond_signal,
1465 __old_pthread_cond_wait): Removed.
1466 * init.c: Include shlib-compat.h.
1467 (pthread_functions): Guard ptr___pthread_attr_init_2_0
1468 initialization with SHLIB_COMPAT (GLIBC_2_0, GLIBC_2_1).
1469 Rename ptr_pthread_cond_* to ptr___pthread_cond_*, initialize
1470 ptr___pthread_cond_*_2_0 fields.
1471 * forward.c: Export both pthread_cond_*@@GLIBC_2.3.2 and
1472 pthread_cond_*@GLIBC_2.0 compatibility symbols.
1473
1474 * sysdeps/pthread/sigaction.c (SIGCANCEL): Only define if
1475 LIBC_SIGACTION was not yet defined.
1476 [!defined LIBC_SIGACTION]: Define LIBC_SIGACTION, #include self.
1477 [!defined LIBC_SIGACTION] (__sigaction): New function and
1478 libc_hidden_weak.
1479 [!defined LIBC_SIGACTION] (sigaction): New weak_alias.
1480 [defined LIBC_SIGACTION]: #include_next <sigaction.c>.
1481
14822003-01-02 Jakub Jelinek <jakub@redhat.com>
1483
1484 * Makefile (CFLAGS-pthread_atfork.c): Add -DNOT_IN_libc.
1485
05df18c3
UD
14862003-01-02 Ulrich Drepper <drepper@redhat.com>
1487
1488 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h (pthread_cond_t):
1489 New, larger type definition.
1490 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: New condvar
1491 implementation.
1492 * Versions [libpthread]: Add definitions for new pthread_cond_*
1493 interfaces for version GLIBC_2.3.2.
1494 * pthread_cond_init.c: Update initialization for new type definition.
1495 * Makefile (libpthread-routines): Remove pthread_cond_wait,
1496 pthread_cond_timedwait, pthread_cond_signal, and
1497 pthread_cond_broadcast. Add old_pthread_cond_init,
1498 old_pthread_cond_destroy, old_pthread_cond_wait,
1499 old_pthread_cond_timedwait, old_pthread_cond_signal, and
1500 old_pthread_cond_broadcast.
1501 * old_pthread_cond_broadcast.c: New file.
1502 * old_pthread_cond_destroy.c: New file.
1503 * old_pthread_cond_init.c: New file.
1504 * old_pthread_cond_signal.c: New file.
1505 * old_pthread_cond_timedwait.c: New file.
1506 * old_pthread_cond_wait.c: New file.
1507 * pthreadP.h: Add prototypes for the compatibility interfaces.
1508
1509 * pthread_cond_destroy.c: Don't include <errno.h>.
1510
fd8979e4
UD
15112003-01-01 Ulrich Drepper <drepper@redhat.com>
1512
1513 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Avoid
1514 unnecessary zero offset when addressing MUTEX.
1515
6d6ee629
UD
15162002-12-31 Ulrich Drepper <drepper@redhat.com>
1517
1518 * sysdeps/unix/sysv/linux/fork.h: Add libc_hidden_proto for
1519 __register_atfork.
1520 * sysdeps/unix/sysv/linux/register-atfork.c: Add libc_hidden_def
1521 for __register_atfork.
1522
a4baf360
UD
15232002-12-31 Jakub Jelinek <jakub@redhat.com>
1524
1525 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Use __ASSEMBLER__
1526 instead of ASSEMBLER test macro.
1527
1528 * sysdeps/unix/sysv/linux/allocrtsig.c (__libc_current_sigrtmin,
1529 __libc_current_sigrtmax): Add libc_hidden_def.
1530
1531 * sysdeps/pthread/list.h: Remove assert.h include.
1532
e9395a94
UD
15332002-12-31 Ulrich Drepper <drepper@redhat.com>
1534
1535 * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Use
1536 __pthread_initialize_minimal_internal not
1537 __pthread_initialize_minimal.
1538
89d6e444
UD
15392002-12-30 Ulrich Drepper <drepper@redhat.com>
1540
416d2de6
UD
1541 * sysdeps/pthread/pt-initfini.c (call_initialize_minimal): Mark
1542 __pthread_initialize_minimal as hidden.
1543
89d6e444
UD
1544 * init.c (__pthread_initialize_minimal_internal): Don't mark as
1545 constructor.
1546
15472002-12-31 Jakub Jelinek <jakub@redhat.com>
1548
1549 * Makefile ($(inst_libdir)/libpthread.so): Depend on
1550 $(common-objpfx)format.lds, include that into the output script.
1551 Fix comment.
1552 (extra-B-pthread.so): Change linuxthreads/ into nptl/.
1553
8cac677c
UD
15542002-12-28 Andreas Jaeger <aj@suse.de>
1555
1556 * sysdeps/unix/sysv/linux/xstatconv.c (xstat_conv): Adjust for
1557 nsec resolution changes.
1558 (xstat64_conv): Likewise.
1559 (xstat32_conv): Likewise.
1560 * sysdeps/unix/sysv/linux/kernel_stat.h: Add nsec resolution for
1561 struct kernel_stat.
1562 * sysdeps/unix/sysv/linux/bits/stat.h: Add nsec resolution for
1563 structs stat and stat64.
1564 * time/time.h (__timespec_defined): Define for __USE_MISC.
89d6e444 1565 * io/sys/stat.h [__USE_MISC]: Define __need_timespec for struct stat.
8cac677c 1566
49e9f864
UD
15672002-12-30 Jakub Jelinek <jakub@redhat.com>
1568
1569 * forward.c (FORWARD2): Renamed from FORWARD3. Remove unused export
1570 argument.
1571 (pthread_attr_init_2_0, pthread_attr_init_2_1): Use FORWARD macro.
1572 (pthread_exit): Use strong_alias to avoid warnings.
1573 * pthreadP.h (struct pthread_functions): Rename ptr_pthread_exit
1574 and ptr_pthread_attr_init_2_* to ptr___pthread_exit and
1575 ptr___pthread_attr_init_2_*.
1576 * init.c (pthread_functions): Adjust.
1577
bab09b26
UD
15782002-12-29 Ulrich Drepper <drepper@redhat.com>
1579
598d7a42
UD
1580 * forward.c: Make all functions available by default again. It
1581 caused too much trouble.
1582
bab09b26
UD
1583 * pt-siglongjmp.c: Removed.
1584
3b7ed871
UD
15852002-12-28 Jakub Jelinek <jakub@redhat.com>
1586
1587 * sysdeps/i386/tls.h: Include tcb-offsets.h in assembler.
1588 (SYSINFO_OFFSET, MULTIPLE_THREADS_OFFSET): Remove.
1589 * sysdeps/i386/Makefile: New file.
1590 * sysdeps/i386/tcb-offsets.sym: New file.
1591 * sysdeps/pthread/tcb-offsets.h: New file.
1592 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
1593 Remove MULTIPLE_THREADS_OFFSET and SYSINFO_OFFSET checks.
1594
1595 * sysdeps/unix/sysv/linux/Versions [libc] (GLIBC_PRIVATE): Move
1596 __register_atfork...
1597 (GLIBC_2.3.2): ...here.
1598
15992002-12-28 Ulrich Drepper <drepper@redhat.com>
1600
1601 * sysdeps/pthread/pthread.h: Mark pthread_attr_getstackaddr and
1602 pthread_attr_setstackaddr with __attribute_deprecated__.
1603
270d9d47
UD
16042002-12-27 Jakub Jelinek <jakub@redhat.com>
1605
1606 * pt-system.c (system): Remove cancellation handling.
1607 * tst-cancel-wrappers.sh: Allow pt-system.o* to not use the
1608 cancellation routines.
1609
131fd126
UD
16102002-12-28 Ulrich Drepper <drepper@redhat.com>
1611
afb2e954
UD
1612 * descr.h: Include <dl-sysdep.h>.
1613 (struct pthread): Move header.data.list to the back of the struct.
131fd126
UD
1614 * sysdeps/i386/tls.h (tcbhead_t): Move list to the back of the struct.
1615 (MULTIPLE_THREADS_OFFSET): Adjust offset.
1616 (SYSINFO_OFFSEET): Likewise.
1617
16182002-12-27 Jakub Jelinek <jakub@redhat.com>
1619
1620 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h (USE_DL_SYSINFO):
1621 Define.
1622 (DL_SYSINFO_DEFAULT): Cast to uintptr_t to avoid warnings.
1623 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h (NEED_DL_SYSINFO,
1624 DL_SYSINFO_DEFAULT, DL_SYSINFO_IMPLEMENTATION): Define.
1625 (USE_DL_SYSINFO): Undef.
1626
16272002-12-22 Jakub Jelinek <jakub@redhat.com>
1628
1629 * Makefile (tests-reverse): Use $(objpfx)../libc.so instead of
1630 $(common-objpfx)libc.so.
1631 * tst-cancel4.c (tf_write, tf_writev): Increase buf sizes so that
1632 it is bigger than pipe buffer size even on arches with bigger
1633 page size.
1634 (tf_usleep): Cast usleep argument to useconds_t to avoid warnings.
1635
a218c9cf
UD
16362002-12-25 Ulrich Drepper <drepper@redhat.com>
1637
1638 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Implement
1639 correct errno access for case that USE___THREAD is not defined.
1640
015a2dc9
UD
16412002-12-24 Ulrich Drepper <drepper@redhat.com>
1642
1643 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Add missing #endif.
1644 Patch by Marijn Ros <marijn@mad.scientist.com>.
1645
5220f9ac
RM
16462002-12-22 Roland McGrath <roland@redhat.com>
1647
1648 * Makefile (omit-deps): Add $(unix-syscalls:%=ptw-%).
1649
1561bf63
UD
16502002-12-20 Ulrich Drepper <drepper@redhat.com>
1651
1652 * sysdeps/pthread/bits/stdio-lock.h (_IO_lock_inexpensive): Define.
1653
3325198e
UD
16542002-12-19 Ulrich Drepper <drepper@redhat.com>
1655
057c823f
UD
1656 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Don't define
1657 NEED_DL_SYSINFO since no processor < i686 had the sysenter opcode.
1658 * sysdeps/unix/sysv/linux/i386/i686/dl-sysdep.h: New file.
1659
097eca29
UD
1660 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Use ENTER_KERNEL instead
1661 of int $0x80.
1662 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
1663 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: Likewise.
1664 * sysdeps/unix/sysv/linux/i386/i486/lowlevelcond.S: Likewise.
1665 * sysdeps/unix/sysv/linux/i386/i486/lowlevellock.S: Likewise.
1666 * sysdeps/unix/sysv/linux/i386/i486/lowlevelmutex.S: Likewise.
1667 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Likewise.
1668 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Likewise.
1669 * sysdeps/unix/sysv/linux/i386/i486/pthread_barrier_wait.S: Likewise.
1670
1671 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Add support for using
1672 sysenter.
1673 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Likewise.
1674
1675 * sysdeps/i386/tls.h: Unconditionally include <dl-sysdep.h>.
1676
5f5843e3
UD
1677 * allocatestack.c (allocate_stack) [NEED_DL_SYSINFO]: Set sysinfo
1678 in new TCB.
1679 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Check
1680 that sysinfo is properly initialized.
1681 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define RTLD_PRIVATE_ERRNO
1682 to 1 only for ld.so.
1683
3325198e
UD
1684 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: Define
1685 RTLD_CORRECT_DYNAMIC_WEAK.
1686
74e8f2dc
UD
16872002-12-19 Jakub Jelinek <jakub@redhat.com>
1688
1689 * forward.c (pthread_attr_init_2_0, pthread_attr_init_2_1):
1690 Use return 0 as 6th argument to FORWARD4.
1691 * pthread_equal.c: Include pthreadP.h instead of pthread.h.
1692
df45b31e
UD
16932002-12-18 Ulrich Drepper <drepper@redhat.com>
1694
1695 * descr.h (struct pthread) [NEED_DL_SYSINFO]: Add sysinfo member.
1696 * sysdeps/i386/tls.h (tcbhead_t): Add sysinfo member.
1697 Define SYSINFO_OFFSEET if NEED_DL_SYSINFO is defined.
1698 (INIT_SYSINFO): New #define.
1699 (TLS_TP_INIT): Use INIT_SYSINFO.
1700 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
1701 At test to make sure SYSINFO_OFFSET value is correct.
1702 * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: New file.
1703
3d539579
UD
17042002-12-18 Jakub Jelinek <jakub@redhat.com>
1705
1706 * sysdeps/pthread/flockfile.c (flockfile): Change into weak alias.
1707 * sysdeps/unix/sysv/linux/raise.c (gsignal): Add weak alias to raise.
1708 * Versions [libc: GLIBC_2.0]: Add pthread_attr_init.
1709 [libpthread: GLIBC_2.1]: Remove __pthread_rwlock_init,
1710 __pthread_rwlock_destroy, __pthread_rwlock_rdlock,
1711 __pthread_rwlock_wrlock, __pthread_rwlock_unlock,
1712 __pthread_rwlock_tryrdlock and __pthread_rwlock_trywrlock.
1713
d7913e0e
UD
17142002-12-18 Ulrich Drepper <drepper@redhat.com>
1715
f051627f
UD
1716 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Use ENTER_KERNEL
1717 macro instead of using int $0x80 directly.
1718
d7913e0e
UD
1719 * sysdeps/pthread/bits/stdio-lock.h: New file.
1720 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevelmutex.S: New file.
1721 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevelmutex.S: New file.
1722 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevelmutex.S: New file.
1723 * Makefile (routines): Add libc-lowlevelmutex.
1724
1725 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Remove
1726 __i686.get_pc_thunk.dx.
1727
f077a4a9
UD
17282002-12-17 Jakub Jelinek <jakub@redhat.com>
1729
1730 * Makefile (libpthread-shared-only-routines): Add pt-allocrtsig.
1731 (tests): Depend on $(objpfx)tst-cancel-wrappers.out.
1732 ($(objpfx)tst-cancel-wrappers.out): New rule.
1733 * tst-cancel-wrappers.sh: New test.
1734 * tst-locale1.c: Include signal.h.
1735 (uselocale): Test static linking of __libc_current_sigrt*.
1736
17372002-12-17 Ulrich Drepper <drepper@redhat.com>
1738
1739 * Makefile (tests): Add tst-cancel6.
1740 * tst-cancel6.c: New file
1741
bd499a3b
UD
17422002-12-17 Jakub Jelinek <jakub@redhat.com>
1743
1744 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (SINGLE_THREAD_P):
1745 Define meaningfully for assembler as well.
1746 * pthreadP.h (struct pthread_functions): Remove
1747 ptr_pthread_attr_init field. Add ptr_pthread_attr_init_2_0
1748 and ptr_pthread_attr_init_2_1 fields.
1749 * init.c (pthread_functions): Initialize ptr_pthread_attr_init_2_0
1750 and ptr_pthread_attr_init_2_1 instead of ptr_pthread_attr_init.
1751 * forward.c (FORWARD4): Renamed from FORWARD3. Add export argument.
1752 (FORWARD3): Define using FORWARD4.
1753 (pthread_attr_init): Provide both @GLIBC_2.0 and @@GLIBC_2.1
1754 versions.
1755 * pt-system.c: Remove duplicate stdlib.h include.
1756
0a1063f4
UD
17572002-12-16 Ulrich Drepper <drepper@redhat.com>
1758
87d60668
UD
1759 * sem_init.c: Define sem_init@GLIBC_2.0.
1760 * sem_destroy.c: Define sem_destroy@GLIBC_2.0.
1761 * sem_getvalue.c: Define sem_getvalue@GLIBC_2.0.
1762
0a1063f4
UD
1763 * flockfile.c: Moved to...
1764 * sysdeps/pthread/flockfile.c: ...here. New file.
1765 * funlockfile.c: Moved to...
1766 * sysdeps/pthread/funlockfile.c: ...here. New file.
1767 * ftrylockfile.c: Moved to...
1768 * sysdeps/pthread/ftrylockfile.c: ...here. New file.
1769
9634cf9d
UD
17702002-12-16 Jakub Jelinek <jakub@redhat.com>
1771
1772 * libc-cancellation.c: Guard both function with
1773 #if !defined NOT_IN_libc.
1774 * Makefile (libpthread-routines): Use ptw-, not pt- prefix for the
1775 automatically provided pthread wrappers.
1776 * pthreadP.h (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): Define to
1777 CANCEL_* if IS_IN_libpthread and to dummy versions if not in libc
1778 nor in libpthread.
1779 * pt-open.c: Removed.
1780 * pt-fcntl.c: Removed.
1781 * pt-fsync.c: Removed.
1782 * pt-lseek.c: Removed.
1783 * pt-msgrcv.c: Removed.
1784 * pt-msgsnd.c: Removed.
1785 * pt-msync.c: Removed.
1786 * pt-nanosleep.c: Removed.
1787 * pt-open64.c: Removed.
1788 * pt-pause.c: Removed.
1789 * pt-pread.c: Removed.
1790 * pt-pread64.c: Removed.
1791 * pt-pwrite.c: Removed.
1792 * pt-pwrite64.c: Removed.
1793 * pt-read.c: Removed.
1794 * pt-recv.c: Removed.
1795 * pt-recvfrom.c: Removed.
1796 * pt-recvmsg.c: Removed.
1797 * pt-send.c: Removed.
1798 * pt-sendto.c: Removed.
1799 * pt-sigtimedwait.c: Removed.
1800 * pt-sigwait.c: Removed.
1801 * pt-wait.c: Removed.
1802 * pt-waitpid.c: Removed.
1803 * pt-write.c: Removed.
1804 * pt-accept.c: Removed.
1805 * pt-close.c: Removed.
1806 * pt-connect.c: Removed.
1807 * pt-lseek64.c: Removed.
1808 * pt-sendmsg.c: Removed.
1809 * pt-tcdrain.c: Removed.
1810
6ee8d334
UD
18112002-12-15 Ulrich Drepper <drepper@redhat.com>
1812
81fa9371
UD
1813 * init.c (__pthread_initialize_minimal_internal): Renamed from
1814 __pthread_initialize_minimal. Make old name an alias. This
1815 converts a normal relocation into a relative relocation.
1816
f3015aa5
UD
1817 * pt-fcntl.c (__fcntl): Use fcntl64 syscall, not fcntl.
1818
4cbc1950
UD
1819 * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect,
1820 readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev.
1821 * Makefile (libpthread-routines): Remove pt-creat, pt-poll,
1822 pt-pselect, pt-readv, pt-select, pt-sigpause, pt-sigsuspend,
1823 pt-sigwaitinfo, pt-waitid, and pt-writev.
1824 * pt-creat.c: Removed.
1825 * pt-poll.c: Removed.
1826 * pt-pselect.c: Removed.
1827 * pt-readv.c: Removed.
1828 * pt-select.c: Removed.
1829 * pt-sigpause.c: Removed.
1830 * pt-sigsuspend.c: Removed.
1831 * pt-sigwaitinfo.c: Removed.
1832 * pt-waitid.c: Removed.
1833 * pt-writev.c: Removed.
1834
8454830b
UD
1835 * init.c (pthread_functions): New variable.
1836 (__pthread_initialize_minimal): Pass pointer to pthread_functions
1837 (or NULL) to __libc_pthread_init.
1838 * forward.c: Rewrite to use __libc:pthread_functions array to get
1839 function addresses.
1840 * sysdeps/unix/sysv/linux/fork.h: Remove __libc_pthread_init
1841 prototype.
1842 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
1843 Take new parameter. Copy content of variable pointed to by it
1844 to __libc_pthread_init.
1845
1846 * pthreadP.h (struct pthread_functions): New type.
1847 (__libc_pthread_init): Declare.
1848
1849 * pthread_attr_destroy.c: Add namespace protected alias.
1850 * pthread_attr_getdetachstate.c: Likewise.
1851 * pthread_attr_getinheritsched.c: Likewise.
1852 * pthread_attr_getschedparam.c: Likewise.
1853 * pthread_attr_getschedpolicy.c: Likewise.
1854 * pthread_attr_getscope.c: Likewise.
1855 * pthread_attr_setdetachstate.c: Likewise.
1856 * pthread_attr_setinheritsched.c: Likewise.
1857 * pthread_attr_setschedparam.c: Likewise.
1858 * pthread_attr_setschedpolicy.c: Likewise.
1859 * pthread_attr_setscope.c: Likewise.
1860 * pthread_cond_broadcast.c: Likewise.
1861 * pthread_cond_destroy.c: Likewise.
1862 * pthread_cond_init.c: Likewise.
1863 * pthread_cond_signal.c: Likewise.
1864 * pthread_cond_wait.c: Likewise.
1865 * pthread_condattr_destroy.c: Likewise.
1866 * pthread_condattr_init.c: Likewise.
1867 * pthread_equal.c: Likewise.
1868 * pthread_exit.c: Likewise.
1869 * pthread_getschedparam.c: Likewise.
1870 * pthread_self.c: Likewise.
1871 * pthread_setcancelstate.c: Likewise.
1872 * pthread_setschedparam.c: Likewise.
1873 * pthread_mutex_destroy.c: Likewise.
1874 * pthread_mutex_init.c: Likewise.
1875 * pthreadP.h: Add prototypes for the aliases.
1876
0d5f4929
UD
1877 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Set
1878 multiple_threads member in correct TCB to 1.
1879
6ee8d334
UD
1880 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define
1881 SINGLE_THREAD_P. If in libc or libpthread examine multiple_thread
1882 member of thread decriptor, otherwise return unconditionally 1.
1883
2fb6444d
UD
18842002-12-14 Ulrich Drepper <drepper@redhat.com>
1885
1886 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Changes folded into the
1887 regular Linux version. Remove file.
1888 * sysdeps/unix/sysv/linux/connect.S: Likewise. Remove file.
1889 * sysdeps/unix/sysv/linux/llseek.c: Likewise. Remove file.
1890 * sysdeps/unix/sysv/linux/msgrcv.c: Likewise. Remove file.
1891 * sysdeps/unix/sysv/linux/msgsnd.c: Likewise. Remove file.
1892 * sysdeps/unix/sysv/linux/open64.c: Likewise. Remove file.
1893 * sysdeps/unix/sysv/linux/poll.c: Likewise. Remove file.
1894 * sysdeps/unix/sysv/linux/pread.c: Likewise. Remove file.
1895 * sysdeps/unix/sysv/linux/pread64.c: Likewise. Remove file.
1896 * sysdeps/unix/sysv/linux/pselect.c: Likewise. Remove file.
1897 * sysdeps/unix/sysv/linux/pwrite.c: Likewise. Remove file.
1898 * sysdeps/unix/sysv/linux/pwrite64.c: Likewise. Remove file.
1899 * sysdeps/unix/sysv/linux/readv.c: Likewise. Remove file.
1900 * sysdeps/unix/sysv/linux/recv.S: Likewise. Remove file.
1901 * sysdeps/unix/sysv/linux/recvfrom.S: Likewise. Remove file.
1902 * sysdeps/unix/sysv/linux/recvmsg.S: Likewise. Remove file.
1903 * sysdeps/unix/sysv/linux/send.S: Likewise. Remove file.
1904 * sysdeps/unix/sysv/linux/sendmsg.S: Likewise. Remove file.
1905 * sysdeps/unix/sysv/linux/sendto.S: Likewise. Remove file.
1906 * sysdeps/unix/sysv/linux/sigpause.c: Likewise. Remove file.
1907 * sysdeps/unix/sysv/linux/sigsuspend.c: Likewise. Remove file.
1908 * sysdeps/unix/sysv/linux/sigtimedwait.c: Likewise. Remove file.
1909 * sysdeps/unix/sysv/linux/sigwait.c: Likewise. Remove file.
1910 * sysdeps/unix/sysv/linux/sigwaitinfo.c: Likewise. Remove file.
1911 * sysdeps/unix/sysv/linux/system.c: Likewise. Remove file.
1912 * sysdeps/unix/sysv/linux/tcdrain.c: Likewise. Remove file.
1913 * sysdeps/unix/sysv/linux/wait.c: Likewise. Remove file.
1914 * sysdeps/unix/sysv/linux/waitid.c: Likewise. Remove file.
1915 * sysdeps/unix/sysv/linux/waitpid.c: Likewise. Remove file.
1916 * sysdeps/unix/sysv/linux/writev.c: Likewise. Remove file.
1917 * sysdeps/unix/sysv/linux/i386/fcntl.c: Likewise. Remove file.
1918
86b2dc40
UD
19192002-12-14 Jakub Jelinek <jakub@redhat.com>
1920
1921 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: New file.
1922 * sysdeps/unix/sysv/linux/open.c: Removed.
1923 * sysdeps/unix/sysv/linux/fsync.c: Removed.
1924 * sysdeps/unix/sysv/linux/lseek.c: Removed.
1925 * sysdeps/unix/sysv/linux/msync.c: Removed.
1926 * sysdeps/unix/sysv/linux/read.c: Removed.
1927 * sysdeps/unix/sysv/linux/close.c: Removed.
1928 * sysdeps/unix/sysv/linux/creat.c: Removed.
1929 * sysdeps/unix/sysv/linux/nanosleep.c: Removed.
1930 * sysdeps/unix/sysv/linux/pause.c: Removed.
1931 * sysdeps/unix/sysv/linux/select.c: Removed.
1932 * sysdeps/unix/sysv/linux/write.c: Removed.
1933
9d263d72
UD
19342002-12-14 Ulrich Drepper <drepper@redhat.com>
1935
1936 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Check multiple_threads
1937 element in TCB to see whether locking is needed.
1938
1939 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Check that
1940 MULTIPLE_THREADS_OFFSET value is correct.
1941
1942 * sysdeps/unix/sysv/linux/close.c: New file.
1943 * sysdeps/unix/sysv/linux/connect.S: New file.
1944 * sysdeps/unix/sysv/linux/creat.c: New file.
1945 * sysdeps/unix/sysv/linux/fsync.c: New file.
1946 * sysdeps/unix/sysv/linux/llseek.c: New file.
1947 * sysdeps/unix/sysv/linux/lseek.c: New file.
1948 * sysdeps/unix/sysv/linux/msgrcv.c: New file.
1949 * sysdeps/unix/sysv/linux/msgsnd.c: New file.
1950 * sysdeps/unix/sysv/linux/msync.c: New file.
1951 * sysdeps/unix/sysv/linux/nanosleep.c: New file.
1952 * sysdeps/unix/sysv/linux/open.c: New file.
1953 * sysdeps/unix/sysv/linux/open64.c: New file.
1954 * sysdeps/unix/sysv/linux/pause.c: New file.
1955 * sysdeps/unix/sysv/linux/poll.c: New file.
1956 * sysdeps/unix/sysv/linux/pread.c: New file.
1957 * sysdeps/unix/sysv/linux/pread64.c: New file.
1958 * sysdeps/unix/sysv/linux/pselect.c: New file.
1959 * sysdeps/unix/sysv/linux/pwrite.c: New file.
1960 * sysdeps/unix/sysv/linux/pwrite64.c: New file.
1961 * sysdeps/unix/sysv/linux/readv.c: New file.
1962 * sysdeps/unix/sysv/linux/recv.S: New file.
1963 * sysdeps/unix/sysv/linux/recvfrom.S: New file.
1964 * sysdeps/unix/sysv/linux/recvmsg.S: New file.
1965 * sysdeps/unix/sysv/linux/select.c: New file.
1966 * sysdeps/unix/sysv/linux/send.S: New file.
1967 * sysdeps/unix/sysv/linux/sendmsg.S: New file.
1968 * sysdeps/unix/sysv/linux/sendto.S: New file.
1969 * sysdeps/unix/sysv/linux/sigpause.c: New file.
1970 * sysdeps/unix/sysv/linux/sigsuspend.c: New file.
1971 * sysdeps/unix/sysv/linux/sigtimedwait.c: New file.
1972 * sysdeps/unix/sysv/linux/sigwait.c: New file.
1973 * sysdeps/unix/sysv/linux/sigwaitinfo.c: New file.
1974 * sysdeps/unix/sysv/linux/system.c: New file.
1975 * sysdeps/unix/sysv/linux/tcdrain.c: New file.
1976 * sysdeps/unix/sysv/linux/wait.c: New file.
1977 * sysdeps/unix/sysv/linux/waitid.c: New file.
1978 * sysdeps/unix/sysv/linux/waitpid.c: New file.
1979 * sysdeps/unix/sysv/linux/writev.c: New file.
1980 * sysdeps/unix/sysv/linux/i386/fcntl.c: New file.
1981
1982 * pt-readv.c: Fix comment.
1983
19842002-12-14 Jakub Jelinek <jakub@redhat.com>
1985
1986 * tst-cleanup1.c: Include stdlib.h.
1987
1988 * tst-cancel5.c: New test.
1989 * Makefile (tests): Add tst-cancel5.
1990 (tst-cancel5): Link against libc.so libpthread.so in that order.
1991
9ae0909b
UD
19922002-12-13 Ulrich Drepper <drepper@redhat.com>
1993
b7bdd9c4
UD
1994 * forward.c (test_loaded): Prevent recursive calls.
1995
9ae0909b
UD
1996 * Makefile (routines): Add libc-cancellation.
1997 * libc-cancellation.c: New file.
1998 * descr.h (struct pthread): Add multiple_threads field.
1999 * allocatestack.c (allocate_stack): Initialize multiple_header field of
2000 new thread descriptor to 1.
2001 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread):
2002 Initialize multiple_thread field after successful thread creation.
2003 * cancellation.c (__do_cancel): Move to pthreadP.h.
2004 (__pthread_enable_asynccancel): Remove parameter from __do_cancel call.
2005 (__pthread_disable_asynccancel): Add internal_function attribute.
2006 * init.c (sigcancel_handler): Remove parameter from __do_cancel call.
2007 * pthread_setcancelstate.c: Likewise.
2008 * pthread_setcanceltype.c: Likewise.
2009 * pthread_exit.c: Likewise.
2010 * pthreadP.h (CANCELLATION_P): Likewise.
2011 (__do_cancel): Define as static inline.
2012 (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): New #defines.
2013 (__libc_enable_asynccancel, __libc_disable_asynccancel): New
2014 declarations.
2015 * sysdeps/i386/tls.h (tcbhead_t): Add list and multiple_threads
2016 fields. Define MULTIPLE_THREADS_OFFSET.
2017 * sysdeps/pthread/bits/libc-lock.h: Remove __libc_locking_needed
2018 declaration.
2019 * sysdeps/unix/sysv/linux/accept.S: New file.
2020 * sysdeps/unix/sysv/linux/read.c: New file.
2021 * sysdeps/unix/sysv/linux/write.c: New file.
2022 * sysdeps/unix/sysv/linux/i386/pt-socket.S: New file.
2023 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Remove definition and
2024 initialization of __libc_locking_needed.
2025 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Don't use
2026 __libc_locking_needed, use multiple_threads field in TCB.
2027 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
2028
22f20674
UD
20292002-12-12 Ulrich Drepper <drepper@redhat.com>
2030
2ad2e1e7
UD
2031 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: Use i486
2032 version.
2033 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: Likewise.
2034
22f20674
UD
2035 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Correct
2036 access to __libc_locking_needed for PIC.
2037
aa80bf86
UD
20382002-12-12 Jakub Jelinek <jakub@redhat.com>
2039
2040 * sysdeps/pthread/bits/libc-lock.h (__libc_locking_needed): Only
2041 declare for libc.so.
2042 (__libc_lock_init, __libc_lock_init_recursive): Change into comma
2043 expression.
2044 (__libc_lock_lock): Put into statement expression.
2045 (__libc_lock_unlock): Remove trailing semicolon.
2046 * sysdeps/unix/sysv/linux/fork.h (__libc_pthread_init): Fix typo.
2047
24021373
RM
20482002-12-12 Roland McGrath <roland@redhat.com>
2049
2050 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use asm operand with
2051 "m" constraint to refer to __libc_locking_needed. Declare it here.
2052
14e7aece
UD
20532002-12-12 Ulrich Drepper <drepper@redhat.com>
2054
2055 * sysdeps/unix/sysv/linux/fork-gen.c: Renamed to...
2056 * sysdeps/unix/sysv/linux/libc_pthread_init.c: ...this.
2057 Initialize __libc_locking_needed.
2058 * init.c (__pthread_initialize_minimal): Call __libc_pthread_init
2059 instead of __register_pthread_fork_handler.
2060 * sysdeps/pthread/bits/libc-lock.h: Declare __libc_locking_needed.
2061 * sysdeps/unix/sysv/linux/Makefile (sysdep_routimes): Replace
2062 fork-gen with libc_pthread_init.
2063 * sysdeps/unix/sysv/linux/Versions: Use __libc_pthread_init instead
2064 of __register_pthread_fork_handler.
2065 * sysdeps/unix/sysv/linux/fork.h: Declare __libc_pthread_init instead
2066 of __register_pthread_fork_handler.
2067 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use
2068 __libc_locking_needed to determine whether lock prefix can be avoided.
2069 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
2070
85631c8e
UD
20712002-12-11 Ulrich Drepper <drepper@redhat.com>
2072
da63009e
UD
2073 * Makefile (tests): Add tst-cleanup1.
2074 * tst-cleanup1.c: New file.
2075 * cancellation.c (__cleanup_thread): Removed.
2076 (__do_cancel): Remove call to __cleanup_thread.
2077 * pthreadP.h: Remove __cleanup_thread prorotype.
2078
000160a2
UD
2079 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start):
2080 Remember function and argument even if cancellation handler
2081 function is not available.
2082 (__libc_cleanup_region_end): Execute registered function directly if
2083 pthread functions are not available.
2084 (__libc_cleanup_end): Likewise.
2085
85631c8e
UD
2086 * init.c (__pthread_initialize_minimal): Fix initialization in
2087 static lib by preventing gcc from being too clever.
2088
dce8f2b6
UD
20892002-12-10 Ulrich Drepper <drepper@redhat.com>
2090
34a075be
UD
2091 * init.c (__pthread_initialize_minimal): Remove unneccesary
2092 sigaddset call.
2093
dce8f2b6
UD
2094 * Makefile (tests): We can run tst-locale2 now.
2095
e5e45b53
UD
20962002-12-09 Ulrich Drepper <drepper@redhat.com>
2097
2098 * Versions: Remove duplicated sigwait entry.
2099
bdb04f92
UD
21002002-12-08 Ulrich Drepper <drepper@redhat.com>
2101
1e506629
UD
2102 * pthreadP.h: Enable pthread_cleanup_{push,pop} optimizations only
2103 inside libpthread.
2104
a3957dd5
UD
2105 * pt-fcntl.c (__fcntl): Initialize oldtype to avoid warning.
2106
bdb04f92
UD
2107 * pthreadP.h: Declare __pthread_enable_asynccancel and
2108 __pthread_disable_asynccancel.
2109 (CANCEL_ASYNC): Use __pthread_enable_asynccancel.
2110 (CANCEL_RESET): Use __pthread_disable_asynccancel.
2111 * cancellation.c (__pthread_enable_asynccancel): New function.
2112 (__pthread_disable_asynccancel): New function.
2113 * pt-accept.c: Adjust for CANCEL_ASYNC and CANCEL_RESET change.
2114 * pt-close.c: Likewise.
2115 * pt-connect.c: Likewise.
2116 * pt-creat.c: Likewise.
2117 * pt-fcntl.c: Likewise.
2118 * pt-fsync.c: Likewise.
2119 * pt-lseek.c: Likewise.
2120 * pt-lseek64.c: Likewise.
2121 * pt-msgrcv.c: Likewise.
2122 * pt-msgsnd.c: Likewise.
2123 * pt-msync.c: Likewise.
2124 * pt-nanosleep.c: Likewise.
2125 * pt-open.c: Likewise.
2126 * pt-open64.c: Likewise.
2127 * pt-pause.c: Likewise.
2128 * pt-poll.c: Likewise.
2129 * pt-pread.c: Likewise.
2130 * pt-pread64.c: Likewise.
2131 * pt-pselect.c: Likewise.
2132 * pt-pwrite.c: Likewise.
2133 * pt-pwrite64.c: Likewise.
2134 * pt-read.c: Likewise.
2135 * pt-readv.c: Likewise.
2136 * pt-recv.c: Likewise.
2137 * pt-recvfrom.c: Likewise.
2138 * pt-recvmsg.c: Likewise.
2139 * pt-select.c: Likewise.
2140 * pt-send.c: Likewise.
2141 * pt-sendmsg.c: Likewise.
2142 * pt-sendto.c: Likewise.
2143 * pt-sigpause.c: Likewise.
2144 * pt-sigsuspend.c: Likewise.
2145 * pt-sigtimedwait.c: Likewise.
2146 * pt-sigwait.c: Likewise.
2147 * pt-sigwaitinfo.c: Likewise.
2148 * pt-system.c: Likewise.
2149 * pt-tcdrain.c: Likewise.
2150 * pt-wait.c: Likewise.
2151 * pt-waitid.c: Likewise.
2152 * pt-waitpid.c: Likewise.
2153 * pt-write.c: Likewise.
2154 * pt-writev.c: Likewise.
a3957dd5
UD
2155 * pthread_join.c: Likewise.
2156 * pthread_timedjoin.c: Likewise.
bdb04f92
UD
2157
2158 * pt-sigpause.c (sigsuspend): Call __sigsuspend.
2159 (__xpg_sigpause): New function.
2160 * Versions (libpthread:GLIBC_2.3.2): Add __xpg_sigpause.
2161
6ccb3834
UD
21622002-12-07 Ulrich Drepper <drepper@redhat.com>
2163
09efc3ba
UD
2164 * Makefile (CFLAGS-ftrylockfile.c): Add -D_IO_MTSAFE_IO.
2165
2166 * cleanup.c: Move declarations of _GI_pthread_cleanup_push and
2167 _GI_pthread_cleanup_pop to pthreadP.h.
2168
2169 * ftrylockfile.c: Use _IO_lock_trylock instead of
2170 pthread_mutex_trylock.
2171
2172 * pthreadP.h (CANCEL_ASYNC): Use __pthread_setcanceltype.
2173 (CANCEL_RESET): Likewise.
2174 (__pthread_setcanceltype_): Declare.
2175 (__pthread_mutex_lock_internal): Declare.
2176 (__pthread_mutex_unlock_internal): Declare.
2177 (__pthread_once_internal): Declare.
2178 (pthread_cleanup_push): Redefine using _GI_pthread_cleanup_push.
2179 (pthread_cleanup_pop): Redefine using _GI_pthread_cleanup_pop.
2180
2181 * pthread_cond_timedwait.c: Use INTUSE is calls to pthread_mutex_lock
2182 and pthread_mutex_unlock.
2183 * pthread_cond_wait.c: Likewise.
2184 * pthread_mutex_lock.c: Use INTDEF to define alias if needed.
2185 * pthread_mutex_unlock.c: Likewise.
2186
2187 * pthread_setcanceltype.c: Add additional alias
2188 __pthread_setcanceltype.
2189
2190 * sem_unlink.c (sem_unlink): Use __pthread_once with INTDEF.
2191 * sem_open.c (sem_open): Likewise.
2192 Use __libc_open, __libc_write, and __libc_close instead of
2193 open, write, and close respectively.
2194
2195 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_trylock_internal):
2196 Rewrite as statement expression since it must return a value.
2197
2198 * pthread_cancel.c: Use __pthread_kill instead of pthread_kill.
2199 * sysdeps/unix/sysv/linux/pthread_kill.c: Define additional alias
2200 __pthread_kill.
2201
2202 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Define additional
2203 alias __pthread_once_internal.
2204
6ccb3834
UD
2205 * sysdeps/unix/sysv/linux/raise.c: Use libc_hidden_def for raise.
2206
d3c9f895
UD
22072002-12-06 Ulrich Drepper <drepper@redhat.com>
2208
4614167a
UD
2209 * Makefile (tests): Add tst-stdio1 and tst-stdio2.
2210 * tst-stdio1.c: New file.
2211 * tst-stdio2.c: New file.
2212
a4548cea
UD
2213 * init.c (__pthread_initialize_minimal): Correct INIT_LIST_HEAD use.
2214
d3c9f895
UD
2215 * Makefile (tests): Comment out tst-locale2 for now.
2216 (CFLAGS-flockfile.c, CFLAGS-funlockfile.c): Define to -D_IO_MTSAFE_IO.
2217
2218 * sysdeps/unix/sysv/linux/Makefile: Define CFLAGS-fork.c to
2219 -D_IO_MTSAFE_IO.
2220 * sysdeps/unix/sysv/linux/fork.c: Include <bits/stdio-lock.h>.
2221 Use _IO_lock_init instead of explicit assignment.
2222
2223 * sysdeps/pthread/bits/libc-lock.h: Define __rtld_lock_* macros.
2224 Define __libc_lock_* and __libc_lock_recursive macros with
2225 lowlevellock macros, not pthread mutexes.
2226
2227 * flockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_lock instead
2228 of pthread_mutex_lock.
2229 * funlockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_unlock
2230 instead of pthread_mutex_unlock.
2231
fde89ad0
RM
22322002-12-06 Roland McGrath <roland@redhat.com>
2233
2234 * allocatestack.c (__stack_user): Use uninitialized defn.
2235 * init.c (__pthread_initialize_minimal): Initialize it here.
2236
11767d47
RM
22372002-12-05 Roland McGrath <roland@redhat.com>
2238
fde89ad0
RM
2239 * sysdeps/i386/tls.h (TLS_INIT_TP): Make it return zero or an error
2240 string.
2241 * sysdeps/x86_64/tls.h (TLS_INIT_TP): Likewise.
2242
11767d47
RM
2243 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Add
2244 missing & here too.
2245
440d8bc2
UD
22462002-12-05 Ulrich Drepper <drepper@redhat.com>
2247
2248 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
2249 lowlevellock.
2250 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: New file.
2251 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: New file.
2252 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: New file.
2253 * sysdeps/pthread/bits/libc-lock.h: Use lowlevellock implementation
2254 for __libc_lock_* macros.
2255 * Makefile (routines): Add libc-lowlevellock.
2256
22572002-10-09 Roland McGrath <roland@redhat.com>
2258
2259 * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call): New macro.
2260 Under [__PIC__], call the function via the pointer fetched for
2261 comparison rather than a call by name that uses the PLT.
2262 (__libc_lock_init, __libc_rwlock_init, __libc_lock_fini)
2263 (__libc_rwlock_fini, __libc_lock_lock, __libc_rwlock_rdlock)
2264 (__libc_rwlock_wrlock, __libc_lock_trylock, __libc_rwlock_tryrdlock)
2265 (__libc_rwlock_trywrlock, __libc_lock_unlock, __libc_rwlock_unlock)
2266 (__libc_key_create, __libc_getspecific, __libc_setspecific): Use it.
2267
d5ed0118
RM
22682002-12-04 Roland McGrath <roland@redhat.com>
2269
2270 * forward.c (pthread_self): Use FORWARD3 macro to correct return type.
2271
2272 * sysdeps/i386/td_ta_map_lwp2thr.c: Moved from ../nptl_db.
2273 * sysdeps/generic/td_ta_map_lwp2thr.c: New file.
2274
2275 * pthread_create.c (start_thread): Add missing & on __nptl_last_event.
2276
eaa4099f
UD
22772002-12-04 Ulrich Drepper <drepper@redhat.com>
2278
2279 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Make pthread_t
2280 a completely opaque, non-integer type.
2281 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
2282
33b5d0cc
UD
22832002-12-05 Jakub Jelinek <jakub@redhat.com>
2284
2285 * sysdeps/i386/tls.h: Include stdlib.h.
2286 * sysdeps/x86_64/tls.h: Likewise.
2287
7a5cdb30
UD
22882002-12-04 Ulrich Drepper <drepper@redhat.com>
2289
c4a6d859
UD
2290 * Makefile (tests): Add tst-locale2.
2291 (tests-static): Likewise.
2292 * tst-locale2.c: New file.
2293
7a5cdb30
UD
2294 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Mark asms as
2295 volatile and add memory clobbers to lock operations.
2296
d82d5d12
UD
22972002-12-03 Ulrich Drepper <drepper@redhat.com>
2298
69cae3cf
UD
2299 * sysdeps/i386/i686/bits/atomic.h: Use i486 version.
2300 * sysdeps/i386/i486/bits/atomic.h: New file.
2301 * sysdeps/i386/i586/bits/atomic.h: New file.
2302 * sysdeps/i386/i686/pthread_spin_trylock.S: Define HAVE_CMOV and
2303 include i486 version.
2304 * sysdeps/i386/i486/pthread_spin_trylock.S: New file.
2305 * sysdeps/i386/i586/pthread_spin_trylock.S: New file.
c97c64de 2306 Patch by Marijn Ros <marijn@mad.scientist.com>.
69cae3cf 2307
e4044c01
UD
2308 * allocatestack.c (get_cached_stack): Don't crash if we first
2309 found a stack with a larger size then needed.
2310 Reported by Hui Huang <hui.huang@sun.com>.
2311
d82d5d12
UD
2312 * Makefile (tests): Add tst-sysconf.
2313 * tst-sysconf.c: New file.
2314
2315 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine
2316 PTHREAD_THREADS_MAX.
2317
fa9a4ff0
RM
23182002-12-02 Roland McGrath <roland@redhat.com>
2319
2320 * pthreadP.h (__stack_user, __nptl_create_event, __nptl_death_event):
2321 Declare using hidden_proto instead of attribute_hidden, so there are
2322 non-.hidden static symbols for gdb to find.
2323 (__pthread_keys): Likewise.
2324 * events.c (__nptl_create_event, __nptl_death_event): Add hidden_def.
2325 * allocatestack.c (__stack_user): Likewise.
2326 * pthread_create.c (__pthread_keys): Likewise.
2327 (__nptl_threads_events, __nptl_last_event): Make these static instead
2328 of hidden.
2329 * pthread_key_create.c (__pthread_pthread_keys_max,
2330 __pthread_pthread_key_2ndlevel_size): Renamed from __linuxthreads_*.
2331
91949a33
UD
23322002-12-02 Ulrich Drepper <drepper@redhat.com>
2333
c22b52fa
UD
2334 * Makefile (tests): Add tst-locale1. If buid-static is yes link
2335 statically.
2336 * tst-locale1.c: New file.
2337
beb6aa41
UD
2338 * pthread_cond_timedwait.c: Include <stdlib.h>.
2339
91949a33
UD
2340 * Makefile (tests): Add tst-fork2 and tst-fork3.
2341 * tst-fork2.c: New file.
2342 * tst-fork3.c: New file.
2343
654dff90
UD
23442002-11-28 Ulrich Drepper <drepper@redhat.com>
2345
cb0e76b4
UD
2346 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: New file.
2347
2348 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define macros which
2349 require it to 200112L.
2350
2351 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Use cmov
2352 instruction only if HAVE_CMOV is defined.
2353 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrwlock.S: Define HAVE_CMOV.
2354
975aa229
UD
2355 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: New file.
2356
654dff90
UD
2357 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: New file.
2358
2359 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: New file.
2360
2361 * sysdeps/unix/sysv/linux/x86_64/pt-vfork.S: New file.
2362
a3931336
UD
23632002-11-27 Ulrich Drepper <drepper@redhat.com>
2364
c10c099c
UD
2365 * sysdeps/x86_64/bits/atomic.h: New file.
2366
2367 * sysdeps/i386/i686/bits/atomic.h: Fix asm syntax for 8- and
2368 16-bit operations.
2369
dca99d27
UD
2370 * sysdeps/unix/sysv/linux/raise.c (raise): Use INTERNAL_SYSCALL if
2371 possible since gettid cannot fail.
2372
f78deea6
UD
2373 * sysdeps/x86_64/pthreaddef.h: New file.
2374
2375 * sysdeps/i386/pthreaddef.h (gettid): Removed.
2376
2377 * sysdeps/x86_64/pthread_spin_init.c: New file.
2378 * sysdeps/x86_64/pthread_spin_lock.c: New file.
2379 * sysdeps/x86_64/pthread_spin_trylock.c: New file.
2380 * sysdeps/x86_64/pthread_spin_unlock.c: New file.
2381
2382 * sysdeps/i386/i686/pthread_spin_trylock.S (pthread_spin_trylock):
2383 Add missing lock prefix. Minute optimization.
2384
2385 * tst-spin2.c (main): Also check successful trylock call.
2386
2387 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Use correct
2388 syscall. Fix typo in case INTERNAL_SYSCALL is not used.
2389
2390 * sysdeps/i386/pthread_spin_destroy.c: Moved to...
2391 * sysdeps/pthread/pthread_spin_destroy.c: ...here. New file.
2392
2393 * sysdeps/i386/pthread_sigmask.c: Removed. Use the generic code.
2394 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Return correct
2395 value in case of an error. Add support for INTERNAL_SYSCALL.
b54e18eb
UD
2396
2397 * sysdeps/i386/pthread_sigmask.c (pthread_sigmask): Return correct
2398 value in case of an error.
2399
a3931336
UD
2400 * sysdeps/x86_64/tls.h: New file.
2401
76a50749
UD
24022002-11-26 Ulrich Drepper <drepper@redhat.com>
2403
117c452c
UD
2404 * sysdeps/i386/tls.h (THREAD_GETMEM_NC): Change interface. It now
2405 takes the array member name and the index as parameters.
2406 (THREAD_SETMEM_NC): Likewise.
2407 * pthread_getspecific.c: Use new THREAD_GETMEM_NC interface.
2408 * pthread_setspecific.c: Use new THREAD_GETMEM_NC and THREAD_SETMEM_NC
2409 interfaces.
2410
2411 * sysdeps/i386/tls.h (THREAD_SETMEM): Use size of member element
2412 to decide which code to use.
2413 (THREAD_SETMEM_NC): Likewise.
2414
76a50749
UD
2415 * allocatestack.c (queue_stack): Don't remove stack from list here.
2416 Do it in the caller. Correct condition to prematurely terminate
2417 loop to free stacks.
2418 (__deallocate_stack): Remove stack from list here.
2419
24202002-11-26 Ulrich Drepper <drepper@redhat.com>
2421
2422 * Makefile (tests): Add tst-stack1.
2423 * tst-stack1.c: New file.
2424
2425 * allocatestack.c (allocate_stack): Initialize the TCB on a user
2426 provided stack.
2427
2428 * pthread_attr_getstack.c: Return bottom of the thread area.
2429
24302002-11-25 Ulrich Drepper <drepper@redhat.com>
2431
2432 * Makefile (libpthread-routines): Add pt-allocrtsig and
2433 pthread_kill_other_threads.
2434 * pt-allocrtsig.c: New file.
2435 * pthread_kill_other_threads.c: New file.
2436 * sysdeps/unix/sysv/linux/allocrtsig.c: Add additional aliases for
2437 all three functions.
2438 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
2439 allocrtsig.
2440 * sysdeps/unix/sysv/linux/Versions (libc:GLIBC_PRIVATE): Export
2441 __libc_current_sigrtmin_private, __libc_current_sigrtmax_private,
2442 and __libc_allocate_rtsig_private.
2443 * Versions (libpthread): Export pthread_kill_other_threads_np,
2444 __libc_current_sigrtmin, and __libc_current_sigrtmax.
2445
24462002-11-24 Ulrich Drepper <drepper@redhat.com>
2447
2448 * allocatestack.c (allocate_stack): stackaddr in attribute points to
2449 the end of the stack. Adjust computations.
2450 When mprotect call fails dequeue stack and free it.
2451 * pthread_attr_setstack.c: Store top of the stack in stackaddr
2452 attribute.
2453 * pthread_getattr_np.c: Likewise.
2454
2455 * descr.h (IS_DETACHED): Add some more parenthesis to prevent
2456 surprises.
2457
24582002-11-23 Ulrich Drepper <drepper@redhat.com>
2459
2460 * sysdeps/pthread/pthread.h (pthread_self): __THROW must come before
2461 attribute definitions. Patch by Luca Barbieri <ldb@ldb.ods.org>.
2462
24632002-11-22 Ulrich Drepper <drepper@redhat.com>
2464
2465 * pthread_getspecific.c: Optimize access to first 2nd-level array.
2466 * pthread_setspecific.c: Likewise.
2467
24682002-11-21 Ulrich Drepper <drepper@redhat.com>
2469
2470 * sysdeps/unix/sysv/linux/i386/createthread.c: Remove CLONE_ flags
2471 definitions. Get them from the official place.
2472 * sysdeps/unix/sysv/linux/i386/fork.c: Likewise.
2473
2474 * sysdeps/unix/sysv/linux/i386/createthread.c: Update CLONE_* flags.
2475 Use new CLONE_ flags in clone() calls.
2476
2477 * sysdeps/unix/sysv/linux/fork.c: Use ARCH_FORK to actually fork.
2478 * sysdeps/unix/sysv/linux/i386/fork.c: New file.
2479
2480 * Versions: Add pthread_* functions for libc.
2481 * forward.c: New file.
2482
2483 * sysdeps/pthread/Makefile (libpthread-sysdeps_routines): Add
2484 errno-loc.
2485 * herrno.c: New file.
2486 * res.c: New file.
2487
2488 * Makefile (libpthread-routines): Remove sem_post, sem_wait,
2489 sem_trywait, and sem_timedwait. Add herrno and res.
2490 * sem_init.c: Don't initialize lock and waiters members.
2491 * sem_open.c: Likewise.
2492 * sem_post.c: Removed.
2493 * sem_wait.c: Removed.
2494 * sem_trywait.c: Removed.
2495 * sem_timedwait.c: Removed.
2496 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Complete rewrite.
2497 Includes full implementations of sem_post, sem_wait, sem_trywait,
2498 and sem_timedwait.
2499 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Adjust
2500 for new implementation.
2501 * sysdeps/unix/sysv/linux/internaltypes.h (struct sem): Remove lock
2502 and waiters fields.
2503
2504 * tst-sem3.c: Improve error message.
2505 * tst-signal3.c: Likewise.
2506
2507 * init.c (__pthread_initialize_minimal): Use set_tid_address syscall
2508 to tell the kernel about the termination futex and to initialize tid
2509 member. Don't initialize main_thread.
2510 * descr.h (struct pthread): Remove main_thread member.
2511 * cancelllation.c (__do_cancel): Remove code handling main thread.
2512 The main thread is not special anymore.
2513
2514 * allocatestack.c (__reclaim_stacks): Mark stacks as unused. Add
2515 size of the stacks to stack_cache_actsize.
2516
2517 * pt-readv.c: Add missing "defined".
2518 * pt-sigwait.c: Likewise.
2519 * pt-writev.c: Likewise.
2520
25212002-11-09 Ulrich Drepper <drepper@redhat.com>
2522
2523 * Versions: Export __connect from libpthread.
2524 Patch by Luca Barbieri <ldb@ldb.ods.org>.
2525
2526 * Makefile (libpthread-routines): Add pt-raise.
2527 * sysdeps/unix/sysv/linux/raise.c: New file.
2528 * sysdeps/unix/sysv/linux/pt-raise.c: New file.
2529 * sysdeps/generic/pt-raise.c: New file.
2530
2531 * pthread_cond_init.c: Initialize all data elements of the condvar
2532 structure. Patch by Luca Barbieri <ldb@ldb.ods.org>.
2533
2534 * pthread_attr_init.c: Actually implement 2.0 compatibility version.
2535 * pthread_create.c: Likewise.
2536
2537 * Makefile (tests): Add tst-key1, tst-key2, tst-key3.
2538 * tst-key1.c: New file.
2539 * tst-key2.c: New file.
2540 * tst-key3.c: New file.
2541
2542 * Versions: Export pthread_detach for version GLIBC_2.0.
2543 Reported by Saurabh Desai <sdesai@austin.ibm.com>.
2544
25452002-11-08 Ulrich Drepper <drepper@redhat.com>
2546
2547 * pthread_key_create.c: Terminate search after an unused key was found.
2548 Patch by Luca Barbieri <ldb@ldb.ods.org>.
2549
2550 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Return zero.
2551 Patch by Luca Barbieri <ldb@ldb.ods.org>.
2552
25532002-10-10 Ulrich Drepper <drepper@redhat.com>
2554
2555 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Use slow generic
2556 dynamic lookup for errno in PIC.
2557
2558 * allocatestack.c (get_cached_stack): Rearrange code slightly to
2559 release the stack lock as soon as possible.
2560 Call _dl_allocate_tls_init for TCB from the cache to re-initialize
2561 the static TLS block.
2562 (allocate_stack): Call _dl_allocate_tls_init for user-provided stack.
2563
2564 * cancellation.c: Renamed from cancelation.c.
2565 * Makefile: Adjust accordingly.
2566 * pthreadP.h (CANCELLATION_P): Renamed from CANCELATION_P.
2567 * cleanup_defer.c: Use CANCELLATION_P.
2568 * pthread_testcancel.c: Likewise.
2569 * descr.h: Fix spelling in comments.
2570 * init.c: Likewise.
2571 * pthread_getattr_np.c: Likewise.
2572 * pthread_getschedparam.c: Likewise.
2573 * pthread_setschedparam.c: Likewise.
2574 * Versions: Likewise.
2575
2576 * pt-pselect.c: New file.
2577 * Makefile (libpthread-routines): Add pt-pselect.
2578 * Versions: Add pselect.
2579
2580 * tst-cancel4.c: New file.
2581 * Makefile (tests): Add tst-cancel4.
2582
25832002-10-09 Ulrich Drepper <drepper@redhat.com>
2584
2585 * pthread_mutex_lock.c: Always record lock ownership.
2586 * pthread_mutex_timedlock.c: Likewise.
2587 * pthread_mutex_trylock.c: Likewise.
2588
2589 * pt-readv.c: New file.
2590 * pt-writev.c: New file.
2591 * pt-creat.c: New file.
2592 * pt-msgrcv.c: New file.
2593 * pt-msgsnd.c: New file.
2594 * pt-poll.c: New file.
2595 * pt-select.c: New file.
2596 * pt-sigpause.c: New file.
2597 * pt-sigsuspend.c: New file.
2598 * pt-sigwait.c: New file.
2599 * pt-sigwaitinfo.c: New file.
2600 * pt-waitid.c: New file.
2601 * Makefile (libpthread-routines): Add pt-readv, pt-writev, pt-creat,
2602 pt-msgrcv, pt-msgsnd, pt-poll, pt-select, pt-sigpause, pt-sigsuspend,
2603 pt-sigwait, pt-sigwaitinfo, and pt-waitid.
2604 * Versions: Add all the new functions.
2605
2606 * tst-exit1.c: New file.
2607 * Makefile (tests): Add tst-exit1.
2608
2609 * sem_timedwait.c: Minor optimization for more optimal fastpath.
2610
26112002-10-08 Ulrich Drepper <drepper@redhat.com>
2612
2613 * pt-fcntl.c: Only enable asynchronous cancellation for F_SETLKW.
2614
2615 * pthread_join.c: Enable asynchronous cancellation around lll_wait_tid
2616 call. pthread_join is an official cancellation point.
2617 * pthread_timedjoin.c: Likewise.
2618
2619 * pthread_cond_wait.c: Revert order in which internal lock are dropped
2620 and the condvar's mutex are retrieved.
2621 * pthread_cond_timedwait.c: Likewise.
2622 Reported by dice@saros.East.Sun.COM.
2623
26242002-10-07 Ulrich Drepper <drepper@redhat.com>
2625
2626 * pthreadP.h: Cut out all type definitions and move them...
2627 * sysdeps/unix/sysv/linux/internaltypes.h: ...here. New file.
2628 * pthreadP.h: Include <internaltypes.h>.
2629
2630 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Little
2631 performance tweaks.
2632
2633 * sem_trywait.c: Shuffle #includes around to get right order.
2634 * sem_timedwait.c: Likewise.
2635 * sem_post.c: Likewise.
2636 * sem_wait.c: Likewise.
2637
2638 * nptl 0.3 released.
2639
2640 * Makefile (tests): Add tst-signal3.
2641 * tst-signal3.c: New file.
2642
26432002-10-05 Ulrich Drepper <drepper@redhat.com>
2644
2645 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Tell the compiler that
2646 the asms modify the sem object.
2647 (__lll_sem_timedwait): Now takes struct sem* as first parameter.
2648
2649 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h (sem_t): Don't expose
2650 the actual members.
2651 * pthreadP.h (struct sem): New type. Actual semaphore type.
2652 * semaphoreP.h: Include pthreadP.h.
2653 * sem_getvalue.c: Adjust to sem_t change.
2654 * sem_init.c: Likewise.
2655 * sem_open.c: Likewise.
2656 * sem_post.c: Likewise.
2657 * sem_timedwait.c: Likewise.
2658 * sem_trywait.c: Likewise.
2659 * sem_wait.c: Likewise.
2660
26612002-10-04 Ulrich Drepper <drepper@redhat.com>
2662
2663 * Makefile (tests): Add tst-basic2, tst-exec1, tst-exec3, tst-exec3.
2664 * tst-basic2.c: New file.
2665 * tst-exec1.c: New file.
2666 * tst-exec2.c: New file.
2667 * tst-exec3.c: New file.
2668
2669 * tst-fork1.c: Remove extra */.
2670
2671 * nptl 0.2 released. The API for IA-32 is complete.
This page took 0.368704 seconds and 5 git commands to generate.