Skip to content
Prev 9488 / 10988 Next

[Rcpp-devel] Rcpp Parallel is not working

Hi To,

Le 22/12/2016 ? 12:55, To Duc Khanh a ?crit :
As your result is of type "aggregation" (res[0] += ...) wouldn't it be more
appropriate to use parallelReduce() instead of parallelFor()?

Another point to pay attention for is that index domain to cover is
square in your case (i and j) while parallelFor (and Reduce) are
intended to split plain linear index domains. So some additional effort
is needed to treat it properly.

Hoping it helps,
Serguei.