From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.5-pre1 (2020-06-20) on ip-172-31-74-118.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-1.9 required=3.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.5-pre1 Date: 24 Oct 92 13:01:20 GMT From: pipex!warwick!uknet!yorkohm!minster!mjl-b@uunet.uu.net Subject: Real time and concurrency (was: What is real-time?) Message-ID: <719931680.25559@minster.york.ac.uk> List-Id: In article <1992Oct22.153813.15179@mksol.dseg.ti.com> mccall@mksol.dseg.ti.com (fred j mccall 575-3539) writes: >In <719335132.5132@minster.york.ac.uk> mjl-b@minster.york.ac.uk writes: >>The Burns and Wellings book writes off C fairly early on, because it has no >>features for concurrency. Real-time and concurrency go hand in hand, and the >>authors provide a fairly convincing argument. > >How many languages (other than Ada) actually provide support for >concurrency (as opposed to getting it from the OS)? The book covers Ada, Modula, Modula-2 and occam, all of which provide concurrency features. Other concurrent languages get a mention, but the above are the "main" langauges used. >Does this mean >that there was no such thing as real time software until Ada was >available? Of course not. My point is that a concurrent language makes the expression and maintenance of real-time programs far easier. Real time software is most often inherently concurrent, and it makes the job so much harder if those concurrent tasks have to be forced into a sequential form. Not only have you lost the inherent structure of the design in the implementation, the expression of other real-time concerns such as deadline constraints on a particular task becomes much harder. For example, you have three tasks that must run concurrently: P, Q and R. If you have a concurrent language, you simply map them to the unit of concurrency. In a sequential language, you must split up P, Q and R into, say, three bits, so that you can interleave their execution: P1; Q1; R1; P2; Q2; R2; P3; Q3; R3; Now try and express the constraint that P must complete its execution within 2.0 seconds of when it started... not impossible, but already the program's difficult to understand and maintain. The trade off is between manually interleaving P, Q and R at the coding stage, and letting the language do it at run time. I know which one I'd rather maintain :-) >An awful lot of real-time software has been written in >LANGUAGES to provide no support for concurrency (like assembly). Yes, it has. But how easy was it to write, debug and maintain? >There seems to be something a bit off about this line of reasoning. The reasoning is better explained in Burns and Wellings' book -- read it and then make your judgement. >Fred.McCall@dseg.ti.com - I don't speak for others and they don't speak for me . Mat | Mathew Lodge | "A conversation with you, Baldrick, | | mjl-b@minster.york.ac.uk | and somehow death loses its sting..." | | Langwith College, Uni of York, UK | -- Blackadder II |