2169
1573
print_matrix(X,f)
2172
<t tx="gcross.20081119205342.2">testCase(MM2x2x2_mediumlevel,MatrixMultiplierTests) {
2174
typedef Array<double,2> Matrix;
2176
int I = 2, J = 2, K = 2;
2178
CProxy_MatrixMultiplier<double> multiplier = CProxy_MatrixMultiplier<double>::ckNew(I,J,K);
2179
CkGroupID mCastGrpId = CProxy_CkMulticastMgr::ckNew();
2180
Array<CProxySection_MatrixMultiplier<double>,2> A_section_matrix(I,J), B_section_matrix(J,K), C_section_matrix(I,K);
2181
MatrixMultiplier<double>::build_section_matrices(
2189
Array<CkCallback,2> C_callback_matrix(I,K);
2190
MatrixMultiplier<double>::build_thread_delay_callback_matrix(mCastGrpId,C_section_matrix,C_callback_matrix);
2195
Matrix C_data(2,2), correct_C_data(2,2);
2212
MatrixMultiplier<double>::broadcast_A_data(0,A_section_matrix,A_data);
2213
MatrixMultiplier<double>::broadcast_B_data(0,B_section_matrix,B_data);
2214
MatrixMultiplier<double>::gather_results(C_callback_matrix,C_data);
2215
assertTrue(all(C_data==correct_C_data));
2221
Matrix C_data(3,3), correct_C_data(3,3);
2225
0.127764833566,0.895385553445,0.84219862626,0.802958441991,0.248950345431,
2226
0.70459464403,0.889923629647,0.786650904792,0.536201242653,0.354616263865,
2227
0.0203439811731,0.257875825771,0.945103940903,0.171736390081,0.220236463943;
2230
0.792611499585,0.613120251251,0.931379767255,
2231
0.541683178571,0.583090577153,0.965973018146,
2232
0.125656090874,0.406462288666,0.0669359314281,
2233
0.496243647861,0.599131362563,0.258425222495,
2234
0.446161420577,0.478176105036,0.927927387316;
2237
1.20164562218,1.54286775909,1.47880177354,
2238
1.56367651206,1.76147526011,2.0361686897,
2239
0.458054043388,0.755191853684,0.580054936153;
2241
MatrixMultiplier<double>::broadcast_A_data(1,A_section_matrix,A_data);
2242
MatrixMultiplier<double>::broadcast_B_data(1,B_section_matrix,B_data);
2243
MatrixMultiplier<double>::gather_results(C_callback_matrix,C_data);
2244
assertTrue(sum(abs(C_data-correct_C_data))<1e-8);
2247
multiplier.ckDestroy();
2251
<t tx="gcross.20081119205342.3">testCase(MM3x3x3_mediumlevel,MatrixMultiplierTests) {
2253
typedef Array<double,2> Matrix;
2255
int I = 3, J = 3, K = 3;
2257
CProxy_MatrixMultiplier<double> multiplier = CProxy_MatrixMultiplier<double>::ckNew(I,J,K);
2258
CkGroupID mCastGrpId = CProxy_CkMulticastMgr::ckNew();
2259
Array<CProxySection_MatrixMultiplier<double>,2> A_section_matrix(I,J), B_section_matrix(J,K), C_section_matrix(I,K);
2260
MatrixMultiplier<double>::build_section_matrices(
2268
Array<CkCallback,2> C_callback_matrix(I,K);
2269
MatrixMultiplier<double>::build_thread_delay_callback_matrix(mCastGrpId,C_section_matrix,C_callback_matrix);
2274
Matrix C_data(3,3), correct_C_data(3,3);
2278
0.127764833566,0.895385553445,0.84219862626,0.802958441991,0.248950345431,
2279
0.70459464403,0.889923629647,0.786650904792,0.536201242653,0.354616263865,
2280
0.0203439811731,0.257875825771,0.945103940903,0.171736390081,0.220236463943;
2283
0.792611499585,0.613120251251,0.931379767255,
2284
0.541683178571,0.583090577153,0.965973018146,
2285
0.125656090874,0.406462288666,0.0669359314281,
2286
0.496243647861,0.599131362563,0.258425222495,
2287
0.446161420577,0.478176105036,0.927927387316;
2290
1.20164562218,1.54286775909,1.47880177354,
2291
1.56367651206,1.76147526011,2.0361686897,
2292
0.458054043388,0.755191853684,0.580054936153;
2294
MatrixMultiplier<double>::broadcast_A_data(0,A_section_matrix,A_data);
2295
MatrixMultiplier<double>::broadcast_B_data(0,B_section_matrix,B_data);
2296
MatrixMultiplier<double>::gather_results(C_callback_matrix,C_data);
2297
assertTrue(sum(abs(C_data-correct_C_data))<1e-8);
2301
Matrix A_data(23,11);
2302
Matrix B_data(11,13);
2303
Matrix C_data(23,13), correct_C_data(23,13);
2306
<< A data >>
2307
<< B data >>
2308
<< C data >>
2310
MatrixMultiplier<double>::broadcast_A_data(1,A_section_matrix,A_data);
2311
MatrixMultiplier<double>::broadcast_B_data(1,B_section_matrix,B_data);
2312
MatrixMultiplier<double>::gather_results(C_callback_matrix,C_data);
2313
assertTrue(sum(abs(C_data-correct_C_data))<1e-8);
2316
multiplier.ckDestroy();
2320
<t tx="gcross.20081119205342.4">A_data =
2321
0.261866504012,0.236878231696,0.380017632472,0.593987204289,0.576522290572,0.686579179271,0.117057531975,0.0807189706706,0.524975647917,0.85348478089,0.32784113737,
2322
0.137307045661,0.721936270775,0.497272066704,0.00662990346833,0.934311820255,0.502196682797,0.609445178422,0.667736158144,0.798899583748,0.264161595828,0.104879945885,
2323
0.319679294935,0.636055286206,0.202729143402,0.207783865394,0.207354412515,0.335238700104,0.332923346186,0.189648385055,0.564489673834,0.309237115548,0.0589418897135,
2324
0.999552611389,0.207128209479,0.247170553961,0.249903696288,0.154265191093,0.792262871179,0.072877133596,0.817728566028,0.402116231499,0.607123140639,0.650708802013,
2325
0.853262567001,0.406558437323,0.462162950196,0.327946206801,0.264524424748,0.313971710267,0.633660743369,0.182623441676,0.136914584174,0.450341797727,0.0196506606282,
2326
0.850488263174,0.392463174662,0.735361834236,0.127493420602,0.332147016106,0.0300456280638,0.590630855646,0.414666471259,0.703663964187,0.923810792082,0.229049012856,
2327
0.995381059916,0.0428851257525,0.331077528949,0.78942945132,0.0834955598012,0.562198320834,0.936545350473,0.203572807047,0.892898850112,0.444973460656,0.0353533980962,
2328
0.788296011328,0.386833544193,0.891491850101,0.720879441372,0.742939842246,0.0510329573871,0.543584321238,0.149015778982,0.225329893599,0.40366551859,0.0315998155218,
2329
0.117003592342,0.237838001157,0.626057726921,0.508260895763,0.251743407826,0.190431967605,0.181848316198,0.50718214391,0.253622652508,0.450387478269,0.316331657775,
2330
0.515321437577,0.18875157865,0.632103577772,0.583705912732,0.841264070191,0.762791813602,0.0774012127148,0.670523177977,0.789176322828,0.1022102638,0.280725419529,
2331
0.331632772234,0.234608677795,0.946428173367,0.137036736073,0.777750220575,0.51776744907,0.46393810078,0.887574374768,0.957032697844,0.0171661939031,0.908509457721,
2332
0.0772033681099,0.460392995892,0.0999736374282,0.124643265136,0.978162973761,0.627270091518,0.0918355267612,0.542172490245,0.147837745177,0.818201023204,0.441658037386,
2333
0.304822197347,0.258127731465,0.952000877532,0.0956031274,0.925584101293,0.223408891998,0.722190228738,0.470058193836,0.309569888912,0.729637739648,0.81879995657,
2334
0.869796694677,0.291586527602,0.66192336729,0.75163303431,0.0105178952743,0.00831692641014,0.0768833949029,0.479968396166,0.0335657059737,0.698932952358,0.653429929735,
2335
0.32174317456,0.648326493503,0.84967268436,0.656475965688,0.233985674544,0.641282854781,0.161111230474,0.244099484477,0.963960208219,0.738368804128,0.716742533635,
2336
0.743825752552,0.956786997119,0.982975918727,0.332842770646,0.396636089193,0.678692624518,0.88678704315,0.271125786829,0.98314504261,0.883802487105,0.928988477637,
2337
0.568245202433,0.826197364222,0.688841426927,0.413868882819,0.436794442184,0.874196234122,0.284235074501,0.297373711938,0.254977644551,0.649149256866,0.606234019467,
2338
0.398292442086,0.230579511912,0.734614155349,0.852451092972,0.270141827812,0.88315782443,0.460339544548,0.0757437091179,0.527865725712,0.387833359001,0.56126945855,
2339
0.560272465525,0.733386233656,0.120197299603,0.531059891155,0.840337422591,0.63321258362,0.95969901644,0.925321288462,0.0441286085524,0.470060673073,0.912808667526,
2340
0.275027079982,0.760436571123,0.250187713192,0.0515411291099,0.477228325956,0.74090147845,0.765654219776,0.928727520985,0.423168694547,0.970202875799,0.503643520798,
2341
0.702490884601,0.276432745893,0.391797180964,0.0200279887029,0.795195910365,0.0640564369366,0.376991533787,0.907223629813,0.960200927608,0.166900303993,0.52333355076,
2342
0.120646470018,0.579610926073,0.319190579385,0.509717478291,0.756912045055,0.693859810094,0.955367185739,0.440628477158,0.362813479607,0.135191898404,0.237680156013,
2343
0.271258720902,0.806695911736,0.529901417966,0.513610843064,0.254644600733,0.944565840039,0.714090517383,0.868523248131,0.635095196522,0.43880840514,0.447541464633;
2345
<t tx="gcross.20081119205342.5">B_data=
2346
0.338519448043,0.577445183289,0.714344727323,0.658301919056,0.793882195017,0.921157722106,0.0577648914639,0.687847024532,0.221618396668,0.170520402727,0.8984799562,0.668947955869,0.577999351541,
2347
0.653005818577,0.0777651307304,0.711003764864,0.310151984884,0.914902614143,0.794477586671,0.773372230331,0.947623242984,0.436268073833,0.115415900853,0.405067181246,0.308730012857,0.894462112134,
2348
0.685594167421,0.735907517741,0.183719988621,0.666037511439,0.83002130814,0.239093384013,0.604118187996,0.537144978572,0.279110396519,0.503183430236,0.958675711569,0.0113832056294,0.356667594252,
2349
0.515346650749,0.909519285222,0.361015245685,0.250015226661,0.643764662855,0.596689458656,0.639496226552,0.818496603303,0.700322559662,0.173394856186,0.101736041896,0.746345700845,0.301758606997,
2350
0.114771039479,0.608565873708,0.0155564484873,0.0176004576729,0.146978067832,0.963790424666,0.941671038922,0.710537197538,0.360260687003,0.488077184582,0.567896265204,0.710638567666,0.657722169854,
2351
0.955411872403,0.469631027096,0.538684684305,0.155027174568,0.0847980450302,0.942753117215,0.0145723259252,0.07679558772,0.885385875752,0.384913773723,0.34411140759,0.940314506079,0.321729030911,
2352
0.796731457201,0.342200403242,0.877966175523,0.380792077741,0.0513280264837,0.388143887869,0.472304007402,0.571411313158,0.0435416803201,0.655414843166,0.559857494826,0.924098840128,0.61060334532,
2353
0.891355837223,0.259171606051,0.542057917249,0.296033351049,0.910216386014,0.965320698874,0.382805153784,0.394092102599,0.853425291667,0.842133338027,0.557750047891,0.299478767031,0.713239273885,
2354
0.0414586701968,0.0126832723749,0.121381949536,0.556698529383,0.360770654669,0.416265722879,0.976527683174,0.0947413944391,0.96366821334,0.547672954636,0.565537572823,0.345727946086,0.02620734045,
2355
0.897827854819,0.546836317787,0.521642028451,0.217358529231,0.866370833193,0.476831978805,0.213789572269,0.0602385864117,0.452237648572,0.885551918228,0.7593062306,0.187170341416,0.809114719133,
2356
0.795928215029,0.460802836536,0.651159141431,0.477902630548,0.465155904725,0.0699897504759,0.529268026702,0.800777123722,0.0634700119732,0.91668143046,0.264076065876,0.974929169956,0.72910092266;</t>
2357
<t tx="gcross.20081119205342.6">correct_C_data =
2358
2.74630887563,2.34824795471,1.88749763459,1.46696440406,2.42618650929,2.8494203107,2.31547088645,2.01963930175,2.48568504913,2.40041046928,2.46172287712,2.54446545946,2.35050419565,
2359
2.88381435847,1.89636790137,2.19028375931,1.72348780374,2.57136311684,3.54381004672,3.19362884375,2.54051383117,2.76245193383,2.73679223432,2.99031715743,2.65258028199,2.84008538833,
2360
1.89597831248,1.22236107094,1.63997744186,1.24286548798,1.88534576127,2.18700473539,1.84425487982,1.65895739017,1.78587145472,1.51114860069,1.85525338942,1.70514210737,1.77947232828,
2361
3.41314357877,2.34224905431,2.7225684684,2.0115129485,3.16071823751,3.50918668137,1.89819559072,2.35122919671,2.71733227959,2.83306152092,2.9617225615,2.97581785227,2.88687322163,
2362
2.46381138372,1.99236704105,2.1947942171,1.6097910975,2.35702987655,2.66146432988,1.71587075023,2.19080239746,1.61870872183,1.7927020798,2.54719971163,2.22058142042,2.29509609954,
2363
3.06196962174,2.3242184069,2.54884964027,2.26341160987,3.34658062993,3.07455756425,2.63520711969,2.50121438308,2.29052041042,2.90586684945,3.56186832667,2.36738924172,2.96081159144,
2364
2.93778623805,2.49878500407,2.68762758571,2.20265030859,2.62985943893,3.25802587465,2.3883746404,2.40688014142,2.69085803275,2.43604092065,3.04033600607,3.21291163735,2.33204800744,
2365
2.59901999753,2.73587730256,2.11775694551,1.91328823757,2.90653948824,3.08424264137,2.681463071,2.94980765817,1.96251673132,2.12650849928,3.06215286197,2.50209551157,2.6359619265,
2366
2.3605300934,1.84063484445,1.56398014958,1.33844531682,2.31030149055,2.07450439719,1.92519584978,1.85990944876,1.82860398153,2.02074378416,2.01549527863,1.69644711625,1.95835542841,
2367
2.86447816225,2.57403302663,2.01649227605,1.9214588997,2.78869189932,3.72820557165,2.96851500958,2.62114770943,3.16035629705,2.62860290483,2.9604340175,2.99892942935,2.50057014648,
2368
3.50787298252,2.57630020603,2.52321434403,2.45975810165,3.12435220489,3.54466590989,3.57788720407,3.09745301423,3.03996023436,3.58619824544,3.48307990672,3.3612421795,3.07626960208,
2369
2.81981383874,1.98193838831,1.90583370063,1.07250880414,2.30853498234,3.11088115492,2.23483480691,2.07140142638,2.24815064073,2.58424076716,2.31104046775,2.45497281858,2.80554759615,
2370
3.60739012899,2.80101122303,2.58565178766,2.12601351281,3.07448027243,3.14137320402,3.14103823659,3.04558254805,2.1569545936,3.55056799062,3.51515136115,3.08363522025,3.4278209239,
2371
2.97324083415,2.54041473628,2.34808279686,1.94752907913,3.35523863872,2.54375424472,1.91440936235,2.65508952741,1.84512898397,2.34460425562,2.65246823604,2.24993829597,2.6681375693,
2372
3.71197473245,2.76679235419,2.67563833617,2.41973188812,3.61653418302,3.33807975298,3.3308566137,2.94291803336,3.22680775532,3.18208582924,3.30801987425,3.07653135596,3.04497763201,
2373
4.93786345433,3.38771616266,3.99497120347,3.23784987999,4.45670414797,4.40268597104,4.13631711029,4.05655342404,3.50958954092,4.22664236344,4.61098742563,4.28431977818,4.36904808611,
2374
3.87021305755,2.76399585849,2.92210100741,2.10483500742,3.40517585471,3.69210574976,2.73336360074,3.08836757224,2.74376609144,2.86725301558,3.21876386544,3.23675928141,3.36614499086,
2375
3.35424242099,2.79757928588,2.4481975096,2.02189521948,2.68036861204,3.02307209336,2.59938603482,2.66027607841,2.67453913652,2.59632482852,2.74075755356,3.25499819263,2.48948667867,
2376
4.46588650727,3.00725593652,3.67875053826,2.12441752137,3.47388514978,4.42337628884,3.24651236043,3.9018061952,2.85747918453,3.67205924769,3.34116258093,4.34866165224,4.23236717835,
2377
4.27772913177,2.35801305817,3.26930361625,1.97332274016,3.40001269977,3.9742288443,2.85264034622,2.78769279955,3.03100114892,3.62413619831,3.38184968341,3.30046665156,3.78940564902,
2378
2.56493240515,1.95643360563,2.19159367672,2.07111845441,2.85056719548,3.33714156529,3.02928329632,2.63498565823,2.56752902929,2.92957977068,3.11944672685,2.69350259607,2.76173825905,
2379
3.13016537508,2.22890041969,2.47344732538,1.55929623113,2.19790861852,3.36401833337,2.82578380071,2.76439415431,2.45617663226,2.50649982441,2.52088167253,3.2313182663,2.76671373086,
2380
4.29788080518,2.59873116073,3.2580433505,2.25287687684,3.48606217197,4.08035529893,3.16228977305,3.10482538871,3.458874146,3.32902133917,3.29514346712,3.54703945901,3.44719544193;
2382
<t tx="gcross.20081119205342.7">testCase(MM3x5x7_mediumlevel,MatrixMultiplierTests) {
2384
typedef Array<double,2> Matrix;
2386
int I = 3, J = 5, K = 7;
2388
CProxy_MatrixMultiplier<double> multiplier = CProxy_MatrixMultiplier<double>::ckNew(I,J,K);
2389
CkGroupID mCastGrpId = CProxy_CkMulticastMgr::ckNew();
2390
Array<CProxySection_MatrixMultiplier<double>,2> A_section_matrix(I,J), B_section_matrix(J,K), C_section_matrix(I,K);
2391
MatrixMultiplier<double>::build_section_matrices(
2399
Array<CkCallback,2> C_callback_matrix(I,K);
2400
MatrixMultiplier<double>::build_thread_delay_callback_matrix(mCastGrpId,C_section_matrix,C_callback_matrix);
2403
Matrix A_data(23,11);
2404
Matrix B_data(11,13);
2405
Matrix C_data(23,13), correct_C_data(23,13);
2407
<< A data >>
2408
<< B data >>
2409
<< C data >>
2411
MatrixMultiplier<double>::broadcast_A_data(0,A_section_matrix,A_data);
2412
MatrixMultiplier<double>::broadcast_B_data(0,B_section_matrix,B_data);
2413
MatrixMultiplier<double>::gather_results(C_callback_matrix,C_data);
2414
assertTrue(sum(abs(C_data-correct_C_data))<1e-8);
2417
multiplier.ckDestroy();
2421
<t tx="gcross.20081119205342.8">A_data =
2422
0.261866504012,0.236878231696,0.380017632472,0.593987204289,0.576522290572,0.686579179271,0.117057531975,0.0807189706706,0.524975647917,0.85348478089,0.32784113737,
2423
0.137307045661,0.721936270775,0.497272066704,0.00662990346833,0.934311820255,0.502196682797,0.609445178422,0.667736158144,0.798899583748,0.264161595828,0.104879945885,
2424
0.319679294935,0.636055286206,0.202729143402,0.207783865394,0.207354412515,0.335238700104,0.332923346186,0.189648385055,0.564489673834,0.309237115548,0.0589418897135,
2425
0.999552611389,0.207128209479,0.247170553961,0.249903696288,0.154265191093,0.792262871179,0.072877133596,0.817728566028,0.402116231499,0.607123140639,0.650708802013,
2426
0.853262567001,0.406558437323,0.462162950196,0.327946206801,0.264524424748,0.313971710267,0.633660743369,0.182623441676,0.136914584174,0.450341797727,0.0196506606282,
2427
0.850488263174,0.392463174662,0.735361834236,0.127493420602,0.332147016106,0.0300456280638,0.590630855646,0.414666471259,0.703663964187,0.923810792082,0.229049012856,
2428
0.995381059916,0.0428851257525,0.331077528949,0.78942945132,0.0834955598012,0.562198320834,0.936545350473,0.203572807047,0.892898850112,0.444973460656,0.0353533980962,
2429
0.788296011328,0.386833544193,0.891491850101,0.720879441372,0.742939842246,0.0510329573871,0.543584321238,0.149015778982,0.225329893599,0.40366551859,0.0315998155218,
2430
0.117003592342,0.237838001157,0.626057726921,0.508260895763,0.251743407826,0.190431967605,0.181848316198,0.50718214391,0.253622652508,0.450387478269,0.316331657775,
2431
0.515321437577,0.18875157865,0.632103577772,0.583705912732,0.841264070191,0.762791813602,0.0774012127148,0.670523177977,0.789176322828,0.1022102638,0.280725419529,
2432
0.331632772234,0.234608677795,0.946428173367,0.137036736073,0.777750220575,0.51776744907,0.46393810078,0.887574374768,0.957032697844,0.0171661939031,0.908509457721,
2433
0.0772033681099,0.460392995892,0.0999736374282,0.124643265136,0.978162973761,0.627270091518,0.0918355267612,0.542172490245,0.147837745177,0.818201023204,0.441658037386,
2434
0.304822197347,0.258127731465,0.952000877532,0.0956031274,0.925584101293,0.223408891998,0.722190228738,0.470058193836,0.309569888912,0.729637739648,0.81879995657,
2435
0.869796694677,0.291586527602,0.66192336729,0.75163303431,0.0105178952743,0.00831692641014,0.0768833949029,0.479968396166,0.0335657059737,0.698932952358,0.653429929735,
2436
0.32174317456,0.648326493503,0.84967268436,0.656475965688,0.233985674544,0.641282854781,0.161111230474,0.244099484477,0.963960208219,0.738368804128,0.716742533635,
2437
0.743825752552,0.956786997119,0.982975918727,0.332842770646,0.396636089193,0.678692624518,0.88678704315,0.271125786829,0.98314504261,0.883802487105,0.928988477637,
2438
0.568245202433,0.826197364222,0.688841426927,0.413868882819,0.436794442184,0.874196234122,0.284235074501,0.297373711938,0.254977644551,0.649149256866,0.606234019467,
2439
0.398292442086,0.230579511912,0.734614155349,0.852451092972,0.270141827812,0.88315782443,0.460339544548,0.0757437091179,0.527865725712,0.387833359001,0.56126945855,
2440
0.560272465525,0.733386233656,0.120197299603,0.531059891155,0.840337422591,0.63321258362,0.95969901644,0.925321288462,0.0441286085524,0.470060673073,0.912808667526,
2441
0.275027079982,0.760436571123,0.250187713192,0.0515411291099,0.477228325956,0.74090147845,0.765654219776,0.928727520985,0.423168694547,0.970202875799,0.503643520798,
2442
0.702490884601,0.276432745893,0.391797180964,0.0200279887029,0.795195910365,0.0640564369366,0.376991533787,0.907223629813,0.960200927608,0.166900303993,0.52333355076,
2443
0.120646470018,0.579610926073,0.319190579385,0.509717478291,0.756912045055,0.693859810094,0.955367185739,0.440628477158,0.362813479607,0.135191898404,0.237680156013,
2444
0.271258720902,0.806695911736,0.529901417966,0.513610843064,0.254644600733,0.944565840039,0.714090517383,0.868523248131,0.635095196522,0.43880840514,0.447541464633;
2446
<t tx="gcross.20081119205342.9">B_data=
2447
0.338519448043,0.577445183289,0.714344727323,0.658301919056,0.793882195017,0.921157722106,0.0577648914639,0.687847024532,0.221618396668,0.170520402727,0.8984799562,0.668947955869,0.577999351541,
2448
0.653005818577,0.0777651307304,0.711003764864,0.310151984884,0.914902614143,0.794477586671,0.773372230331,0.947623242984,0.436268073833,0.115415900853,0.405067181246,0.308730012857,0.894462112134,
2449
0.685594167421,0.735907517741,0.183719988621,0.666037511439,0.83002130814,0.239093384013,0.604118187996,0.537144978572,0.279110396519,0.503183430236,0.958675711569,0.0113832056294,0.356667594252,
2450
0.515346650749,0.909519285222,0.361015245685,0.250015226661,0.643764662855,0.596689458656,0.639496226552,0.818496603303,0.700322559662,0.173394856186,0.101736041896,0.746345700845,0.301758606997,
2451
0.114771039479,0.608565873708,0.0155564484873,0.0176004576729,0.146978067832,0.963790424666,0.941671038922,0.710537197538,0.360260687003,0.488077184582,0.567896265204,0.710638567666,0.657722169854,
2452
0.955411872403,0.469631027096,0.538684684305,0.155027174568,0.0847980450302,0.942753117215,0.0145723259252,0.07679558772,0.885385875752,0.384913773723,0.34411140759,0.940314506079,0.321729030911,
2453
0.796731457201,0.342200403242,0.877966175523,0.380792077741,0.0513280264837,0.388143887869,0.472304007402,0.571411313158,0.0435416803201,0.655414843166,0.559857494826,0.924098840128,0.61060334532,
2454
0.891355837223,0.259171606051,0.542057917249,0.296033351049,0.910216386014,0.965320698874,0.382805153784,0.394092102599,0.853425291667,0.842133338027,0.557750047891,0.299478767031,0.713239273885,
2455
0.0414586701968,0.0126832723749,0.121381949536,0.556698529383,0.360770654669,0.416265722879,0.976527683174,0.0947413944391,0.96366821334,0.547672954636,0.565537572823,0.345727946086,0.02620734045,
2456
0.897827854819,0.546836317787,0.521642028451,0.217358529231,0.866370833193,0.476831978805,0.213789572269,0.0602385864117,0.452237648572,0.885551918228,0.7593062306,0.187170341416,0.809114719133,
2457
0.795928215029,0.460802836536,0.651159141431,0.477902630548,0.465155904725,0.0699897504759,0.529268026702,0.800777123722,0.0634700119732,0.91668143046,0.264076065876,0.974929169956,0.72910092266;</t>
2458
<t tx="gcross.20081119205342.10">correct_C_data =
2459
2.74630887563,2.34824795471,1.88749763459,1.46696440406,2.42618650929,2.8494203107,2.31547088645,2.01963930175,2.48568504913,2.40041046928,2.46172287712,2.54446545946,2.35050419565,
2460
2.88381435847,1.89636790137,2.19028375931,1.72348780374,2.57136311684,3.54381004672,3.19362884375,2.54051383117,2.76245193383,2.73679223432,2.99031715743,2.65258028199,2.84008538833,
2461
1.89597831248,1.22236107094,1.63997744186,1.24286548798,1.88534576127,2.18700473539,1.84425487982,1.65895739017,1.78587145472,1.51114860069,1.85525338942,1.70514210737,1.77947232828,
2462
3.41314357877,2.34224905431,2.7225684684,2.0115129485,3.16071823751,3.50918668137,1.89819559072,2.35122919671,2.71733227959,2.83306152092,2.9617225615,2.97581785227,2.88687322163,
2463
2.46381138372,1.99236704105,2.1947942171,1.6097910975,2.35702987655,2.66146432988,1.71587075023,2.19080239746,1.61870872183,1.7927020798,2.54719971163,2.22058142042,2.29509609954,
2464
3.06196962174,2.3242184069,2.54884964027,2.26341160987,3.34658062993,3.07455756425,2.63520711969,2.50121438308,2.29052041042,2.90586684945,3.56186832667,2.36738924172,2.96081159144,
2465
2.93778623805,2.49878500407,2.68762758571,2.20265030859,2.62985943893,3.25802587465,2.3883746404,2.40688014142,2.69085803275,2.43604092065,3.04033600607,3.21291163735,2.33204800744,
2466
2.59901999753,2.73587730256,2.11775694551,1.91328823757,2.90653948824,3.08424264137,2.681463071,2.94980765817,1.96251673132,2.12650849928,3.06215286197,2.50209551157,2.6359619265,
2467
2.3605300934,1.84063484445,1.56398014958,1.33844531682,2.31030149055,2.07450439719,1.92519584978,1.85990944876,1.82860398153,2.02074378416,2.01549527863,1.69644711625,1.95835542841,
2468
2.86447816225,2.57403302663,2.01649227605,1.9214588997,2.78869189932,3.72820557165,2.96851500958,2.62114770943,3.16035629705,2.62860290483,2.9604340175,2.99892942935,2.50057014648,
2469
3.50787298252,2.57630020603,2.52321434403,2.45975810165,3.12435220489,3.54466590989,3.57788720407,3.09745301423,3.03996023436,3.58619824544,3.48307990672,3.3612421795,3.07626960208,
2470
2.81981383874,1.98193838831,1.90583370063,1.07250880414,2.30853498234,3.11088115492,2.23483480691,2.07140142638,2.24815064073,2.58424076716,2.31104046775,2.45497281858,2.80554759615,
2471
3.60739012899,2.80101122303,2.58565178766,2.12601351281,3.07448027243,3.14137320402,3.14103823659,3.04558254805,2.1569545936,3.55056799062,3.51515136115,3.08363522025,3.4278209239,
2472
2.97324083415,2.54041473628,2.34808279686,1.94752907913,3.35523863872,2.54375424472,1.91440936235,2.65508952741,1.84512898397,2.34460425562,2.65246823604,2.24993829597,2.6681375693,
2473
3.71197473245,2.76679235419,2.67563833617,2.41973188812,3.61653418302,3.33807975298,3.3308566137,2.94291803336,3.22680775532,3.18208582924,3.30801987425,3.07653135596,3.04497763201,
2474
4.93786345433,3.38771616266,3.99497120347,3.23784987999,4.45670414797,4.40268597104,4.13631711029,4.05655342404,3.50958954092,4.22664236344,4.61098742563,4.28431977818,4.36904808611,
2475
3.87021305755,2.76399585849,2.92210100741,2.10483500742,3.40517585471,3.69210574976,2.73336360074,3.08836757224,2.74376609144,2.86725301558,3.21876386544,3.23675928141,3.36614499086,
2476
3.35424242099,2.79757928588,2.4481975096,2.02189521948,2.68036861204,3.02307209336,2.59938603482,2.66027607841,2.67453913652,2.59632482852,2.74075755356,3.25499819263,2.48948667867,
2477
4.46588650727,3.00725593652,3.67875053826,2.12441752137,3.47388514978,4.42337628884,3.24651236043,3.9018061952,2.85747918453,3.67205924769,3.34116258093,4.34866165224,4.23236717835,
2478
4.27772913177,2.35801305817,3.26930361625,1.97332274016,3.40001269977,3.9742288443,2.85264034622,2.78769279955,3.03100114892,3.62413619831,3.38184968341,3.30046665156,3.78940564902,
2479
2.56493240515,1.95643360563,2.19159367672,2.07111845441,2.85056719548,3.33714156529,3.02928329632,2.63498565823,2.56752902929,2.92957977068,3.11944672685,2.69350259607,2.76173825905,
2480
3.13016537508,2.22890041969,2.47344732538,1.55929623113,2.19790861852,3.36401833337,2.82578380071,2.76439415431,2.45617663226,2.50649982441,2.52088167253,3.2313182663,2.76671373086,
2481
4.29788080518,2.59873116073,3.2580433505,2.25287687684,3.48606217197,4.08035529893,3.16228977305,3.10482538871,3.458874146,3.32902133917,3.29514346712,3.54703945901,3.44719544193;
2483
<t tx="gcross.20081119205342.15">testCase(MM9x10x11_mediumlevel,MatrixMultiplierTests) {
2485
typedef Array<double,2> Matrix;
2487
int I = 9, J = 10, K = 11;
2489
CProxy_MatrixMultiplier<double> multiplier = CProxy_MatrixMultiplier<double>::ckNew(I,J,K);
2490
CkGroupID mCastGrpId = CProxy_CkMulticastMgr::ckNew();
2491
Array<CProxySection_MatrixMultiplier<double>,2> A_section_matrix(I,J), B_section_matrix(J,K), C_section_matrix(I,K);
2492
MatrixMultiplier<double>::build_section_matrices(
2500
Array<CkCallback,2> C_callback_matrix(I,K);
2501
MatrixMultiplier<double>::build_thread_delay_callback_matrix(mCastGrpId,C_section_matrix,C_callback_matrix);
2504
Matrix A_data(23,11);
2505
Matrix B_data(11,13);
2506
Matrix C_data(23,13), correct_C_data(23,13);
2508
<< A data >>
2509
<< B data >>
2510
<< C data >>
2512
MatrixMultiplier<double>::broadcast_A_data(0,A_section_matrix,A_data);
2513
MatrixMultiplier<double>::broadcast_B_data(0,B_section_matrix,B_data);
2514
MatrixMultiplier<double>::gather_results(C_callback_matrix,C_data);
2515
assertTrue(sum(abs(C_data-correct_C_data))<1e-8);
2518
multiplier.ckDestroy();
2522
<t tx="gcross.20081119205342.16">A_data =
2523
0.261866504012,0.236878231696,0.380017632472,0.593987204289,0.576522290572,0.686579179271,0.117057531975,0.0807189706706,0.524975647917,0.85348478089,0.32784113737,
2524
0.137307045661,0.721936270775,0.497272066704,0.00662990346833,0.934311820255,0.502196682797,0.609445178422,0.667736158144,0.798899583748,0.264161595828,0.104879945885,
2525
0.319679294935,0.636055286206,0.202729143402,0.207783865394,0.207354412515,0.335238700104,0.332923346186,0.189648385055,0.564489673834,0.309237115548,0.0589418897135,
2526
0.999552611389,0.207128209479,0.247170553961,0.249903696288,0.154265191093,0.792262871179,0.072877133596,0.817728566028,0.402116231499,0.607123140639,0.650708802013,
2527
0.853262567001,0.406558437323,0.462162950196,0.327946206801,0.264524424748,0.313971710267,0.633660743369,0.182623441676,0.136914584174,0.450341797727,0.0196506606282,
2528
0.850488263174,0.392463174662,0.735361834236,0.127493420602,0.332147016106,0.0300456280638,0.590630855646,0.414666471259,0.703663964187,0.923810792082,0.229049012856,
2529
0.995381059916,0.0428851257525,0.331077528949,0.78942945132,0.0834955598012,0.562198320834,0.936545350473,0.203572807047,0.892898850112,0.444973460656,0.0353533980962,
2530
0.788296011328,0.386833544193,0.891491850101,0.720879441372,0.742939842246,0.0510329573871,0.543584321238,0.149015778982,0.225329893599,0.40366551859,0.0315998155218,
2531
0.117003592342,0.237838001157,0.626057726921,0.508260895763,0.251743407826,0.190431967605,0.181848316198,0.50718214391,0.253622652508,0.450387478269,0.316331657775,
2532
0.515321437577,0.18875157865,0.632103577772,0.583705912732,0.841264070191,0.762791813602,0.0774012127148,0.670523177977,0.789176322828,0.1022102638,0.280725419529,
2533
0.331632772234,0.234608677795,0.946428173367,0.137036736073,0.777750220575,0.51776744907,0.46393810078,0.887574374768,0.957032697844,0.0171661939031,0.908509457721,
2534
0.0772033681099,0.460392995892,0.0999736374282,0.124643265136,0.978162973761,0.627270091518,0.0918355267612,0.542172490245,0.147837745177,0.818201023204,0.441658037386,
2535
0.304822197347,0.258127731465,0.952000877532,0.0956031274,0.925584101293,0.223408891998,0.722190228738,0.470058193836,0.309569888912,0.729637739648,0.81879995657,
2536
0.869796694677,0.291586527602,0.66192336729,0.75163303431,0.0105178952743,0.00831692641014,0.0768833949029,0.479968396166,0.0335657059737,0.698932952358,0.653429929735,
2537
0.32174317456,0.648326493503,0.84967268436,0.656475965688,0.233985674544,0.641282854781,0.161111230474,0.244099484477,0.963960208219,0.738368804128,0.716742533635,
2538
0.743825752552,0.956786997119,0.982975918727,0.332842770646,0.396636089193,0.678692624518,0.88678704315,0.271125786829,0.98314504261,0.883802487105,0.928988477637,
2539
0.568245202433,0.826197364222,0.688841426927,0.413868882819,0.436794442184,0.874196234122,0.284235074501,0.297373711938,0.254977644551,0.649149256866,0.606234019467,
2540
0.398292442086,0.230579511912,0.734614155349,0.852451092972,0.270141827812,0.88315782443,0.460339544548,0.0757437091179,0.527865725712,0.387833359001,0.56126945855,
2541
0.560272465525,0.733386233656,0.120197299603,0.531059891155,0.840337422591,0.63321258362,0.95969901644,0.925321288462,0.0441286085524,0.470060673073,0.912808667526,
2542
0.275027079982,0.760436571123,0.250187713192,0.0515411291099,0.477228325956,0.74090147845,0.765654219776,0.928727520985,0.423168694547,0.970202875799,0.503643520798,
2543
0.702490884601,0.276432745893,0.391797180964,0.0200279887029,0.795195910365,0.0640564369366,0.376991533787,0.907223629813,0.960200927608,0.166900303993,0.52333355076,
2544
0.120646470018,0.579610926073,0.319190579385,0.509717478291,0.756912045055,0.693859810094,0.955367185739,0.440628477158,0.362813479607,0.135191898404,0.237680156013,
2545
0.271258720902,0.806695911736,0.529901417966,0.513610843064,0.254644600733,0.944565840039,0.714090517383,0.868523248131,0.635095196522,0.43880840514,0.447541464633;
2547
<t tx="gcross.20081119205342.17">B_data=
2548
0.338519448043,0.577445183289,0.714344727323,0.658301919056,0.793882195017,0.921157722106,0.0577648914639,0.687847024532,0.221618396668,0.170520402727,0.8984799562,0.668947955869,0.577999351541,
2549
0.653005818577,0.0777651307304,0.711003764864,0.310151984884,0.914902614143,0.794477586671,0.773372230331,0.947623242984,0.436268073833,0.115415900853,0.405067181246,0.308730012857,0.894462112134,
2550
0.685594167421,0.735907517741,0.183719988621,0.666037511439,0.83002130814,0.239093384013,0.604118187996,0.537144978572,0.279110396519,0.503183430236,0.958675711569,0.0113832056294,0.356667594252,
2551
0.515346650749,0.909519285222,0.361015245685,0.250015226661,0.643764662855,0.596689458656,0.639496226552,0.818496603303,0.700322559662,0.173394856186,0.101736041896,0.746345700845,0.301758606997,
2552
0.114771039479,0.608565873708,0.0155564484873,0.0176004576729,0.146978067832,0.963790424666,0.941671038922,0.710537197538,0.360260687003,0.488077184582,0.567896265204,0.710638567666,0.657722169854,
2553
0.955411872403,0.469631027096,0.538684684305,0.155027174568,0.0847980450302,0.942753117215,0.0145723259252,0.07679558772,0.885385875752,0.384913773723,0.34411140759,0.940314506079,0.321729030911,
2554
0.796731457201,0.342200403242,0.877966175523,0.380792077741,0.0513280264837,0.388143887869,0.472304007402,0.571411313158,0.0435416803201,0.655414843166,0.559857494826,0.924098840128,0.61060334532,
2555
0.891355837223,0.259171606051,0.542057917249,0.296033351049,0.910216386014,0.965320698874,0.382805153784,0.394092102599,0.853425291667,0.842133338027,0.557750047891,0.299478767031,0.713239273885,
2556
0.0414586701968,0.0126832723749,0.121381949536,0.556698529383,0.360770654669,0.416265722879,0.976527683174,0.0947413944391,0.96366821334,0.547672954636,0.565537572823,0.345727946086,0.02620734045,
2557
0.897827854819,0.546836317787,0.521642028451,0.217358529231,0.866370833193,0.476831978805,0.213789572269,0.0602385864117,0.452237648572,0.885551918228,0.7593062306,0.187170341416,0.809114719133,
2558
0.795928215029,0.460802836536,0.651159141431,0.477902630548,0.465155904725,0.0699897504759,0.529268026702,0.800777123722,0.0634700119732,0.91668143046,0.264076065876,0.974929169956,0.72910092266;</t>
2559
<t tx="gcross.20081119205342.18">correct_C_data =
2560
2.74630887563,2.34824795471,1.88749763459,1.46696440406,2.42618650929,2.8494203107,2.31547088645,2.01963930175,2.48568504913,2.40041046928,2.46172287712,2.54446545946,2.35050419565,
2561
2.88381435847,1.89636790137,2.19028375931,1.72348780374,2.57136311684,3.54381004672,3.19362884375,2.54051383117,2.76245193383,2.73679223432,2.99031715743,2.65258028199,2.84008538833,
2562
1.89597831248,1.22236107094,1.63997744186,1.24286548798,1.88534576127,2.18700473539,1.84425487982,1.65895739017,1.78587145472,1.51114860069,1.85525338942,1.70514210737,1.77947232828,
2563
3.41314357877,2.34224905431,2.7225684684,2.0115129485,3.16071823751,3.50918668137,1.89819559072,2.35122919671,2.71733227959,2.83306152092,2.9617225615,2.97581785227,2.88687322163,
2564
2.46381138372,1.99236704105,2.1947942171,1.6097910975,2.35702987655,2.66146432988,1.71587075023,2.19080239746,1.61870872183,1.7927020798,2.54719971163,2.22058142042,2.29509609954,
2565
3.06196962174,2.3242184069,2.54884964027,2.26341160987,3.34658062993,3.07455756425,2.63520711969,2.50121438308,2.29052041042,2.90586684945,3.56186832667,2.36738924172,2.96081159144,
2566
2.93778623805,2.49878500407,2.68762758571,2.20265030859,2.62985943893,3.25802587465,2.3883746404,2.40688014142,2.69085803275,2.43604092065,3.04033600607,3.21291163735,2.33204800744,
2567
2.59901999753,2.73587730256,2.11775694551,1.91328823757,2.90653948824,3.08424264137,2.681463071,2.94980765817,1.96251673132,2.12650849928,3.06215286197,2.50209551157,2.6359619265,
2568
2.3605300934,1.84063484445,1.56398014958,1.33844531682,2.31030149055,2.07450439719,1.92519584978,1.85990944876,1.82860398153,2.02074378416,2.01549527863,1.69644711625,1.95835542841,
2569
2.86447816225,2.57403302663,2.01649227605,1.9214588997,2.78869189932,3.72820557165,2.96851500958,2.62114770943,3.16035629705,2.62860290483,2.9604340175,2.99892942935,2.50057014648,
2570
3.50787298252,2.57630020603,2.52321434403,2.45975810165,3.12435220489,3.54466590989,3.57788720407,3.09745301423,3.03996023436,3.58619824544,3.48307990672,3.3612421795,3.07626960208,
2571
2.81981383874,1.98193838831,1.90583370063,1.07250880414,2.30853498234,3.11088115492,2.23483480691,2.07140142638,2.24815064073,2.58424076716,2.31104046775,2.45497281858,2.80554759615,
2572
3.60739012899,2.80101122303,2.58565178766,2.12601351281,3.07448027243,3.14137320402,3.14103823659,3.04558254805,2.1569545936,3.55056799062,3.51515136115,3.08363522025,3.4278209239,
2573
2.97324083415,2.54041473628,2.34808279686,1.94752907913,3.35523863872,2.54375424472,1.91440936235,2.65508952741,1.84512898397,2.34460425562,2.65246823604,2.24993829597,2.6681375693,
2574
3.71197473245,2.76679235419,2.67563833617,2.41973188812,3.61653418302,3.33807975298,3.3308566137,2.94291803336,3.22680775532,3.18208582924,3.30801987425,3.07653135596,3.04497763201,
2575
4.93786345433,3.38771616266,3.99497120347,3.23784987999,4.45670414797,4.40268597104,4.13631711029,4.05655342404,3.50958954092,4.22664236344,4.61098742563,4.28431977818,4.36904808611,
2576
3.87021305755,2.76399585849,2.92210100741,2.10483500742,3.40517585471,3.69210574976,2.73336360074,3.08836757224,2.74376609144,2.86725301558,3.21876386544,3.23675928141,3.36614499086,
2577
3.35424242099,2.79757928588,2.4481975096,2.02189521948,2.68036861204,3.02307209336,2.59938603482,2.66027607841,2.67453913652,2.59632482852,2.74075755356,3.25499819263,2.48948667867,
2578
4.46588650727,3.00725593652,3.67875053826,2.12441752137,3.47388514978,4.42337628884,3.24651236043,3.9018061952,2.85747918453,3.67205924769,3.34116258093,4.34866165224,4.23236717835,
2579
4.27772913177,2.35801305817,3.26930361625,1.97332274016,3.40001269977,3.9742288443,2.85264034622,2.78769279955,3.03100114892,3.62413619831,3.38184968341,3.30046665156,3.78940564902,
2580
2.56493240515,1.95643360563,2.19159367672,2.07111845441,2.85056719548,3.33714156529,3.02928329632,2.63498565823,2.56752902929,2.92957977068,3.11944672685,2.69350259607,2.76173825905,
2581
3.13016537508,2.22890041969,2.47344732538,1.55929623113,2.19790861852,3.36401833337,2.82578380071,2.76439415431,2.45617663226,2.50649982441,2.52088167253,3.2313182663,2.76671373086,
2582
4.29788080518,2.59873116073,3.2580433505,2.25287687684,3.48606217197,4.08035529893,3.16228977305,3.10482538871,3.458874146,3.32902133917,3.29514346712,3.54703945901,3.44719544193;
2584
1576
<t tx="gcross.20081204190733.8"></t>
2585
1577
<t tx="gcross.20081205110513.3">typedef void (*AMPISlaveFunction)(std::vector<Operation*>& arguments);