On Friday, March 20, 2015 at 11:48:40 AM UTC-5, Nils Gudat wrote: > > Thanks, that's a great suggestion! Writing: > > function solveall(agrid, bgrid, cgrid, dgrid) > @sync @parallel for a = 1:length(agrid) > ... > end > return result > end > > @time solveall(agrid, bgrid, cgrid, dgrid) > > Reduces the time to ~4.3s, just about half the time of the single core > implementation! >
It's possible that you might eke a little more out by using SharedArrays, but I'm not sure of all the tradeoffs. I do know in the problem I tried it for, I didn't derive any benefit from that approach.
