
I don't know a lot about parallel Haskell, so I'm wondering in general terms how that would work with my M2 Mac. I have a search task that's easily run in parallel. For example, I might map a function over a list, and each item's evaluation can run in parallel. On the M2 MacBook I have, there are 4 efficiency cores with 1 thread each, and 8 performance cores with 2 threads each. Is it fairly easy to use parallel Haskell to spread the task over these 20 possible threads? By any chance could I limit it to using the performance cores if that helps the speed? Thanks, Dennis

I'd also be curious to know if you can somehow distinguish the types of
cores from each other, but otherwise all the usual parallel stuff should
work on Arm-based Macs as it works on other platforms supported by GHC. The
book described at https://simonmar.github.io/pages/pcph.html is still the
best source for learning about parallel Haskell.
On Fri, 19 Jan 2024 at 08:22, Dennis Raddle
I don't know a lot about parallel Haskell, so I'm wondering in general terms how that would work with my M2 Mac. I have a search task that's easily run in parallel. For example, I might map a function over a list, and each item's evaluation can run in parallel. On the M2 MacBook I have, there are 4 efficiency cores with 1 thread each, and 8 performance cores with 2 threads each. Is it fairly easy to use parallel Haskell to spread the task over these 20 possible threads? By any chance could I limit it to using the performance cores if that helps the speed?
Thanks, Dennis _______________________________________________ Haskell-Cafe mailing list To (un)subscribe, modify options or view archives go to: http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe Only members subscribed via the mailman list are allowed to post.

Thanks, I'll check out the book.
On Fri, Jan 19, 2024 at 4:47 AM Bryan Richter
I'd also be curious to know if you can somehow distinguish the types of cores from each other, but otherwise all the usual parallel stuff should work on Arm-based Macs as it works on other platforms supported by GHC. The book described at https://simonmar.github.io/pages/pcph.html is still the best source for learning about parallel Haskell.
On Fri, 19 Jan 2024 at 08:22, Dennis Raddle
wrote: I don't know a lot about parallel Haskell, so I'm wondering in general terms how that would work with my M2 Mac. I have a search task that's easily run in parallel. For example, I might map a function over a list, and each item's evaluation can run in parallel. On the M2 MacBook I have, there are 4 efficiency cores with 1 thread each, and 8 performance cores with 2 threads each. Is it fairly easy to use parallel Haskell to spread the task over these 20 possible threads? By any chance could I limit it to using the performance cores if that helps the speed?
Thanks, Dennis _______________________________________________ Haskell-Cafe mailing list To (un)subscribe, modify options or view archives go to: http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe Only members subscribed via the mailman list are allowed to post.

Hi Dennis,
For easy concurrent/parallel processing you may find the Haskell
library "streamly" to be helpful. Please see the quick tutorial here:
https://streamly.composewell.com/streamly-0.9.0/User/Tutorials/quick-overvie...
. There are some concurrency/parallelism examples provided in this
tutorial. If you want to run some external programs concurrently and
process the output in a Haskell program you may also want to take a
look at the streamly-process package here:
https://hackage.haskell.org/package/streamly-process .
In case you need further help on using the library, I can help you
out. I am a contributor to the library.
-harendra
On Fri, 19 Jan 2024 at 11:52, Dennis Raddle
I don't know a lot about parallel Haskell, so I'm wondering in general terms how that would work with my M2 Mac. I have a search task that's easily run in parallel. For example, I might map a function over a list, and each item's evaluation can run in parallel. On the M2 MacBook I have, there are 4 efficiency cores with 1 thread each, and 8 performance cores with 2 threads each. Is it fairly easy to use parallel Haskell to spread the task over these 20 possible threads? By any chance could I limit it to using the performance cores if that helps the speed?
Thanks, Dennis _______________________________________________ Haskell-Cafe mailing list To (un)subscribe, modify options or view archives go to: http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe Only members subscribed via the mailman list are allowed to post.
participants (3)
-
Bryan Richter
-
Dennis Raddle
-
Harendra Kumar