Re: C vs. Ada performance (Wilbur Streett)
3 Jan 1997 23:17:24 -0500

          From comp.compilers

Related articles
Re: Possible to write compiler to Java VM? (W. Wesley Groleau (Wes)) (1997-01-02)
Re: C vs. Ada performance (1997-01-03)
Re: C vs. Ada performance (Walter Banks) (1997-01-04)
Re: C vs. Ada performance (Dean Sutherland) (1997-01-07)
Re: C vs. Ada performance (1997-01-12)
| List of all articles for this month |

From: (Wilbur Streett)
Newsgroups: comp.compilers
Date: 3 Jan 1997 23:17:24 -0500
Organization: Monmouth Internet
References: 97-01-019
Keywords: C, Ada

W. Wesley Groleau (Wes) <> wrote:

>Comparing C with Ada: the amount of semantic consistency required by Ada
>and shunned by C is the reason why code optimizers for Ada can do so much
>more. (I don't care whether you post this or not. comp.lang.ada has had
>several very lucid discussions of this point in recent months.)

>[Do Ada compilers really generate better code than C compilers for similar
>source code? -John]

Ada compilers do more because they are farther away from abstraction
of the hardware. That doesn't mean that the resulting code generated
is faster, it means that the Ada code is typically written farther
away from the hardware level in the first place. I would imagine that
a good C coder would consistently generate faster code than an Ada
programmer would. There's much less chance that a C programmer would
get very far away from the most optimized algorithms, since the
abstraction is so close to the hardware level.

Claims that Ada generates faster code seem like a straw horse to me,
as Ada as a language reminds me so much of PL/I. Optimization by the
compiler may be a good thing, but nothing beats code that is written
cleanly in the first place.


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.