Earlier quoted context omitted.
3% regression in QPS, 20% regression in CPU, and 5% regression in memory usage according to the article. Those are considerably worse than "5 orders of magnitude below".
GP meant 5 orders of magnitude below "20 ms". 20 ms is a lot of time. There is nothing one can do to a, say, a 1 kilo byte buffer that will cross 1 ms in any language. My own Go code doesn't cross more than few micros per message.
A new ProtoBuf generator for Go
21–30 of 78 posts
Re: A new ProtoBuf generator for Go
#22Earlier quoted context omitted.
Proto message unmarshal in Go for a small message should be 5 orders of magnitude below 20ms, shouldn't even begin to matter until you are sweating individual microseconds.
Until the GC kicks in and steals a full 200usec + a bunch of your throughput... (Holy shit, who is downvoting this? It's literally the whole article!)
Re: A new ProtoBuf generator for Go
#23Earlier quoted context omitted.
Properly written Go code (or even Java for that matter) will try to minimize allocations. For Java, unless I am mistaken pause-less GC is only offered by Azul - $$
>or even Java Just in case you may be unaware, the latest GCs for Java (Shenandoah, ZGC) are miles ahead of anything available for Go due to sheer age and manpower. Parallel and Pauseless are easily achievable in most cases.
Beyond hyperbole, do you have any actual comparison of Go vs Java GC performance?
Re: A new ProtoBuf generator for Go
#24Earlier quoted context omitted.
Not only that, there are other garbage collected languages like D, Nim and C# that offer the language features to do arenas without having to touch any C code. There is still so much education to do.
Aren't arenas old news in GC languages in general? Most of the time, their non-presence is due to general pools being just as good most of the time, or people simply not needing them that much with modern GC
Probably lack of experience with machine friendly code.
Re: A new ProtoBuf generator for Go
#25> Arenas are, however, unfeasible to implement in Go because it is a garbage collected language. If you are willing to use cgo, google already implemented one for gapid. https://github.com/google/gapid/tree/master/core/memory/aren...
Not only that, there are other garbage collected languages like D, Nim and C# that offer the language features to do arenas without having to touch any C code. There is still so much education to do.
Re: A new ProtoBuf generator for Go
#26I'm not sure that the phrasing in the article is particularly fair: > The maintainers of Gogo, understandably, were not up to the gigantic task. I'm 99% sure they are "up to" (as in "capable of") doing so, they are just not "up for" it (as in, "will not do it").
Re: A new ProtoBuf generator for Go
#27Earlier quoted context omitted.
Not only that, there are other garbage collected languages like D, Nim and C# that offer the language features to do arenas without having to touch any C code. There is still so much education to do.
I can't believe we've managed to have this lengthy of a discussion about GC languages and speed without anyone mentioning rust. Has HN turned a corner?
Re: A new ProtoBuf generator for Go
#28Earlier quoted context omitted.
Not only that, there are other garbage collected languages like D, Nim and C# that offer the language features to do arenas without having to touch any C code. There is still so much education to do.
Do I misunderstand what arenas are? I thought it was just "allocate this big array as a single allocation rather than N little allocations"? If so, how is that not supported in Go? (e.g., `arena := make([]Foo, 1000000000)`)
Re: A new ProtoBuf generator for Go
#29Earlier quoted context omitted.
Not only that, there are other garbage collected languages like D, Nim and C# that offer the language features to do arenas without having to touch any C code. There is still so much education to do.
I can't believe we've managed to have this lengthy of a discussion about GC languages and speed without anyone mentioning rust. Has HN turned a corner?
In what concerns me, although I like Rust, I only see it for scenarios where any kind of memory allocation is very precious, Ada/SPARK and MISRA-C style.
I have been using GC languages with C++ like features, or polyglot codebases, for almost 20 years to think otherwise.
Most of the time developers learn about new and miss out on the low level language features.
It is a matter of balance, either trying to do everything in a single language, or eventually write a couple of functions in a lower level language that are then used as building blocks for the rest of the application.
No need to throw away the ecosystem and developer tooling just to rewrite a data structure.
Re: A new ProtoBuf generator for Go
#30Is there one for Kotlin yet? It's pretty pathetic that Google's own protocol lacks native support for its most popular operating system.
Yes: https://developers.google.com/protocol-buffers/docs/kotlintu...
https://medium.com/digitalfrontiers/a-dance-with-protocols-k...