Re: Process with many NPTL threads terminates slowly on core dump signal

From: Michael Kerrisk
Date: Thu Oct 13 2005 - 03:43:30 EST


> Von: Oleg Nesterov <oleg@xxxxxxxxxx>
> Datum: Wed, 12 Oct 2005 21:33:46 +0400
>
> Michael Kerrisk wrote:
> >
> > Following up (belatedly) from my earlier message, I took Daniel
> > Jacobowitz's suggestion to investigate the result from booting
> > with "profile=2". When running my program (shwon below) on
> > 2.6.14-rc4 to create 100 threads, and sending a core dump signal,
> > the program takes 90 seconds to terminate, and readprofile shows
> > the following:
>
> I think the coredumping code in __group_complete_signal() is bogus
> and what happens is:

[...]

> TIF_SIGPENDING is not cleared, so get_signal_to_deliver() will be
> called again on return to userspace. When all threads will eat their
> ->time_slice, P will return from yield() and kill all threads.

Thanks for investiagting this further.

> Could you try this patch (added to mm tree):
> http://marc.theaimsgroup.com/?l=linux-kernel&m=112887453531139
> ? It does not solve the whole problem, but may help.
>
> Please report the result, if possible.

Thanks. I've applied it to 2.6.14-rc4: this patch does fix the
specific behaviour that my program demonstrates.

What remains to be solved?

Cheers,

Michael

--
10 GB Mailbox, 100 FreeSMS/Monat http://www.gmx.net/de/go/topmail
+++ GMX - die erste Adresse für Mail, Message, More +++
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/