4 ms·
Go GCs fewer things, though. At least in my experience -- this isn't a hard fact :) To me, Go feels like C-but-some-things-are-GCd, which Java is not. The expl
by Manishearth 10y ago
Go GCs fewer things, though. At least in my experience -- this isn't a hard fact :)
To me, Go feels like C-but-some-things-are-GCd, which Java is not. The explicit sharing annotations in Go means that it's super easy for it to not put most of the things on the GC heap, and it's super easy for me, the programmer, to see what's not being put on the GC heap. Whenever I've debugged Go code this been validated.
But yes, it's not as clear cut. I ignored the threading runtime being a factor, and ignored that Java has a better GC (though it GCs more things).
I also ignored JIT as steve pointed out to me in irc.
So yeah, there could be language reasons behind the benchmark order too. Worth investigating though, I'm sure the folks using fasthttp would love a perf boost :)