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=0.2 required=5.0 tests=BAYES_00,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,1356f4179c1e4ef4 X-Google-Attributes: gid103376,public From: ncohen@watson.ibm.com (Norman H. Cohen) Subject: Re: ADA task Date: 1996/09/16 Message-ID: <51jnm6$16qc@watnews1.watson.ibm.com>#1/1 X-Deja-AN: 180920781 distribution: world references: <5174qu$o1p@nr1.ottawa.istar.net> <51cjp0$q7k@watnews1.watson.ibm.com> <51ep6c$cut@nr1.ottawa.istar.net> organization: IBM T.J. Watson Research Center reply-to: ncohen@watson.ibm.com newsgroups: comp.lang.ada Date: 1996-09-16T00:00:00+00:00 List-Id: In article <51ep6c$cut@nr1.ottawa.istar.net>, "Roumen Roupski" writes: |> In your example above you use Calendar package. I saw GNAT has |> Ada.Real_Time package. Should I use it instead of Calendar? Old habits die hard. Yes, you should. Ada.Real_Time is provided by every Ada-95 compiler that supports the Real-Time Annex and is guaranteed to provide more accurate time measurement than Ada.Calendar is guaranteed to provide. The delay-until statement works not only with type Ada.Calendar.Time, but also with type Ada.Real_Time.Time. Paragraph D.9(13) of the Ada-95 RM requires an implementation supporting the Real-Time Annex to guarantee an upper bound on the difference between the delay time specified in the delay-until statement and the time at which execution of the delayed task actually resumes. This can be used to address Ken Garlington's concerns about guaranteeing on-time execution of a periodic piece of work. (Careful analysis, such as rate-monotonic scheduling, is necessary to ensure that the processor will be available, i.e., that all other tasks of equal or higher priority will be suspended, when a delay expires; the guarantees in paragraph D.9(13) ensure that under those conditions a sleeping task awakens quickly when the delay expires.) -- Norman H. Cohen ncohen@watson.ibm.com