Remix.run Logo
nchie 5 hours ago

> But are we really saying that the primary motivation for async/await is performance?

Of course - what else would it be? The whole async trend started because moving away from each http request spawning (or being bound to) an OS thread gave quite extreme improvements in requests/second metrics, didn't it?

groundzeros2015 5 hours ago | parent | next [-]

I agree. Managing many http requests or responses was a motivating problem.

What I question is whether 1. Most programs resemble that, so that they make it an invasive feature of every general purpose language. 2. Whether programmers are making a conscious choice because they ruled out the perf overhead of the simpler model we have by default.

swiftcoder 4 hours ago | parent [-]

That is why we have the function colouring problem and a split ecosystem in the first place - if it were obviously better in all cases, we'd make async the default, and get rid of the split altogether (and there are languages, like Erlang, that fall on this side of the fence)

lukaslalinsky an hour ago | parent | prev [-]

It was not for performance reasons, but for scaling up.

pjc50 an hour ago | parent [-]

That's the same thing?