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.8 required=5.0 tests=BAYES_00,INVALID_DATE autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,c0a32fc5a2c39b9 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 1995-01-09 16:09:52 PST Newsgroups: comp.lang.ada Path: nntp.gmd.de!newsserver.jvnc.net!nntpserver.pppl.gov!princeton!rutgers!engr.orst.edu!reuter.cse.ogi.edu!psgrain!charnel.ecst.csuchico.edu!csusac!csus.edu!news.ucdavis.edu!agate!howland.reston.ans.net!gatech!udel!news.mathworks.com!uhog.mit.edu!news.mtholyoke.edu!world!pazy From: pazy@world.std.com (Offer Pazy) Subject: Re: Task Scheduling in Applications Written in Ada Message-ID: Keywords: Real-Time Task Scheduling Organization: The World Public Access UNIX, Brookline, MA References: <3erg9v$28h@caess8.cae.aro.allied.com> Date: Tue, 10 Jan 1995 00:09:52 GMT Date: 1995-01-10T00:09:52+00:00 List-Id: In article <3erg9v$28h@caess8.cae.aro.allied.com>, Dar_Tzen wrote: >Dear Ada group subscribers: > >Is there any one out there familiar with the way to impose scheduling >algorithms of our own into real-time applications written in Ada >(Ada83 or Ada9x)? > >As we know, there are some scheduling algorithms implemented in the >entry, accept and select constructs of Ada83, but these algorithms >are not satisfactory in most time-critical real-time applications. >If we want to use our own scheduling algorithm(s), then what are the >ways to make our own and ada scheduling algorithms work together >(or disable the Ada algorithm)? Does any one know or have experience >on this? >Thanks in advance for your information. A comprehensive answer to the above would probably require several MB's of text (:-) since so much was published about this particular issue, but maybe there are some good souls on the net... Very briefly: 1. If youtalk about Ada 83, you don't have many choices. First because the language rules are quite restrictive (to customization) and second, there are not enough primitives to tailor the scheduling behavior. 2. For Ada 95, the situation is somewhat better: If you are talking from the perspective of someone who has access to the RTS sources, then the language and the RT annex allow you a lot o fflexibility within the leagl model. But only few have this access, so 3. As a user of Ada 95, you can use the Requeue statement to implement "almost" any preference control you would like when it comes to entry calls and accepts. If by scheduling, you are refering to dispatching (i.e. assignment of the CPU(s) to ready tasks), then you may want to utilize the dynamic prioirties capability and by adjusting tasks priorities control when they execute. This solution, is not perfect and has some limitations, but it can support simple solutions. (Originally, there was much more in that area, but it got reduced in the review process). I don't have a good bibliography on the subject handy, but the 95 rationale contains some useful advice on this topics ( I hear that it is supposed to be published on the ajpo machine soon). Offer Pazy