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.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,8ddc02527645a844 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-03-31 11:10:08 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!newsfeed.vmunix.org!feed.news.nacamar.de!newsfeed.freenet.de!newsfeed.r-kom.de!newsfeed00.sul.t-online.de!newsmm00.sul.t-online.com!t-online.de!news.t-online.com!not-for-mail From: Bernd.Specht@gmx.com (Bernd Specht) Newsgroups: comp.lang.ada Subject: Re: tasking with GNAT 3.14p on windows Date: Mon, 31 Mar 2003 21:09:36 +0200 Organization: No company Message-ID: References: <6jIha.35142$ja4.2255611@bgtnsc05-news.ops.worldnet.att.net> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: news.t-online.com 1049137776 00 9172 kd0KEUlTSvALFc 030331 19:09:36 X-Complaints-To: abuse@t-online.com X-ID: XuKriEZDoex76rQk0HPMD2LToyxx-guD3-9MAYXGx70Tde8ctfxC6T User-Agent: Xnews/4.05.03 Xref: archiver1.google.com comp.lang.ada:35835 Date: 2003-03-31T21:09:36+02:00 List-Id: "James S. Rogers" wrote in news:W4Oha.35749$ja4.2291095@bgtnsc05-news.ops.worldnet.att.net: > "Jano" wrote in message > news:MPG.18f18ac32e4a300d9896c8@News.CIS.DFN.DE... >> James S. Rogers dice... >> > "Bernd Specht" wrote in message >> > news:Xns934E8C5D49EFBerndSpechtgmxcom@62.153.159.134... >> > > Hi, >> > > >> > > I tried an example from "Barnes, 18.8", but it didn't work as >> > > expected. Any ideas? >> > > >> > > with Text_IO; use Text_IO; >> > > >> > > procedure TaskTest is begin >> > > select >> > > delay 3.0; >> > > put_line ("aborted"); >> > > then abort >> > > loop >> > > null; -- modified >> > > end loop; >> > > end select; >> > > end TaskTest; >> > > >> (...) >> > The null command will reliably take less than 3.0 seconds to complete. >> >> It's inside of a neverending loop. > > And optimization will remove the loop, leaving a single null statement. No. 1. If this would be true, then the program should terminate after a short time, but in fact it is still not terminated after a few hours. so it seem to "hang" inside the loop. 2. If this would be the case it would be a serious compiler error. An endless loop must never be removed by compiler optimisation (it would be interessting to know the opinion of Robert Dewar). I hope my code loop if Get_Pressure > Upper_Limit then Open_Valve; elsif Get_Pressure < Lower_Limit then Close_Valve; end if; end loop; still executes, and was not only executed once due to compiler optimisation (I don't like to be blown up due to an compiler "feature"). > > Jim Rogers > > >