Open chrismwendt opened 1 year ago
Hey 👋
I've also tried my hands at a Haskell implementation, and it's at runjak/async-runtimes-benchmarks.
While I was aware of Control.Concurrent.Async I went with Control.Concurrent.Chan instead (and quite a long list, that I suspect growing slow). How would you feel about introducing separate subdirectories?
I must also admit that I went for a bit of a more naïve setup (no stack, no cabal, only ghc ^^).
Anyway, in terms of results - I'm aiming to write them up a bit more, but so far I got 575428
and 694560
the results.
I think the decision around RTS stuff makes a big difference with Haskell.
Most recent changes on my end get 465220
(<470MB) for 1M when running single threaded, but 9611132
(>9.6GB) when compiling with -threaded -rtsopts -with-rtsopts=-N
and running on 8 threads.
Sorry for being so spammy. Upon further investigation I'm not currently confident that my attempts actually run as concurrent as desired.
With your code I get comparable memory usage - which is somewhat unexpected to me, but quite interesting nevertheless.
Thanks for sharing it 🙏
stack run coroutines 1000000
(1M) uses 12GB of RAM on my machine.