From: Colin Paul Gloster <Colin_Paul_Gloster@ACM.org>
Subject: Re: Is there an Ada compiler whose Ada.Numerics.Generic_Elementary_Functions.Log(Base=>10, X=>variable) is efficient?
Date: Wed, 17 Feb 2010 10:25:03 +0000
Date: 2010-02-17T10:25:03+00:00 [thread overview]
Message-ID: <alpine.LNX.2.00.1002171021590.23841@Bluewhite64.example.net> (raw)
In-Reply-To: <hleqsd$7q5$1@tornado.tornevall.net>
On Tue, 16 Feb 2010, Jeffrey R. Carter sent:
|------------------------------------------------------------------|
|"[..] |
| |
|[..] when comparing execution times between Ada and a language |
|like C++, it's important not to try to compare apples to lugnuts."|
|------------------------------------------------------------------|
Fair enough, but when I say Ada is better than C++ I am not comparing
an apple with an apple.
Anyway, as I mentioned in
news:alpine.LNX.2.00.1002161654110.21651@Bluewhite64.example.net
in response to Bill Findlay, G++ has produced much slower code than
GNAT (the GNATism is in standard Ada, merely the obvious way to do it
in standard Ada is different)...
gnatmake -O3 -ffast-math Logarithmic_Work_In_Ada_with_a_Findlay_loop_with_a_Parker_GNATism_compiled_by_GCC4.4.3_with_-ffast-math.adb -o Logarithmic_Work_In_Ada_with_a_Findlay_loop_with_a_Parker_GNATism_compiled_by_GCC4.4.3_with_-ffast-math
time ./Logarithmic_Work_In_Ada_with_a_Findlay_loop_with_a_Parker_GNATism_compiled_by_GCC4.4.3_with_-ffast-math
6.34086408606382E+08
real 0m14.434s
user 0m14.433s
sys 0m0.004s
g++ -O3 -ffast-math logarithmic_work_in_CPlusPlus_with_a_Findlay_loop.cc -o logarithmic_work_in_CPlusPlus_with_a_Findlay_loop_compiled_by_GCC4.4.3_with_-ffast-math
time ./logarithmic_work_in_CPlusPlus_with_a_Findlay_loop_compiled_by_GCC4.4.3_with_-ffast-math
6.34086e+08
real 0m38.388s
user 0m38.390s
sys 0m0.000s
next prev parent reply other threads:[~2010-02-17 10:25 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
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 [this message]
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