Ada compilers can generate code comparable to C, C++, and Pascal compilers. Because of the way Ada was designed, Ada compilers can sometimes generate better code because they have more information that can be used for code optimization. For example, in a large number of cases an Ada compiler can do better than a C or C++ compiler can while passing parameters, because an Ada compiler knows when aliasing is not possible.
Some Ada compilers, such as the GNAT and DEC VAX Ada compilers, use the same (back-end) code generators as many other languages, and on those systems the Ada compiler's results should be at least as good as for other languages.
One paper that discusses this further is ``C vs. Ada: Arguing Performance Religion'' by David Syiek .
It is true that Ada run-time error-checking capabilities require some time and space, but they can be selectively or completely turned off. Since Ada compilers can often detect and optimize these away, they often do not have as much of a performance hit as you might expect even when left in.
You may go back to the question
You may also:
|Skip to the next section.||Go up to the outline of lesson 1|
David A. Wheeler (firstname.lastname@example.org)
The master copy of this file is at
The master copy of this file is at "http://www.adahome.com/Tutorials/Lovelace/s1s1r3.htm".