2 ms·
As a VM implementer, I conclude nothing from the observation that Go is slower on this test. Because it’s a bullshit loop that I wouldn’t ever write and neither
by pizlonator 2y ago
As a VM implementer, I conclude nothing from the observation that Go is slower on this test. Because it’s a bullshit loop that I wouldn’t ever write and neither would anyone else unless they were trying to troll people with nonsense “experiments”.
The fact that you’re drawing information from the fact that Go is slower on this loop is just you being mislead by a bad experiment.
If you want to understand Go’s performance, run some real benchmarks. My understanding is that Go is plenty fast.
- pkolaczk 2y agoA simple loop like that running slower tells that the compiler optimization strength is not really very good. If it misses optimizations of trivial code like looping and basic arithmetic, it will likely miss even more in complex code. And instead of getting defensive about your language of choice, the right reaction is what Dart developers did - they improved their compiler. The benchmark proved actually useful to them. This benchmark is not any less real than your “real world” benchmark. By being a simple micro benchmarks it may be actually even more useful than running very complex “real world” code, because it simplifies analysis.