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,9adfbb907494972e X-Google-Attributes: gid103376,public X-Google-Thread: 1014db,9adfbb907494972e X-Google-Attributes: gid1014db,public From: ken@coho.halcyon.com (Ken Pizzini) Subject: Re: Ada to C/C++ translator needed Date: 1996/09/29 Message-ID: <52ltk5$qlf@news1.halcyon.com>#1/1 X-Deja-AN: 186028142 references: <32499FA0.4B5E@magic.fr> <52e5t5$m28@btmpjg.god.bel.alcatel.be> <52feul$os2@goanna.cs.rmit.edu.au> <01bbad6e$67743f20$32ee6fcf@timhome2> organization: What, me? newsgroups: comp.lang.c,comp.lang.ada Date: 1996-09-29T00:00:00+00:00 List-Id: In article <01bbad6e$67743f20$32ee6fcf@timhome2>, Tim Behrendsen wrote: >Richard A. O'Keefe wrote in article ><52feul$os2@goanna.cs.rmit.edu.au>... >> Just for the record, here's the result of a speed test between C, Ada, >> Scheme, and Fortran versions of the same numerical program, on an >> UltraSPARC. >> cc and f77 are SPARCompiler C and Fortran version 4.0. >> gnat is 3.04 with gcc back end 2.7.2. stalin was version 0.6. >> >> cc 30 seconds >> gnat 27 seconds >> stalin 26 seconds (Siskind's Scheme->C then gcc 2.7.2) >> f77 25 seconds >> >> The f77 code came from a book. I wrote the C, Ada, and Scheme versions. >> I am fluent in C and Scheme, striving to become so in Ada. >> >> I can't think of any reason to convert the Ada code to C, >> especially as the Ada compiler that got this result is free >> and supports the Ada 95 *standard* interface with C, so that calling >> existing C code from Ada is a breeze. > >I hope you're not suggesting that comparing compilers on one >system with one program tells you *anything* about the relative >merits of languages ... What I read in his results is that the quality of a compiler is more important to performance than the language. Ignoring the cc result the value "26 +/- 1 seconds" sounds pretty even. It would be interesting (to me, not this group) to know how gcc 2.7.2 would do on the C version of the program, since it shares the same back-end as gnat, and is the C compiler used by the stalin test. --Ken Pizzini