harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geir Magnusson Jr." <g...@pobox.com>
Subject Re: [classlib][luni] signalis interruptus in hysock
Date Wed, 25 Oct 2006 06:00:05 GMT

Ivan Volosyuk wrote:
> On 10/20/06, Geir Magnusson Jr. <geir@pobox.com> wrote:
>> Ivan Volosyuk wrote:
>> > Well, I think that the solution is what Geir suggests. One think which
>> > bothers me is following. EINTR can happen in different places and the
>> > situations can be quite rare in some circumstances. It can lead to
>> > hard to reproduce stability bugs (race conditions).
>> Can you give an example?
> Half a year ago, I was working on the problem. Socket operations get
> sometimes interrupted. We have found out that it occurs sometime after
> GC. It was not quite easy as the application was quite big and
> situation - quite rare.

I believe it is rare, but if the code deals with EINTR correctly, where 
can the race conditions come from?

> Given the fact, that current implementation of monitor reservation
> code can stop other thread in quite random fashion we should have rock
> solid support of EINTR handling everywhere the select(), poll() calls
> is used.

Well... yeah.  Not bury it.



View raw message