Re: hanging linuxthread processes

"Carlos O'Donell" <[email protected]>
Newsgroups gmane.linux.ports.hppa
Message-ID <[email protected]>
On 4/21/07, Helge Deller <[email protected]> wrote:
> Do we still see pthread/linuxthread-"hangs" on HPPA ?

The HPPA hangs are attributed to a race condition in our space id
setting code. We can reproduce this at will, but we don't yet have a
good solution. See the older thread about this.

> On Alpha they had similiar problems with "hanging" threads:
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=325600

This isn't hanging, this is just zombie threads because the compiler
optimized away the waitpid call in the C library.

> Their trivial solution seems to be:
> http://permalink.gmane.org/gmane.linux.debian.ports.alpha/7114
>
> Could this be a solution on HPPA (with #ifdef __hppa__ added) as well ?
> Mabye someone who compiles glibc on regular basis want to try ?

1. apt-get source glibc
2. Apply patch.
3. dpkg-buildpackage -rfakeroot
4. Install package to chroot.
5. Test.

I reviewed INLINE_SYSCALL for hppa on mainline and I didn't find any
problems with the constraints.

When compiling with mainline gcc I did find that -O2 has a code-gen
issue with some of the loops in NPTL and optimizes away the inline
assembly macros. I have not had time to reproduce this. Instead I
killed the issue with my "volatile" shotgun.

In summary...
1. Read source snippet.
2. Read assembly block.
3. Use brain to determine if they do the same thing.

This way you find if the compiler is broken. It's tedious and labour
intensive work. Welcome to compiler development :-)

Cheers,
Carlos.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.