RE: Threads signalling issue [was RE: threads change]

[email protected] ("Jan Dubois")
Newsgroups perl.perl5.porters,perl.ithreads
Message-ID <01b501c6a7ae$a3efd5f0$ebcf81d0$@com>
On Fri, 14 Jul 2006, Artur Bergman wrote:
> I owe you a big beer, I hope you will be at OSCON? :)

Unfortunately I can't make it this year. :(

> The mutex will issue a memory barrier, so it should be safe.

This is true for threads.xs, but the standard Perl signal code
in S_raise_signal() doesn't provide such a barrier:

static void
S_raise_signal(pTHX_ int sig)
{
    dVAR;
    /* Set a flag to say this signal is pending */
    PL_psig_pend[sig]++;
    /* And one to say _a_ signal is pending */
    PL_sig_pending = 1;
}

I think Nicholas has a valid point that this is not guaranteed
to be "timely" on all SMP systems.

Cheers,
-Jan
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.