

Which programming language is fastest? - alifaziz
http://shootout.alioth.debian.org/fastest-programming-language.php

======
bcl
The fastest language is the one that you know well enough that you are
actually able to implement and release your ideas to your users. Benchmarks
speed is only one part of the equation.

~~~
igouy
Nope - that's the fastest language for you.

------
lucisferre
I once heard a joke related to this: Dev1: "Did you know C# is faster than C?"
Dev2: "No, really? By how much?" Dev1: "Oh about 6-12 months"

------
russell
"No. ... No."

Benchmarks are worthless unless they accurately model your application and
workload. Is C 42 times faster than Python for doing numerical calculations?
No. If you are using NumPy, the difference is more like 10%. (I pulled the 10%
figure out of my nether orifice, but I believe it to be in the ballpark.) Yes,
I know that NumPy is buckets of C with a tasty Python frosting.

~~~
igouy
> Benchmarks are worthless unless...

There's a page for that! <http://shootout.alioth.debian.org/flawed-
benchmarks.php#app>

> If you are using NumPy...

[http://shootout.alioth.debian.org/u32/program.php?test=spect...](http://shootout.alioth.debian.org/u32/program.php?test=spectralnorm&lang=python&id=2)

------
onan_barbarian
Things we don't need to hear, EVERY LAST TIME anyone says anything
quantifiable about programming language performance:

1\. People are more or less productive in different languages.

2\. If a task can be done mostly in a library the speed of the programming
language is less important.

3\. The performance difference between languages depends on the workload.

------
oddthink
I'm surprised that Racket is beating SBCL. When did that start happening?

~~~
swannodette
They now have JIT compilation.

------
supersillyus
I don't want the fastest possible language or the most powerful possible
language. I want the simplest language that is fast enough and powerful
enough. The Benchmarks game is a lot of fun, but if I were making a language
(especially one not designed for speed), I probably wouldn't put it up there.
It encourages contributors to think "oh crap, if we optimized our X better,
we'd be like 4 higher in the listings!" instead of "What sort of useful code
can I write?".

------
brlewis
I'm impressed that PHP is now less than 20x slower than SBCL and Racket (Lisp
and Scheme implementations). It's improved a lot since PHP4.

------
kumarshantanu
Assembly Language, I guess.

------
alok-g
With so much variation in the time measured for a given language? Fastest to
slowest is approaching a factor of 100 in some cases.

This study is useless (even if meaningful) with this much variation, and no
clear explanation for why so.

~~~
igouy
> Fastest to slowest is approaching a factor of 100 in some cases.

Which cases?

------
aristidb
GHC Haskell is doing surprisingly well. That must be a testament to the
extremely high quality of the GHC code generator and optimizer.

~~~
ww520
Static type gives compiler plenty of information for analysis and can generate
very optimized code.

------
avar
You have to click around to see it, because the default rendering only
includes GNU C++, not GNU C.

~~~
giu
Graph including GNU C: [http://shootout.alioth.debian.org/fastest-programming-
langua...](http://shootout.alioth.debian.org/fastest-programming-
language.php?calc=chart&gcc=on&gpp=on&ghc=on&java=on&csharp=on&racket=on&sbcl=on&v8=on&hipe=on&lua=on&vw=on&python3=on&yarv=on&php=on&perl=on)

------
Synaesthesia
How about LLVM C & C++ ?

~~~
igouy
Here's where you can download the Python measurement scripts so you can make
those LLVM measurements and publish them -
<http://shootout.alioth.debian.org/help.php#languagex>

------
signa11
let's kill all the language lawyers...

------
jeberle
Also notice, time is plotted on a log scale.

------
berntb
Seems quite different compared to what I remember previously. Have some
communities been updating their interpreters/compilers to optimize for these
tests?

(Reminds me of the 1990s when Intel built a special machine (which you could
theoretically buy, to fulfill the demands) and wrote a special compiler for
SPECs... :-)

~~~
draegtun
Could be?... but I suspect its more _communities_ optimising their benchmark
programs.

See footnote: _Which programming language is fastest? No. Which programming
language implementation has the fastest benchmark programs?_

