4 ms·
It's odd how he goes out of his way to make the Go team's decisions seem strange just because they're different. What's going on there? I'm happy that the Go t
by skybrian 7y ago
It's odd how he goes out of his way to make the Go team's decisions seem strange just because they're different. What's going on there?
I'm happy that the Go team doesn't want to expose tuning knobs. I've seen a lot of people fiddle with JVM settings without doing the controlled experiments needed to see if it actually helps on a particular machine and I've done that myself. It ends up as cargo-cult programming, like people sharing magic JVM settings on the wiki to allegedly make IntelliJ faster. (It worked for one person!)
- apta 7y ago> I've seen a lot of people fiddle with JVM settings without doing the controlled experiments That's a problem with what the people are doing then, not the JVM. Furthermore, the new low latency JVM GCs only have 2-3 knobs to tune. golang likes to pretend that complexity doesn't exist, and goes for the most simplistic approach, at the cost of things like throughput, code size, speed, code maintainability, etc. The JVM is suited for a much wider range of tasks.
- hu3 7y agoThat's not the impression I get from Go literature at all. Go authors tend to be quite humble about Go being targeted mostly to a specific class of software, read servers. And Go is pretty darn successful at it. The lack of GC knobs is an informed decision within that context.
- apta 7y ago"Servers" refers to a broad range of software. If you're writing a simple app that parses JSON and handles REST, it can be an ok fit. Now if you're writing server software that needs to be high-throughput, then that's where you hit golang's limitations.
- hu3 7y agoHigh throughput servers you say? I'll just leave this here: > How We Built Uber Engineering’s Highest Query per Second Service Using Go https://eng.uber.com/go-geofence/ https://eng.uber.com/go-geofence/ And that was in 2016. Go's GC performance characteristics improved quite a bit since then.
- apta 7y agoThis doesn't negate the fact that I stated. You can throw more hardware at the problem to reach higher throughput if your problem domain allows for it (such as the use case you link to). It goes without saying that this is an inefficient approach, not to mention that this won't apply if you're running batch jobs for instance where you need high throughput (e.g. on individual nodes).
- HALtheWise 7y agoThey have had a personal bone to pick with the Go team for a while as a result of some of their marketing language around low-latency GC designs. It sounds to me like their personal work focuses on high-throughput designs, and an increasing industry emphasis on low latency threatens that.
- pcwalton 7y agoIt's not that the Go team's decisions are different; it's that they are worse for most applications. If you read the first part of the series, the author goes into detail on this. The problem is essentially that the Go GC focuses entirely on latency at the expense of throughput, which is not the best choice in most cases.
- skybrian 7y agoWell, yes, he says that, but I'm not sure it's an objectively worse tradeoff? It seems like it depends on what you think "most apps" are like. It's not obvious to me that throughput is usually more important than latency, since latency is what the user sees and throughput has more to do with how many machines you need.
- pcwalton 7y ago> It's not obvious to me that throughput is usually more important than latency, since latency is what the user sees and throughput has more to do with how many machines you need. No, it's not true that "latency is what the user sees". Only for interactive applications is that true. In fact, given a choice between the two, I would generally choose throughput over latency. The Go compiler is an example of an application in which throughput matters 100% and latency matters 0%. Even with some semi-interactive tools like ripgrep, throughput matters much more than latency, because throughput determines how quickly the search finishes. Even for servers, throughput often matters more in ways beyond how many machines you need. Would you rather have a Web page that takes 10 ms to load with 1 in 10,000 loads taking 2 seconds, or a page that takes 200 ms across-the-board? I'd take the former. Remember that another name for throughput in this context is allocation performance, which makes it clear how important it is.