comp.lang.ada
 help / color / mirror / Atom feed
From: "Samuel A. Mize" <smize@magellan.bgm.link.com>
Subject: Re: Tasking Techniques - Opinions?
Date: 1997/06/06
Date: 1997-06-06T00:00:00+00:00	[thread overview]
Message-ID: <339808BF.41C6@magellan.bgm.link.com> (raw)
In-Reply-To: JSA.97Jun5140920@alexandria.organon.com


Jon S Anthony wrote:
> In article <3395A448.41C6@magellan.bgm.link.com> "Samuel A. Mize" <smize@magellan.bgm.link.com> writes:
> 
> > Absolutely true.  However, do be aware that protected types have
> > significant overhead -- not as much as task rendezvous, but on the
> > order of ten times a procedure call.
> 
> I find this surprising. On what do you base this 10X figure?

It surprised me too, and forced me to redesign data-sharing
in some real-time code.  (Measure everything, early.  Thank
heaven we DID.)

As Tom Quiggle of SGI pointed out to me in email, Ada semantics
surround a protected call with a lot of required processing:
a) deferral of abortion/asynchronous transfer of control (ATC)
   for the current task
b) acquisition of of a mutex
c) execution of the protected actions
d) release the mutex
e) re-enable abortion/ATC
f) check for pending abort/ATC

Some of this will be system calls, which take longer than
simple procedure calls on most systems I know of.  In a
multi-processor environment, those system calls will have to
coordinate between processors, which takes even more time.

Sam Mize

--
-- Samuel Mize           (817) 619-8622               "Team Ada"
-- Hughes Training Inc.  PO Box 6171 m/s 400, Arlington TX 76005




  reply	other threads:[~1997-06-06  0:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1997-06-04  0:00 Tasking Techniques - Opinions? Steve Doiel
1997-06-03  0:00 ` Tom Moran
1997-06-07  0:00   ` Steve Doiel
1997-06-04  0:00 ` Jon S Anthony
1997-06-04  0:00 ` bsanden
1997-06-04  0:00   ` Samuel A. Mize
1997-06-05  0:00     ` Jon S Anthony
1997-06-06  0:00       ` Samuel A. Mize [this message]
1997-06-07  0:00       ` Robert Dewar
1997-06-10  0:00         ` Jon S Anthony
1997-06-05  0:00 ` Robert A Duff
replies disabled

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