Re: Invisible threads in 2.6

From: lm240504
Date: Tue May 25 2004 - 13:57:00 EST


> my kernel:
> # cat /proc/version
> Linux version 2.6.6-rc3-mm2 (root@phoebee) (gcc version 3.3.2 20031218 (Gentoo
> Linux 3.3.2-r5, propolice-3.3-7)) #6 Fri May 7 10:56:06 CEST 2004
>
> I just compiled your example and ran it:
> # ./thread_test
>
<snip>
> On my -mm patched kernel I can see them.

I tried 2.6.6-rc3-mm2, and didn't see any difference:

# cat /proc/version
Linux version 2.6.6-rc3-mm2 (lmakhlis@levlinux) (gcc version 3.2.2 20030222 (Red Hat Linux 3.2.2-5)) #3 SMP Tue May 25 14:04:28 EDT 2004

# ./thread_test &
[749]

# ls /proc/749/task
ls: /proc/749/task: No such file or directory

# ps axw
...
749 tty1 Z 0:00 [thread_test <defunct>]
...

I have now tested it on Fedora Core 2 (2.6.5), SLES 9 Beta (2.6.5) and RHL 9 w/ 2.6.6-rc3-mm2, with identical results. Could it have anything to do with which thread library the program is using? Here's mine:

# ldd ./thread_test
libpthread.so.0 => /lib/tls/libpthread.so.0 (0x40028000)
libc.so.6 => /lib/tls/libc.so.6 (0x42000000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)

# strace ./pthread_test
<see attachment>

Lev



Attachment: strace.out
Description: Binary data