Hi there,
I have written a simple distributed matrix multiplication code
in chapel.
The main part of the code is
var D: domain(2) dmapped Block(boundingBox={1..n,1..n})= {1..n,1..n}
which declares domain mapping of type Block and this Block type helps to
distributes data
into multiple nodes. So now I create an Array for them to distributed along
the nodes.
var A,B,C:[D] int;
//var c:[n, n] int ; q1) What if I create c this way, will it reside on
locale 0 and all result come to node 0?
Then I do the multiplication here
forall i in arow do
forall j in bcol do
forall k in acol do
C(i,j) += A(i,k)*B(k,j);
I thought there will not be any race condition here because we are
reading array A, B and writing into C's individual array position.
q2) Is it ok to do so?
I was looking into the BlockDist.chpl to figure out how its internal
works but little confused.
Thank you,
Bibek
------------------------------------------------------------------------------
"Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE
Instantly run your Selenium tests across 300+ browser/OS combos. Get
unparalleled scalability from the best Selenium testing platform available.
Simple to use. Nothing to install. Get started now for free."
http://p.sf.net/sfu/SauceLabs
_______________________________________________
Chapel-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/chapel-users