Hacker News new | ask | show | jobs
by bjoli 24 days ago
you can implent something like futures on top of cml and use it as async. then you get async for stuff where async is useful and a proper way to write parallel programs for when async would lead to all the bad stuff async leads to.

i rarely write gui stuff and I find async is rarely what I need. in f# I at least have the option to use hopac.

1 comments

> and a proper way to write parallel programs for when async would lead to all the bad stuff async leads to.

you need real threads for parallelism though? And real threads scale just fine such that m:n threading isn't typically needed.

that is one of the reasons async is everywhere. proper threads are not enough. 2 threads are great at doing 2 things at once, but unless you have the hardware 1000 threads scale very badly at doing 1000 dings at once.

with CAS, making a multicore cml is not too hard.