I really like the Repa
interface, despite its concurrency capabilities. And I really need repa arrays to be consistent, since my arrays are relatively small, and parallelizing them is useless, even harmful.
However, I use parallelization in my program with parallel io, so I compile it -threaded
and run with +RTS -Nx
. And it allows parallelization for repa. Is there a way to disable repa concurrency functions?
Hm, when writing this, I realized that it was unlikely that I would need something else and then DIM1
, so maybe I need to switch to Vector
. Nevertheless, the answer to the question will be useful.
A warning message that I get with parallel running,
Data.Array.Repa: Performing nested parallel computation sequentially. You've probably called the 'force' function while another instance was already running. This can happen if the second version was suspended due to lazy evaluation. Use 'deepSeqArray' to ensure that each array is fully evaluated before you 'force' the next one.
I don't really have force
in my code.
Yrogirg
source share