Welcome to the Functional Programming Zulip Chat Archive. You can join the chat here.
What do you all use to utilize more than 1 cpu core in your Haskell program?
(Asking in the context of making neuron do so ...)
have you taken a look at parallel and concurrent programming by Marlow? or are you looking for something more high-level/a "production" example?
the goto is the async library for concurrency and the parallel strategies sparks stuff for parallelism, I'd wager
not sure what the nomenclature is elsewhere
basically a "task" for the rts to schedule on some thread eventually
of the form "evaluate this expression"
A related question: once you’ve parallelised your program, is it possible to get the executable to automatically use all available cores? It seems that you have to pass +RTS -N<cores> to use more than one core, but this is rather inconvenient if you’re making a program for end users who may not even know what a command line is…
I think you can set these to be the "default" rts options
and I think the default stack new template does this already
Fighting multicore GC with -qn1 mostly.
Thanks @Georgi Lyubenov // googleson78 , I didn’t know about either of those! So I can just do -with-rtsopts -N then.