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 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,1d575f572a099528 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-11-30 17:43:56 PST Path: archiver1.google.com!news1.google.com!sn-xit-02!supernews.com!news.tele.dk!small.news.tele.dk!195.158.233.21!news1.ebone.net!news.ebone.net!newsrouter.euroconnect.net!newsfeed.song.fi!news.cc.tut.fi!news.helsinki.fi!not-for-mail From: aaro@iki.fi (Aaro Koskinen) Newsgroups: comp.lang.ada Subject: Re: What is faster Ada or C? Date: 01 Dec 2001 03:43:53 +0200 Organization: University of Helsinki Message-ID: References: <3c08314d$0$158$9b622d9e@news.freenet.de> NNTP-Posting-Host: sirppi.helsinki.fi X-Trace: oravannahka.helsinki.fi 1007171035 21588 128.214.205.27 (1 Dec 2001 01:43:55 GMT) X-Complaints-To: usenet@news.helsinki.fi NNTP-Posting-Date: 1 Dec 2001 01:43:55 GMT X-Newsreader: Gnus v5.3/Emacs 19.34 Xref: archiver1.google.com comp.lang.ada:17259 Date: 2001-12-01T01:43:55+00:00 List-Id: "Heiko Hamann" writes: > I have a program written in Ada that is very processor intensiv. It > does bit and integer operations. What would you guess is the faster > languages for this task? Ada or C - or another language (excpet > Assembler)? Can that be said in common? What is about some > benchmarks concerning this case? Depends heavily on the compiler, really. Basically, if you use the same set of language features you will get the same performance (i.e. turn run-time checks off from the Ada program; similarly don't use assertions in the C program). Ada is very much like the C in the way that it allows you to control *exactly* what's going on at the execution level so you can write very efficient code without worrying about any "implicit overhead". (Also, I would imagine that with Ada's strong typing, the compiler can do better optimizations than an average C compiler. However, I don't have any evidence for this...) A. -- Aaro Koskinen, aaro@iki.fi, http://www.iki.fi/aaro