Skip to content

Commit

Permalink
Fixing failing gasnet tests due to domain.dist deprecation (chapel-la…
Browse files Browse the repository at this point in the history
…ng#22848)

Fixed 8 failing tests in all gasnet configurations caused due to chapel-lang#22823

[Reviewed by @vasslitvinov ]
  • Loading branch information
ShreyasKhandekar authored Jul 31, 2023
2 parents 61ec4b3 + 2fe1ff9 commit a159490
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 17 deletions.
4 changes: 2 additions & 2 deletions test/distributions/bharshbarg/fastFollowerEquality.chpl
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ proc test(DA : domain, DB : domain) {

proc test(A : [?DA], B : [?DB]) {
writeln("--- ", A.type:string, " vs. ", B.type:string, " ---");
DA.dist.displayRepresentation();
DA.distribution.displayRepresentation();
writeln();
DB.dist.displayRepresentation();
DB.distribution.displayRepresentation();
writeln();

if !zipRange {
Expand Down
2 changes: 1 addition & 1 deletion test/distributions/deitz/test_block_representation.chpl
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ var A: [{1..4, 1..4} dmapped Block(boundingBox={1..4,1..4},

writeln("Distribution Representation");
writeln();
A.domain.dist.displayRepresentation();
A.domain.distribution.displayRepresentation();

writeln();
writeln("Domain");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@ writeln(dist_eq(A3.domain.distribution, D3.distribution));
if distType == DistType.default then
writeln(true);
else
writeln(dist_neq(A4.domain.dist, D1.dist));
writeln(dist_neq(A4.domain.distribution, D1.distribution));
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ writeln(dist_eq(Dom2D32.distribution, Dist2D32));
if distType == DistType.default then
writeln(true);
else
writeln(dist_neq(Dom2D32.dist, Dist2D));
writeln(dist_neq(Dom2D32.distribution, Dist2D));
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ writeln(dist_eq(A2D32.domain.distribution, Dist2D32));
if distType == DistType.default then
writeln(true);
else
writeln(dist_neq(A1D.domain.dist, {1..n1}.dist));
writeln(dist_neq(A1D.domain.distribution, {1..n1}.distribution));
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ proc dfft(A: [?ADom], W, cyclicPhase) {
// lo.. by str #num == lo, lo+str, lo+2*str, ... lo+(num-1)*str
//
forall lo in bankStart..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local do butterfly(wk1, wk2, wk3, A.localSlice(lo..by str #radix));

//
Expand All @@ -200,7 +200,7 @@ proc dfft(A: [?ADom], W, cyclicPhase) {
// loop in parallel over the high bank, computing butterflies
//
forall lo in bankStart+span..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local do butterfly(wk1, wk2, wk3, A.localSlice(lo.. by str #radix));
}
}
Expand All @@ -216,15 +216,15 @@ proc dfft(A: [?ADom], W, cyclicPhase) {
//
if (str*radix == numElements) {
forall lo in 0..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local do butterfly(1.0, 1.0, 1.0, A.localSlice(lo.. by str # radix));
}
//
// ...otherwise using a simple radix-2 butterfly scheme
//
else
forall lo in 0..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local {
const a = A(lo),
b = A(lo+str);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ proc dfft(A: [?ADom], W, cyclicPhase) {
// lo.. by str #num == lo, lo+str, lo+2*str, ... lo+(num-1)*str
//
forall lo in bankStart..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local do butterfly(wk1, wk2, wk3, A.localSlice(lo..by str #radix));

//
Expand All @@ -340,7 +340,7 @@ proc dfft(A: [?ADom], W, cyclicPhase) {
// loop in parallel over the high bank, computing butterflies
//
forall lo in bankStart+span..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local do butterfly(wk1, wk2, wk3, A.localSlice(lo.. by str #radix));
}
}
Expand All @@ -356,15 +356,15 @@ proc dfft(A: [?ADom], W, cyclicPhase) {
//
if (str*radix == numElements) {
forall lo in 0..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local do butterfly(1.0, 1.0, 1.0, A.localSlice(lo.. by str # radix));
}
//
// ...otherwise using a simple radix-2 butterfly scheme
//
else
forall lo in 0..#str do
on ADom.dist.idxToLocale(lo) do
on ADom.distribution.idxToLocale(lo) do
local {
const a = A(lo),
b = A(lo+str);
Expand Down
6 changes: 3 additions & 3 deletions test/performance/ferguson/cyclic-id-queries.chpl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ start();
coforall loc in Locales do on loc {
coforall tid in 1..here.maxTaskPar {
for i in cyclicSpace {
var locid = cyclicDom.dist.idxToLocale(i).id;
var locid = cyclicDom.distribution.idxToLocale(i).id;
}
}
}
Expand All @@ -36,7 +36,7 @@ start();
coforall loc in Locales do on loc {
coforall tid in 1..here.maxTaskPar {
for i in cyclicSpace {
var loc = cyclicDom.dist.idxToLocale(i);
var loc = cyclicDom.distribution.idxToLocale(i);
var locID = chpl_nodeFromLocaleID(__primitive("_wide_get_locale", loc));
assert(cyclicArr[i].locale == Locales[locID]);
}
Expand All @@ -46,7 +46,7 @@ stop();
report(maxGets=0, maxOns=1);

inline proc getLocale(dom, idx) {
var loc = dom.dist.idxToLocale(idx);
var loc = dom.distribution.idxToLocale(idx);
var locID = chpl_nodeFromLocaleID(__primitive("_wide_get_locale", loc));

// Handles cases where we get a locale that is allocated on another locale...
Expand Down

0 comments on commit a159490

Please sign in to comment.