benchmarks
benchmarks copied to clipboard
Added functional programming version of go bf2
Made a version of the go interpreter that matches the Scala implementation instead of the standard struct based system.
Performance is better as well :)
hm seems this is slower for bench.b, 5.36s -> 5.57s, for mandel.b it faster 100s -> 70s, but for gccgo it also slower.
That seems strange it would be slower for bench.b but faster for mandel.b.
I didn't test with gccgo locally (only go 1.7.3 on ubuntu 16.04).
I can do some more benching and see if I can figure out why that would be. Could you try a few times and see if that time was just a fluke?
mandel.b Go 75.26s, 2.7Mb Functional Go 48.05s, 1.7Mb
For bench.b I see Go 4.34s, 1.4Mb Functional Go 3.10s, 1.4Mb
I ran the tests about 10 times and didn't see much divergence from what I pasted here.