From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,8d576fd5240da9e9 X-Google-Attributes: gid103376,public From: Tucker Taft Subject: Re: Are delay statements abortable? Date: 2000/01/10 Message-ID: <387A3981.A2601F48@averstar.com>#1/1 X-Deja-AN: 570835670 Content-Transfer-Encoding: 7bit Sender: news@inmet.camb.inmet.com (USENET news) X-Nntp-Posting-Host: houdini.burl.averstar.com References: <85buah$hn4$1@nnrp1.deja.com> To: davidb42@my-deja.com X-Accept-Language: en Content-Type: text/plain; charset=us-ascii Organization: AverStar (formerly Intermetrics) Burlington, MA USA Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 2000-01-10T00:00:00+00:00 List-Id: davidb42@my-deja.com wrote: > > Are delay statements interruptable/abortable? Yes. > > I was expecting delay statements in tasks (or in the abortable part of > an asynchronous select construct) to be brought to a premature end on > aborting the task (or on the triggering event). They should be. > > However, in the Ada implementation I am using, the abortion only seems > to take effect at the expiry of the delay. This would not qualify as a "real-time-systems-annex" supporting implementation in Ada 95. "Real-time" implementations are required to abort preemptively in Ada 95 (see RM95 D.6(2)). > > For example, in the program below, the main task completes after 25 > seconds, but the dependent task (and thus the program as a whole) > doesn't terminate until 40 seconds (at expiry of the 2nd 20 second > delay). > > Is this right? In a non-real-time implementation, this is "correct" but not particularly helpful. In a "real-time" Ada 95 implementation, this would be incorrect. > David Bowerman > CSC Australia. -- -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