haskell / haskell/parallel

The interaction of runEval, rpar, and rseq is underdocumented

Open
#18 0 comments 2 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
98
Forks
24
PR merge metrics
No merged PRs in 30d

Description

(IMHO). It has never really been clear to me when I should use `rseq`, even after reading this chapter: http://chimera.labs.oreilly.com/books/1230000000929/ch02.html#sec_par-rpar-rseq

What I'm lacking I think is an intuitive sense of how or when we "block" waiting for a parallel computation to return. Is it the case that once a spark is "converted" to a thread then evaluation of the sparked thunk will block? At what point exactly do sparks fizzle, and how does this relate to the whims of lazy evaluation? Does `-feager-blackholing` come into play here? Do data dependencies matter at all in this?

I was motivated to open this after reading https://ghc.haskell.org/trac/ghc/ticket/14330 and realizing I don't have a strong sense of what's going on when doing pure parallelism.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.