comp.lang.ada
 help / color / mirror / Atom feed
From: stt@houdini.camb.inmet.com (Tucker Taft)
Subject: Re: Streams and Concurrency
Date: 1999/01/08
Date: 1999-01-08T00:00:00+00:00	[thread overview]
Message-ID: <F598A5.44p.0.-s@inmet.camb.inmet.com> (raw)
In-Reply-To: 36962E36.BA1A61B0@elca-matrix.ch

Mats Weber (Mats.Weber@elca-matrix.ch) wrote:

.. [discussion of restriction against potentially-blocking operations
   in protected operations]
: ...
: 4) It is another case where the standard enforces things that no
: compiler can check, neither at compile time nor at run time. Ada 83 had
: incorrect order dependences in this category, where it was allowed to
: raise Program_Error if it found one. Fortunately, this was removed from
: Ada 95 and I think the restriction on blocking protected operations
: falls in the same category.

Checking for explicit use of entry calls or task activation "statically"
within the protected operation is not difficult.  Checking for
such uses outside the protected body is of course more difficult (though not
impossible if willing to do it at link-time).  Detecting incorrect order 
dependences, by contrast, involves solving the halting problem ;-).

The restriction against performing other *entry* calls (or activating
new tasks) while in a protected operation seems entirely appropriate, and 
I presume that GNAT does not support that.  I agree that things which
the programmer "knows" won't suspend the Ada task ("suspend" in the sense
of waiting indefinitely for some other Ada task of potentially lower 
priority to wake it up) are safe and generally portable to do, so in
this sense the standard was probably overly conservative.

--
-Tucker Taft   stt@averstar.com   http://www.averstar.com/~stt/
Technical Director, Distributed IT Solutions  (www.averstar.com/tools)
AverStar (formerly Intermetrics, Inc.)   Burlington, MA  USA




  reply	other threads:[~1999-01-08  0:00 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-12-30  0:00 Streams and Concurrency James S. Rogers
1998-12-29  0:00 ` David Botton
1998-12-30  0:00   ` James S. Rogers
1998-12-30  0:00     ` dennison
1998-12-30  0:00       ` James S. Rogers
1999-01-04  0:00       ` Robert I. Eachus
1998-12-31  0:00     ` Jean-Pierre Rosen
1998-12-31  0:00       ` dewar
1998-12-31  0:00         ` dennison
1999-01-04  0:00         ` Jean-Pierre Rosen
1999-01-04  0:00           ` robert_dewar
1998-12-31  0:00       ` dewar
1998-12-31  0:00         ` Ada-G, was " Tom Moran
1999-01-01  0:00           ` Brian Rogoff
1999-01-04  0:00             ` Robert I. Eachus
1999-01-08  0:00               ` Mats Weber
1999-01-08  0:00                 ` Robert I. Eachus
1999-01-01  0:00           ` dewar
1999-01-01  0:00             ` Larry Kilgallen
1999-01-08  0:00         ` Mats Weber
1999-01-08  0:00           ` Tucker Taft [this message]
1998-12-30  0:00   ` dennison
1998-12-30  0:00     ` Tucker Taft
1998-12-30  0:00       ` dennison
1998-12-31  0:00         ` robert_dewar
1998-12-30  0:00       ` Robert I. Eachus
1998-12-30  0:00         ` Tucker Taft
1998-12-31  0:00         ` dennison
1998-12-31  0:00           ` robert_dewar
1998-12-31  0:00             ` dennison
1999-01-01  0:00               ` robert_dewar
1999-01-04  0:00           ` Robert I. Eachus
1998-12-30  0:00 ` dennison
1998-12-30  0:00   ` Robert I. Eachus
1999-01-11  0:00   ` Bulk synchronous model for IO (was Re: Streams and Concurrency) Kevin Rigotti
replies disabled

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