Christian Schoenebeck wrote:
Es geschah am Sonntag 05 Juni 2005 04:18 als Erik de
Castro Lopo schrieb:
I also find Ocaml a better high level language
than Python because
it is strictly and statically typed as well as compiling to native
binaries which come close to the speed of C. The (very flawed IMO)
language shootout puts Ocaml compiled to native binaries as faster
than C++ but slower than C.
Hooo, that is a very brave claim,
Not my claim. The claim is here:
http://shootout.alioth.debian.org/benchmark.php?test=all&lang=all&s…
I believe that this shootout is somewhat flawed in that the examples
are all relatively short pieces of code unlike anything that even
approaches real world code.
It should be noted that the benchmark attempts to use the technique
most approriate for the language. So, for the count words example,
the C++ version uses std::vector from of the STL:
http://shootout.alioth.debian.org/benchmark.php?test=wc&lang=icpp&i…
while the C version uses standard C arrays:
http://shootout.alioth.debian.org/benchmark.php?test=wc&lang=icc&id…
Are you surprised that C arrays are faster than std::vector?
Erik
--
+-----------------------------------------------------------+
Erik de Castro Lopo nospam(a)mega-nerd.com (Yes it's valid)
+-----------------------------------------------------------+
" Baldie is such a wonderful villain
The Linux/OSS community could not possibly ask for a better villain than
our man Baldie. He is absolutely perfect for the part. Just look at his
creds: 1) Physically repulsive; 2) Morally bankrupt; 3) Megalomaniacal;
4) Possessed of a truly nasty, abusive disposition; 5) Prone to Hitlerian
ranting; 6) Stalinesque paranoia... The list just goes on and on. The man
has the gift of true despicability, no doubt about it. If it weren't for
Baldie we'd be stuck with Bilgatus' merely vacuuous and creepy persona
for an anthropomorphization of the Evil Empire -- tepid at best."
-- Matthew Alton in
LinuxToday.com on Steve Balmer