3 ms·
Having checked the C implementations of the algorithms, I'm a little skeptical because the implementations aren't optimized. Tiling matrix multiplication explo
by bjourne 3y ago
Having checked the C implementations of the algorithms, I'm a little skeptical because the implementations aren't optimized. Tiling matrix multiplication exploiting SIMD could easily improve performance 100-fold or more. At those speeds the cost of memory transfer usually dominate so the languages that give you the most fine-grained control over how data is laid out in memory tend to win. And it may not be the same languages that are now winning in your benchmark.
- nerdponx 3y agoI think a benchmark of "naive" implementations is interesting too, because it shows you how fast your code is usually going to run, not how fast it theoretically could run at its best.
- igouy 3y ago> shows you how fast your code is usually going to run Why would you think that? Maybe the "naive" implementation just shows how fast the easily removed hotspot in your code is going to run. "Swap the order of two statements and see the Java code slow down … Swap globals for local variables in a function and see the Python code speed up. Swap language implementations and see the C code speed up." https://benchmarksgame-team.pages.debian.net/benchmarksgame/performance/toosimple.html https://benchmarksgame-team.pages.debian.net/benchmarksgame/...