harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ivan Volosyuk" <ivan.volos...@gmail.com>
Subject Re: [classlib][luni] signalis interruptus in hysock
Date Thu, 19 Oct 2006 14:49:54 GMT
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). We should find a
way how to test the implementation.
--
Ivan

On 10/19/06, Jeff Disher <jmdisher@gmail.com> wrote:
> The problem is larger than SA_RESTART since a VM can receive signals for
> which it did not set SA_RESTART.  On some platforms, forcing EINTR is the
> only way to break a thread out of an indefinitely blocking syscall.  Losing
> this information would cause us to lose the ability to perform these kinds
> of operations.
>
> If the lower level didn't generate the signal, it probably shouldn't assume
> its intention.
>
> The timeout handling is an issue which we can probably resolve by stating
> that the timeout value is undefined after a call to hysock_select.
>
>
> Does that make sense?
> Jeff.
>
>
>
> On 10/18/06, Ivan Volosyuk <ivan.volosyuk@gmail.com> wrote:
> >
> > Why not? I understand your opinion, that EINTR should be handled in
> > upper layers. But here we have somewhat buggy (strange) implementation
> > specifics of select() and similar calls.
> > Good functions like read() and write() and so on doesn't interrupt
> > with SA_RESTART system calls, but select() does. I think it is low
> > level issue and should be handled in the same low level layer.
> > Handling it in upper layer may cause hard to detect bugs in that
> > implementations.
> > There are issues with timeout handling here to maintain platform
> > independence (Linux implementation is different then POSIX, AFAIK),
> > but it can be solved with minor performance decrease.
> > --
> > Ivan
> >
> > On 10/18/06, Geir Magnusson Jr. <geir@pobox.com> wrote:
> > > Thanks, but we're not going to eat EINTR....
> > >
> > > Artem Aliev wrote:
> > > > Geir,
> > > >
> > > > I create HARMONY-1904 issue for this case.
> > > >
> > > > Thanks
> > > > Artem

-- 
Ivan
Intel Enterprise Solutions Software Division

---------------------------------------------------------------------
Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: harmony-dev-unsubscribe@incubator.apache.org
For additional commands, e-mail: harmony-dev-help@incubator.apache.org


Mime
View raw message