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,fd3a5ba6349a6060 X-Google-Attributes: gid103376,public From: robert_dewar@my-dejanews.com Subject: Re: should I be interested in ada? Date: 1999/02/23 Message-ID: <7atdf0$gu6$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 447354081 References: <7a72e6$g55$1@probity.mcc.ac.uk> <36C93BB4.1429@ecs.soton.ac.uk> <7afc1o$3mi$2@plug.news.pipex.net> <7afttr$7v3$1@nnrp1.dejanews.com> <7aganu$qsc$1@plug.news.pipex.net> <36CC3AEA.59E2@lanl.gov> <7ai502$6an$1@nnrp1.dejanews.com> <36CD8DBA.237C@lanl.gov> <7akvao$j5t$2@plug.news.pipex.net> <7aldu1$4q$1@nnrp1.dejanews.com> <7aslfp$gpq$1@plug.news.pipex.net> X-Http-Proxy: 1.0 x13.dejanews.com:80 (Squid/1.1.22) for client 205.232.38.14 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Tue Feb 23 05:14:15 1999 GMT Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.04 [en] (OS/2; I) Date: 1999-02-23T00:00:00+00:00 List-Id: In article <7aslfp$gpq$1@plug.news.pipex.net>, "Nick Roberts" wrote: > Perhaps Robert should re-read RM95 11.6 (6). Only the > intervention of an independant subprogram (in the loop) > would cause the problems he suggests. Well that's good for a laugh! Robert helped write 11.6, and has spent hundreds of hours over the years understanding what it means. If you think it really means that Ada can provide as much parallelism as Fortran, it is probably you who are misreading 11.6. This is a pretty (in)famous section of the RM. All of us know this number so well that we insisted that the same section number be used in RM 95 (we just could not imagine this being called anything but 11.6). 11.6(6) has been discussed and dissected over a long period, but there is nothing in it to suggest that the kind of parellelism you suggest is possible. For example: for all J in 1 .. N loop S := S + D(J); end loop; The FOR ALL here implies that the additions can be done in any order. If we write the above loop without the ALL, there is ABSOLUTELY no permission anywhere in the RM (including in 11.6(6) that would allow the additions to be done in other than the canonical order). Note that the model interval of the result can of course be changed by changing the order of additions! There are many other similar examples > In most code, there will be no such subprogram, but, anyway, in just about > any speed critical code an independant subprogram can almost always be > avoided (by changing the place its body is declared in the source text, or > making it inline). > > |This means that FOR ALL is in a sense even more crucial > |in Ada (which doesn't have it) than in Fortran 95 (which > |does). > | > |All this was covered in rather excruciating detail in the > |thread a few years ago about implementing FOR ALL in Ada. > > I never saw this thread: I shall have a little search on DN. [The trouble > with DN is that there must be tens of thousands of posts per year, even on a > 'signal-dense' NG like CLA. To review it all would be a Herculean task (give > a smelly stables any day :-).] > > [BTW I would like to restate that I am very pleased - most gratified > really - to see answers to my silly posts from the likes of Professor > Dewar, a man who has a rare depth of experience in the field (of computer > science and the development of programming languages). My personal > philosophy is that the only way to learn is to make mistakes. To have your > mistakes pointed out to you by the experts is a privilege. I say what I > really think (you may have noticed ;-), and I do not give praise lightly.] > > ------------------------------------- > Nick Roberts > ------------------------------------- > > -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own