Ah. I didn’t click through and didn’t realize you were speaking of the speed graph; assumed you were talking about the table under “How source code size is measured” here: How programs are measured (Benchmarks Game)
Are you using the original timings from Which programming language is fastest? or the new ones from https://github.com/JuliaPerf/BenchmarksGame.jl ?
Ah, no. That table got me wondering but it’s so old Julia isn’t even in there…
Are you using the original timings […]
Yes, I’m using the timings from the benchmarks website. The “new” ones are actually much older (last update was ~8 months ago) so the data I used represent Julias capabilities better (and more favorably).
I noticed something looking at the Chapel code for pidigits: the author of the Chapel translation really
understood the algorithm, and made a much clearer description that in most other languages. The Julia translation was made without any effort to understand the algorithm: it shows!
Ha! You caught me. In my defense, I did make an attempt to understand the algo from the paper linked in the benchmark description, but I didn’t have time (or inclination honestly) to learn enough Haskell to interpret the paper.
Well, you should just then translate the Chapel code to Julia: you will get a better program!
That’s exactly what I did.
Since you have the data, any chance you could make a list/table of each Julia program sorted by gzipped length relative to the shortest program for each benchmark?
Of course, I’m just not quite sure what you are asking for exactly? 10 tables, one for each benchmark, only Julia programs (but all of them), sorted by factor of gzipped length vs. shortes length?
If you prefer, I can also clean up my messy script and provide that.
Edit: here we go, the script to get the data and create the plot.
I’m way out of my depth in this conversation in general, but I wanted to step in for just this moment and say that Haskell is a very nice, very fun language to learn and use. It’s not as pragmatic as Julia (… or, like, any other language), but learning it is a real treat. Programming in general is meat and potatoes (and some of it is boring veggies). Haskell is dessert.
The Julia version on the website got updated to 1.3 . Unless I managed to gaslight myself, this made the benchmarks run a bit faster:
Julia is now listed ahead of Java, which is an impressive achievement. The only remaining GCed language which is still ahead of Julia on the benchmarks game is C#.
A few months back I run some of the C and Julia benchmarks on my laptop. Excluding compilation time, Julia was much faster than what shown on the website and typically on par with C. I wonder what would happen to your plot if you removed compilation time, i.e. running code twice, after a first “warm-up”.
Including jit warmup time is an intentional design decision of the benchmark game. It hurts languages like Java as well. Many of the tasks are compute-intensive enough that Julia’s compilation time doesn’t matter much, but not all are. Julia’s high rank including compilation I think testifies strongly to the strength of Julia’s approach.
If that’s the case they should include compilation time for the AOT languages.
There’s some sense in their approach in that with the AOT languages you can just compile a binary once and run it multiple times and even distribute it. For Julia, JIT compilation has to happen again every time you quit and restart julia.
However, perhaps this means that there’s room for us to pull a stunt with PackageCompiler where we do a static step, building a custom sysimage for the BenchmarksGames tests with all methods precompiled.
Dropping the compilation time can be a bit misleading even for AOT languages. Languages like C++ and Rust move some computations to compile time, this places them in front of C and Fortran in some benchmarks, which is definitely not true. Also, compilation time in Julia seems mostly constant, regardless of the input size, which is really great.
We are quite capable of this in Julia as well. Compile time computations are incredibly important for high performance computing in general and I see no reason why it should be regarded as cheating the benchmarks.
Languages like C++ and Rust move some computations to compile time
Please be specific — which programs ?
We are quite capable of this in Julia as well.
Please don’t.
I think that this is considered cheating by the rules of the game.
Also, I am not sure if the Julia community really needs to prove anything so desperately at this point that rigging this game should even be considered (assuming we could, which I doubt). I think it is widely recognized that this is just a game, not a competition to pick the “fastest” language.