From: "John B. Matthews" <nospam@nospam.invalid>
Subject: Re: Is there an Ada compiler whose Ada.Numerics.Generic_Elementary_Functions.Log(Base=>10, X=>variable) is efficient?
Date: Mon, 15 Feb 2010 12:19:35 -0500
Date: 2010-02-15T12:19:35-05:00 [thread overview]
Message-ID: <nospam-2DF182.12193515022010@news.aioe.org> (raw)
In-Reply-To: alpine.LNX.2.00.1002151339400.17315@Bluewhite64.example.net
In article
<alpine.LNX.2.00.1002151339400.17315@Bluewhite64.example.net>,
Colin Paul Gloster <Colin_Paul_Gloster@ACM.org> wrote:
> Thanks for running it. The Ada program for timing had 500 statements
> in the body of the loop. I reproduced only the first and last
> verbatim: I showed a bash (Bourne Again SHell) line for producing
> all 500 statements in a comment in-between the the first statement
> and the last statement. You ran a program with 498 of the statements
> missing.
Ah, source level compression!
> Anyway, the answer produced by the program is not so much of concern
> as the relative speeds of different implementations. Did g++
> produce a faster result for you than GNAT? It did for me for many
> versions of GCC today on a different platform than I used in the
> beginning of this thread...
Retesting both 500+ line programs produces results similar to yours:
$ make test
Darwin: gcc 4.3.4
rm -f *.o *.ali b~* core
rm -f *.s temp.txt logada logcpp
gnatmake logada -cargs -O3 -gnatnp -bargs -shared -largs -ffast-math
-dead_strip
gcc -c -O3 -gnatnp logada.adb
gnatbind -shared -x logada.ali
gnatlink logada.ali -shared-libgcc -ffast-math -dead_strip
g++ -O3 logcpp.cc -o logcpp
time ./logcpp
6.35785e+08 0.57 real 0.56 user 0.00 sys
time ./logada
6.35785378608776E+08
28.15 real 28.10 user 0.02 sys
--
John B. Matthews
trashgod at gmail dot com
<http://sites.google.com/site/drjohnbmatthews>
next prev parent reply other threads:[~2010-02-15 17:19 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-15 10:58 Is there an Ada compiler whose Ada.Numerics.Generic_Elementary_Functions.Log(Base=>10, X=>variable) is efficient? Colin Paul Gloster
2010-02-15 13:02 ` John B. Matthews
2010-02-15 14:17 ` Colin Paul Gloster
2010-02-15 17:19 ` John B. Matthews [this message]
2010-02-15 14:54 ` jonathan
2010-02-15 15:04 ` jonathan
2010-02-15 19:50 ` sjw
2010-02-16 16:50 ` Colin Paul Gloster
2010-02-15 18:26 ` (see below)
2010-02-15 18:51 ` jonathan
2010-02-15 20:00 ` sjw
2010-02-15 21:17 ` jonathan
2010-02-16 0:09 ` jonathan
2010-02-16 17:33 ` Colin Paul Gloster
2010-02-24 10:07 ` Colin Paul Gloster
2010-02-15 23:04 ` Jeffrey R. Carter
2010-02-16 14:54 ` Colin Paul Gloster
2010-02-16 15:24 ` Colin Paul Gloster
2010-02-16 19:01 ` Jeffrey R. Carter
2010-02-17 10:25 ` Colin Paul Gloster
2010-02-15 23:20 ` Randy Brukardt
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox