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-Thread: 103376,c4cb2c432feebd9d X-Google-Thread: 1094ba,c4cb2c432feebd9d X-Google-Attributes: gid103376,gid1094ba,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!wn11feed!worldnet.att.net!bgtnsc05-news.ops.worldnet.att.net.POSTED!b680011b!not-for-mail From: Dick Hendrickson User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada,comp.lang.fortran Subject: Re: Ada vs Fortran for scientific applications References: <0ugu4e.4i7.ln@hunter.axlog.fr> <%P_cg.155733$eR6.26337@bgtnsc04-news.ops.worldnet.att.net> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: NNTP-Posting-Host: 69d27de9fac4599aee5ef6a06a81ac41 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc05-news.ops.worldnet.att.net 1148504689 69d27de9fac4599aee5ef6a06a81ac41 (Wed, 24 May 2006 21:04:49 GMT) NNTP-Posting-Date: Wed, 24 May 2006 21:04:49 GMT Organization: AT&T Worldnet Date: Wed, 24 May 2006 21:04:50 GMT Xref: g2news2.google.com comp.lang.ada:4435 comp.lang.fortran:10223 Date: 2006-05-24T21:04:50+00:00 List-Id: Dr. Adrian Wrigley wrote: > On Wed, 24 May 2006 17:12:55 +0000, Dick Hendrickson wrote: [snip, discussion mostly of subscript bounds checking and some discussion of subroutine calling consistency] > I think this is an area that Ada really shines. The standard > requires numerous checks for consistency at both compile > time and runtime. Versions of code that don't match properly > can't be linked together or can't be run together (as appropriate). > Using the language gives a feeling of integrity of coding, > with mistakes often being caught very early on. > > Unfortunately, the language features for integrity cannot > be added to an existing language without breaking old > code. This is because the integrity features are often a result > of prohibiting "dodgy" code, flawed syntax or misfeatures. Yes, in Fortran 90 the decision was made to allow complete compatability with existing standard conforming code. For good or bad, old code written in the 60s dealt with 32,000 word memories and, as a result, the standard adopted features that let memory be reused and viewed in different ways. COMMON, EQUIVALENCE, the ability to magically reshape arrays across the CALL boundary, alternate ENRTY points in subroutines and functions all, in my opinion, trace their ancestry to dealing with small memories and slow (or nonexistent) rotating storage. Keeping those codes alive required some compromises. The need for separate compilation of 1,000,000 line programs and the use of well tested existing libraries (often in C or assembly) basically prevented Fortran from adopting strict CALL interface rules. However, I think more and more libraries are being retro-fitted with a clean module interface where possible. So things are getting better. There's no real excuse for writting a new program without using modules to specify the interfaces and this essentially guarantees that the compiler will do the right thing. One serious practical problem with large codes has been compilation cascades. Any change to a low-level module almost always forced a recompilation of everything that used the module, even if the change had no effect on the interfaces. This is mostly due to the way make interacts with the commonest implementation of modules, I think. This will be fixed (or at least changed ;) ) in F2008. Dick Hendrickson