The Swift Code looks like something you'd write in C.
Like this? (There are 8 other C++ binary trees programs.)
https://benchmarksgame-team.pages.debian.net/benchmarksgame/...
> … or Swift's reference counting.
Like this? (There are 4 other Swift binary trees programs.)
https://benchmarksgame-team.pages.debian.net/benchmarksgame/...
You could look at the different binary trees programs shown on the current benchmarks game.
Most people aren't building applications whose business requirements preclude preallocating memory except for languages which lack garbage collectors.
If we don't experience a performance problem, we don't need a workaround.
Errare humanum est.
"Energy Efficiency across Programming Languages" not "programming language performance in the general case".
I maintain a contrived benchmark is not a useful benchmark.
In this case for Go, the same as other languages that provide a library pool implementation.
Apparently the study authors found a use.
Because as-you-know the whole point is to "allocate zillions of short-lived nodes" —
https://news.ycombinator.com/item?id=29323468