]> git.ipfire.org Git - thirdparty/glibc.git/blame - nptl/ChangeLog
Update.
[thirdparty/glibc.git] / nptl / ChangeLog
CommitLineData
f077a4a9
UD
12002-12-17 Jakub Jelinek <jakub@redhat.com>
2
3 * Makefile (libpthread-shared-only-routines): Add pt-allocrtsig.
4 (tests): Depend on $(objpfx)tst-cancel-wrappers.out.
5 ($(objpfx)tst-cancel-wrappers.out): New rule.
6 * tst-cancel-wrappers.sh: New test.
7 * tst-locale1.c: Include signal.h.
8 (uselocale): Test static linking of __libc_current_sigrt*.
9
102002-12-17 Ulrich Drepper <drepper@redhat.com>
11
12 * Makefile (tests): Add tst-cancel6.
13 * tst-cancel6.c: New file
14
bd499a3b
UD
152002-12-17 Jakub Jelinek <jakub@redhat.com>
16
17 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h (SINGLE_THREAD_P):
18 Define meaningfully for assembler as well.
19 * pthreadP.h (struct pthread_functions): Remove
20 ptr_pthread_attr_init field. Add ptr_pthread_attr_init_2_0
21 and ptr_pthread_attr_init_2_1 fields.
22 * init.c (pthread_functions): Initialize ptr_pthread_attr_init_2_0
23 and ptr_pthread_attr_init_2_1 instead of ptr_pthread_attr_init.
24 * forward.c (FORWARD4): Renamed from FORWARD3. Add export argument.
25 (FORWARD3): Define using FORWARD4.
26 (pthread_attr_init): Provide both @GLIBC_2.0 and @@GLIBC_2.1
27 versions.
28 * pt-system.c: Remove duplicate stdlib.h include.
29
0a1063f4
UD
302002-12-16 Ulrich Drepper <drepper@redhat.com>
31
87d60668
UD
32 * sem_init.c: Define sem_init@GLIBC_2.0.
33 * sem_destroy.c: Define sem_destroy@GLIBC_2.0.
34 * sem_getvalue.c: Define sem_getvalue@GLIBC_2.0.
35
0a1063f4
UD
36 * flockfile.c: Moved to...
37 * sysdeps/pthread/flockfile.c: ...here. New file.
38 * funlockfile.c: Moved to...
39 * sysdeps/pthread/funlockfile.c: ...here. New file.
40 * ftrylockfile.c: Moved to...
41 * sysdeps/pthread/ftrylockfile.c: ...here. New file.
42
9634cf9d
UD
432002-12-16 Jakub Jelinek <jakub@redhat.com>
44
45 * libc-cancellation.c: Guard both function with
46 #if !defined NOT_IN_libc.
47 * Makefile (libpthread-routines): Use ptw-, not pt- prefix for the
48 automatically provided pthread wrappers.
49 * pthreadP.h (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): Define to
50 CANCEL_* if IS_IN_libpthread and to dummy versions if not in libc
51 nor in libpthread.
52 * pt-open.c: Removed.
53 * pt-fcntl.c: Removed.
54 * pt-fsync.c: Removed.
55 * pt-lseek.c: Removed.
56 * pt-msgrcv.c: Removed.
57 * pt-msgsnd.c: Removed.
58 * pt-msync.c: Removed.
59 * pt-nanosleep.c: Removed.
60 * pt-open64.c: Removed.
61 * pt-pause.c: Removed.
62 * pt-pread.c: Removed.
63 * pt-pread64.c: Removed.
64 * pt-pwrite.c: Removed.
65 * pt-pwrite64.c: Removed.
66 * pt-read.c: Removed.
67 * pt-recv.c: Removed.
68 * pt-recvfrom.c: Removed.
69 * pt-recvmsg.c: Removed.
70 * pt-send.c: Removed.
71 * pt-sendto.c: Removed.
72 * pt-sigtimedwait.c: Removed.
73 * pt-sigwait.c: Removed.
74 * pt-wait.c: Removed.
75 * pt-waitpid.c: Removed.
76 * pt-write.c: Removed.
77 * pt-accept.c: Removed.
78 * pt-close.c: Removed.
79 * pt-connect.c: Removed.
80 * pt-lseek64.c: Removed.
81 * pt-sendmsg.c: Removed.
82 * pt-tcdrain.c: Removed.
83
6ee8d334
UD
842002-12-15 Ulrich Drepper <drepper@redhat.com>
85
81fa9371
UD
86 * init.c (__pthread_initialize_minimal_internal): Renamed from
87 __pthread_initialize_minimal. Make old name an alias. This
88 converts a normal relocation into a relative relocation.
89
f3015aa5
UD
90 * pt-fcntl.c (__fcntl): Use fcntl64 syscall, not fcntl.
91
4cbc1950
UD
92 * Versions [libpthread: GLIBC_2.3.2]: Remove creat, poll, pselect,
93 readv, select, sigpause, sigsuspend, sigwaitinfo, waitid, writev.
94 * Makefile (libpthread-routines): Remove pt-creat, pt-poll,
95 pt-pselect, pt-readv, pt-select, pt-sigpause, pt-sigsuspend,
96 pt-sigwaitinfo, pt-waitid, and pt-writev.
97 * pt-creat.c: Removed.
98 * pt-poll.c: Removed.
99 * pt-pselect.c: Removed.
100 * pt-readv.c: Removed.
101 * pt-select.c: Removed.
102 * pt-sigpause.c: Removed.
103 * pt-sigsuspend.c: Removed.
104 * pt-sigwaitinfo.c: Removed.
105 * pt-waitid.c: Removed.
106 * pt-writev.c: Removed.
107
8454830b
UD
108 * init.c (pthread_functions): New variable.
109 (__pthread_initialize_minimal): Pass pointer to pthread_functions
110 (or NULL) to __libc_pthread_init.
111 * forward.c: Rewrite to use __libc:pthread_functions array to get
112 function addresses.
113 * sysdeps/unix/sysv/linux/fork.h: Remove __libc_pthread_init
114 prototype.
115 * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init):
116 Take new parameter. Copy content of variable pointed to by it
117 to __libc_pthread_init.
118
119 * pthreadP.h (struct pthread_functions): New type.
120 (__libc_pthread_init): Declare.
121
122 * pthread_attr_destroy.c: Add namespace protected alias.
123 * pthread_attr_getdetachstate.c: Likewise.
124 * pthread_attr_getinheritsched.c: Likewise.
125 * pthread_attr_getschedparam.c: Likewise.
126 * pthread_attr_getschedpolicy.c: Likewise.
127 * pthread_attr_getscope.c: Likewise.
128 * pthread_attr_setdetachstate.c: Likewise.
129 * pthread_attr_setinheritsched.c: Likewise.
130 * pthread_attr_setschedparam.c: Likewise.
131 * pthread_attr_setschedpolicy.c: Likewise.
132 * pthread_attr_setscope.c: Likewise.
133 * pthread_cond_broadcast.c: Likewise.
134 * pthread_cond_destroy.c: Likewise.
135 * pthread_cond_init.c: Likewise.
136 * pthread_cond_signal.c: Likewise.
137 * pthread_cond_wait.c: Likewise.
138 * pthread_condattr_destroy.c: Likewise.
139 * pthread_condattr_init.c: Likewise.
140 * pthread_equal.c: Likewise.
141 * pthread_exit.c: Likewise.
142 * pthread_getschedparam.c: Likewise.
143 * pthread_self.c: Likewise.
144 * pthread_setcancelstate.c: Likewise.
145 * pthread_setschedparam.c: Likewise.
146 * pthread_mutex_destroy.c: Likewise.
147 * pthread_mutex_init.c: Likewise.
148 * pthreadP.h: Add prototypes for the aliases.
149
0d5f4929
UD
150 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Set
151 multiple_threads member in correct TCB to 1.
152
6ee8d334
UD
153 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: Define
154 SINGLE_THREAD_P. If in libc or libpthread examine multiple_thread
155 member of thread decriptor, otherwise return unconditionally 1.
156
2fb6444d
UD
1572002-12-14 Ulrich Drepper <drepper@redhat.com>
158
159 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Changes folded into the
160 regular Linux version. Remove file.
161 * sysdeps/unix/sysv/linux/connect.S: Likewise. Remove file.
162 * sysdeps/unix/sysv/linux/llseek.c: Likewise. Remove file.
163 * sysdeps/unix/sysv/linux/msgrcv.c: Likewise. Remove file.
164 * sysdeps/unix/sysv/linux/msgsnd.c: Likewise. Remove file.
165 * sysdeps/unix/sysv/linux/open64.c: Likewise. Remove file.
166 * sysdeps/unix/sysv/linux/poll.c: Likewise. Remove file.
167 * sysdeps/unix/sysv/linux/pread.c: Likewise. Remove file.
168 * sysdeps/unix/sysv/linux/pread64.c: Likewise. Remove file.
169 * sysdeps/unix/sysv/linux/pselect.c: Likewise. Remove file.
170 * sysdeps/unix/sysv/linux/pwrite.c: Likewise. Remove file.
171 * sysdeps/unix/sysv/linux/pwrite64.c: Likewise. Remove file.
172 * sysdeps/unix/sysv/linux/readv.c: Likewise. Remove file.
173 * sysdeps/unix/sysv/linux/recv.S: Likewise. Remove file.
174 * sysdeps/unix/sysv/linux/recvfrom.S: Likewise. Remove file.
175 * sysdeps/unix/sysv/linux/recvmsg.S: Likewise. Remove file.
176 * sysdeps/unix/sysv/linux/send.S: Likewise. Remove file.
177 * sysdeps/unix/sysv/linux/sendmsg.S: Likewise. Remove file.
178 * sysdeps/unix/sysv/linux/sendto.S: Likewise. Remove file.
179 * sysdeps/unix/sysv/linux/sigpause.c: Likewise. Remove file.
180 * sysdeps/unix/sysv/linux/sigsuspend.c: Likewise. Remove file.
181 * sysdeps/unix/sysv/linux/sigtimedwait.c: Likewise. Remove file.
182 * sysdeps/unix/sysv/linux/sigwait.c: Likewise. Remove file.
183 * sysdeps/unix/sysv/linux/sigwaitinfo.c: Likewise. Remove file.
184 * sysdeps/unix/sysv/linux/system.c: Likewise. Remove file.
185 * sysdeps/unix/sysv/linux/tcdrain.c: Likewise. Remove file.
186 * sysdeps/unix/sysv/linux/wait.c: Likewise. Remove file.
187 * sysdeps/unix/sysv/linux/waitid.c: Likewise. Remove file.
188 * sysdeps/unix/sysv/linux/waitpid.c: Likewise. Remove file.
189 * sysdeps/unix/sysv/linux/writev.c: Likewise. Remove file.
190 * sysdeps/unix/sysv/linux/i386/fcntl.c: Likewise. Remove file.
191
86b2dc40
UD
1922002-12-14 Jakub Jelinek <jakub@redhat.com>
193
194 * sysdeps/unix/sysv/linux/i386/sysdep-cancel.h: New file.
195 * sysdeps/unix/sysv/linux/open.c: Removed.
196 * sysdeps/unix/sysv/linux/fsync.c: Removed.
197 * sysdeps/unix/sysv/linux/lseek.c: Removed.
198 * sysdeps/unix/sysv/linux/msync.c: Removed.
199 * sysdeps/unix/sysv/linux/read.c: Removed.
200 * sysdeps/unix/sysv/linux/close.c: Removed.
201 * sysdeps/unix/sysv/linux/creat.c: Removed.
202 * sysdeps/unix/sysv/linux/nanosleep.c: Removed.
203 * sysdeps/unix/sysv/linux/pause.c: Removed.
204 * sysdeps/unix/sysv/linux/select.c: Removed.
205 * sysdeps/unix/sysv/linux/write.c: Removed.
206
9d263d72
UD
2072002-12-14 Ulrich Drepper <drepper@redhat.com>
208
209 * sysdeps/unix/sysv/linux/i386/pt-socket.S: Check multiple_threads
210 element in TCB to see whether locking is needed.
211
212 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Check that
213 MULTIPLE_THREADS_OFFSET value is correct.
214
215 * sysdeps/unix/sysv/linux/close.c: New file.
216 * sysdeps/unix/sysv/linux/connect.S: New file.
217 * sysdeps/unix/sysv/linux/creat.c: New file.
218 * sysdeps/unix/sysv/linux/fsync.c: New file.
219 * sysdeps/unix/sysv/linux/llseek.c: New file.
220 * sysdeps/unix/sysv/linux/lseek.c: New file.
221 * sysdeps/unix/sysv/linux/msgrcv.c: New file.
222 * sysdeps/unix/sysv/linux/msgsnd.c: New file.
223 * sysdeps/unix/sysv/linux/msync.c: New file.
224 * sysdeps/unix/sysv/linux/nanosleep.c: New file.
225 * sysdeps/unix/sysv/linux/open.c: New file.
226 * sysdeps/unix/sysv/linux/open64.c: New file.
227 * sysdeps/unix/sysv/linux/pause.c: New file.
228 * sysdeps/unix/sysv/linux/poll.c: New file.
229 * sysdeps/unix/sysv/linux/pread.c: New file.
230 * sysdeps/unix/sysv/linux/pread64.c: New file.
231 * sysdeps/unix/sysv/linux/pselect.c: New file.
232 * sysdeps/unix/sysv/linux/pwrite.c: New file.
233 * sysdeps/unix/sysv/linux/pwrite64.c: New file.
234 * sysdeps/unix/sysv/linux/readv.c: New file.
235 * sysdeps/unix/sysv/linux/recv.S: New file.
236 * sysdeps/unix/sysv/linux/recvfrom.S: New file.
237 * sysdeps/unix/sysv/linux/recvmsg.S: New file.
238 * sysdeps/unix/sysv/linux/select.c: New file.
239 * sysdeps/unix/sysv/linux/send.S: New file.
240 * sysdeps/unix/sysv/linux/sendmsg.S: New file.
241 * sysdeps/unix/sysv/linux/sendto.S: New file.
242 * sysdeps/unix/sysv/linux/sigpause.c: New file.
243 * sysdeps/unix/sysv/linux/sigsuspend.c: New file.
244 * sysdeps/unix/sysv/linux/sigtimedwait.c: New file.
245 * sysdeps/unix/sysv/linux/sigwait.c: New file.
246 * sysdeps/unix/sysv/linux/sigwaitinfo.c: New file.
247 * sysdeps/unix/sysv/linux/system.c: New file.
248 * sysdeps/unix/sysv/linux/tcdrain.c: New file.
249 * sysdeps/unix/sysv/linux/wait.c: New file.
250 * sysdeps/unix/sysv/linux/waitid.c: New file.
251 * sysdeps/unix/sysv/linux/waitpid.c: New file.
252 * sysdeps/unix/sysv/linux/writev.c: New file.
253 * sysdeps/unix/sysv/linux/i386/fcntl.c: New file.
254
255 * pt-readv.c: Fix comment.
256
2572002-12-14 Jakub Jelinek <jakub@redhat.com>
258
259 * tst-cleanup1.c: Include stdlib.h.
260
261 * tst-cancel5.c: New test.
262 * Makefile (tests): Add tst-cancel5.
263 (tst-cancel5): Link against libc.so libpthread.so in that order.
264
9ae0909b
UD
2652002-12-13 Ulrich Drepper <drepper@redhat.com>
266
b7bdd9c4
UD
267 * forward.c (test_loaded): Prevent recursive calls.
268
9ae0909b
UD
269 * Makefile (routines): Add libc-cancellation.
270 * libc-cancellation.c: New file.
271 * descr.h (struct pthread): Add multiple_threads field.
272 * allocatestack.c (allocate_stack): Initialize multiple_header field of
273 new thread descriptor to 1.
274 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread):
275 Initialize multiple_thread field after successful thread creation.
276 * cancellation.c (__do_cancel): Move to pthreadP.h.
277 (__pthread_enable_asynccancel): Remove parameter from __do_cancel call.
278 (__pthread_disable_asynccancel): Add internal_function attribute.
279 * init.c (sigcancel_handler): Remove parameter from __do_cancel call.
280 * pthread_setcancelstate.c: Likewise.
281 * pthread_setcanceltype.c: Likewise.
282 * pthread_exit.c: Likewise.
283 * pthreadP.h (CANCELLATION_P): Likewise.
284 (__do_cancel): Define as static inline.
285 (LIBC_CANCEL_ASYNC, LIBC_CANCEL_RESET): New #defines.
286 (__libc_enable_asynccancel, __libc_disable_asynccancel): New
287 declarations.
288 * sysdeps/i386/tls.h (tcbhead_t): Add list and multiple_threads
289 fields. Define MULTIPLE_THREADS_OFFSET.
290 * sysdeps/pthread/bits/libc-lock.h: Remove __libc_locking_needed
291 declaration.
292 * sysdeps/unix/sysv/linux/accept.S: New file.
293 * sysdeps/unix/sysv/linux/read.c: New file.
294 * sysdeps/unix/sysv/linux/write.c: New file.
295 * sysdeps/unix/sysv/linux/i386/pt-socket.S: New file.
296 * sysdeps/unix/sysv/linux/libc_pthread_init.c: Remove definition and
297 initialization of __libc_locking_needed.
298 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Don't use
299 __libc_locking_needed, use multiple_threads field in TCB.
300 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
301
22f20674
UD
3022002-12-12 Ulrich Drepper <drepper@redhat.com>
303
2ad2e1e7
UD
304 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: Use i486
305 version.
306 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: Likewise.
307
22f20674
UD
308 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Correct
309 access to __libc_locking_needed for PIC.
310
aa80bf86
UD
3112002-12-12 Jakub Jelinek <jakub@redhat.com>
312
313 * sysdeps/pthread/bits/libc-lock.h (__libc_locking_needed): Only
314 declare for libc.so.
315 (__libc_lock_init, __libc_lock_init_recursive): Change into comma
316 expression.
317 (__libc_lock_lock): Put into statement expression.
318 (__libc_lock_unlock): Remove trailing semicolon.
319 * sysdeps/unix/sysv/linux/fork.h (__libc_pthread_init): Fix typo.
320
24021373
RM
3212002-12-12 Roland McGrath <roland@redhat.com>
322
323 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use asm operand with
324 "m" constraint to refer to __libc_locking_needed. Declare it here.
325
14e7aece
UD
3262002-12-12 Ulrich Drepper <drepper@redhat.com>
327
328 * sysdeps/unix/sysv/linux/fork-gen.c: Renamed to...
329 * sysdeps/unix/sysv/linux/libc_pthread_init.c: ...this.
330 Initialize __libc_locking_needed.
331 * init.c (__pthread_initialize_minimal): Call __libc_pthread_init
332 instead of __register_pthread_fork_handler.
333 * sysdeps/pthread/bits/libc-lock.h: Declare __libc_locking_needed.
334 * sysdeps/unix/sysv/linux/Makefile (sysdep_routimes): Replace
335 fork-gen with libc_pthread_init.
336 * sysdeps/unix/sysv/linux/Versions: Use __libc_pthread_init instead
337 of __register_pthread_fork_handler.
338 * sysdeps/unix/sysv/linux/fork.h: Declare __libc_pthread_init instead
339 of __register_pthread_fork_handler.
340 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Use
341 __libc_locking_needed to determine whether lock prefix can be avoided.
342 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: Likewise.
343
85631c8e
UD
3442002-12-11 Ulrich Drepper <drepper@redhat.com>
345
da63009e
UD
346 * Makefile (tests): Add tst-cleanup1.
347 * tst-cleanup1.c: New file.
348 * cancellation.c (__cleanup_thread): Removed.
349 (__do_cancel): Remove call to __cleanup_thread.
350 * pthreadP.h: Remove __cleanup_thread prorotype.
351
000160a2
UD
352 * sysdeps/pthread/bits/libc-lock.h (__libc_cleanup_region_start):
353 Remember function and argument even if cancellation handler
354 function is not available.
355 (__libc_cleanup_region_end): Execute registered function directly if
356 pthread functions are not available.
357 (__libc_cleanup_end): Likewise.
358
85631c8e
UD
359 * init.c (__pthread_initialize_minimal): Fix initialization in
360 static lib by preventing gcc from being too clever.
361
dce8f2b6
UD
3622002-12-10 Ulrich Drepper <drepper@redhat.com>
363
34a075be
UD
364 * init.c (__pthread_initialize_minimal): Remove unneccesary
365 sigaddset call.
366
dce8f2b6
UD
367 * Makefile (tests): We can run tst-locale2 now.
368
e5e45b53
UD
3692002-12-09 Ulrich Drepper <drepper@redhat.com>
370
371 * Versions: Remove duplicated sigwait entry.
372
bdb04f92
UD
3732002-12-08 Ulrich Drepper <drepper@redhat.com>
374
1e506629
UD
375 * pthreadP.h: Enable pthread_cleanup_{push,pop} optimizations only
376 inside libpthread.
377
a3957dd5
UD
378 * pt-fcntl.c (__fcntl): Initialize oldtype to avoid warning.
379
bdb04f92
UD
380 * pthreadP.h: Declare __pthread_enable_asynccancel and
381 __pthread_disable_asynccancel.
382 (CANCEL_ASYNC): Use __pthread_enable_asynccancel.
383 (CANCEL_RESET): Use __pthread_disable_asynccancel.
384 * cancellation.c (__pthread_enable_asynccancel): New function.
385 (__pthread_disable_asynccancel): New function.
386 * pt-accept.c: Adjust for CANCEL_ASYNC and CANCEL_RESET change.
387 * pt-close.c: Likewise.
388 * pt-connect.c: Likewise.
389 * pt-creat.c: Likewise.
390 * pt-fcntl.c: Likewise.
391 * pt-fsync.c: Likewise.
392 * pt-lseek.c: Likewise.
393 * pt-lseek64.c: Likewise.
394 * pt-msgrcv.c: Likewise.
395 * pt-msgsnd.c: Likewise.
396 * pt-msync.c: Likewise.
397 * pt-nanosleep.c: Likewise.
398 * pt-open.c: Likewise.
399 * pt-open64.c: Likewise.
400 * pt-pause.c: Likewise.
401 * pt-poll.c: Likewise.
402 * pt-pread.c: Likewise.
403 * pt-pread64.c: Likewise.
404 * pt-pselect.c: Likewise.
405 * pt-pwrite.c: Likewise.
406 * pt-pwrite64.c: Likewise.
407 * pt-read.c: Likewise.
408 * pt-readv.c: Likewise.
409 * pt-recv.c: Likewise.
410 * pt-recvfrom.c: Likewise.
411 * pt-recvmsg.c: Likewise.
412 * pt-select.c: Likewise.
413 * pt-send.c: Likewise.
414 * pt-sendmsg.c: Likewise.
415 * pt-sendto.c: Likewise.
416 * pt-sigpause.c: Likewise.
417 * pt-sigsuspend.c: Likewise.
418 * pt-sigtimedwait.c: Likewise.
419 * pt-sigwait.c: Likewise.
420 * pt-sigwaitinfo.c: Likewise.
421 * pt-system.c: Likewise.
422 * pt-tcdrain.c: Likewise.
423 * pt-wait.c: Likewise.
424 * pt-waitid.c: Likewise.
425 * pt-waitpid.c: Likewise.
426 * pt-write.c: Likewise.
427 * pt-writev.c: Likewise.
a3957dd5
UD
428 * pthread_join.c: Likewise.
429 * pthread_timedjoin.c: Likewise.
bdb04f92
UD
430
431 * pt-sigpause.c (sigsuspend): Call __sigsuspend.
432 (__xpg_sigpause): New function.
433 * Versions (libpthread:GLIBC_2.3.2): Add __xpg_sigpause.
434
6ccb3834
UD
4352002-12-07 Ulrich Drepper <drepper@redhat.com>
436
09efc3ba
UD
437 * Makefile (CFLAGS-ftrylockfile.c): Add -D_IO_MTSAFE_IO.
438
439 * cleanup.c: Move declarations of _GI_pthread_cleanup_push and
440 _GI_pthread_cleanup_pop to pthreadP.h.
441
442 * ftrylockfile.c: Use _IO_lock_trylock instead of
443 pthread_mutex_trylock.
444
445 * pthreadP.h (CANCEL_ASYNC): Use __pthread_setcanceltype.
446 (CANCEL_RESET): Likewise.
447 (__pthread_setcanceltype_): Declare.
448 (__pthread_mutex_lock_internal): Declare.
449 (__pthread_mutex_unlock_internal): Declare.
450 (__pthread_once_internal): Declare.
451 (pthread_cleanup_push): Redefine using _GI_pthread_cleanup_push.
452 (pthread_cleanup_pop): Redefine using _GI_pthread_cleanup_pop.
453
454 * pthread_cond_timedwait.c: Use INTUSE is calls to pthread_mutex_lock
455 and pthread_mutex_unlock.
456 * pthread_cond_wait.c: Likewise.
457 * pthread_mutex_lock.c: Use INTDEF to define alias if needed.
458 * pthread_mutex_unlock.c: Likewise.
459
460 * pthread_setcanceltype.c: Add additional alias
461 __pthread_setcanceltype.
462
463 * sem_unlink.c (sem_unlink): Use __pthread_once with INTDEF.
464 * sem_open.c (sem_open): Likewise.
465 Use __libc_open, __libc_write, and __libc_close instead of
466 open, write, and close respectively.
467
468 * sysdeps/pthread/bits/libc-lock.h (__libc_lock_trylock_internal):
469 Rewrite as statement expression since it must return a value.
470
471 * pthread_cancel.c: Use __pthread_kill instead of pthread_kill.
472 * sysdeps/unix/sysv/linux/pthread_kill.c: Define additional alias
473 __pthread_kill.
474
475 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Define additional
476 alias __pthread_once_internal.
477
6ccb3834
UD
478 * sysdeps/unix/sysv/linux/raise.c: Use libc_hidden_def for raise.
479
d3c9f895
UD
4802002-12-06 Ulrich Drepper <drepper@redhat.com>
481
4614167a
UD
482 * Makefile (tests): Add tst-stdio1 and tst-stdio2.
483 * tst-stdio1.c: New file.
484 * tst-stdio2.c: New file.
485
a4548cea
UD
486 * init.c (__pthread_initialize_minimal): Correct INIT_LIST_HEAD use.
487
d3c9f895
UD
488 * Makefile (tests): Comment out tst-locale2 for now.
489 (CFLAGS-flockfile.c, CFLAGS-funlockfile.c): Define to -D_IO_MTSAFE_IO.
490
491 * sysdeps/unix/sysv/linux/Makefile: Define CFLAGS-fork.c to
492 -D_IO_MTSAFE_IO.
493 * sysdeps/unix/sysv/linux/fork.c: Include <bits/stdio-lock.h>.
494 Use _IO_lock_init instead of explicit assignment.
495
496 * sysdeps/pthread/bits/libc-lock.h: Define __rtld_lock_* macros.
497 Define __libc_lock_* and __libc_lock_recursive macros with
498 lowlevellock macros, not pthread mutexes.
499
500 * flockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_lock instead
501 of pthread_mutex_lock.
502 * funlockfile.c: Include <bits/stdio-lock.h>. Use _IO_lock_unlock
503 instead of pthread_mutex_unlock.
504
fde89ad0
RM
5052002-12-06 Roland McGrath <roland@redhat.com>
506
507 * allocatestack.c (__stack_user): Use uninitialized defn.
508 * init.c (__pthread_initialize_minimal): Initialize it here.
509
11767d47
RM
5102002-12-05 Roland McGrath <roland@redhat.com>
511
fde89ad0
RM
512 * sysdeps/i386/tls.h (TLS_INIT_TP): Make it return zero or an error
513 string.
514 * sysdeps/x86_64/tls.h (TLS_INIT_TP): Likewise.
515
11767d47
RM
516 * sysdeps/unix/sysv/linux/i386/createthread.c (create_thread): Add
517 missing & here too.
518
440d8bc2
UD
5192002-12-05 Ulrich Drepper <drepper@redhat.com>
520
521 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
522 lowlevellock.
523 * sysdeps/unix/sysv/linux/i386/i486/libc-lowlevellock.S: New file.
524 * sysdeps/unix/sysv/linux/i386/i586/libc-lowlevellock.S: New file.
525 * sysdeps/unix/sysv/linux/i386/i686/libc-lowlevellock.S: New file.
526 * sysdeps/pthread/bits/libc-lock.h: Use lowlevellock implementation
527 for __libc_lock_* macros.
528 * Makefile (routines): Add libc-lowlevellock.
529
5302002-10-09 Roland McGrath <roland@redhat.com>
531
532 * sysdeps/pthread/bits/libc-lock.h (__libc_maybe_call): New macro.
533 Under [__PIC__], call the function via the pointer fetched for
534 comparison rather than a call by name that uses the PLT.
535 (__libc_lock_init, __libc_rwlock_init, __libc_lock_fini)
536 (__libc_rwlock_fini, __libc_lock_lock, __libc_rwlock_rdlock)
537 (__libc_rwlock_wrlock, __libc_lock_trylock, __libc_rwlock_tryrdlock)
538 (__libc_rwlock_trywrlock, __libc_lock_unlock, __libc_rwlock_unlock)
539 (__libc_key_create, __libc_getspecific, __libc_setspecific): Use it.
540
d5ed0118
RM
5412002-12-04 Roland McGrath <roland@redhat.com>
542
543 * forward.c (pthread_self): Use FORWARD3 macro to correct return type.
544
545 * sysdeps/i386/td_ta_map_lwp2thr.c: Moved from ../nptl_db.
546 * sysdeps/generic/td_ta_map_lwp2thr.c: New file.
547
548 * pthread_create.c (start_thread): Add missing & on __nptl_last_event.
549
eaa4099f
UD
5502002-12-04 Ulrich Drepper <drepper@redhat.com>
551
552 * sysdeps/unix/sysv/linux/i386/bits/pthreadtypes.h: Make pthread_t
553 a completely opaque, non-integer type.
554 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: Likewise.
555
33b5d0cc
UD
5562002-12-05 Jakub Jelinek <jakub@redhat.com>
557
558 * sysdeps/i386/tls.h: Include stdlib.h.
559 * sysdeps/x86_64/tls.h: Likewise.
560
7a5cdb30
UD
5612002-12-04 Ulrich Drepper <drepper@redhat.com>
562
c4a6d859
UD
563 * Makefile (tests): Add tst-locale2.
564 (tests-static): Likewise.
565 * tst-locale2.c: New file.
566
7a5cdb30
UD
567 * sysdeps/unix/sysv/linux/i386/lowlevellock.h: Mark asms as
568 volatile and add memory clobbers to lock operations.
569
d82d5d12
UD
5702002-12-03 Ulrich Drepper <drepper@redhat.com>
571
69cae3cf
UD
572 * sysdeps/i386/i686/bits/atomic.h: Use i486 version.
573 * sysdeps/i386/i486/bits/atomic.h: New file.
574 * sysdeps/i386/i586/bits/atomic.h: New file.
575 * sysdeps/i386/i686/pthread_spin_trylock.S: Define HAVE_CMOV and
576 include i486 version.
577 * sysdeps/i386/i486/pthread_spin_trylock.S: New file.
578 * sysdeps/i386/i586/pthread_spin_trylock.S: New file.
579 Patch by Marjin Ros <marjin@mad.scientist.com>.
580
e4044c01
UD
581 * allocatestack.c (get_cached_stack): Don't crash if we first
582 found a stack with a larger size then needed.
583 Reported by Hui Huang <hui.huang@sun.com>.
584
d82d5d12
UD
585 * Makefile (tests): Add tst-sysconf.
586 * tst-sysconf.c: New file.
587
588 * sysdeps/unix/sysv/linux/bits/local_lim.h: Undefine
589 PTHREAD_THREADS_MAX.
590
fa9a4ff0
RM
5912002-12-02 Roland McGrath <roland@redhat.com>
592
593 * pthreadP.h (__stack_user, __nptl_create_event, __nptl_death_event):
594 Declare using hidden_proto instead of attribute_hidden, so there are
595 non-.hidden static symbols for gdb to find.
596 (__pthread_keys): Likewise.
597 * events.c (__nptl_create_event, __nptl_death_event): Add hidden_def.
598 * allocatestack.c (__stack_user): Likewise.
599 * pthread_create.c (__pthread_keys): Likewise.
600 (__nptl_threads_events, __nptl_last_event): Make these static instead
601 of hidden.
602 * pthread_key_create.c (__pthread_pthread_keys_max,
603 __pthread_pthread_key_2ndlevel_size): Renamed from __linuxthreads_*.
604
91949a33
UD
6052002-12-02 Ulrich Drepper <drepper@redhat.com>
606
c22b52fa
UD
607 * Makefile (tests): Add tst-locale1. If buid-static is yes link
608 statically.
609 * tst-locale1.c: New file.
610
beb6aa41
UD
611 * pthread_cond_timedwait.c: Include <stdlib.h>.
612
91949a33
UD
613 * Makefile (tests): Add tst-fork2 and tst-fork3.
614 * tst-fork2.c: New file.
615 * tst-fork3.c: New file.
616
654dff90
UD
6172002-11-28 Ulrich Drepper <drepper@redhat.com>
618
cb0e76b4
UD
619 * sysdeps/unix/sysv/linux/i386/bits/posix_opt.h: New file.
620
621 * sysdeps/unix/sysv/linux/bits/posix_opt.h: Define macros which
622 require it to 200112L.
623
624 * sysdeps/unix/sysv/linux/i386/i486/lowlevelrwlock.S: Use cmov
625 instruction only if HAVE_CMOV is defined.
626 * sysdeps/unix/sysv/linux/i386/i686/lowlevelrwlock.S: Define HAVE_CMOV.
627
975aa229
UD
628 * sysdeps/unix/sysv/linux/x86_64/bits/semaphore.h: New file.
629
654dff90
UD
630 * sysdeps/unix/sysv/linux/x86_64/pthread_once.S: New file.
631
632 * sysdeps/unix/sysv/linux/x86_64/bits/pthreadtypes.h: New file.
633
634 * sysdeps/unix/sysv/linux/x86_64/pt-vfork.S: New file.
635
a3931336
UD
6362002-11-27 Ulrich Drepper <drepper@redhat.com>
637
c10c099c
UD
638 * sysdeps/x86_64/bits/atomic.h: New file.
639
640 * sysdeps/i386/i686/bits/atomic.h: Fix asm syntax for 8- and
641 16-bit operations.
642
dca99d27
UD
643 * sysdeps/unix/sysv/linux/raise.c (raise): Use INTERNAL_SYSCALL if
644 possible since gettid cannot fail.
645
f78deea6
UD
646 * sysdeps/x86_64/pthreaddef.h: New file.
647
648 * sysdeps/i386/pthreaddef.h (gettid): Removed.
649
650 * sysdeps/x86_64/pthread_spin_init.c: New file.
651 * sysdeps/x86_64/pthread_spin_lock.c: New file.
652 * sysdeps/x86_64/pthread_spin_trylock.c: New file.
653 * sysdeps/x86_64/pthread_spin_unlock.c: New file.
654
655 * sysdeps/i386/i686/pthread_spin_trylock.S (pthread_spin_trylock):
656 Add missing lock prefix. Minute optimization.
657
658 * tst-spin2.c (main): Also check successful trylock call.
659
660 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Use correct
661 syscall. Fix typo in case INTERNAL_SYSCALL is not used.
662
663 * sysdeps/i386/pthread_spin_destroy.c: Moved to...
664 * sysdeps/pthread/pthread_spin_destroy.c: ...here. New file.
665
666 * sysdeps/i386/pthread_sigmask.c: Removed. Use the generic code.
667 * sysdeps/pthread/pthread_sigmask.c (pthread_sigmask): Return correct
668 value in case of an error. Add support for INTERNAL_SYSCALL.
b54e18eb
UD
669
670 * sysdeps/i386/pthread_sigmask.c (pthread_sigmask): Return correct
671 value in case of an error.
672
a3931336
UD
673 * sysdeps/x86_64/tls.h: New file.
674
76a50749
UD
6752002-11-26 Ulrich Drepper <drepper@redhat.com>
676
117c452c
UD
677 * sysdeps/i386/tls.h (THREAD_GETMEM_NC): Change interface. It now
678 takes the array member name and the index as parameters.
679 (THREAD_SETMEM_NC): Likewise.
680 * pthread_getspecific.c: Use new THREAD_GETMEM_NC interface.
681 * pthread_setspecific.c: Use new THREAD_GETMEM_NC and THREAD_SETMEM_NC
682 interfaces.
683
684 * sysdeps/i386/tls.h (THREAD_SETMEM): Use size of member element
685 to decide which code to use.
686 (THREAD_SETMEM_NC): Likewise.
687
76a50749
UD
688 * allocatestack.c (queue_stack): Don't remove stack from list here.
689 Do it in the caller. Correct condition to prematurely terminate
690 loop to free stacks.
691 (__deallocate_stack): Remove stack from list here.
692
6932002-11-26 Ulrich Drepper <drepper@redhat.com>
694
695 * Makefile (tests): Add tst-stack1.
696 * tst-stack1.c: New file.
697
698 * allocatestack.c (allocate_stack): Initialize the TCB on a user
699 provided stack.
700
701 * pthread_attr_getstack.c: Return bottom of the thread area.
702
7032002-11-25 Ulrich Drepper <drepper@redhat.com>
704
705 * Makefile (libpthread-routines): Add pt-allocrtsig and
706 pthread_kill_other_threads.
707 * pt-allocrtsig.c: New file.
708 * pthread_kill_other_threads.c: New file.
709 * sysdeps/unix/sysv/linux/allocrtsig.c: Add additional aliases for
710 all three functions.
711 * sysdeps/unix/sysv/linux/Makefile (sysdep_routines): Remove
712 allocrtsig.
713 * sysdeps/unix/sysv/linux/Versions (libc:GLIBC_PRIVATE): Export
714 __libc_current_sigrtmin_private, __libc_current_sigrtmax_private,
715 and __libc_allocate_rtsig_private.
716 * Versions (libpthread): Export pthread_kill_other_threads_np,
717 __libc_current_sigrtmin, and __libc_current_sigrtmax.
718
7192002-11-24 Ulrich Drepper <drepper@redhat.com>
720
721 * allocatestack.c (allocate_stack): stackaddr in attribute points to
722 the end of the stack. Adjust computations.
723 When mprotect call fails dequeue stack and free it.
724 * pthread_attr_setstack.c: Store top of the stack in stackaddr
725 attribute.
726 * pthread_getattr_np.c: Likewise.
727
728 * descr.h (IS_DETACHED): Add some more parenthesis to prevent
729 surprises.
730
7312002-11-23 Ulrich Drepper <drepper@redhat.com>
732
733 * sysdeps/pthread/pthread.h (pthread_self): __THROW must come before
734 attribute definitions. Patch by Luca Barbieri <ldb@ldb.ods.org>.
735
7362002-11-22 Ulrich Drepper <drepper@redhat.com>
737
738 * pthread_getspecific.c: Optimize access to first 2nd-level array.
739 * pthread_setspecific.c: Likewise.
740
7412002-11-21 Ulrich Drepper <drepper@redhat.com>
742
743 * sysdeps/unix/sysv/linux/i386/createthread.c: Remove CLONE_ flags
744 definitions. Get them from the official place.
745 * sysdeps/unix/sysv/linux/i386/fork.c: Likewise.
746
747 * sysdeps/unix/sysv/linux/i386/createthread.c: Update CLONE_* flags.
748 Use new CLONE_ flags in clone() calls.
749
750 * sysdeps/unix/sysv/linux/fork.c: Use ARCH_FORK to actually fork.
751 * sysdeps/unix/sysv/linux/i386/fork.c: New file.
752
753 * Versions: Add pthread_* functions for libc.
754 * forward.c: New file.
755
756 * sysdeps/pthread/Makefile (libpthread-sysdeps_routines): Add
757 errno-loc.
758 * herrno.c: New file.
759 * res.c: New file.
760
761 * Makefile (libpthread-routines): Remove sem_post, sem_wait,
762 sem_trywait, and sem_timedwait. Add herrno and res.
763 * sem_init.c: Don't initialize lock and waiters members.
764 * sem_open.c: Likewise.
765 * sem_post.c: Removed.
766 * sem_wait.c: Removed.
767 * sem_trywait.c: Removed.
768 * sem_timedwait.c: Removed.
769 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Complete rewrite.
770 Includes full implementations of sem_post, sem_wait, sem_trywait,
771 and sem_timedwait.
772 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Adjust
773 for new implementation.
774 * sysdeps/unix/sysv/linux/internaltypes.h (struct sem): Remove lock
775 and waiters fields.
776
777 * tst-sem3.c: Improve error message.
778 * tst-signal3.c: Likewise.
779
780 * init.c (__pthread_initialize_minimal): Use set_tid_address syscall
781 to tell the kernel about the termination futex and to initialize tid
782 member. Don't initialize main_thread.
783 * descr.h (struct pthread): Remove main_thread member.
784 * cancelllation.c (__do_cancel): Remove code handling main thread.
785 The main thread is not special anymore.
786
787 * allocatestack.c (__reclaim_stacks): Mark stacks as unused. Add
788 size of the stacks to stack_cache_actsize.
789
790 * pt-readv.c: Add missing "defined".
791 * pt-sigwait.c: Likewise.
792 * pt-writev.c: Likewise.
793
7942002-11-09 Ulrich Drepper <drepper@redhat.com>
795
796 * Versions: Export __connect from libpthread.
797 Patch by Luca Barbieri <ldb@ldb.ods.org>.
798
799 * Makefile (libpthread-routines): Add pt-raise.
800 * sysdeps/unix/sysv/linux/raise.c: New file.
801 * sysdeps/unix/sysv/linux/pt-raise.c: New file.
802 * sysdeps/generic/pt-raise.c: New file.
803
804 * pthread_cond_init.c: Initialize all data elements of the condvar
805 structure. Patch by Luca Barbieri <ldb@ldb.ods.org>.
806
807 * pthread_attr_init.c: Actually implement 2.0 compatibility version.
808 * pthread_create.c: Likewise.
809
810 * Makefile (tests): Add tst-key1, tst-key2, tst-key3.
811 * tst-key1.c: New file.
812 * tst-key2.c: New file.
813 * tst-key3.c: New file.
814
815 * Versions: Export pthread_detach for version GLIBC_2.0.
816 Reported by Saurabh Desai <sdesai@austin.ibm.com>.
817
8182002-11-08 Ulrich Drepper <drepper@redhat.com>
819
820 * pthread_key_create.c: Terminate search after an unused key was found.
821 Patch by Luca Barbieri <ldb@ldb.ods.org>.
822
823 * sysdeps/unix/sysv/linux/i386/pthread_once.S: Return zero.
824 Patch by Luca Barbieri <ldb@ldb.ods.org>.
825
8262002-10-10 Ulrich Drepper <drepper@redhat.com>
827
828 * sysdeps/unix/sysv/linux/i386/i486/lowlevelsem.S: Use slow generic
829 dynamic lookup for errno in PIC.
830
831 * allocatestack.c (get_cached_stack): Rearrange code slightly to
832 release the stack lock as soon as possible.
833 Call _dl_allocate_tls_init for TCB from the cache to re-initialize
834 the static TLS block.
835 (allocate_stack): Call _dl_allocate_tls_init for user-provided stack.
836
837 * cancellation.c: Renamed from cancelation.c.
838 * Makefile: Adjust accordingly.
839 * pthreadP.h (CANCELLATION_P): Renamed from CANCELATION_P.
840 * cleanup_defer.c: Use CANCELLATION_P.
841 * pthread_testcancel.c: Likewise.
842 * descr.h: Fix spelling in comments.
843 * init.c: Likewise.
844 * pthread_getattr_np.c: Likewise.
845 * pthread_getschedparam.c: Likewise.
846 * pthread_setschedparam.c: Likewise.
847 * Versions: Likewise.
848
849 * pt-pselect.c: New file.
850 * Makefile (libpthread-routines): Add pt-pselect.
851 * Versions: Add pselect.
852
853 * tst-cancel4.c: New file.
854 * Makefile (tests): Add tst-cancel4.
855
8562002-10-09 Ulrich Drepper <drepper@redhat.com>
857
858 * pthread_mutex_lock.c: Always record lock ownership.
859 * pthread_mutex_timedlock.c: Likewise.
860 * pthread_mutex_trylock.c: Likewise.
861
862 * pt-readv.c: New file.
863 * pt-writev.c: New file.
864 * pt-creat.c: New file.
865 * pt-msgrcv.c: New file.
866 * pt-msgsnd.c: New file.
867 * pt-poll.c: New file.
868 * pt-select.c: New file.
869 * pt-sigpause.c: New file.
870 * pt-sigsuspend.c: New file.
871 * pt-sigwait.c: New file.
872 * pt-sigwaitinfo.c: New file.
873 * pt-waitid.c: New file.
874 * Makefile (libpthread-routines): Add pt-readv, pt-writev, pt-creat,
875 pt-msgrcv, pt-msgsnd, pt-poll, pt-select, pt-sigpause, pt-sigsuspend,
876 pt-sigwait, pt-sigwaitinfo, and pt-waitid.
877 * Versions: Add all the new functions.
878
879 * tst-exit1.c: New file.
880 * Makefile (tests): Add tst-exit1.
881
882 * sem_timedwait.c: Minor optimization for more optimal fastpath.
883
8842002-10-08 Ulrich Drepper <drepper@redhat.com>
885
886 * pt-fcntl.c: Only enable asynchronous cancellation for F_SETLKW.
887
888 * pthread_join.c: Enable asynchronous cancellation around lll_wait_tid
889 call. pthread_join is an official cancellation point.
890 * pthread_timedjoin.c: Likewise.
891
892 * pthread_cond_wait.c: Revert order in which internal lock are dropped
893 and the condvar's mutex are retrieved.
894 * pthread_cond_timedwait.c: Likewise.
895 Reported by dice@saros.East.Sun.COM.
896
8972002-10-07 Ulrich Drepper <drepper@redhat.com>
898
899 * pthreadP.h: Cut out all type definitions and move them...
900 * sysdeps/unix/sysv/linux/internaltypes.h: ...here. New file.
901 * pthreadP.h: Include <internaltypes.h>.
902
903 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h (lll_sem_post): Little
904 performance tweaks.
905
906 * sem_trywait.c: Shuffle #includes around to get right order.
907 * sem_timedwait.c: Likewise.
908 * sem_post.c: Likewise.
909 * sem_wait.c: Likewise.
910
911 * nptl 0.3 released.
912
913 * Makefile (tests): Add tst-signal3.
914 * tst-signal3.c: New file.
915
9162002-10-05 Ulrich Drepper <drepper@redhat.com>
917
918 * sysdeps/unix/sysv/linux/i386/lowlevelsem.h: Tell the compiler that
919 the asms modify the sem object.
920 (__lll_sem_timedwait): Now takes struct sem* as first parameter.
921
922 * sysdeps/unix/sysv/linux/i386/bits/semaphore.h (sem_t): Don't expose
923 the actual members.
924 * pthreadP.h (struct sem): New type. Actual semaphore type.
925 * semaphoreP.h: Include pthreadP.h.
926 * sem_getvalue.c: Adjust to sem_t change.
927 * sem_init.c: Likewise.
928 * sem_open.c: Likewise.
929 * sem_post.c: Likewise.
930 * sem_timedwait.c: Likewise.
931 * sem_trywait.c: Likewise.
932 * sem_wait.c: Likewise.
933
9342002-10-04 Ulrich Drepper <drepper@redhat.com>
935
936 * Makefile (tests): Add tst-basic2, tst-exec1, tst-exec3, tst-exec3.
937 * tst-basic2.c: New file.
938 * tst-exec1.c: New file.
939 * tst-exec2.c: New file.
940 * tst-exec3.c: New file.
941
942 * tst-fork1.c: Remove extra */.
943
944 * nptl 0.2 released. The API for IA-32 is complete.