comp.lang.ada
 help / color / mirror / Atom feed
From: Ted Dennison<dennison@telepath.com>
Subject: Re: Multiple entry tasks
Date: Thu, 19 Apr 2001 19:12:24 GMT
Date: 2001-04-19T19:12:24+00:00	[thread overview]
Message-ID: <sMGD6.3326$D4.330928@www.newsranger.com> (raw)
In-Reply-To: 9bmuo9$50h$1@s1.read.news.oleane.net

In article <9bmuo9$50h$1@s1.read.news.oleane.net>, Jean-Pierre Rosen says...
>
>The sequence of events I was thinking of is the following:
>2) The call to Entry2 times out (it was a timed entry call).

Ahhh. I didn't think about timed entry calls. Hmmm. So you are saying that the
runtime can change the state of the entry queues between the start of a select
statement and its decision to block or immediately accept an entry? In that
case, an "abort"ed task would hose him as well, right?

Generally I find that one has to be very carful about using timed or tenative
entry calls. As a general rule, you have to be damn sure that the server will at
some point sit and wait for your entry. If there's an "else" or "delay" clause
on the server's selective wait, you can get into a nasty case of livelock. Since
I generally need to use one of those clauses, I don't use timed or tenative
rendezvous very much.

Since I usually can't use them anyway, I don't think its much of a hardship to
prohibit timed rendezvous (and aborts) for clients of this server. What you gain
by doing this is an easier to maintain structure. With the way we did it, there
are two select branches that must be maintined in lock-step for all but the
highest-priority entry. That's not a big deal with our little toy example, as
there was no code in any of the branches. But for a complicated server with
loads of code in each branch, it could be a very big deal indeed.

Then again, its possible you might want to do different things if the entry was
accepted immediately vs. waited for. In that case what we did would be better.

---
T.E.D.    homepage   - http://www.telepath.com/dennison/Ted/TED.html
          home email - mailto:dennison@telepath.com



  reply	other threads:[~2001-04-19 19:12 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-04-18 14:57 Multiple entry tasks Lutz Donnerhacke
2001-04-18 16:22 ` Marin David Condic
2001-04-18 18:12   ` Ted Dennison
2001-04-18 18:57     ` Ted Dennison
2001-04-18 20:16       ` Marin David Condic
2001-04-19 14:02         ` Ted Dennison
2001-04-19 14:28           ` Marin David Condic
2001-04-18 19:46     ` Marin David Condic
2001-04-19 21:52       ` Robert A Duff
2001-04-24  9:19         ` Lutz Donnerhacke
2001-04-19  8:17   ` Jean-Pierre Rosen
2001-04-19 14:42     ` Ted Dennison
2001-04-19 15:01       ` Marin David Condic
2001-04-19 15:02       ` Jean-Pierre Rosen
2001-04-19 19:12         ` Ted Dennison [this message]
2001-04-20 14:17           ` Jean-Pierre Rosen
2001-04-20 19:04             ` Ted Dennison
2001-04-23  6:55               ` Jean-Pierre Rosen
2001-04-23 13:50                 ` Ted Dennison
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox